Exports and events
Start a fire from your own resource
TriggerEvent("FireScriptV2:StartFireExternal", x, y, z, flames, spread, firetype, location)TriggerEvent("FireScriptV2:StartFireExternal", 100.0, 200.0, 30.0, 20, 5, "chemical", "Refinery")Feed live wind and weather in
TriggerEvent('FireScriptV2:SetWind', directionDegrees, strength0to1)
TriggerEvent('FireScriptV2:SetWeatherWet', true)TriggerEvent('FireScriptV2:SetWind', 270.0, 0.8)If a weather resource is pushing values in withSetWeatherWet, turnConfig.Weather.AutoDetectoff or the two will fight.
Read the current wind
local wind = exports.firescriptv2:GetWind()
-- { degrees, strength, wet }Put fires out from your own script
Raise this client-side and any burning flame inside the radius is knocked down:
TriggerEvent('FireScriptV2:WaterHit', x, y, z, radius)This is exactly how Fire Hose V2 does it — the hose raises FireHoseV2:WaterHit on every client for every sprayer, and FireScript listens. That single event is the whole contract between the two resources.
Whether a knocked-down flame flares back up is a roll the server makes, so everyone sees the same result at the same moment.
Can't find what you need? Ask on Discord — response in under 5 hours.
