This code was posted by Gunner98, created by another member of the forum.
Code: Select all
local temp= math.random(18,24)
local rain= math.random(0,3)
local cloud= math.random(0,3)/10.0
local sea= math.random(1,4)
ScenEdit_SetWeather(temp,rain, cloud, sea)
ScenEdit_SpecialMessage('Russia', '<P><FONT size=2 face="Courier New">COMMANDER,</P><P>NEW WX REPORT,</P> TEMPERATURE: ' .. temp .. ' DEGREES CELSIUS, RAIN STATE: ' .. rain .. ' CLOUD LEVEL: ' .. cloud .. ' AND SEA STATE: ' .. sea)
ScenEdit_SpecialMessage('US', '<P><FONT size=2 face="Courier New">COMMANDER,</P><P>NEW WX REPORT,</P> TEMPERATURE: ' .. temp .. ' DEGREES CELSIUS, RAIN STATE: ' .. rain .. ' CLOUD LEVEL: ' .. cloud .. ' AND SEA STATE: ' .. sea)Tested it and apparently is adding 10°C to the value randomly generated for most of the map, in some areas minus 10 and the less frecuent is the random value.
Is it a bug? The value should be the same for all the map? The other variables seem to be stable along the map and according to the random value.