• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Weather system trigger with moveevent

ralke

(҂ ͠❛ ෴ ͡❛)ᕤ
Joined
Dec 17, 2011
Messages
1,759
Solutions
31
Reaction score
999
Location
Santiago - Chile
GitHub
ralke23
Twitch
ralke23
Hi again, I want to request a thing for this weather system… Using TFS 1.3 8.6 Nekiro's...
I need it to be triggered by StepIn after you hit a certain tile, I dont know if is necessary to make two scripts for it, one with StepIn event that turn on the system, and other for turn it off (in a different tile). To avoid stepping Out to a zone that is not going to have weather active (in the hypothetical case of using only one tile). Here is the system script, atm i know onThink function should be replaced for onStepIn to make it work that way:

LUA:
function onThink(interval, lastExecution)
local players = Game.getPlayers()
if #players == 0 then
return true
end

local player
for i = 1, #players do
player = players[i]
player:sendWeatherEffect(weatherConfig.groundEffect, weatherConfig.fallEffect, weatherConfig.thunderEffect)
end
return true
end

And image to explain it better, do it like a "weather toll":

weather.png

Thanks in advance!!
 
Last edited:
Back
Top