diff options
Diffstat (limited to 'gamemode/events/weather_event.lua')
| -rw-r--r-- | gamemode/events/weather_event.lua | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/gamemode/events/weather_event.lua b/gamemode/events/weather_event.lua new file mode 100644 index 0000000..f7640fe --- /dev/null +++ b/gamemode/events/weather_event.lua @@ -0,0 +1,39 @@ + +local EVENT = {} + +EVENT.Chance = 0.95 +EVENT.Type = EVENT_WEATHER + +EVENT.Types = {} +EVENT.Types[1] = "rain" +EVENT.Types[2] = "thunder" +EVENT.Types[3] = "lightning" +EVENT.Types[4] = "strong winds" + +function EVENT:Start() + + GAMEMODE:RandomizeWeather( true ) + + for k,v in pairs( team.GetPlayers( TEAM_ARMY ) ) do + + v:Notice( "The weather conditions are worsening", GAMEMODE.Colors.White, 5 ) + + end + +end + +function EVENT:Think() + +end + +function EVENT:EndThink() + + return true // true ends this immediately + +end + +function EVENT:End() + +end + +event.Register( EVENT ) |
