#248 LUA Support for using a door (widget)

بسته‌شده
3 سال پیش باز شده توسط image · 0 دیدگاه
  • new SpawnScripts function 'usedoor' function usedoor(NPC, Spawn, IsOpen) LUA Functions additionally needed:
  • OpenDoor, CloseDoor, IsOpen

Example script:

function usedoor(NPC, Spawn, IsOpen)
    if IsOpen == true then
        if Spawn then
            SendMessage(Spawn, "Door was open", "red")
        end
        
        CloseDoor(NPC)
    else
        if Spawn then
            SendMessage(Spawn, "Door was closed", "red")
        end
        
        OpenDoor(NPC)
    end
end
- new SpawnScripts function 'usedoor' ```function usedoor(NPC, Spawn, IsOpen)``` LUA Functions additionally needed: - OpenDoor, CloseDoor, IsOpen Example script: ``` function usedoor(NPC, Spawn, IsOpen) if IsOpen == true then if Spawn then SendMessage(Spawn, "Door was open", "red") end CloseDoor(NPC) else if Spawn then SendMessage(Spawn, "Door was closed", "red") end OpenDoor(NPC) end end ```
image 3 سال پیش بسته شد
برای پیوستن به گفتگو، وارد شودید.
درحال بارگذاری...
لغو
ذخيره
هنوز محتوایی ایجاد نشده.