Wind extractor
From Spring
Jump to navigationJump to searchRead the wind speed and direction from the map randomiser
the battle seting or map maker define a wind minimal and maximal speed
so when the values are not equal its a gambling
and generaly this values is used for being converted in energy by "elolienne"
(seem english not use them...)
- winddirX,winddirY,winddirZ,windstrength,windnormDirX,windnormDirY,windnormDirZ=Spring.GetWind()
- rotorspeed=windstrength/5
- Spring.UnitScript.Spin(rotor,z_axis,rotorspeed,0.3)
- windradian=Spring.GetHeadingFromVector(windnormDirX,windnormDirZ)
- Turn(turet,y_axis,windradian,rotorspeed)
- because windspeed is from 1 to 99 is often needed to divide it
- because the wind direction is gived as vector it must be converted in radian for turet direction
- SpringRtsTutorialAnimDef return to the list of animDef exemples