Added and used a new trigger without recompiling, scripting really works. :)

This commit is contained in:
Steffen Fündgens 2015-01-13 17:52:31 +01:00
parent b483cb2eb9
commit c6d4e1d916
2 changed files with 14 additions and 3 deletions

View File

@ -26,16 +26,16 @@
<toChangeObjNum>0</toChangeObjNum>
</trigger>
<trigger>
<name>deleteRandomObjectAtTorch</name>
<name>deleteMarbleAtTorch</name>
<xPosition>0.0</xPosition>
<yPosition>0.0</yPosition>
<zPosition>0.0</zPosition>
<targetIdGreen>1</targetIdGreen>
<targetIdBlue>3</targetIdBlue>
<distance>2.0</distance>
<distance>2.5</distance>
<isBiggerThan>false</isBiggerThan>
<objectNum>0</objectNum>
<luaScript>deleteRandomObject</luaScript>
<luaScript>deleteObject</luaScript>
<toChangeIdGreen>1</toChangeIdGreen>
<toChangeIdBlue>5</toChangeIdBlue>
<toChangeObjNum>0</toChangeObjNum>

View File

@ -0,0 +1,11 @@
function trigger(objectToChange)
if(not level) then
print("No level found in Lua!")
return
end
if(not physics) then
print("No physics found in Lua!")
return
end
level:deleteObject(objectToChange)
end