#Change default weather effect

1 messages · Page 1 of 1 (latest)

drowsy nimbus
#

How can I use valve's snow weather and set it as default? Re writing user custom weather with snow is also okay.

Found this command (SetCustomTerrainWeatherEffect(effectName: string)) and here's how I use it:

WINTER_PARTICLE = "particles/winter_fx/weather_frostivus_snow.vpcf"
    PrecacheResource("particle", WINTER_PARTICLE, context)
...
-------------------------------------------------------------------------
--- Set forced winter weather effect.
-------------------------------------------------------------------------
function SetWinterWeather()
    GameMode:SetCustomTerrainWeatherEffect(WINTER_PARTICLE)
end

...
if currentState == DOTA_GAMERULES_STATE_GAME_IN_PROGRESS then
   SetWinterWeather()

It also doesn't have to be this specific particle, I was just trying different options out.

I wonder why it doesn't work..

surreal briar
#

You might call it too late or its just broken. You can also just find out what particle used in that weather and create it every time player connects

distant grove
#

in lua its broken

#

but you can change weather effect in hummer

#

find weather entities they are at fountain

#

they named ent_dota_lightinfo

burnt ginkgo
#

if you prefer to do it manually, you need to attach the weather particle to PATTACH_EYES_FOLLOW (this is the player's camera attachment), since the way the weather effect works is that it spawns (and culls) particles in a sphere that is attached to the camera.

But yea, alternatively, follow iWas_inMineDream's suggestion and change the default weather property to use the weather particle you want, in the ent_dota_lightinfo in your map

opal phoenix
drowsy nimbus
drowsy nimbus
drowsy nimbus
burnt ginkgo
#

with code

#

sorry if that wasn't obvious