evilmarshmallow Posted July 7, 2025 Share Posted July 7, 2025 How can I make a custom character take damage in the rain similar to wx-78? I've tried checking out their prefab file and tried searching around but nothing seems to have worked. Link to comment https://forums.kleientertainment.com/forums/topic/166868-help-with-rain-damage/ Share on other sites More sharing options...
PROfessor13 Posted July 28, 2025 Share Posted July 28, 2025 You can probably check with a if TheWorld.state.israining then inst.components.health:SetRegen(amount, ticks) else inst.components.health:StopRegen() end Just create a local function and run it from either DoPeriodicTask(ticks, function) or maybe (and I haven’t tested it) WatchWorldState(“weather”, function) Also it will stop all sources of regen (example: jellybeans) so look into wurt’s lua file to figure out how their when wet regen function works Link to comment https://forums.kleientertainment.com/forums/topic/166868-help-with-rain-damage/#findComment-1829177 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now