1
Fork 0
mirror of https://github.com/redstrate/Kawari.git synced 2025-05-12 14:47:46 +00:00
kawari/resources/scripts/common/GenericWarp.lua
Joshua Goins e237cbe84d Create GenericWarp script to handle simple warps
It turns out that most warps are just a yes/no, and can be handled by
one single script. I scripted the lift attendants from Bulwark Hall <->
Airship Landing <-> Drowning Wench this way.
2025-05-05 23:30:36 -04:00

14 lines
328 B
Lua

-- generic warp, use this for most warps that are just a yes/no option
function onTalk(target, player)
player:play_scene(target, EVENT_ID, 00000, 8192, 0)
end
function onReturn(scene, results, player)
player:finish_event(EVENT_ID)
if results[1] == 1 then
-- get warp
player:warp(EVENT_ID)
end
end