Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/Dialog_HS16/data/levels/missionOne.oxw @ 11319

Last change on this file since 11319 was 11317, checked in by dmoritz, 8 years ago

Picture added

  • Property svn:eol-style set to native
File size: 63.5 KB
Line 
1<!---->
2<LevelInfo
3 name = "Mission One"
4 description = "Codename: Awakening - First Guided Steps in the Orxonoxian Universe."
5 screenshot = "missionOne.png"
6 tags = "mission"
7/>
8
9<?lua
10  include("stats.oxo")
11  include("HUDTemplates3.oxo")
12  include("templates/lodInformation.oxt")
13  include("templates/spaceshipAssff.oxt")
14  include("templates/spaceshipPirate.oxt")
15  include("templates/spaceshipSpacecruiser.oxt")
16  include("templates/spaceshipTransporter.oxt")
17?>
18
19<?lua
20include("templates/pickupRepresentationTemplates.oxt")
21?>
22
23<Level
24 gametype     = "Mission"
25>
26  <templates>
27    <Template link=lodtemplate_default />
28  </templates>
29  <?lua include("includes/notifications.oxi") ?>
30
31  <NotificationQueueCEGUI
32    name="narrative"
33    targets="simpleNotification,dialogue"
34    size=3
35    displayTime=3.9
36    position="0.2, 0, 0.1, 0"
37    fontSize="19"
38    fontColor="0.3, 1, 0.2, 0.8"
39    alignment="HorzCentred"
40    displaySize="0.6, 0, 0, 0"
41    />
42
43  <Scene
44    ambientlight = "0.8, 0.8, 0.8"
45    skybox       = "Orxonox/Starbox"
46  >
47    <?lua
48      include("includes/pickups.oxi")
49    ?>
50
51    <WorldAmbientSound source="Earth.ogg" looping="true" playOnLoad="true" /> <!-- AlphaCentauri.ogg, Mars.ogg-->
52
53    <Light type=directional position="0,0,0" direction="0.253, 0.593, -0.765" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 0.9, 1.0"/>
54<!-- END OF INCLUDES & NECESSARITIES -->
55
56<!-- SPAWNPOINT & START OF QUESTS via spawntrigger -->
57    <EventMultiTrigger name=spawntrigger>
58        <events>
59            <trigger>
60                <TeamSpawnPoint team=0 position="800,700,600" direction="-1,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff>
61                  <EventTrigger invert=true>
62                    <events>
63                      <trigger>
64                        <EventListener event="attack" />
65                      </trigger>
66                    </events>
67                  </EventTrigger>
68                </TeamSpawnPoint>
69            </trigger>
70        </events>
71    </EventMultiTrigger>
72
73        <QuestEffectBeacon times=1>
74            <effects>
75                <AddQuest questId="missionOne.basicFlying" />
76                <!--AddQuestHint hintId ="quest1hint3" /-->
77            </effects>
78            <events>
79                <execute>
80                    <EventListener event=spawntrigger />
81                </execute>
82            </events>
83        </QuestEffectBeacon>
84
85        <QuestEffectBeacon times=1>
86            <effects>
87                <CompleteQuest questId="missionOne.basicFlying" />
88            </effects>
89            <events>
90                <execute>
91                    <EventListener event="flying4" />
92                </execute>
93            </events>
94        </QuestEffectBeacon>
95
96        <QuestEffectBeacon times=1>
97            <effects>
98                <CompleteQuest questId="missionOne.navigation" />
99            </effects>
100            <events>
101                <execute>
102                    <EventListener event="navigationend" />
103                </execute>
104            </events>
105        </QuestEffectBeacon>
106
107<!--helper trigger to end the weaponsystemI quest -->
108    <DistanceTrigger name="boxend" position="0,0,0" distance=950 target="SpaceShip" stayActive="false" delay=0.1>
109              <EventTrigger>
110                <events>
111                  <trigger>
112                    <EventListener event="boxtrigger4" />
113                  </trigger>
114                </events>
115              </EventTrigger>
116    </DistanceTrigger>
117
118        <QuestEffectBeacon times=1>
119            <effects>
120                <CompleteQuest questId="missionOne.weaponsystemI" />
121            </effects>
122            <events>
123                <execute>
124                    <EventListener event="boxend" />
125                </execute>
126            </events>
127        </QuestEffectBeacon>
128
129<!--helper trigger to end the weaponsystemII quest -->
130    <DistanceTrigger name="piratesend" position="0,0,0" distance=2000 target="SpaceShip" stayActive="false" delay=0.1>
131              <EventTrigger>
132                <events>
133                  <trigger>
134                    <EventListener event="movingpirates2" />
135                  </trigger>
136                </events>
137              </EventTrigger>
138    </DistanceTrigger>
139
140        <QuestEffectBeacon times=1>
141            <effects>
142                <CompleteQuest questId="missionOne.weaponsystemII" />
143            </effects>
144            <events>
145                <execute>
146                    <EventListener event=piratesend />
147                </execute>
148            </events>
149        </QuestEffectBeacon>
150
151<!--helper trigger to end the DuBallStation quest -->
152    <DistanceTrigger name="duballend" position="-1000,-300,700" distance=2000 target="SpaceShip" stayActive="false" delay=0.1>
153              <EventTrigger>
154                <events>
155                  <trigger>
156                    <EventListener event="duball3" />
157                  </trigger>
158                </events>
159              </EventTrigger>
160    </DistanceTrigger>
161
162
163        <QuestEffectBeacon times=1>
164            <effects>
165                <CompleteQuest questId="missionOne.DuballStation" />
166            </effects>
167            <events>
168                <execute>
169                    <EventListener event=duballend />
170                </execute>
171            </events>
172        </QuestEffectBeacon>
173
174        <QuestEffectBeacon times=1> <!--  alternative quest end  -->
175            <effects>
176                <CompleteQuest questId="missionOne.DuballStation" />
177            </effects>
178            <events>
179                <execute>
180                    <EventListener event=toHydroFarmer />
181                </execute>
182            </events>
183        </QuestEffectBeacon>
184
185<!--helper trigger to end the getHelp quest -->
186    <DistanceTrigger name="getHelpEnd" position="-47000,-1000,1300" distance=1400 target="SpaceShip" stayActive="false" delay=0.1>
187              <EventTrigger>
188                <events>
189                  <trigger>
190                    <EventListener event="ondock" />
191                  </trigger>
192                </events>
193              </EventTrigger>
194    </DistanceTrigger>
195
196        <QuestEffectBeacon times=1>
197            <effects>
198                <CompleteQuest questId="missionOne.getHelp" />
199            </effects>
200            <events>
201                <execute>
202                    <EventListener event=getHelpEnd />
203                </execute>
204            </events>
205        </QuestEffectBeacon>
206
207<!--helper trigger to end the getHome quest -->
208    <DistanceTrigger name="getHomeEnd" position="0,0,0" distance=4000 target="SpaceShip" stayActive="false" delay=0.1>
209              <EventTrigger>
210                <events>
211                  <trigger>
212                    <EventListener event="attack" />
213                  </trigger>
214                </events>
215              </EventTrigger>
216    </DistanceTrigger>
217
218        <QuestEffectBeacon times=1>
219            <effects>
220                <CompleteQuest questId="missionOne.getHome" />
221            </effects>
222            <events>
223                <execute>
224                    <EventListener event=getHomeEnd />
225                </execute>
226            </events>
227        </QuestEffectBeacon>
228
229<!--helper trigger to end the defence quest -->
230    <DistanceTrigger name="defenceEnd" position="0,0,0" distance=4000 target="SpaceShip" stayActive="false" delay=0.1>
231              <EventTrigger>
232                <events>
233                  <trigger>
234                    <EventListener event="attacktrigger6" />
235                  </trigger>
236                </events>
237              </EventTrigger>
238    </DistanceTrigger>
239
240        <QuestEffectBeacon times=1>
241            <effects>
242                <CompleteQuest questId="missionOne.defence" />
243            </effects>
244            <events>
245                <execute>
246                    <EventListener event=defenceEnd />
247                </execute>
248            </events>
249        </QuestEffectBeacon>
250
251<!-- End the quest after own destruction of spacecruiser -->
252        <QuestEffectBeacon position="-100,0,0" times=1>
253            <effects>
254                <FailQuest questId="missionOne.getHelp" />
255            </effects>
256            <events>
257                <execute>
258                    <EventListener event="failQuest" />
259                </execute>
260            </events>
261            <attached>
262                <DistanceTrigger name="failQuest" position="-47000,-1000,1300" distance=2300 target="SpaceShip">
263                  <EventTrigger>
264                    <events>
265                      <trigger>
266                        <EventListener event="gameEnd" />
267                      </trigger>
268                    </events>
269                  </EventTrigger>
270                </DistanceTrigger>
271            </attached>
272        </QuestEffectBeacon>
273
274
275
276
277    <LocalQuest id="missionOne.basicFlying">
278        <QuestDescription title="Flying" description="Can you see the blinking light straight ahead? Your goal is to fly through it.
279Use (W) to accelerate and steer with your mouse.
280
281Further flying moves:
282break (S)
283roll     (Q) and (E)
284boost (Space)
285
286Whenever a new quest is added you can view it by pressing (F3). Quit this menu via (Esc)." failmessage="" completeMessage="" />
287        <complete-effects>
288            <AddQuest questId="missionOne.navigation" />
289        </complete-effects>
290    </LocalQuest>
291
292    <LocalQuest id="missionOne.navigation">
293        <QuestDescription title="Navigation" description="The next goal is to find and move towards the test targets for your weaponsystem. The three arrows that just appeared down in the right corner of your screen indicate in which direction you have to turn your spacefighter to find your next targets.
294
295Alternative navigation: There's a green circle in the left corner - the radar. The red dots on the radar represent your targets. If you manage to move your spaceship in a way such that a dot is at the center of the radar, you will be able to see the concerning object straight ahead." failmessage="" completeMessage="" />
296        <complete-effects>
297            <AddQuest questId="missionOne.weaponsystemI" />
298        </complete-effects>
299    </LocalQuest>
300
301            <LocalQuest id ="missionOne.weaponsystemI">
302                <QuestDescription title="Destroy the Boxes" description="Test your four different weapons on the four boxes:
3031. laser (left click)
3042. plasma (right click)
3053. target seeking rockets (middle click)
3064. manual rockets (T)
307
308Attention if you use manual rockets: Press (T) only once to start the rocket. If you miss your target you can get out of the rocket, by clicking or pressing (T) once more." failmessage="" completeMessage="" />
309                    <hints>
310                        <QuestHint id="missionOne.weaponsystem.laser">
311                            <QuestDescription title="Laser" description="The laser is a standard weapon. It is fast and precise but does not deal much damage." />
312                        </QuestHint>
313                        <QuestHint id="missionOne.weaponsystem.lightningGun">
314                            <QuestDescription title="Lightninggun" description="That was the lightning gun. Its plasma munition is quite slow, but a normal spaceship can't take more than three hits of such a strong weapon. That could be your favourite weapon for close range combat or if you want to hit a really slow enemy." />
315                        </QuestHint>
316                        <QuestHint id="missionOne.weaponsystem.targetSeekingRocket">
317                            <QuestDescription title="Target Seeking Rocket" description="The target seeking rockets follow slow targets on their own." />
318                        </QuestHint>
319                        <QuestHint id="missionOne.weaponsystem.manualrocket">
320                            <QuestDescription title="Manual Rocket" description="Manual rockets are your most powerful weapon. But since you have to steer it to your target yourself, you will leave your spaceship unprotected for a while. The total amount of both manual and target seeking rockets is limited to 10." />
321                        </QuestHint>
322                    </hints>
323                <complete-effects>
324                    <AddQuest questId="missionOne.weaponsystemII" />
325                </complete-effects>
326            </LocalQuest>
327
328            <LocalQuest id="missionOne.weaponsystemII">
329                <QuestDescription title="Kill the pirates" description="Get rid of the patrolling pirates.
330Find out which weapon is best to tackle moving targets. Get close enough." failmessage="" completeMessage="" />
331                <complete-effects>
332                    <AddQuest questId="missionOne.DuballStation" />
333                </complete-effects>
334            </LocalQuest>
335
336    <LocalQuest id="missionOne.DuballStation">
337        <QuestDescription title="Duball Space Station" description="Fly towards the Duball Space Station. The grey radar marker will lead you to its position." failmessage="" completeMessage="" />
338        <complete-effects>
339            <AddQuest questId="missionOne.getHelp" />
340        </complete-effects>
341    </LocalQuest>
342
343    <LocalQuest id="missionOne.getHelp">
344        <QuestDescription title="Get Help" description="There are several enemies approaching. You can't handle it on your own. Fortunately there's a shortcut to the next friendly unit. Use the portal (grey dot) to get near the Hydrogen Farmer.
345The Hydrogen Farmer is a large spaceship with three legs.
346There you might get help - as far as we know there should be a strong spaceruiser docked to the Hydrogen Farmer. In order to be able to use that stronger spaceship, you have to dock to the Hydrogen Farmer.
347Simply fly to the center of the Hydrogen Farmer, which is between its three legs.
348
349How to dock: Accept the dialogue, take your hands off the keyboard and watch." failmessage="" completeMessage="" />
350        <complete-effects>
351            <AddQuest questId="missionOne.getHome" />
352        </complete-effects>
353    </LocalQuest>
354
355    <LocalQuest id="missionOne.getHome">
356        <QuestDescription title="Return ASAP" description="So you managed to get the spacecruiser. Use the portal to return to the DuBall Space Station.
357Hurry! Your help is desperately needed." failmessage="" completeMessage="" />
358        <complete-effects>
359            <AddQuest questId="missionOne.defence" />
360        </complete-effects>
361    </LocalQuest>
362
363    <LocalQuest id="missionOne.defence">
364        <QuestDescription title="Defence" description="Seven enemies were detected that seem to launch a coordinated attack.
365Do not hesitate to fight or you will be the target.
366
367Always take care of the enemy that is the closest to you." failmessage="" completeMessage="Yeah! You did it." />
368    </LocalQuest>
369<!-- --------------------- END OF QUESTS -------------------------- -->
370
371
372    <DistanceTrigger name="spawndelaytrigger0" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=2/>
373    <Dialogue speaker="Speaker" message=" Press (F3) to see your mission briefing." portrait="Orxonox/DialogueHUD_Person">
374        <events>
375            <trigger>
376                <EventListener event="spawndelaytrigger0" />
377            </trigger>
378        </events>
379    </Dialogue>
380
381<!-- Blinking Billboard should be replaced with WAYPOINT -->
382<BlinkingBillboard position="-900,640,600" frequency=0.6 amplitude=3 material="Flares/lensflare" colour="1,1,0.05">
383          <events>
384            <visibility>
385              <EventTrigger invert=true>
386                <events>
387                  <trigger>
388                    <EventListener event=flying4 />
389                  </trigger>
390                </events>
391              </EventTrigger>
392            </visibility>
393          </events>
394</BlinkingBillboard>
395<Billboard position="-900,640,600" amplitude=1 material="Flares/lensflare" colour="0,0.8,0.1">
396          <events>
397            <visibility>
398              <EventTrigger>
399                <events>
400                  <trigger>
401                    <EventListener event=flying4 />
402                  </trigger>
403                </events>
404              </EventTrigger>
405            </visibility>
406          </events>
407</Billboard>
408
409<!-------------------------------------- PART ZERO: How to fly --------------------------------------->
410
411    <DistanceTrigger name="flying1" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=6/>
412    <Dialogue speaker="Speaker" message="Let's fly to the blinking light." portrait="Orxonox/DialogueHUD_Person">
413        <events>
414            <trigger>
415                <EventListener event="flying1" />
416            </trigger>
417        </events>
418    </Dialogue>
419
420    <DistanceTrigger name="flying2" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=10/>
421    <Dialogue speaker="Speaker" message="Use (W) to accelerate and the mouse to steer." portrait="Orxonox/DialogueHUD_Person">
422        <events>
423            <trigger>
424                <EventListener event="flying2" />
425            </trigger>
426        </events>
427    </Dialogue>
428
429<!-- QUEST-Trigger && Message Trigger: navigationend is activated after flying4 was triggered -->
430    <DistanceTrigger name="navigationend" position="0,0,0" distance=950 target="SpaceShip" stayActive="false" delay=1.1>
431        <DistanceTrigger name="flying4" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=1/>
432    </DistanceTrigger>
433
434
435    <Dialogue speaker="Speaker2" message="Three arrows just appeared." portrait="Orxonox/DialogueHUD_Person2">
436        <events>
437            <trigger>
438                <EventListener event="flying4" />
439            </trigger>
440        </events>
441    </Dialogue>
442
443    <DistanceTrigger name="flying5" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=5/>
444    <Dialogue speaker="Speaker2" message="Follow those arrows." portrait="Orxonox/DialogueHUD_Person2">
445        <events>
446            <trigger>
447                <EventListener event="flying5" />
448            </trigger>
449        </events>
450    </Dialogue>
451
452<!-------------------------------------- PART ONE : Destroy boxes --------------------------------------->
453<!-- @ triggers: spawndelaytriggerX: textoutput only if no box was destroyed -->
454    <Trigger name="spawndelaytrigger1" mode="and" stayActive="true">
455        <DistanceTrigger position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=9 />
456        <EventTrigger activations="1" invert="true">
457          <events>
458            <trigger>
459              <EventListener event="boxtrigger1" />
460            </trigger>
461          </events>
462        </EventTrigger>
463    </Trigger>
464
465    <Trigger name="spawndelaytrigger2" mode="and" stayActive="true">
466        <DistanceTrigger position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=13 />
467        <EventTrigger activations="1" invert="true">
468          <events>
469            <trigger>
470              <EventListener event="boxtrigger1" />
471            </trigger>
472          </events>
473        </EventTrigger>
474    </Trigger>
475
476    <Trigger name="spawndelaytrigger3" mode="and" stayActive="true">
477        <DistanceTrigger position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=17 />
478        <EventTrigger activations="1" invert="true">
479          <events>
480            <trigger>
481              <EventListener event="boxtrigger1" />
482            </trigger>
483          </events>
484        </EventTrigger>
485    </Trigger>
486
487<!-- @Text: How to shoot-->
488    <Dialogue speaker="Speaker" message="Destroy the four boxes." portrait="Orxonox/DialogueHUD_Person" broadcast="true">
489        <events>
490            <trigger>
491                <EventListener event="spawndelaytrigger1" />
492            </trigger>
493        </events>
494    </Dialogue>
495
496    <SimpleNotification message=" 1. Aim at the red cycle." broadcast="true">
497        <events>
498            <trigger>
499                <EventListener event="spawndelaytrigger2" />
500            </trigger>
501        </events>
502    </SimpleNotification>
503
504    <SimpleNotification message="2. Click! (hold the left mouse button)" broadcast="true">
505        <events>
506            <trigger>
507                <EventListener event="spawndelaytrigger3" />
508            </trigger>
509        </events>
510    </SimpleNotification>
511
512<!-- @Objects: 4 boxes (uncontrolled pawns) -->
513    <Pawn health=30 position="0,0,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box radarname = "Box 4" >
514        <events>
515          <visibility>
516            <EventListener event="flying4" />
517          </visibility>
518        </events>
519        <attached>
520            <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
521        </attached>
522        <collisionShapes>
523            <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
524        </collisionShapes>
525        <controller>
526            <WaypointController team=1>
527            </WaypointController>
528        </controller>
529        <explosion >
530            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_flash2" effect2="orxonox/explosion_flame2" />
531            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_shockwave2" effect2="orxonox/explosion_sparks2" />
532            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_streak2" effect2="orxonox/explosion_afterglow" />
533        </explosion>
534    </Pawn>
535
536    <Pawn health=30 position="0,100,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box radarname = "Box 3">
537        <events>
538          <visibility>
539            <EventListener event="flying4" />
540          </visibility>
541        </events>
542        <attached>
543           <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
544        </attached>
545        <collisionShapes>
546            <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
547        </collisionShapes>
548        <controller>
549            <WaypointController team=1>
550            </WaypointController>
551        </controller>
552        <explosion >
553            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_flash2" effect2="orxonox/explosion_flame2" />
554            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_shockwave2" effect2="orxonox/explosion_sparks2" />
555            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_streak2" effect2="orxonox/explosion_afterglow" />
556        </explosion>
557    </Pawn>
558
559    <Pawn health=30 position="0,200,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box radarname = "Box 2">
560        <events>
561          <visibility>
562            <EventListener event="flying4" />
563          </visibility>
564        </events>
565        <attached>
566           <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
567        </attached>
568        <controller>
569            <WaypointController team=1>
570            </WaypointController>
571        </controller>
572        <collisionShapes>
573            <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
574        </collisionShapes>
575        <explosion >
576            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_flash2" effect2="orxonox/explosion_flame2" />
577            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_shockwave2" effect2="orxonox/explosion_sparks2" />
578            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_streak2" effect2="orxonox/explosion_afterglow" />
579        </explosion>
580    </Pawn>
581
582    <Pawn health=30 position="0,300,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box radarname = "Box 1">
583        <events>
584          <visibility>
585            <EventListener event="flying4" />
586          </visibility>
587        </events>
588        <attached>
589            <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
590        </attached>
591        <collisionShapes>
592           <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
593        </collisionShapes>
594        <controller>
595            <WaypointController team=1>
596            </WaypointController>
597        </controller>
598        <explosion >
599            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_flash2" effect2="orxonox/explosion_flame2" />
600            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_shockwave2" effect2="orxonox/explosion_sparks2" />
601            <ExplosionPart minspeed=0 maxspeed=0 effect1="orxonox/explosion_streak2" effect2="orxonox/explosion_afterglow" />
602        </explosion>
603    </Pawn>
604
605<!-- @Triggers: boxtrigger1 <-> one   box   destroyed
606                boxtrigger2 <-> two   boxes destroyed
607                boxtrigger3 <-> three boxes destroyed
608                boxtrigger4 <-> four  boxes destroyed  -->
609    <EventTrigger name="boxtrigger4" activations="1" stayactive="true" delay=0.1>
610      <events>
611        <trigger>
612          <EventListener event="box" />
613        </trigger>
614      </events>
615      <EventTrigger name="boxtrigger3" activations="1" stayactive="true" delay=0.1>
616        <events>
617          <trigger>
618            <EventListener event="box" />
619          </trigger>
620        </events>
621        <EventTrigger name="boxtrigger2" activations="1" stayactive="true" delay=0.1>
622          <events>
623            <trigger>
624              <EventListener event="box" />
625            </trigger>
626          </events>
627          <EventTrigger name="boxtrigger1" activations="1" stayactive="true" delay=0.1>
628            <events>
629              <trigger>
630                <EventListener event="box" />
631              </trigger>
632            </events>
633          </EventTrigger>
634        </EventTrigger>
635      </EventTrigger>
636    </EventTrigger>
637
638
639  <SimpleNotification message="Right click on the next target." broadcast="true">
640        <events>
641            <trigger>
642                <EventListener event="boxtrigger1" />
643            </trigger>
644        </events>
645    </SimpleNotification>
646
647  <SimpleNotification message="Middle click on the next target." broadcast="true">
648        <events>
649            <trigger>
650                <EventListener event="boxtrigger2" />
651            </trigger>
652        </events>
653    </SimpleNotification>
654
655  <SimpleNotification message="Aim at the last target and press (T)." broadcast="true">
656        <events>
657            <trigger>
658                <EventListener event="boxtrigger3" />
659            </trigger>
660        </events>
661    </SimpleNotification>
662
663  <SimpleNotification message="Try to hit the pirates while you are flying." broadcast="true">
664        <events>
665            <trigger>
666                <EventListener event="boxtrigger4" />
667            </trigger>
668        </events>
669    </SimpleNotification>
670
671
672<!--------------------------------------PART TWO: Moving targets --------------------------------------->
673
674<!-- @Objects: 2 pirates moving in squares, nonlethal -->
675                <SpaceShip position="0,2000,200" lookat="0,0,0" name="movingtarget" radarname="Pirate">
676                            <events>
677                                <visibility>
678                                    <EventListener event="boxtrigger4" />
679                                </visibility>
680                            </events>
681                    <templates>
682                      <Template link=spaceshippirate />
683                    </templates>
684                    <controller>
685                      <WaypointController team=1>
686                         <waypoints>
687                          <Model mesh="cube.mesh" scale=8 position="  0,1700,-200" />
688                          <Model mesh="cube.mesh" scale=8 position="  0,1700,-700" />
689                          <Model mesh="cube.mesh" scale=8 position="500,1700,-700" />
690                          <Model mesh="cube.mesh" scale=8 position="500,1700,-200" />
691                       </waypoints>
692                    </WaypointController>
693                  </controller>
694                </SpaceShip>
695
696                <SpaceShip position="0,2000,400" lookat="0,0,0" name="movingtarget" radarname="Pirate">
697                            <events>
698                                <visibility>
699                                    <EventListener event="boxtrigger4" />
700                                </visibility>
701                            </events>
702                  <templates>
703                    <Template link=spaceshippirate />
704                  </templates>
705                  <controller>
706                    <WaypointController team=1>
707                      <waypoints>
708                        <Model mesh="cube.mesh" scale=8 position="  0,2400,1000" />
709                        <Model mesh="cube.mesh" scale=8 position="  0,2400, 500" />
710                        <Model mesh="cube.mesh" scale=8 position="500,2400, 500" />
711                        <Model mesh="cube.mesh" scale=8 position="500,2400,1000" />
712                      </waypoints>
713                    </WaypointController>
714                  </controller>
715                </SpaceShip>
716
717<!-- @Triggers: movingpirates1 <-> one  pirate  dead
718                movingpirates2 <-> both pirates dead  -->
719    <EventTrigger name="movingpirates2" activations="1" stayactive="true" delay=0.1>
720      <events>
721        <trigger>
722          <EventListener event="movingtarget" />
723        </trigger>
724      </events>
725      <EventTrigger name="movingpirates1" activations="1" stayactive="true" delay=0.1>
726        <events>
727          <trigger>
728            <EventListener event="movingtarget" />
729          </trigger>
730        </events>
731      </EventTrigger>
732    </EventTrigger>
733
734
735    <SimpleNotification message="Now get the other one."  broadcast="true">
736        <events>
737            <trigger>
738                <EventListener event="movingpirates1" />
739            </trigger>
740        </events>
741    </SimpleNotification>
742
743    <SimpleNotification message="Fly towards the space station (grey dot)."  broadcast="true">
744        <events>
745            <trigger>
746                <EventListener event="movingpirates2" />
747            </trigger>
748        </events>
749    </SimpleNotification>
750
751
752
753<!--------------------------------------PART THREE: the space station --------------------------------------->
754    <DistanceTrigger name="duball1" position="-1000,-300,700" target="Pawn" distance=700 stayActive="true" delay=1 >
755      <events>
756        <activity>
757          <EventListener event="movingpirates2" />
758        </activity>
759      </events>
760    </DistanceTrigger>
761
762    <Trigger name="duball2" mode="and" stayActive="true">
763        <EventTrigger activations="1" stayactive="true" delay=4 >
764           <events>
765              <trigger>
766                 <EventListener event="duball1" />
767              </trigger>
768           </events>
769        </EventTrigger>
770        <EventTrigger activations="1" invert="true">
771          <events>
772            <trigger>
773              <EventListener event="toHydroFarmer" />
774            </trigger>
775          </events>
776        </EventTrigger>
777    </Trigger>
778
779    <Trigger name="duball3" mode="and" stayActive="true">
780        <EventTrigger activations="1" stayactive="true" delay=4 >
781           <events>
782              <trigger>
783                 <EventListener event="duball2" />
784              </trigger>
785           </events>
786        </EventTrigger>
787        <EventTrigger activations="1" invert="true">
788          <events>
789            <trigger>
790              <EventListener event="toHydroFarmer" />
791            </trigger>
792          </events>
793        </EventTrigger>
794    </Trigger>
795
796
797    <SimpleNotification message="Welcome to the Duball Space Station!">
798        <events>
799            <trigger>
800                <EventListener event=duball1 />
801            </trigger>
802        </events>
803    </SimpleNotification>
804
805    <SimpleNotification message="Warning: Something big is coming." broadcast="true">
806        <events>
807            <trigger>
808                <EventListener event=duball2 />
809            </trigger>
810        </events>
811    </SimpleNotification>
812
813    <SimpleNotification message="Use the portals to get help. (grey dot)" broadcast="true">
814        <events>
815            <trigger>
816                <EventListener event=duball3 />
817            </trigger>
818        </events>
819    </SimpleNotification>
820
821
822<!-- @Objects: DuBall Space Station, (no pawn!) -->
823    <StaticEntity position="-1000,-300,700" collisionType=static>
824      <attached>
825        <Model scale=13 mesh="DuBall1.mesh" position = "-100,0,0"/>
826        <Model scale=13 mesh="DuBall2.mesh" position = "100,0,0"/>
827        <Billboard scale=7 material="Examples/Flare" colour="0.5,0.5,0.5" position = "-100,0,0"/>
828        <Billboard scale=7 material="Examples/Flare" colour="0.5,0.5,0.5" position = "100,0,0"/>
829      </attached>
830      <collisionShapes>
831        <SphereCollisionShape radius="80"            position = "-100,0,0" />
832        <SphereCollisionShape radius="120"           position = "100,0,0" />
833        <BoxCollisionShape    halfExtents="90,25,45" position = "-155,0,40" />
834      </collisionShapes>
835    </StaticEntity>
836
837
838<!-- @Objects: PORTAL: from DuBall to HydroHarvester  -->
839    <Template name=PortalDefault>
840        <PortalEndPoint>
841            <attached>
842                <Billboard material="Portals/Default" />
843            </attached>
844        </PortalEndPoint>
845    </Template>
846
847    <PortalEndPoint position="-1400,-500,800" id="1" distance="50" target="MobileEntity" design="PortalDefault">
848          <events>
849            <activity>
850              <Trigger mode="or" activations="2">
851                <Trigger mode="and" activations="1">
852                  <EventTrigger>
853                    <events>
854                      <trigger>
855                        <EventListener event="movingpirates2" />
856                      </trigger>
857                    </events>
858                  </EventTrigger>
859                  <EventTrigger invert=true>
860                    <events>
861                      <trigger>
862                        <EventListener event="toHydroFarmer" />
863                      </trigger>
864                    </events>
865                  </EventTrigger>
866                </Trigger>
867                <Trigger mode="and" activations="1">
868                  <EventTrigger>
869                    <events>
870                      <trigger>
871                        <EventListener event="ondock" />
872                      </trigger>
873                    </events>
874                  </EventTrigger>
875                  <EventTrigger invert=true>
876                    <events>
877                      <trigger>
878                        <EventListener event="attack" />
879                      </trigger>
880                    </events>
881                  </EventTrigger>
882                </Trigger>
883                <EventTrigger>
884                  <events>
885                    <trigger>
886                      <EventListener event="HydroFarmer" />
887                    </trigger>
888                  </events>
889                </EventTrigger>
890              </Trigger>
891            </activity>
892          </events>
893    </PortalEndPoint>
894
895    <PortalEndPoint position="-47000,-1000,1300" id="2" distance="70" target="MobileEntity" design="PortalDefault">
896          <events>
897            <activity>
898              <Trigger mode="or" activations="3">
899                <Trigger mode="and" activations="1">
900                  <EventTrigger>
901                    <events>
902                      <trigger>
903                        <EventListener event="movingpirates2" />
904                      </trigger>
905                    </events>
906                  </EventTrigger>
907                  <EventTrigger invert=true>
908                    <events>
909                      <trigger>
910                        <EventListener event="toHydroFarmer" />
911                      </trigger>
912                    </events>
913                  </EventTrigger>
914                </Trigger>
915                <Trigger mode="and" activations="1">
916                  <EventTrigger>
917                    <events>
918                      <trigger>
919                        <EventListener event="ondock" />
920                      </trigger>
921                    </events>
922                  </EventTrigger>
923                  <EventTrigger invert=true>
924                    <events>
925                      <trigger>
926                        <EventListener event="attack" />
927                      </trigger>
928                    </events>
929                  </EventTrigger>
930                </Trigger>
931                <EventTrigger>
932                  <events>
933                    <trigger>
934                      <EventListener event="HydroFarmer" />
935                    </trigger>
936                  </events>
937                </EventTrigger>
938              </Trigger>
939            </activity>
940          </events>
941    </PortalEndPoint>
942    <PortalLink fromID="1" toID="2" />
943    <PortalLink fromID="2" toID="1" />
944<!-- ????????????????????????????????????????????????????? why does this NOT work ??
945                <Trigger mode="and" activations="1">
946                  <EventTrigger>
947                    <events>
948                      <trigger>
949                        <EventListener event="HydroFarmer" />
950                      </trigger>
951                    </events>
952                  </EventTrigger>
953                  <EventTrigger invert=true>
954                    <events>
955                      <trigger>
956                        <EventListener event="attack" />
957                      </trigger>
958                    </events>
959                  </EventTrigger>
960                </Trigger>
961-->
962<!-- PORTALS END-->
963
964
965    <SimpleNotification message="Dock to the Hydrogen Farmer." broadcast="true">
966        <events>
967            <trigger>
968                <EventListener event=toHydroFarmer />
969            </trigger>
970        </events>
971    </SimpleNotification>
972
973<!-------------------------------------- PART FOUR : Get Help --------------------------------------->
974
975    <Trigger name="famer1" mode="and" stayActive="true">
976        <DistanceTrigger position="-48200,100,0" target="Pawn" distance=650 stayActive="true" delay=0 />
977        <EventTrigger name="notGameEnd" activations="1" invert="true">
978          <events>
979            <trigger>
980              <EventListener event="gameEnd" />
981            </trigger>
982          </events>
983        </EventTrigger>
984    </Trigger>
985
986    <Trigger name="famer2" mode="and" stayActive="true">
987        <DistanceTrigger position="-48200,100,0" target="Pawn" distance=650 stayActive="true" delay=4 />
988        <EventTrigger activations="1" invert="true">
989          <events>
990            <trigger>
991              <EventListener event="gameEnd" />
992            </trigger>
993          </events>
994        </EventTrigger>
995    </Trigger>
996
997    <SimpleNotification message="We just received a message from DuBall." broadcast="true">
998        <events>
999            <trigger>
1000                <EventListener event=famer1 />
1001            </trigger>
1002        </events>
1003    </SimpleNotification>
1004
1005
1006    <SimpleNotification message="We will lend you our strongest ship." broadcast="true">
1007        <events>
1008            <trigger>
1009                <EventListener event=famer2 />
1010            </trigger>
1011        </events>
1012    </SimpleNotification>
1013
1014
1015<!-- @Objects: HYDROGEN FARMER & DOCKING -->
1016    <SpaceShip
1017        team      = 0
1018        position  = "-48900,100,0"
1019        roll      = 90   yaw=0  pitch=20
1020        mass      = 10000
1021        health    = 100000 initialhealth=100000 maxhealth="100000"
1022        name      = "HydroFarmer"
1023        radarname = "Hydrogen Farmer" >
1024      <attached>
1025        <!-- Docking -->
1026        <DistanceTriggerBeacon name="bcnDestroyer" />
1027        <DockingTarget name="destroyer" />
1028
1029        <Model mesh="HydroHarvester.mesh" mass=10 position="0,0,0" scale=50 />
1030   <!-- <Model mesh="cube.mesh" mass=10 position="-560,0,0" scale3D="115,100,245"  />
1031        <Model mesh="cube.mesh" mass=10 position="290,0,-480" scale3D="115,100,245" yaw=-120 />
1032        <Model mesh="cube.mesh" mass=10 position="290,0,480" scale3D="115,100,245" yaw=-240 />
1033        <Model mesh="cube.mesh" mass=10 position="-280,0,0" scale3D="163,50,50" />
1034        <Model mesh="cube.mesh" mass=10 position="140,0,-240" scale3D="163,50,50"  yaw=-120/>
1035        <Model mesh="cube.mesh" mass=10 position="140,0,240" scale3D="163,50,50" yaw=-240/>
1036        <Model mesh="cube.mesh" mass=10 position="0,530,0" scale3D="172,52,298" />
1037        <Model mesh="cube.mesh" mass=10 position="0,530,0" scale3D="172,52,298" yaw=-120/>
1038        <Model mesh="cube.mesh" mass=10 position="0,530,0" scale3D="172,52,298" yaw=-240/>
1039        <Model mesh="cube.mesh" mass=10 position="0,400,0" scale3D="43,110,26" yaw=-30 />
1040        <Model mesh="cube.mesh" mass=10 position="-200,100,0" scale3D="26,50,43" />
1041        <Model mesh="cube.mesh" mass=10 position="100,100,-173" scale3D="43,50,26" yaw=-30/>
1042        <Model mesh="cube.mesh" mass=10 position="100,100,173" scale3D="43,50,26" yaw=30/>
1043        <Model mesh="cube.mesh" mass=10 position="-100,264,0" scale3D="26,105,43" roll=-49/>
1044        <Model mesh="cube.mesh" mass=10 position="50,264,-87" scale3D="26,105,43" roll=-49 yaw=-120/>
1045        <Model mesh="cube.mesh" mass=10 position="50,264,87" scale3D="26,105,43" roll=-49 yaw=-240/>     -->
1046      </attached>
1047      <collisionShapes>
1048        <BoxCollisionShape  position="-560,0,0" halfExtents="115,100,245" /><!-- Three lower boxes -->
1049        <BoxCollisionShape  position="290,0,-480" halfExtents="115,100,245" yaw=-120 />
1050        <BoxCollisionShape  position="290,0,480" halfExtents="115,100,245" yaw=-240 />
1051        <BoxCollisionShape  position="-280,0,0" halfExtents="163,50,50" /><!-- Three lower connections -->
1052        <BoxCollisionShape  position="140,0,-240" halfExtents="163,50,50" yaw=-120 />
1053        <BoxCollisionShape  position="140,0,240" halfExtents="163,50,50" yaw=-240 />
1054        <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" /><!-- Upper Tower -->
1055        <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" yaw=-120 />
1056        <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" yaw=-240 />
1057        <BoxCollisionShape  position="0,400,0" halfExtents="43,110,26" yaw=-30 /><!-- Middle one-->
1058        <BoxCollisionShape  position="-200,100,0" halfExtents="26,50,43" /><!--Three lower legs -->
1059        <BoxCollisionShape  position="100,100,-173" halfExtents="43,50,26" yaw=-30 />
1060        <BoxCollisionShape  position="100,100,-173" halfExtents="43,50,26" yaw=30 />
1061        <BoxCollisionShape  position="-100,264,0" halfExtents="26,105,43" roll=-49 /><!--Three upper legs -->
1062        <BoxCollisionShape  position="50,264,-87" halfExtents="26,105,43" roll=-49 yaw=-120 />
1063        <BoxCollisionShape  position="50,264,87" halfExtents="26,105,43" roll=-49 yaw=-240 />
1064      </collisionShapes>
1065    </SpaceShip>
1066
1067    <Dock position="-48900,0,0" roll=90 yaw=180 >
1068        <animations>
1069            <MoveToDockingTarget target="destroyer" />
1070        </animations>
1071        <effects>
1072            <DockToShip target="spaceShip" />
1073        </effects>
1074        <events>
1075            <execute>
1076                <EventListener event="dockMe" />
1077            </execute>
1078            <activity>
1079                <EventListener event=notGameEnd />
1080            </activity>
1081        </events>
1082        <attached>
1083            <DistanceTrigger position="10,-202, -42" distance="800" target="Pawn"
1084                beaconMode="exclude" targetname="bcnDestroyer" name="dockMe"
1085            />
1086        </attached>
1087
1088    </Dock>
1089
1090<!--@Objects: SpaceCruiser as docking target -->
1091    <SpaceShip
1092        template            = "spaceshipspacecruiser"
1093        team                = "0"
1094        position            = "-48900,800,0"
1095        orientation         = "-0.14, 0.68, 0.68, 0.223"
1096        health              = "400"
1097        initialhealth       = "400"
1098        maxhealth           = "500"
1099        shieldhealth        = "80"
1100        initialshieldhealth = "80"
1101        maxshieldhealth     = "120"
1102        shieldabsorption    = "0.8"
1103        shieldrechargerate  = "1"
1104        shieldrechargewaittime = "1"
1105        name                = "cruiser"
1106        radarname           = "Spacecruiser" >
1107      <attached>
1108        <DockingTarget name="spaceShip" />
1109      </attached>
1110    </SpaceShip>
1111
1112
1113<!-- cruiserKilled: if cuiser is killed & player hasn't taken control of spacecrusier -->
1114          <Trigger name="cruiserKilled" mode="and" stayActive="true">
1115            <EventTrigger  stayActive="true">
1116              <events>
1117                <trigger>
1118                  <EventListener event="cruiser"/>
1119                </trigger>
1120              </events>
1121            </EventTrigger>
1122            <EventTrigger invert=true>
1123              <events>
1124                <trigger>
1125                  <EventListener event="ondock" />
1126                </trigger>
1127              </events>
1128            </EventTrigger>
1129          </Trigger>
1130
1131
1132<!-- triggers when either hydrofarmer or cruiser is killed -->
1133            <Trigger mode=or name="gameEnd">
1134                <EventTrigger activations="1">
1135                  <events>
1136                    <trigger>
1137                      <EventListener event="HydroFarmer" />
1138                    </trigger>
1139                  </events>
1140                </EventTrigger>
1141                <EventTrigger activations="1">
1142                  <events>
1143                    <trigger>
1144                      <EventListener event="cruiserKilled" />
1145                    </trigger>
1146                  </events>
1147                </EventTrigger>
1148            </Trigger>
1149
1150<!-- triggers delayed when either hydrofarmer or cruiser is killed -->
1151            <EventTrigger delay=4 name="earlyEnd">
1152              <events>
1153                <trigger>
1154                  <EventListener event="gameEnd" />
1155                </trigger>
1156              </events>
1157              <events>
1158                <activity>
1159                  <EventListener event="movingpirates2" />
1160                </activity>
1161              </events>
1162            </EventTrigger>
1163
1164
1165    <SimpleNotification message="Oh no! You killed the Hydrogen Farmer!" broadcast="true">
1166        <events>
1167            <trigger>
1168                <EventListener event="HydroFarmer" />
1169            </trigger>
1170        </events>
1171    </SimpleNotification>
1172
1173    <SimpleNotification message="Oh no! You killed the SpaceCruiser!" broadcast="true">
1174        <events>
1175            <trigger>
1176                <EventListener event="cruiserKilled" />
1177            </trigger>
1178        </events>
1179    </SimpleNotification>
1180
1181    <SimpleNotification message="Press (Esc) and restart the mission." broadcast="true">
1182        <events>
1183            <trigger>
1184                <EventListener event="earlyEnd" />
1185            </trigger>
1186        </events>
1187    </SimpleNotification>
1188
1189<!-- hydrogen farmer & docking END -->
1190
1191
1192<!-- @Objects: Pickup - find better place !! -->
1193    <PickupSpawner pickup=hugeshieldpickup position="-48650,700,100" triggerDistance="70" respawnTime="30" maxSpawnedItems="1" />
1194
1195
1196    <DistanceTrigger name="pickup" position="-48650,700,100" target="Pawn" distance=60 stayActive="true" delay=0 />
1197    <SimpleNotification message="This pickup protects your spaceship.">
1198        <events>
1199            <trigger>
1200                <EventListener event=pickup />
1201            </trigger>
1202        </events>
1203    </SimpleNotification>
1204<!-- Pickup-->
1205
1206
1207<!-- @Objects: planet && spaceboundaries  -->
1208    <Planet
1209      position="-44000,0,0"
1210      scale="2500"
1211      collisionType="dynamic"
1212      linearDamping="0.8"
1213      angularDamping="0"
1214      mass="10000000"
1215      pitch="0"
1216      mesh="planets/muunilinst.mesh"
1217      atmosphere="atmosphere1"
1218      rotationaxis="1,0,0"
1219      rotationrate="1.0"
1220      atmospheresize="80.0f"
1221      imagesize="1024.0f"
1222      collisiondamage = "2"
1223      enablecollisiondamage = "false"
1224    >
1225      <!--attached>
1226        <ForceField position="0,0,0" mode="sphere" diameter="10000" velocity="-50" />
1227      </attached-->  <!-- Forcefield kills HYDROGEN FARMER-->
1228      <collisionShapes>
1229        <SphereCollisionShape radius="2500" position="0,0,0" />
1230      </collisionShapes>
1231    </Planet>
1232
1233
1234<!-------------------------------------- The attack --------------------------------------->
1235<!-- TODO:
1236     - update spaceshipTransporter
1237     - bots do friendly fire (is drone function reusable?)
1238-->
1239
1240<!-- Fallback Spawnpoint: on cruiserdeath caused by pirates. Unfortunately unstable behaviour concerning activity. -->
1241    <TeamSpawnPoint team=0 position="2000,1500,-1500" direction="-1,-1,1" spawnclass=SpaceShip pawndesign=spaceshipspacecruiser>
1242        <events>
1243            <activity>
1244                <EventListener event="attack" />
1245            </activity>
1246        </events>
1247    </TeamSpawnPoint>
1248
1249<!-- @Triggers: toHydroFamer <-> first  portal usage
1250                ondock       <-> successfull docking
1251                attack       <-> second portal usage -->
1252
1253    <DistanceTrigger name="attack" position="-1400,-500,800" target="Pawn" distance=100 stayActive="true" mode="and">
1254        <EventTrigger name="ondock" activations="1" stayactive="true" delay=6>
1255          <events>
1256            <trigger>
1257              <EventListener event="dockMe" />
1258            </trigger>
1259          </events>
1260            <Trigger mode=and>
1261              <DistanceTrigger name="toHydroFarmer" position="-47000,-1000,1300" target="Pawn" distance=100 stayActive="true" />
1262              <EventTrigger activations="1" invert="true">
1263                <events>
1264                  <trigger>
1265                    <EventListener event="gameEnd" />
1266                  </trigger>
1267                </events>
1268              </EventTrigger>
1269            </Trigger>
1270        </EventTrigger>
1271        <EventTrigger activations="1" invert="true">
1272          <events>
1273            <trigger>
1274              <EventListener event="earlyEnd" />
1275            </trigger>
1276          </events>
1277        </EventTrigger>
1278    </DistanceTrigger>
1279
1280    <SimpleNotification message="Return before it's too late. Boost with (Space)." broadcast="true">
1281        <events>
1282            <trigger>
1283                <EventListener event=ondock />
1284            </trigger>
1285        </events>
1286    </SimpleNotification>
1287
1288    <SimpleNotification message="Several serious enemies are approaching!">
1289        <events>
1290            <trigger>
1291                <EventListener event=attack />
1292            </trigger>
1293        </events>
1294    </SimpleNotification>
1295
1296
1297<!-- @Objects: 6 pirates, heading towards DuBall, attacking  -->
1298<!-- TODO: re-hide pirates on early end-->
1299<!-- 1 -->
1300    <SpaceShip position="3000,-4000,4000" lookat="-1300,-600,900" name="attacker"visible="true">
1301        <events>
1302            <visibility>
1303                <EventListener event="ondock" />
1304            </visibility>
1305        </events>
1306        <templates>
1307            <Template link=spaceshippirate /> <!--spaceshipTransporter -->
1308        </templates>
1309        <controller>
1310            <WaypointPatrolController alertnessradius=3129 team=1 active=false>
1311                <waypoints>
1312                    <Model mesh="cube.mesh" scale=0 position="-1300,-600,900" />
1313                    <Model mesh="cube.mesh" scale=0 position="0,0,0" />
1314                </waypoints>
1315                <events>
1316                    <activity>
1317                        <EventListener event="attack" /> <!-- activates enemies-->
1318                     </activity>
1319                </events>
1320            </WaypointPatrolController>
1321        </controller>
1322    </SpaceShip>
1323<!-- 2 -->
1324    <SpaceShip position="3000,-4000,-4000" lookat="-1300,-600,900" name="attacker" visible="true">
1325        <events>
1326            <visibility>
1327                <EventListener event="ondock" />
1328            </visibility>
1329        </events>
1330        <templates>
1331            <Template link=spaceshippirate /> <!--spaceshipTransporter -->
1332        </templates>
1333        <controller>
1334            <WaypointPatrolController alertnessradius=3129 team=1 active=false>
1335                <waypoints>
1336                    <Model mesh="cube.mesh" scale=0 position="-1300,-600,900" />
1337                    <Model mesh="cube.mesh" scale=0 position="0,0,0" />
1338                </waypoints>
1339                <events>
1340                    <activity>
1341                        <EventListener event="attack" /> <!-- activates enemies-->
1342                     </activity>
1343                </events>
1344            </WaypointPatrolController>
1345        </controller>
1346    </SpaceShip>
1347<!-- 3 -->
1348    <SpaceShip position="-4000,-3000,4000" lookat="-1300,-600,900" name="attacker" visible="true">
1349        <events>
1350            <visibility>
1351                <EventListener event="ondock" />
1352            </visibility>
1353        </events>
1354        <templates>
1355            <Template link=spaceshippirate /> <!--spaceshipTransporter -->
1356        </templates>
1357        <controller>
1358            <WaypointPatrolController alertnessradius=3129 team=1 active=false>
1359                <waypoints>
1360                    <Model mesh="cube.mesh" scale=0 position="-1300,-600,900" />
1361                    <Model mesh="cube.mesh" scale=0 position="0,0,0" />
1362                </waypoints>
1363                <events>
1364                    <activity>
1365                        <EventListener event="attack" /> <!-- activates enemies-->
1366                     </activity>
1367                </events>
1368            </WaypointPatrolController>
1369        </controller>
1370    </SpaceShip>
1371<!-- 4 -->
1372    <SpaceShip position="-3000,-3000,-5000" lookat="-1300,-600,900" name="attacker" visible="true">
1373        <events>
1374            <visibility>
1375                <EventListener event="ondock" />
1376            </visibility>
1377        </events>
1378        <templates>
1379            <Template link=spaceshippirate /> <!--spaceshipTransporter -->
1380        </templates>
1381        <controller>
1382            <WaypointPatrolController alertnessradius=3129 team=1 active=false>
1383                <waypoints>
1384                    <Model mesh="cube.mesh" scale=0 position="-1300,-600,900" />
1385                    <Model mesh="cube.mesh" scale=0 position="0,0,0" />
1386                </waypoints>
1387                <events>
1388                    <activity>
1389                        <EventListener event="attack" /> <!-- activates enemies-->
1390                     </activity>
1391                </events>
1392            </WaypointPatrolController>
1393        </controller>
1394    </SpaceShip>
1395<!-- 5 -->
1396    <SpaceShip position="4000,4000,3000" lookat="-1300,-600,900" name="attacker"visible="true">
1397        <events>
1398            <visibility>
1399                <EventListener event="ondock" />
1400            </visibility>
1401        </events>
1402        <templates>
1403            <Template link=spaceshippirate /> <!--spaceshipTransporter -->
1404        </templates>
1405        <controller>
1406            <WaypointPatrolController alertnessradius=3129 team=1 active=false>
1407                <waypoints>
1408                    <Model mesh="cube.mesh" scale=0 position="-1300,-600,900" />
1409                    <Model mesh="cube.mesh" scale=0 position="0,0,0" />
1410                </waypoints>
1411                <events>
1412                    <activity>
1413                        <EventListener event="attack" /> <!-- activates enemies-->
1414                     </activity>
1415                </events>
1416            </WaypointPatrolController>
1417        </controller>
1418    </SpaceShip>
1419<!-- 6 -->
1420    <SpaceShip position="2000,-4000,5000" lookat="-1300,-600,900" name="attacker" visible="true">
1421        <events>
1422            <visibility>
1423                <EventListener event="ondock" />
1424            </visibility>
1425        </events>
1426        <templates>
1427            <Template link=spaceshippirate /> <!--spaceshipTransporter -->
1428        </templates>
1429        <controller>
1430            <WaypointPatrolController alertnessradius=3129 team=1 active=false>
1431                <waypoints>
1432                    <Model mesh="cube.mesh" scale=0 position="-1300,-600,900" />
1433                    <Model mesh="cube.mesh" scale=0 position="0,0,0" />
1434                </waypoints>
1435                <events>
1436                    <activity>
1437                        <EventListener event="attack" /> <!-- activates enemies-->
1438                     </activity>
1439                </events>
1440            </WaypointPatrolController>
1441        </controller>
1442    </SpaceShip>
1443
1444
1445<!-- @Triggers: attacktriggerX <-> X enemies destroyed , X is an element of [1,6] -->
1446    <EventTrigger name="attacktrigger6" activations="1" stayactive="true">
1447      <events>
1448        <trigger>
1449          <EventListener event="attacker" />
1450        </trigger>
1451      </events>
1452      <EventTrigger name="attacktrigger5" activations="1" stayactive="true" delay=0.1>
1453        <events>
1454          <trigger>
1455            <EventListener event="attacker" />
1456          </trigger>
1457        </events>
1458        <EventTrigger name="attacktrigger4" activations="1" stayactive="true" delay=0.1>
1459          <events>
1460            <trigger>
1461              <EventListener event="attacker" />
1462            </trigger>
1463          </events>
1464          <EventTrigger name="attacktrigger3" activations="1" stayactive="true" delay=0.1>
1465            <events>
1466              <trigger>
1467                <EventListener event="attacker" />
1468              </trigger>
1469            </events>
1470            <EventTrigger name="attacktrigger2" activations="1" stayactive="true" delay=0.1>
1471              <events>
1472                <trigger>
1473                  <EventListener event="attacker" />
1474                </trigger>
1475              </events>
1476              <EventTrigger name="attacktrigger1" activations="1" stayactive="true" delay=0.1>
1477                <events>
1478                  <trigger>
1479                    <EventListener event="attacker" />
1480                  </trigger>
1481                </events>
1482              </EventTrigger>
1483            </EventTrigger>
1484          </EventTrigger>
1485        </EventTrigger>
1486      </EventTrigger>
1487    </EventTrigger>
1488
1489
1490    <SimpleNotification message="5 enemies left!" broadcast="true">
1491      <events>
1492        <trigger>
1493          <EventListener event="attacktrigger1" />
1494        </trigger>
1495      </events>
1496    </SimpleNotification>
1497
1498    <SimpleNotification message="4 enemies left!" broadcast="true">
1499      <events>
1500        <trigger>
1501          <EventListener event="attacktrigger2" />
1502        </trigger>
1503      </events>
1504    </SimpleNotification>
1505
1506    <SimpleNotification message="3 enemies left!" broadcast="true">
1507      <events>
1508        <trigger>
1509          <EventListener event="attacktrigger3" />
1510        </trigger>
1511      </events>
1512    </SimpleNotification>
1513
1514    <SimpleNotification message="2 enemies left!" broadcast="true">
1515      <events>
1516        <trigger>
1517          <EventListener event="attacktrigger4" />
1518        </trigger>
1519      </events>
1520    </SimpleNotification>
1521
1522    <SimpleNotification message="One enemy left!" broadcast="true">
1523      <events>
1524        <trigger>
1525          <EventListener event="attacktrigger5" />
1526        </trigger>
1527      </events>
1528    </SimpleNotification>
1529
1530    <SimpleNotification message="Well done. You finished this tutorial." broadcast="true">
1531      <events>
1532        <trigger>
1533          <EventListener event="attacktrigger6" />
1534        </trigger>
1535      </events>
1536    </SimpleNotification>
1537
1538<!-- @Triggers: postAttack <-> delayed attacktrigger6 -->
1539    <EventTrigger name="postAttack1" activations="1" stayactive="true" delay=4.1>
1540      <events>
1541        <trigger>
1542          <EventListener event="attacktrigger6" />
1543        </trigger>
1544      </events>
1545    </EventTrigger>
1546
1547    <EventTrigger name="postAttack2" activations="1" stayactive="true" delay=8.2>
1548      <events>
1549        <trigger>
1550          <EventListener event="attacktrigger6" />
1551        </trigger>
1552      </events>
1553    </EventTrigger>
1554
1555    <SimpleNotification message="Either quit by pressing (Esc) or ..." broadcast="true">
1556      <events>
1557        <trigger>
1558          <EventListener event="postAttack1" />
1559        </trigger>
1560      </events>
1561    </SimpleNotification>
1562
1563    <SimpleNotification message="... stay here to learn some tricks." broadcast="true">
1564      <events>
1565        <trigger>
1566          <EventListener event="postAttack2" />
1567        </trigger>
1568      </events>
1569    </SimpleNotification>
1570
1571<!-------------------------------------- |Bonus Part| --------------------------------------->
1572<!-- @Triggers: "bonusX" <->  delayed "attacktrigger6" -->
1573    <EventTrigger name="bonus1" activations="1" stayactive="true" delay=12.3>
1574      <events>
1575        <trigger>
1576          <EventListener event="attacktrigger6" />
1577        </trigger>
1578      </events>
1579    </EventTrigger>
1580    <EventTrigger name="bonus2" activations="1" stayactive="true" delay=16.4>
1581      <events>
1582        <trigger>
1583          <EventListener event="attacktrigger6" />
1584        </trigger>
1585      </events>
1586    </EventTrigger>
1587    <EventTrigger name="bonus3" activations="1" stayactive="true" delay=22>
1588      <events>
1589        <trigger>
1590          <EventListener event="attacktrigger6" />
1591        </trigger>
1592      </events>
1593    </EventTrigger>
1594    <EventTrigger name="bonus4" activations="1" stayactive="true" delay=28.1>
1595      <events>
1596        <trigger>
1597          <EventListener event="attacktrigger6" />
1598        </trigger>
1599      </events>
1600    </EventTrigger>
1601    <EventTrigger name="bonus5" activations="1" stayactive="true" delay=32.3>
1602      <events>
1603        <trigger>
1604          <EventListener event="attacktrigger6" />
1605        </trigger>
1606      </events>
1607    </EventTrigger>
1608    <EventTrigger name="bonus6" activations="1" stayactive="true" delay=36.5>
1609      <events>
1610        <trigger>
1611          <EventListener event="attacktrigger6" />
1612        </trigger>
1613      </events>
1614    </EventTrigger>
1615    <EventTrigger name="bonus7" activations="1" stayactive="true" delay=4.1>
1616      <events>
1617        <trigger>
1618          <EventListener event="bonus6" />
1619        </trigger>
1620      </events>
1621    </EventTrigger>
1622
1623
1624
1625    <SimpleNotification message="Rotate your ship. Press (Q) or (E). "  broadcast="true">
1626        <events>
1627            <trigger>
1628                <EventListener event=bonus1 />
1629            </trigger>
1630        </events>
1631    </SimpleNotification>
1632
1633    <SimpleNotification message="Switch the camera's position. Press (C). "  broadcast="true">
1634        <events>
1635            <trigger>
1636                <EventListener event=bonus2 />
1637            </trigger>
1638        </events>
1639    </SimpleNotification>
1640
1641    <SimpleNotification message="360° view: press (Ctrl) + use the mouse "  broadcast="true">
1642        <events>
1643            <trigger>
1644                <EventListener event=bonus3 />
1645            </trigger>
1646        </events>
1647    </SimpleNotification>
1648
1649    <SimpleNotification message="Have a look at the main menu's settings."  broadcast="true">
1650        <events>
1651            <trigger>
1652                <EventListener event=bonus4 />
1653            </trigger>
1654        </events>
1655    </SimpleNotification>
1656
1657    <SimpleNotification message="E.g: Settings > Miscellaneous > Nr. of bots"  broadcast="true">
1658        <events>
1659            <trigger>
1660                <EventListener event=bonus5 />
1661            </trigger>
1662        </events>
1663    </SimpleNotification>
1664
1665    <SimpleNotification message="You successfully finished Mission One!"  broadcast="true">
1666        <events>
1667            <trigger>
1668                <EventListener event=bonus6 />
1669            </trigger>
1670        </events>
1671    </SimpleNotification>
1672
1673    <SimpleNotification message="Press (Esc) and return to the main menu."  broadcast="true">
1674        <events>
1675            <trigger>
1676                <EventListener event=bonus7 />
1677            </trigger>
1678        </events>
1679    </SimpleNotification>
1680
1681<!-- @Triggers: HACK. The attacktrigger6 Event is created, but does not trigger the Script.
1682(WTF?) TODO: looks like a BUG
1683Thus a distanceTrigger is created, that gets enabled, when the inner trigger gets activated.
1684Due to the large radius it is likely that it actually gets triggered.
1685-->
1686
1687  <DistanceTrigger name="testDistanceTrigger" position="0,0,0" distance=10000 target="Pawn" stayActive="true" delay=37.0>
1688    <EventTrigger name="testEventTrigger" activations="1" stayactive="true" delay=0.1>
1689      <events>
1690        <trigger>
1691          <EventListener event="attacktrigger6" />
1692        </trigger>
1693      </events>
1694    </EventTrigger>
1695  </DistanceTrigger>
1696
1697    <Script code="Mission endMission true" onLoad="false">
1698        <events>
1699            <trigger>
1700                <EventListener event="testDistanceTrigger" />
1701            </trigger>
1702        </events>
1703    </Script>
1704
1705    <Script code="Mission endMission false" onLoad="false">
1706        <events>
1707            <trigger>
1708                <EventListener event="gameEnd" />
1709            </trigger>
1710        </events>
1711    </Script>
1712
1713
1714
1715
1716
1717
1718    <!--Script code="addBots 3" onLoad="false">
1719        <events>
1720            <trigger>
1721                <EventListener event=bonus6 />
1722            </trigger>
1723        </events>
1724    </Script>
1725
1726    <Script code="artificialcontroller setbotlevel 0.1" onLoad="false">
1727        <events>
1728            <trigger>
1729                <EventListener event=bonus6 />
1730            </trigger>
1731        </events>
1732    </Script-->
1733    <!-- Script code="artificialcontroller setbotlevel 0.1" /-->
1734  </Scene>
1735</Level>
1736
1737<!-- TODO:
1738- Story & more precise Questmessages; more quest hints; fail-quest;
1739- Colouring: Show who is friend or foe via the colour
1740- Waypoints: show the player the way
1741- Foolproof text messages (e.g. verspätete Nachrichten unterdrücken ~done )
1742- End Tutorial, if either the Hydrogen Farmer or the SpaceCruiser gets destroyed. (~done)
1743 -->
Note: See TracBrowser for help on using the repository browser.