Changeset 11932 for code/branches/ScriptableController_FS18/data/levels
- Timestamp:
- May 3, 2018, 3:16:09 PM (7 years ago)
- Location:
- code/branches/ScriptableController_FS18/data/levels
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/ScriptableController_FS18/data/levels/BBBScriptableControllerTest.oxw
r11928 r11932 33 33 34 34 35 <AAAAutonomousDrone id=" Dummy" position="0,0,0" primarythrust="80" auxilarythrust="10" rotationthrust="10" mass= "50" linearDamping = "0.9" angularDamping = "0.7">35 <AAAAutonomousDrone id="dummy" position="0,0,0"> 36 36 <attached> 37 37 <Model scale="10" mesh="drone.mesh"/> 38 38 </attached> 39 <collisionShapes> 40 <BoxCollisionShape position="0,0,0" halfExtents="10, 10, 10" /> 41 </collisionShapes> 39 42 </AAAAutonomousDrone> 40 43 -
code/branches/ScriptableController_FS18/data/levels/scripts/BBBScriptableControllerTest.lua
r11928 r11932 1 1 2 rotate_factor = 0 3 station_loc = 200 4 station_speed = 0 2 id = "dummy" 5 3 6 id = "Dummy"7 8 function spawn_station(obj)9 orxPrint("Spawning station")10 setPosition("Station", 500, 0, 0)11 setOrientation("Station", 0, -1, 0, 0)12 end13 14 function rotate_faster(obj1, obj2, health, shield)15 orxPrint("Rotating station faster")16 17 rotate_factor = rotate_factor + 0.0218 setAngularVelocity("Station", rotate_factor, 0, 0)19 end20 4 21 5 … … 46 30 function move_dummy() 47 31 orxPrint("Moving dummy!") 48 moveControllableEntity(id, 1 00.0, 0.0, 0.0)32 moveControllableEntity(id, 1.0, 0.0, 0.0) 49 33 end 50 34 … … 56 40 57 41 58 function next_station_loc(obj1, obj2)59 orxPrint("Moving station")60 61 station_loc = station_loc + 50062 setPosition("Station", station_loc, 0, 0)63 64 station_speed = station_speed + 565 setVelocity("Station", -station_speed, 0, 0)66 67 registerAtNearObject(next_station_loc, "Player", "Station", 200)68 end69 42 70 43 44 move_dummy_after_timeout(5) 45 kill_dummy_after_timeout(10) 71 46 72 73 74 move_dummy_after_timeout(3)75 kill_dummy_after_timeout(6)76 47 77 48 orxPrint("Script started! OMG ROFL LOL WTF")
Note: See TracChangeset
for help on using the changeset viewer.