Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/levelMichael/data/levels/missionOne.oxw @ 9888

Last change on this file since 9888 was 9743, checked in by schlaem, 11 years ago

The eventtrigger for the pirate doesn't work. When you shot the pirate, the quest spacefight.guard1 should be completed. but there is no reaction.
I've tried to copy the code new from mission one but it wasn't succesfull.

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