The rect where the weather will be visible.
(Rawcode) Which weather preset to apply.
Creates a weather effect that is spatially limited to the specified area.
This creates a new object and returns its handle, to prevent leaks it must be destroyed with
RemoveWeatherEffectwhen no longer needed.
The weather effect is created initially disabled and must be turned on with
Example (Lua): to create an "Ashenvale Heavy Rain" at map center:
center = Rect(-1024, -1024, 1024, 1024) weather = AddWeatherEffect(center, FourCC("RAhr")) EnableWeatherEffect(weather, true)
To understand more about weather effects nature, I advise to read Ammorth's article about weather effects: http://www.wc3c.net/showthread.php?t=91176.
To get an idea on how to add your own weather effects, you may read CryoniC's article about custom weather effects: http://www.wc3c.net/showthread.php?t=67949.
The weather effects are defined in
terrainart/weather.slkin game files. The current default list is here (v1.32.10).
- return type
- Source code
native AddWeatherEffect takes rect where, integer effectID returns weathereffect