Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/notifications/data/levels/Fight in our Back.oxw @ 7441

Last change on this file since 7441 was 7354, checked in by dafrick, 14 years ago

Started work on edit mode. ConsoleCommand is not yet working.
Some additional cleanup. All the NotificationQueues generated by the NotificationManager now are destroyed upon destruction of the NotificationManager.
Removed NotificationQueue from level files.

  • Property svn:eol-style set to native
File size: 20.2 KB
Line 
1<?lua
2    include("stats.oxo")
3    include("hudtemplates3.oxo")
4    include("templates/lodinformation.oxt")
5    include("templates/spaceship_assff.oxt")
6    include("templates/spaceship_pirate.oxt")
7    include("templates/spaceship_Transporter.oxt")
8?>
9
10<!--*****************************************************************************************************************************************************************************************-->
11<!--Including Template for triggering on player-->
12
13<Template name=spaceshipassffplayer>
14  <SpaceShip
15   hudtemplate            = spaceshiphud
16   camerapositiontemplate = spaceshipassffcameras
17   engine                 = spaceshipassffengine
18   spawnparticlesource    = "Orxonox/fairytwirl"
19   spawnparticleduration  = 3
20   explosionchunks        = 6
21
22   health            = 100
23   maxhealth         = 200
24   initialhealth     = 100
25
26   primaryThrust     = 100;
27   auxilaryThrust    = 30;
28   rotationThrust    = 25;
29
30   collisionType     = "dynamic"
31   mass              = 100
32   linearDamping     = 0.7
33   angularDamping    = 0.9999999
34  >
35    <attached>
36      <Model position="0,0,0" yaw=90 pitch=-90 roll=0 scale=4 mesh="assff.mesh" />
37      <BlinkingBillboard position="17,-1.5,0" material="Examples/Flare" colour="1.0, 0.5, 0.3" amplitude=0.1 frequency=0.5 quadratic=1 />
38      <BlinkingBillboard position="-17,-1.5,0" material="Examples/Flare" colour="0.5, 1.0, 0.3" amplitude=0.1 frequency=0.5 phase=180 quadratic=1 />
39      <DistanceTriggerBeacon name="PlayerDistanceTrigger" /> <!--added DistanceTrigger-->
40    </attached>
41    <collisionShapes>
42      <BoxCollisionShape position="0,0,0"      halfExtents="10, 3, 5" />
43      <BoxCollisionShape position="13,-1.3,0"  halfExtents="3, 1, 2" />
44      <BoxCollisionShape position="-13,-1.3,0" halfExtents="3, 1, 2" />
45      <BoxCollisionShape position="0,0,7"      halfExtents="3, 2, 2" />
46      <BoxCollisionShape position="0,0.1,-11"  halfExtents="2.2, 1.8, 6" />
47      <BoxCollisionShape position="0,0.1,-19"  halfExtents="1.4, 1, 2" />
48    </collisionShapes>
49<?lua
50  include("includes/weaponsettings3.oxi")
51?>
52  </SpaceShip>
53</Template>
54
55<!--*****************************************************************************************************************************************************************************************-->
56<Level
57  name="Fight in our back"
58  description="Our fleet is far ahead of us. We need to get rid of all the enemies in its back, because we do not want our enemies to attack from everywhere. So let us clear this Sector!"
59  gametype=TeamDeathmatch
60>
61  <templates>
62    <Template link=lodtemplate_default />
63  </templates>
64
65    <!-- Ausgang: Szene ===> ambientlight/skybox -->
66    <Scene
67     ambientlight="0.8,0.8,0.8"
68     skybox="Orxonox/skypanoramagen1"
69    >
70
71        <!--Light: noch zu aendern -->
72        <Light type=directional position="0,0,0" direction="0, 0, 0" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 1.0, 0.9" />
73
74
75<!--*****************************************************************************************************************************************************************************************-->
76<!--Quests-->
77    <GlobalQuest id="FightInOurBack.DiscoveryMission_">
78        <QuestDescription title="Discovery mission" description="Your team has to scout out this sector." failMessage="You failed!" completeMessage="You won. You have reached the end of this level." />
79        <subquests>
80            <GlobalQuest id="FightInOurBack.FollowYourGroupLeader">
81                <QuestDescription title="Follow your group leader" description="Your task is to follow the team leader and to destroy all the enemy spaceships on your way!" failMessage="You failed!" completeMessage="Good job!" />
82            </GlobalQuest>
83            <GlobalQuest id="FightInOurBack.TransportersAhead">
84                <QuestDescription title="Transporters ahead" description="This is a lucky day for us. We have found supplies that the enemy is transporting in these Transporters. We have to destroy them." failMessage="You failed!" completeMessage="Good job!" />
85            </GlobalQuest>
86            <GlobalQuest id="FightInOurBack.TheySentUsAssistance">
87                <QuestDescription title="They sent us assistance" description="The transporters will surely be heavily protected but our base sent us assistance. It should now be easier to destroy them." failMessage="You failed" completeMessage="Good job!" />
88            </GlobalQuest>
89        </subquests>
90    </GlobalQuest>
91
92
93<!--Quests____END-->
94<!--*****************************************************************************************************************************************************************************************-->
95
96
97<!--Player's Spawnpoints -->
98        <!--Spieler Spawnpoint ===> position/direction--> <!-- funktioniert noch nicht ab naechtem Mal wahrscheinlich-->
99        <SpawnPoint position="0,50,25" direction="2000,0,-1000" spawnclass=SpaceShip pawndesign=spaceshipassffplayer team=0 active="true" >
100            <events>
101                <activity>
102                    <EventListener event="activateFirstSpawnpoint" />
103                </activity>
104            </events>
105        </SpawnPoint>
106
107        <SpawnPoint position="10000,0,3000" direction="2000,0,-1000" spawnclass=SpaceShip pawndesign=spaceshipassffplayer team=0 active="false" >
108            <events>
109                <activity>
110                    <EventListener event="activateSecondSpawnpoint" />
111                </activity>
112            </events>
113        </SpawnPoint>
114   
115<!--Player's Spawnpoint END-->
116
117<!--Launching Quests -->
118        <QuestEffectBeacon position="0,50,25" times="1">
119            <effects>
120                <AddQuest questId="FightInOurBack.DiscoveryMission_" />
121                <AddQuest questId="FightInOurBack.FollowYourGroupLeader" />
122            </effects>
123            <events>
124                <execute>
125                    <EventListener event="FightInOurBack_MainStart_FollowStart"/>
126                </execute>
127            </events>
128            <attached>
129                <DistanceTrigger name="FightInOurBack_MainStart_FollowStart" position="0,0,0" distance="50" target="DistanceTriggerBeacon" targetname="PlayerDistanceTrigger" />
130                <!--<Billboard position="0,0,0" colour="1.0,1.0,1.0" material="Examples/Flare" />-->
131            </attached>
132        </QuestEffectBeacon>
133
134        <QuestEffectBeacon position="8000,0,3100" times=1 >
135            <effects>
136                <AddQuest questID="FightInOurBack.TransportersAhead" />
137                <AddQuest questID="FightInOurBack.TheySentUsAssistance" />
138                <CompleteQuest questID="FightInOurBack.FollowYourGroupLeader" />
139            </effects>
140            <events>
141                <execute>
142                    <EventListener event="FightInOurBack_FollowEnd_DTranspStart_AssisStart" />
143                </execute>
144            </events>
145            <attached>
146                <!--<Billboard position="0,0,0" colour="1,1,1" material="Examples/Flare" />-->
147                <DistanceTrigger name="FightInOurBack_FollowEnd_DTranspStart_AssisStart" position="0,0,0" distance="1000" target="DistanceTriggerBeacon" targetname="PlayerDistanceTrigger" stayactive=1 activations=1 />
148            </attached>
149        </QuestEffectBeacon>
150   
151<!---->
152   
153<!--Launching Quests END -->
154
155<!--Creating Transporters OK-->
156
157
158<?lua for i=0,0,1 do
159x=800
160health=2750
161?>
162    <!--Transporter 1-->
163    <EventTrigger name="activateTeam1No1" acitvations=1 stayactive="true">
164    <events>
165    <trigger>
166        <SpaceShip position="<?lua print(3800-i*x) ?>,0,3000" lookat="<?lua print(4800-i*x) ?>,0,4000" health=<?lua print(health) ?> maxhealth=<?lua print(health) ?> initialhealth=<?lua print(health) ?> >
167            <templates>
168                   <Template link=spaceshipTransporter />
169             </templates>
170             <controller>
171                <WaypointPatrolController alertnessradius=1000 team=1>
172                    <waypoints>
173                        <Model mesh="cube.mesh" scale=0 position="<?lua print(14800-i*x) ?>,0,3000"/>
174                    </waypoints>
175                </WaypointPatrolController>
176             </controller>
177        </SpaceShip><!---->
178    </trigger>
179    </events>
180    </EventTrigger>
181<?lua end ?>
182
183
184<?lua for j=0,1,1 do
185health=1600
186x=800
187z=j*300
188?>
189    <!--Transporter 2,3-->
190    <EventTrigger name="activateTeam1No1" acitvations=1 stayactive="true">
191    <events>
192    <trigger>
193        <SpaceShip position="<?lua print(2600+x) ?>,0,<?lua print(3150-z) ?>" lookat="<?lua print(3500+x) ?>,0,<?lua print(4150-z) ?>" health=<?lua print(health) ?> maxhealth=<?lua print(health) ?> initialhealth=<?lua print(health) ?> >
194            <templates>
195                   <Template link=spaceshipTransporter />
196             </templates>
197             <controller>
198                <WaypointPatrolController alertnessradius=1000 team=1>
199                    <waypoints>
200                        <Model mesh="cube.mesh" scale=0 position="<?lua print(13500+x) ?>,0,<?lua print(3150-z) ?>"/>
201                    </waypoints>
202                </WaypointPatrolController>
203             </controller>
204        </SpaceShip><!---->
205    </trigger>
206    </events>
207    </EventTrigger>
208<?lua end ?>
209
210
211<!--Creating Transporters END _-->
212
213<!--Creating player's team OK-->
214        <!--Spaceships team 0 (player:team=0)-->
215        <SpaceShip position="50,0,0" lookat="2050,0,-1000" health="500" maxhealth="500" initialhealth="500" >
216             <templates>
217                  <Template link=spaceshipassff />
218            </templates>
219             <controller>
220                <WaypointPatrolController alertnessradius=2000 team=0 >
221                    <waypoints>
222                        <Model mesh="cube.mesh" scale=0 position="2050,0,-1000" />
223                        <Model mesh="cube.mesh" scale=0 position="6050,0,0" />
224                        <Model mesh="cube.mesh" scale=0 position="10050,0,3000" />
225                        <Model mesh="cube.mesh" scale=0 position="3050,0,3000" />
226                        <Model mesh="cube.mesh" scale=0 position="-4050,0,3000" />
227                    </waypoints>
228                </WaypointPatrolController>
229             </controller>
230        </SpaceShip>
231        <!--Second Spaceship team 0 (player: team 0)-->
232        <SpaceShip position="0,0,100" lookat="2000,0,-950" health="400" maxhealth="400" initialhealth="400" >
233             <templates>
234                  <Template link=spaceshipassff />
235            </templates>
236             <controller>
237                <WaypointPatrolController alertnessradius=2000 team=0 >
238                    <waypoints>
239                        <Model mesh="cube.mesh" scale=0 position="2000,0,-900" />
240                        <Model mesh="cube.mesh" scale=0 position="6000,0,0" />
241                        <Model mesh="cube.mesh" scale=0 position="10000,0,3100" />
242                        <Model mesh="cube.mesh" scale=0 position="3000,0,3100" />
243                        <Model mesh="cube.mesh" scale=0 position="-4000,0,3100"/>
244                    </waypoints>
245                </WaypointPatrolController>
246             </controller>
247        </SpaceShip>
248        <!--third Spaceship team 0 (player: team 0)-->
249        <SpaceShip position="0,0,-100" lookat="2000,0,-1050" health="400" maxhealth="400" initialhealth="400" >
250             <templates>
251                  <Template link=spaceshipassff />
252            </templates>
253             <controller>
254                <WaypointPatrolController alertnessradius=2000 team=0 >
255                    <waypoints>
256                        <Model mesh="cube.mesh" scale=0 position="2000,0,-1100" />
257                        <Model mesh="cube.mesh" scale=0 position="6000,0,-100" />
258                        <Model mesh="cube.mesh" scale=0 position="10000,0,2900" />
259                        <Model mesh="cube.mesh" scale=0 position="3000,0,2900" />
260                        <Model mesh="cube.mesh" scale=0 position="-4000,0,2900" />
261                    </waypoints>
262                </WaypointPatrolController>
263             </controller>
264        </SpaceShip>
265<!--Creating player's team END  -->
266
267
268<!--Asteroids (field OK -->
269
270<?lua for i=0,100,1 do
271x=math.random(250,4000)
272y=math.random(-500,500)
273z=math.random(1000,2000)
274scale=math.random(20,70)
275?>
276<MovableEntity collisionType=kinematic linearDamping=0.8 angularDamping=0 mass="<?lua print(scale * 5) ?>" position="<?lua print(x) ?>,<?lua print(y) ?>,<?lua print(z) ?>" rotationaxis="<?lua print(math.random()) ?>,<?lua print(math.random()) ?>,<?lua print(math.random()) ?>" rotationrate="<?lua print(math.random()*15) ?>">
277    <attached>
278        <Model scale=<?lua print(scale) ?> mesh="ast<?lua print( math.mod(i,6) + 1) ?>.mesh" shadow=false/>
279    </attached>
280    <collisionShapes>
281        <SphereCollisionShape radius="<?lua print(scale * 3) ?>" />
282    </collisionShapes>
283</MovableEntity>
284<?lua end ?>
285
286<!--Asteroids (field) END -->
287
288<!--Asteroids (random) END OK-->
289
290<?lua for i=0,150,1 do
291x=math.random(-8000,8000)
292y=math.random(-8000,8000)
293z=math.random(-8000,8000)
294?>
295<MovableEntity collisionType=kinematic linearDamping=0.8 angularDamping=0 mass="<?lua print(scale * 5) ?>" position="<?lua print(x) ?>,<?lua print(y) ?>,<?lua print(z) ?>" rotationaxis="<?lua print(math.random()) ?>,<?lua print(math.random()) ?>,<?lua print(math.random()) ?>" rotationrate="<?lua print(math.random()*15) ?>" >
296    <attached>
297        <Model scale=<?lua print(math.random(20,70)) ?> mesh="ast<?lua print( math.mod(i,6) + 1) ?>.mesh" shadow=false/>
298    </attached>
299    <collisionShapes>
300            <SphereCollisionShape radius="<?lua print(scale * 3) ?>" />
301        </collisionShapes>
302</MovableEntity>
303<?lua end ?>
304
305<!--Asteroids (random) END -->
306
307<!--Creating spaceships (player's team) OK-->
308<!---->
309<!--Trigger to activate this Team (TEAM NO 1)-->
310    <DistanceTrigger name="activateTeam0No1" position="8000,0,3100" distance="1000" target="DistanceTriggerBeacon" targetname="PlayerDistanceTrigger" activations="1" stayactive="true" />
311
312<!--TEAM NO 1 (activationType : distance || killing a spaceship what belongs to TEAM 0 NO 0)-->
313<?lua for i=0,9,1 do
314x=math.random(-500,500)
315y=math.random(-300,300)
316z=math.random(-300,300)
317?>
318    <EventTrigger name="activateTeam0No1" activations=1 stayactive="true">
319        <events>
320            <trigger>
321                <SpaceShip position="<?lua print(x+4500) ?>,<?lua print(y) ?>,<?lua print(z+6000) ?>" lookat="<?lua print(4000+x) ?>,<?lua print(y) ?>,<?lua print(z+3000) ?>">
322                    <templates>
323                        <Template link=spaceshipassff />
324                    </templates>
325                    <controller>
326                        <WaypointPatrolController alertnessradius=2000 team=0 active=false>
327                            <waypoints>
328                                <Model mesh="cube.mesh" scale=0 position="<?lua print(4500+x) ?>,<?lua print(y) ?>,<?lua print(z+3000) ?>" />
329                                <Model mesh="cube.mesh" scale=0 position="<?lua print(x-4000) ?>,<?lua print(y) ?>,<?lua print(z+3000) ?>" />
330                            </waypoints>
331                            <events>
332                                <activity>
333                                    <EventListener event="activateTeam0No1" />
334                                </activity>
335                            </events>
336                        </WaypointPatrolController>
337                    </controller>
338                </SpaceShip>
339            </trigger>
340        </events>
341    </EventTrigger>
342
343
344<?lua end ?>
345
346<!---->
347<!--Creating spaceships (player's team) END -->
348
349<!--Creating spaceships (enemy) OK-->
350<!---->
351<!--TEAM 1 NO 1 (activationType : killing a Transporter || killing a spaceship what belongs to TEAM 1 NO 1)-->
352<?lua for i=0,11,1 do
353x=math.random(-500,500)
354y=math.random(-300,300)
355z=math.random(-300,300)
356?>
357    <EventTrigger name="activateTeam1No1" activations=1 stayactive="true" >
358        <events>
359            <trigger>
360                <SpaceShip position="<?lua print(x+3800) ?>,<?lua print(y+3000) ?>,<?lua print(z+3000) ?>" lookat="<?lua print(4000+x) ?>,<?lua print(y) ?>,<?lua print(z+3000) ?>">
361                    <templates>
362                        <Template link=spaceshippirate />
363                    </templates>
364                    <controller>
365                        <WaypointPatrolController alertnessradius=5000 team=1 active=false>
366                            <waypoints>
367                                <Model mesh="cube.mesh" scale=0 position="<?lua print(4000+x) ?>,<?lua print(y) ?>,<?lua print(z+3000) ?>" />
368                            </waypoints>
369                            <events>
370                                <activity>
371                                    <EventListener event="activateTeam1No1" />
372                                </activity>
373                            </events>
374                        </WaypointPatrolController>
375                    </controller>
376                </SpaceShip>
377            </trigger>
378        </events>
379    </EventTrigger>
380
381<?lua end ?>
382<!---->
383<!--Creating spaceships (enemy) END -->
384
385<!--Enemies on the way to the transporters -->
386
387<?lua for i=0,1,1 do
388z=math.random(-300,300)
389?>
390<!--NO 1-->
391        <SpaceShip position="<?lua print(5900+i*100) ?>,0,-3000" lookat="2500,0,-1000">
392            <templates>
393                <Template link=spaceshippirate/>
394            </templates>
395            <controller>
396                <WaypointPatrolController alertnessRadius=1500 team=1>
397                    <waypoints>
398                        <Model mesh="cube.mesh" scale=0 position="<?lua print(2500+100*i) ?>,0,-1000" />
399                    </waypoints>
400                </WaypointPatrolController>
401            </controller>
402        </SpaceShip>
403
404<!--NO 4-->
405        <SpaceShip position="<?lua print(9000) ?>,13000,<?lua print(z*i+3000) ?>" lookat="1000,0,3000">
406            <templates>
407                <Template link=spaceshippirate/>
408            </templates>
409            <controller>
410                <WaypointPatrolController alertnessRadius=1500 team=1>
411                    <waypoints>
412                        <Model mesh="cube.mesh" scale=0 position="<?lua print(10000) ?>,0,<?lua print(3000+z*i) ?>" />
413                    </waypoints>
414                </WaypointPatrolController>
415            </controller>
416        </SpaceShip>
417<?lua end ?>
418
419
420<!--NO 3-->
421        <SpaceShip position="<?lua print(200+13000) ?>,0,10000" lookat="8000,0,1000">
422            <templates>
423                <Template link=spaceshippirate/>
424            </templates>
425            <controller>
426                <WaypointPatrolController alertnessRadius=1500 team=1>
427                    <waypoints>
428                        <Model mesh="cube.mesh" scale=0 position="<?lua print(200+8000) ?>,0,1000" />
429                    </waypoints>
430                </WaypointPatrolController>
431            </controller>
432        </SpaceShip>
433<?lua for i=0,1,1 do ?>   
434        <SpaceShip position="<?lua print(i*400+13000) ?>,100,10000" lookat="8000,0,1000">
435            <templates>
436                <Template link=spaceshippirate/>
437            </templates>
438            <controller>
439                <WaypointPatrolController alertnessRadius=1500 team=1>
440                    <waypoints>
441                        <Model mesh="cube.mesh" scale=0 position="<?lua print(i*400+8000) ?>,0,1000" />
442                    </waypoints>
443                </WaypointPatrolController>
444            </controller>
445        </SpaceShip>
446<?lua end ?>
447
448
449<!--NO 2-->
450<?lua for i=0,3,1 do ?>
451        <SpaceShip position="<?lua print(math.random(5500,6500)+2000) ?>,0,1000" lookat="2500,0,-1000">
452            <templates>
453                <Template link=spaceshippirate/>
454            </templates>
455            <controller>
456                <WaypointPatrolController alertnessRadius=1500 team=1>
457                    <waypoints>
458                        <Model mesh="cube.mesh" scale=0 position="<?lua print(math.random(5750,6250)+2000) ?>,0,1250" />
459                        <Model mesh="cube.mesh" scale=0 position="<?lua print(math.random(5750,6250)+2000) ?>,250,1000" />
460                        <Model mesh="cube.mesh" scale=0 position="<?lua print(math.random(5750,6250)+2000) ?>,0,1000" />
461                    </waypoints>
462                </WaypointPatrolController>
463            </controller>
464        </SpaceShip>
465<?lua end ?>
466
467<!--Creating spaceships (enemy) END -->
468
469<Trigger invert=true name="activateFirstSpawnpoint">
470    <DistanceTrigger name="activateSecondSpawnpoint" position="10000,0,3000" distance="1000" target="DistanceTriggerBeacon" targetname="PlayerDistanceTrigger" activations="1" stayactive="true" />
471</Trigger>
472
473    </Scene>
474</Level>
Note: See TracBrowser for help on using the repository browser.