2015-02-15 15:11:31 +00:00
|
|
|
local global = require( "global" )
|
|
|
|
if(global.triggeredOpenFirstDoor == nil) then
|
|
|
|
global.triggeredOpenFirstDoor = false
|
2015-02-13 18:24:57 +00:00
|
|
|
end
|
|
|
|
function trigger(objectToChange)
|
2015-02-15 15:11:31 +00:00
|
|
|
if(global.triggeredOpenFirstDoor == false) then
|
2015-02-13 18:24:57 +00:00
|
|
|
if(not level) then
|
|
|
|
print("No level found in Lua!")
|
|
|
|
return
|
|
|
|
end
|
|
|
|
|
|
|
|
local strength = 100
|
|
|
|
local xPos = 81.5
|
2015-02-13 23:40:52 +00:00
|
|
|
local yPos = 35
|
2015-02-13 18:24:57 +00:00
|
|
|
local zPos = 17.5
|
|
|
|
level:moveObject(objectToChange, strength, xPos, yPos, zPos)
|
|
|
|
|
2015-02-15 15:11:31 +00:00
|
|
|
global.triggeredOpenFirstDoorUndo = false
|
2015-02-13 18:24:57 +00:00
|
|
|
|
2015-02-15 15:11:31 +00:00
|
|
|
global.triggeredOpenFirstDoor = true
|
2015-02-13 18:24:57 +00:00
|
|
|
print("openFirstDoor")
|
|
|
|
end
|
|
|
|
end
|