Changeset 11604
- Timestamp:
- Nov 27, 2017, 4:29:35 PM (7 years ago)
- Location:
- code/branches/ProtectBoss_HS17
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/ProtectBoss_HS17/data/levels/ProtectBoss.oxw
r11585 r11604 11 11 include("templates/lodInformation.oxt") 12 12 include("templates/HeavyCruiser.oxt") 13 include("HUDPickupTemplate.oxo") 14 include("templates/pickupRepresentationTemplates.oxt") 15 include("includes/pickups.oxi") 13 16 ?> 14 17 … … 58 61 team = 0 59 62 collisionType = kinematic 63 enablecollisiondamage=true 64 collisiondamage = 10 60 65 position = "0,0,-2500" 61 mass = 10000 66 mass = 100000 62 67 health = 1000 initialhealth=1000 maxhealth="1000" 63 68 direction = "1,0,0" 64 69 rotationaxis="0,0,1" rotationrate="4.5" velocity="0,0,30" 70 vulnerable=true 65 71 name = "CargoShip" 66 72 radarname = "Cargo Ship" > … … 107 113 <DistanceTrigger name="passedAsteroidFieldOne" beaconMode=identify position="0,0,3000" distance=1000 target="Pawn" targetname="CargoShip" /> 108 114 115 <!-- triggers when first pirate wave is defeated --> 116 <Trigger name="firstPirateWaveKilled" mode="and"> 117 <EventTrigger activations="1" stayactive="true" > 118 <events> 119 <trigger> 120 <EventListener event="p1" /> 121 </trigger> 122 </events> 123 </EventTrigger> 124 <EventTrigger activations="1" stayactive="true" > 125 <events> 126 <trigger> 127 <EventListener event="p2" /> 128 </trigger> 129 </events> 130 </EventTrigger> 131 <EventTrigger activations="1" stayactive="true" > 132 <events> 133 <trigger> 134 <EventListener event="p3" /> 135 </trigger> 136 </events> 137 </EventTrigger> 138 </Trigger> 139 109 140 <!-- create asteroids --> 110 141 <?lua 142 function asteroidMesh() 143 x = math.random(8) 144 if x < 7 then 145 return "ast" .. x .. ".mesh" 146 elseif x == 7 then 147 return "asteroid_ice.mesh" 148 else 149 return "asteroid_UV.mesh" 150 end 151 end 152 111 153 for count = 1, 30, 1 do 112 154 x = math.random(-1000, 1000) … … 121 163 vz = math.random(-vmax, vmax) 122 164 rr = math.random() * 10 123 print("<Pawn team=1 health=30 position=\"" .. x .. "," .. y .. "," .. z .. "\" direction=\"0,0,-1\" velocity=\"" .. vx .. "," .. vy .. "," .. vz .. "\"rotationaxis=\"" .. rx .. "," .. ry .. "," .. rz .. "\" rotationrate=" .. rr .. " collisionType=dynamic mass=1 name=asteroid radarname=Asteroid> <!--events> <visibility> <EventListener event=flying4 /> </visibility> </events--> <attached> <Model position=\"0,0,0\" mesh=\"ast" .. math.random(6) .. ".mesh\" scale3D=\"10,10,10\" /> </attached> <collisionShapes> <SphereCollisionShape position=\"0,0,0\" radius=5 /> </collisionShapes> <!--controller> <WaypointController team=1> </WaypointController> </controller--> <explosion> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_flash2\" effect2=\"orxonox/explosion_flame2\" /> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_shockwave2\" effect2=\"orxonox/explosion_sparks2\" /> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_streak2\" effect2=\"orxonox/explosion_afterglow\" /> </explosion> </Pawn>") 165 print("<Pawn team=1 health=30 position=\"" .. x .. "," .. y .. "," .. z .. "\" direction=\"0,0,-1\" velocity=\"" .. vx .. "," .. vy .. "," .. vz .. "\"rotationaxis=\"" .. rx .. "," .. ry .. "," .. rz .. "\" rotationrate=" .. rr .. " collisionType=dynamic mass=1 name=asteroid radarname=Asteroid> <attached> <Model position=\"0,0,0\" mesh=\"" .. asteroidMesh() .. "\" scale3D=\"10,10,10\" /> </attached> <collisionShapes> <SphereCollisionShape position=\"0,0,0\" radius=5 /> </collisionShapes> <controller> <WaypointController team=1> </WaypointController> </controller> <explosion> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_flash2\" effect2=\"orxonox/explosion_flame2\" /> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_shockwave2\" effect2=\"orxonox/explosion_sparks2\" /> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_streak2\" effect2=\"orxonox/explosion_afterglow\" /> </explosion> </Pawn>") 166 end 167 168 for count = 1, 20, 1 do 169 x = math.random(-1000, 1000) 170 y = math.random(-1000, 1000) 171 z = 125 * count + math.random(-250, 250) 172 typenum = math.random(7) 173 type = "" 174 if typenum == 1 then 175 type = "smallmunition" 176 elseif typenum == 2 then 177 type = "mediummunition" 178 elseif typenum == 3 then 179 type = "hugemunition" 180 elseif typenum == 4 then 181 type = "smallhealth" 182 elseif typenum == 5 then 183 type = "mediumhealth" 184 elseif typenum == 6 then 185 type = "hugehealth" 186 else 187 type = "crazyhealth" 188 end 189 type = type .. "pickup" 190 --[[print("<PickupSpawner pickup=\"" .. "mediumhealth" .. "\" position=\"" .. x .. "," .. y .. "," .. z .. "\" triggerDistance=10 respawnTime=5 maxSpawnedItems=1 />")]] 124 191 end 125 192 ?> 193 194 <!--PickupSpawner pickup=mediumhealthpickup position="0,0,-125" triggerDistance="10" respawnTime="5" maxSpawnedItems="1" /--> 195 <!--PickupSpawner pickup=smallshieldpickup position="-25,-25,-125" triggerDistance="10" respawnTime="5" maxSpawnedItems="10" /--> 126 196 127 197 <!-- start first quest --> … … 185 255 </SimpleNotification> 186 256 187 <!-- A function to put pirates to a certain location --> 257 <SimpleNotification message="A second pirate wave is approaching!" broadcast=true > 258 <events> 259 <trigger> 260 <EventListener event="firstPirateWaveKilled" /> 261 </trigger> 262 </events> 263 </SimpleNotification> 264 265 266 <!-- A function to put pirates and asteroids to a certain location --> 188 267 <?lua 189 function placePirate(posX, posY, posZ, trigger) 190 print("<SpaceShip mass=10 position=\"" .. posX .. "," .. posY .. "," .. posZ .. "\" name=Pirate radarname=Pirate><events><visibility><EventListener event=\"" .. trigger .. "\"/></visibility><activity><EventListener event=\"" .. trigger .. "\"/></activity></events><templates><Template link=spaceshippirate /></templates><controller><WaypointPatrolController alertnessradius=3129 team=1 active=false><waypoints><Model mesh=\"cube.mesh\" scale=0 position=\"-1300,-600,900\" /><Model mesh=\"cube.mesh\" scale=0 position=\"0,0,0\" /></waypoints><events><activity><EventListener event=attack /></activity></events></WaypointPatrolController></controller></SpaceShip>") 268 function placePirate(posX, posY, posZ, name, trigger) 269 print("<SpaceShip mass=10 health=25 initialhealth=25 maxhealth=25 shieldhealth=10 maxshieldhealth=10 initialshieldhealth=10 shieldabsorption=0.3 shieldrechargerate=1 shieldrechargewaittime=1 primaryThrust=40 auxiliaryThrust=15 rotationThrust=10 boostpower=5 boostrate=2 boostCooldownDuration = 20 position=\"" .. posX .. "," .. posY .. "," .. posZ .. "\" name=\"" .. name .. "\" radarname=Pirate><events><visibility><EventListener event=\"" .. trigger .. "\"/></visibility><activity><EventListener event=\"" .. trigger .. "\"/></activity></events><templates><Template link=spaceshippirate /></templates><controller><WaypointPatrolController alertnessradius=3129 team=1 active=false><waypoints><Model mesh=\"cube.mesh\" scale=0 position=\"-1300,-600,900\" /><Model mesh=\"cube.mesh\" scale=0 position=\"0,0,0\" /></waypoints><events><activity><EventListener event=attack /></activity></events></WaypointPatrolController></controller></SpaceShip>") 270 end 271 272 function placeAsteroid(posX, posY, posZ, vx, vy, vz, trigger) 273 rx = math.random(-vmax, vmax) 274 ry = math.random(-vmax, vmax) 275 rz = math.random(-vmax, vmax) 276 rr = math.random() * 10 277 print("<Pawn team=1 health=30 position=\"" .. posX .. "," .. posY .. "," .. posZ .. "\" direction=\"0,0,-1\" velocity=\"" .. vx .. "," .. vy .. "," .. vz .. "\"rotationaxis=\"" .. rx .. "," .. ry .. "," .. rz .. "\" rotationrate=" .. rr .. " collisionType=dynamic mass=1 name=asteroid radarname=Asteroid> <events> <visibility> <EventListener event=\"" .. trigger .. "\" /> </visibility> </events> <attached> <Model position=\"0,0,0\" mesh=\"" .. asteroidMesh() .. "\" scale3D=\"10,10,10\" /> </attached> <collisionShapes> <SphereCollisionShape position=\"0,0,0\" radius=5 /> </collisionShapes> <!--controller> <WaypointController team=1> </WaypointController> </controller--> <explosion> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_flash2\" effect2=\"orxonox/explosion_flame2\" /> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_shockwave2\" effect2=\"orxonox/explosion_sparks2\" /> <ExplosionPart minspeed=0 maxspeed=0 effect1=\"orxonox/explosion_streak2\" effect2=\"orxonox/explosion_afterglow\" /> </explosion> </Pawn>") 191 278 end 192 279 ?> 193 280 194 281 <?lua 195 placePirate(0, 0, 5500, "passedAsteroidFieldOne") 196 placePirate(0, 0, 6500, "passedAsteroidFieldOne") 197 placePirate(0, 0, 7500, "passedAsteroidFieldOne") 282 placeAsteroid(0, 0, -1000, 0, 0, 0, "spawntrigger") 283 placeAsteroid(0, 0, -1100, 0, 0, 0, "spawntrigger") 284 placeAsteroid(0, 0, -1200, 0, 0, 0, "spawntrigger") 285 placeAsteroid(0, 0, -1300, 0, 0, 0, "spawntrigger") 286 placeAsteroid(0, 0, -1400, 0, 0, 0, "spawntrigger") 287 placeAsteroid(0, 0, -1500, 0, 0, 0, "spawntrigger") 288 placePirate(0, 0, 5500, "p1", "spawntrigger") 289 placePirate(0, 0, 6500, "p2", "spawntrigger") 290 placePirate(0, 0, 7500, "p3", "spawntrigger") 291 placePirate(0, 0, 5500, "p11", "firstPirateWaveKilled") 292 placePirate(0, 0, 5600, "p12", "firstPirateWaveKilled") 293 placePirate(0, 0, 5700, "p13", "firstPirateWaveKilled") 294 placePirate(0, 0, 5800, "p14", "firstPirateWaveKilled") 295 placePirate(0, 0, 5900, "p15", "firstPirateWaveKilled") 296 placePirate(0, 0, 6000, "p16", "firstPirateWaveKilled") 198 297 ?> 199 298 -
code/branches/ProtectBoss_HS17/src/orxonox/worldentities/pawns/CMakeLists.txt
r10216 r11604 7 7 TeamBaseMatchBase.cc 8 8 Destroyer.cc 9 ShootableObstacle.cc 9 10 )
Note: See TracChangeset
for help on using the changeset viewer.