Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/Boxhead_FS19/data/levels/expeditionSector.oxw @ 12398

Last change on this file since 12398 was 11802, checked in by landauf, 7 years ago

migrated NotificationLayer.lua to cegui 0.8

  • Property svn:eol-style set to native
File size: 30.9 KB
Line 
1<LevelInfo
2    name = "Expedition to Sector 5C"
3    description = "Commander, our scientists are reporting strange binary radio signals from a yet unexplored and thought to be uninhabited region, sector 5C. Explore the sector and get to the bottom of these messages!"
4    tags = "mission"
5    screenshot = "expeditionSector.png"
6/>
7
8<?lua
9    include("stats.oxo")
10    include("HUDTemplates3.oxo")
11    include("HUDTemplatesFPS.oxo")
12    include("templates/lodInformation.oxt")
13
14    include("templates/spaceshipAssff.oxt")
15    include("templates/spaceshipPirate.oxt")
16    include("templates/spaceshipEscort.oxt")
17    include("templates/spaceshipShuttle.oxt")
18    include("templates/FPS.oxt")
19    include("templates/pickupRepresentationTemplates.oxt")
20?>
21
22<Level gametype = "Mission">
23    <templates>
24        <Template link="lodtemplate_default" />
25    </templates>
26
27    <?lua include("includes/notifications.oxi") ?>
28
29    <NotificationQueueCEGUI
30        name="narrative"
31        targets="simpleNotification"
32        size=3
33        displayTime=3.9
34        position="0.15, 0, 0.1, 0"
35        fontSize="15"
36        fontColor="0.3, 1, 0.2, 0.8"
37        alignment="CentreAligned"
38        displaySize="0.7, 0, 0, 0"
39    />
40
41    <!-- GLOBAL LUA VARIABLES -->
42    <?lua
43
44        --[[ Coordinates in (y,z,x). NOTE: Indexing starts at 1 in lua! Don´t forget to adapt the for loops, too! ]]--
45        cCenter = {0, 0, 0}
46        cSpawn = {-50, 0, 0}
47        cSector = {-15000, -5500, -9000}
48        cSectorEntry = {-4710, -5500, -2826}
49        cPathToEntry = {{0, -2000, 0}}
50        cBeacon = {-6500, -5500, -4400}
51
52        radSector = 12000
53
54            cStationA = {1400, 400, -800}
55        cNewShip = {1000, 250, -350}
56
57        cPlanet1 = {20000, 0, 29000}
58        cPlanet2 = {-22000, 0, -29000}
59
60        cEnemyBasePlanet = {-20000, -5500, -8000}
61
62        cEnemyBaseStation1 = {-12500, -4500, -3500}
63
64              cField1 = {-5000, -4000, -3000}
65              cField2 = {4000, 2000, 4500}
66
67        --[[ Function to print Coordinates. Quotes not included! ]]--
68        function printC(coord)
69          print(coord[1] .. [[,]] .. coord[2] .. [[,]] .. coord[3])
70        end
71
72        --[[ Function to add Coordinates.]]--
73        function addC(coord1, coord2)
74            return {coord1[1]+coord2[1], coord1[2]+coord2[2], coord1[3]+coord2[3]}
75        end
76    ?>
77
78    <Scene
79        ambientlight = "0.8, 0.8, 0.8"
80        skybox = "Orxonox/skyBoxMoreNebula"
81        hasPhysics = true
82    >
83
84    <SpawnPoint name="playerSpawn" team=0 position="<?lua printC(cSpawn) ?>" lookat="<?lua printC(cCenter) ?>" spawnclass=SpaceShip pawndesign=spaceshipescort />
85
86    <WorldAmbientSound source="Earth.ogg" looping="true" playOnLoad="true" />
87
88    <Light type=directional position="<?lua printC(cCenter) ?>" 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"/>
89
90    <!--QUEST DEFINITIONS-->
91
92    <GlobalQuest id="quest1">
93        <QuestDescription title="Get the scout ship" description="We received some extraterrestial binary radio signals from Sector 5C! We'd like you to get to the outer base in sector 4A and get a scout ship to explore the sector!" failMessage="" completeMessage="" />
94        <hints>
95        </hints>
96        <complete-effects>
97            <AddQuest questId="quest2" />
98        </complete-effects>
99    </GlobalQuest>
100
101    <GlobalQuest id="quest2">
102        <QuestDescription title="Explore the sector" description="Now then, Commander, fly over there to check out if life can be found in what we believed it to be an inhabitated region in space. We have marked 5B with red lights so you can easily find it." failMessage="" completeMessage="" />
103        <hints>
104        </hints>
105        <subquests>
106            <GlobalQuest id="quest2.1">
107                <QuestDescription title="> Get to the Field Source" description="We percieve a large magnetic field source at a certain spot in the sector. You should check it out! We have marked it with a blue light." failMessage="" completeMessage="" />
108                <hints>
109                </hints>
110                <complete-effects>
111                    <AddQuest questId="quest2.2" />
112                </complete-effects>
113            </GlobalQuest>
114            <GlobalQuest id="quest2.2">
115                <QuestDescription title="> Fight your way out" description="Oh no... this cannot be happening! We discovered an alien race, and it does not seem to be interested in peace. In fact, they seem to be planning an attack! You must get out of the hot zone. Fight if necessary!" failMessage="" completeMessage="" />
116                <hints>
117                </hints>
118                <complete-effects>
119                    <AddQuest questId="quest3" />
120                </complete-effects>
121            </GlobalQuest>
122        </subquests>
123    </GlobalQuest>
124
125    <GlobalQuest id="quest3">
126        <QuestDescription title="Get back to 4A" description="You made it out in one piece. Now report to base 4A to warn the others!" failMessage="" completeMessage="" />
127        <hints>
128        </hints>
129    </GlobalQuest>
130
131    <!--EVENTS AND TRIGGERS
132        Usable events and triggers:
133        spawntrigger
134        dockA
135        reachedSector
136        reachedEnemyStation
137        fightEnd
138        backToA
139
140        BASE-STORY-LINE:
141        We receive a message from commander (SimpleNotification -> SpawnTrigger) about alien radio activity in a nearby sector and are asked to change our spaceship
142        QUEST1: Dock to Station and get better Spaceship
143        TRIGGER: Docked to Station
144        EVENT: Change Spaceship and Sector 5C becomes visilbe
145
146        We are asked to go to the sector and explore it
147        QUEST2.1: Go to Sector 5C and see what you can find there
148        TRIGGER: Distance Trigger at enemy spacestation, with a rather large radius
149        EVENT: The 25 Enemies and there SpaceStation become visible, the planet should stay invisible; the patroling enemies on your way back become visible as well.
150
151        On your way back you discover the patroling enemy spaceships, they attack you, but you must survive and report to your commander about an possible upcoming attack from the aliens
152        QUEST2.2: Destroy the patroling spaceships, spare no one
153        TRIGGER: -------- The patroling spaceships should triggered bythemselves?
154        EVENT: After destroying all 5 enemy ships, you can return to your base and safety, the Distancetrigger for next quest is activated
155        FAIL: You fail if you die here
156
157        After destroying the enemy ships, you make it bake to your station in time to report about the hord of enemies you saw and start preparing for the upcoming fight!
158        QUEST3: Go back to spacestation
159        TRIGGER: Distancetrigger i suppose?
160        EVENT: You win this level, and the main level is unlocked.
161    -->
162
163    <EventMultiTrigger name="spawntrigger">
164        <events>
165            <trigger>
166                <EventListener event="playerSpawn" />
167            </trigger>
168        </events>
169    </EventMultiTrigger>
170
171    <!-- HACK: just waited out 3sec for animation. Cannot link an event to the COMPLETION of a dock. How is this not possible?? -->
172    <EventMultiTrigger name="dockedA" activations="1" stayactive="true" delay=3>
173        <events>
174            <trigger>
175                <EventListener event="dockA" />
176            </trigger>
177        </events>
178    </EventMultiTrigger>
179
180    <DistanceTrigger name="reachedSector" position="<?lua printC(cSector) ?>" distance="<?lua print(radSector) ?>" target="SpaceShip" beaconMode="identify" targetname="newSpaceShip" stayactive=true />
181
182    <DistanceTrigger name="reachedEnemyStation" position="<?lua printC(cEnemyBaseStation1) ?>" distance="5000" target="SpaceShip" beaconMode="identify" targetname="newSpaceShip" stayactive=true />
183
184    <!-- Recursive helper function for the fightEnd event -->
185    <?lua
186    function enemyTriggerRecursor(i)
187    if i > 0 then
188    return [[
189    <EventTrigger name=killedEnemy]] .. i .. [[ activations=1 stayactive=true delay=0.1>
190        <events>
191            <trigger>
192                <EventListener event=enemy />
193            </trigger>
194        </events>
195        ]] .. enemyTriggerRecursor(i-1) .. [[
196    </EventTrigger>
197    ]]
198    else return ""
199    end
200    end
201    ?>
202    <!-- Actual Event for the enemies. -->
203    <?lua print(enemyTriggerRecursor(5)) ?>
204    <EventMultiTrigger name="fightEnd" delay=0.1 stayactive=true>
205        <events>
206            <trigger>
207                <EventListener event="killedEnemy5" />
208            </trigger>
209        </events>
210    </EventMultiTrigger>
211
212    <DistanceTrigger active=false name="closeToPatrol" position="<?lua printC(cStationA) ?>" distance="6000" target="SpaceShip" beaconMode="identify" targetname="newSpaceShip" stayactive=true >
213        <events>
214            <activity>
215                <EventListener event="reachedEnemyStation" />
216            </activity>
217        </events>
218    </DistanceTrigger>
219
220    <DistanceTrigger active=false name="backToA" position="<?lua printC(cStationA) ?>" distance="600" target="SpaceShip" beaconMode="identify" targetname="newSpaceShip" stayactive=true >
221        <events>
222            <activity>
223                <EventListener event="fightEnd" />
224            </activity>
225        </events>
226    </DistanceTrigger>
227
228    <Script code="Mission endMission true" onLoad="false">
229        <events>
230            <trigger>
231                <EventListener event="backToA" />
232            </trigger>
233        </events>
234    </Script>
235
236    <DistanceTrigger invert=true active=false name="hasDied" position="<?lua printC(cSector) ?>" distance="100000" target="SpaceShip" beaconMode="identify" targetname="newSpaceShip" stayactive=true >
237        <events>
238            <activity>
239                <EventListener event="reachedSector" />
240            </activity>
241        </events>
242    </DistanceTrigger>
243
244    <Script code="Mission endMission fail" onLoad="false">
245        <events>
246            <trigger>
247                <EventListener event="hasDied" />
248            </trigger>
249        </events>
250    </Script>
251
252    <!--QUEST EFFECT BEACONS -->
253
254    <QuestEffectBeacon times=1>
255        <effects>
256            <AddQuest questId="quest1" />
257        </effects>
258        <events>
259            <execute>
260                <EventListener event="spawntrigger" />
261            </execute>
262        </events>
263    </QuestEffectBeacon>
264
265    <QuestEffectBeacon times=1>
266        <effects>
267            <CompleteQuest questId="quest1" />
268        </effects>
269        <events>
270            <execute>
271                <EventListener event="dockedA" />
272            </execute>
273        </events>
274    </QuestEffectBeacon>
275
276    <QuestEffectBeacon times=1>
277        <effects>
278            <AddQuest questId="quest2.1" />
279        </effects>
280        <events>
281            <execute>
282                <EventListener event="reachedSector" />
283            </execute>
284        </events>
285    </QuestEffectBeacon>
286
287    <QuestEffectBeacon times=1>
288        <effects>
289            <CompleteQuest questId="quest2.1" />
290            <AddQuest questId="quest2.2" />
291        </effects>
292        <events>
293            <execute>
294                <EventListener event="reachedEnemyStation" />
295            </execute>
296        </events>
297    </QuestEffectBeacon>
298
299    <QuestEffectBeacon times=1>
300        <effects>
301            <CompleteQuest questId="quest2.2" />
302            <CompleteQuest questId="quest2" />
303        </effects>
304        <events>
305            <execute>
306                <EventListener event="fightEnd" />
307            </execute>
308        </events>
309    </QuestEffectBeacon>
310
311    <!--NOTIFICATIONS -->
312
313    <SimpleNotification broadcast="true" message="Welcome, Commander.">
314        <events>
315            <trigger>
316                <EventTrigger stayactive="true" delay=4 >
317                   <events>
318                      <trigger>
319                         <EventListener event="spawntrigger" />
320                      </trigger>
321                   </events>
322                </EventTrigger>
323            </trigger>
324        </events>
325    </SimpleNotification>
326
327    <SimpleNotification broadcast="true" message="We've picked up strange radio Signals from Sector 5B!">
328        <events>
329            <trigger>
330                <EventTrigger stayactive="true" delay=8 >
331                   <events>
332                      <trigger>
333                         <EventListener event="spawntrigger" />
334                      </trigger>
335                   </events>
336                </EventTrigger>
337            </trigger>
338        </events>
339    </SimpleNotification>
340
341    <SimpleNotification broadcast="true" message="Please dock to the outer base and get into the scout ship!">
342        <events>
343            <trigger>
344                <EventTrigger stayactive="true" delay=12 >
345                   <events>
346                      <trigger>
347                         <EventListener event="spawntrigger" />
348                      </trigger>
349                   </events>
350                </EventTrigger>
351            </trigger>
352        </events>
353    </SimpleNotification>
354
355    <SimpleNotification broadcast="true" message="We have marked the sector in red Lights. Enter it!">
356        <events>
357            <trigger>
358                <EventTrigger stayactive="true" delay=0 >
359                   <events>
360                      <trigger>
361                         <EventListener event="dockedA" />
362                      </trigger>
363                   </events>
364                </EventTrigger>
365            </trigger>
366        </events>
367    </SimpleNotification>
368
369    <SimpleNotification broadcast="true" message="Huh? Something's emanating a strong field... We marked it in blue.">
370        <events>
371            <trigger>
372                <EventTrigger stayactive="true" delay=0 >
373                   <events>
374                      <trigger>
375                         <EventListener event="reachedSector" />
376                      </trigger>
377                   </events>
378                </EventTrigger>
379            </trigger>
380        </events>
381    </SimpleNotification>
382
383    <SimpleNotification broadcast="true" message="Woah! What the hell? We made alien contact!">
384        <events>
385            <trigger>
386                <EventTrigger stayactive="true" delay=0 >
387                   <events>
388                      <trigger>
389                         <EventListener event="reachedEnemyStation" />
390                      </trigger>
391                   </events>
392                </EventTrigger>
393            </trigger>
394        </events>
395    </SimpleNotification>
396
397    <SimpleNotification broadcast="true" message="It looks like they are getting ready to attack someone...">
398        <events>
399            <trigger>
400                <EventTrigger stayactive="true" delay=4 >
401                   <events>
402                      <trigger>
403                         <EventListener event="reachedEnemyStation" />
404                      </trigger>
405                   </events>
406                </EventTrigger>
407            </trigger>
408        </events>
409    </SimpleNotification>
410
411    <SimpleNotification broadcast="true" message="It must be us! Commander, get back to the base and report!">
412        <events>
413            <trigger>
414                <EventTrigger stayactive="true" delay=8 >
415                   <events>
416                      <trigger>
417                         <EventListener event="reachedEnemyStation" />
418                      </trigger>
419                   </events>
420                </EventTrigger>
421            </trigger>
422        </events>
423    </SimpleNotification>
424
425    <SimpleNotification broadcast="true" message="Oh no! A patrol! When did it get here?!">
426        <events>
427            <trigger>
428                <EventTrigger stayactive="true" delay=0 >
429                   <events>
430                      <trigger>
431                         <EventListener event="closeToPatrol" />
432                      </trigger>
433                   </events>
434                </EventTrigger>
435            </trigger>
436        </events>
437    </SimpleNotification>
438
439    <SimpleNotification broadcast="true" message="Phew, that was close. Now get back here!">
440        <events>
441            <trigger>
442                <EventTrigger stayactive="true" delay=0 >
443                   <events>
444                      <trigger>
445                         <EventListener event="fightEnd" />
446                      </trigger>
447                   </events>
448                </EventTrigger>
449            </trigger>
450        </events>
451    </SimpleNotification>
452
453    <!--STATIONS -->
454
455    <Template name="station">
456        <Pawn mass=10000000 collisionType=dynamic friction=0.01>
457            <attached>
458                <Model mesh="HydroHarvester.mesh" position="0,0,0" scale=50 />
459                <DistanceTriggerBeacon name="NPC" />
460            </attached>
461            <collisionShapes>
462                <BoxCollisionShape  position="-560,0,0" halfExtents="115,100,245" /><!-- Three lower boxes -->
463                <BoxCollisionShape  position="290,0,-480" halfExtents="115,100,245" yaw=-120 />
464                <BoxCollisionShape  position="290,0,480" halfExtents="115,100,245" yaw=-240 />
465                <BoxCollisionShape  position="-280,0,0" halfExtents="163,50,50" /><!-- Three lower connections -->
466                <BoxCollisionShape  position="140,0,-240" halfExtents="163,50,50" yaw=-120 />
467                <BoxCollisionShape  position="140,0,240" halfExtents="163,50,50" yaw=-240 />
468                <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" /><!-- Upper Tower -->
469                <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" yaw=-120 />
470                <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" yaw=-240 />
471                <BoxCollisionShape  position="0,400,0" halfExtents="43,110,26" yaw=-30 /><!-- Middle one-->
472                <BoxCollisionShape  position="-200,100,0" halfExtents="26,50,43" /><!--Three lower legs -->
473                <BoxCollisionShape  position="100,100,-173" halfExtents="43,50,26" yaw=-30 />
474                <BoxCollisionShape  position="100,100,-173" halfExtents="43,50,26" yaw=30 />
475                <BoxCollisionShape  position="-100,264,0" halfExtents="26,105,43" roll=-49 /><!--Three upper legs -->
476                <BoxCollisionShape  position="50,264,-87" halfExtents="26,105,43" roll=-49 yaw=-120 />
477                <BoxCollisionShape  position="50,264,87" halfExtents="26,105,43" roll=-49 yaw=-240 />
478            </collisionShapes>
479        </Pawn>
480    </Template>
481
482    <Pawn name="statA" team=0 radarname="Outer Base - Sector 4B" position="<?lua printC(cStationA) ?>" direction="<?lua printC(cSpawn) ?>" yaw=45 pitch=-5 roll=-25 initialhealth=10000 maxhealth=10000 >
483        <templates>
484            <Template link="station" />
485        </templates>
486        <attached>
487            <DockingTarget name="dockTargetA" />
488            <Dock position="0,0,0" active=true>
489                <animations>
490                    <MoveToDockingTarget target="dockTargetA" />
491                </animations>
492                <effects>
493                    <DockToShip target="newSpaceShip" />
494                </effects>
495                <events>
496                    <execute>
497                        <EventListener event="dockA" />
498                    </execute>
499                </events>
500                <attached>
501                    <DistanceTrigger position="0,0,0" distance="200" target="SpaceShip" beaconMode="exclude" targetname="NPC" name="dockA" />
502                    <Billboard position="0,0,0" amplitude=1 material="Flares/lensflare" colour="1,0,0.05" />
503                </attached>
504            </Dock>
505        </attached>
506    </Pawn>
507
508    <!-- EnemyStation -->
509
510    <!-- Marking Billboard -->
511    <Billboard visible=false position="<?lua printC(cEnemyBaseStation1) ?>" amplitude=30 scale=2 material="Flares/lensflare" colour="0,0,1">
512        <events>
513           <visibility>
514              <EventListener event="reachedSector" />
515          </visibility>
516        </events>
517    </Billboard>
518
519
520    <Pawn name="statB" team=1 radarname="EnemyBase" position="<?lua printC(cEnemyBaseStation1) ?>" direction="<?lua printC(cSpawn) ?>" yaw=45 pitch=-5 roll=-25 initialhealth=10000 maxhealth=10000 >
521        <templates>
522            <Template link="station" />
523        </templates>
524        <events>
525            <visibility>
526                <EventListener event="reachedEnemyStation" />
527            </visibility>
528            <activity>
529                <EventListener event="reachedEnemyStation" />
530            </activity>
531        </events>
532    </Pawn>
533
534    <!-- New SpaceShip as destination of dock A-->
535    <SpaceShip
536            template            = "spaceshipassff"
537            team                = "0"
538            position            = "<?lua printC(cNewShip) ?>"
539            lookat              = "<?lua printC(cSector) ?>"
540            health              = "1500"
541            initialhealth       = "1500"
542            maxhealth           = "1500"
543            shieldhealth        = "80"
544            initialshieldhealth = "80"
545            maxshieldhealth     = "120"
546            shieldabsorption    = "0.8"
547            reloadrate          = "1"
548            reloadwaittime      = "1"
549            name                = "newSpaceShip"
550            radarname           = "ScoutShip" >
551        <attached>
552            <DockingTarget name="newSpaceShip" />
553            <DistanceTriggerBeacon name="newSpaceShip" />
554        </attached>
555    </SpaceShip>
556
557    <!--ELEMENTS -->
558
559    <?lua
560    for i = 1, 64, 1
561    do
562    rBillboard = {math.sin(i*math.pi/32)*radSector, 0, math.cos(i*math.pi/32)*radSector}
563    cBillNow = addC(cSector,rBillboard)
564    ?>
565    <Billboard position="<?lua printC(cBillNow) ?>"  scale=10 material="Flares/lensflare" colour="1,0.2,0.2" visible=false>
566        <events>
567            <visibility>
568                <EventListener event="dockedA" />
569            </visibility>
570        </events>
571    </Billboard>
572    <?lua end ?>
573
574    <!-- Asteroids you have to fly through to get to the EnemyBase -->
575
576    <?lua
577        dofile("includes/asteroidField.lua")
578       asteroidField(cField1[1], cField1[2], cField1[3], 20, 30, 4500, 500, 0)
579    ?>
580
581    <!-- Other Asteroid-Fields -->
582
583    <?lua
584        dofile("includes/asteroidField.lua")
585       asteroidField(cField2[1], cField2[2], cField2[3], 20, 30, 4500, 500, 0)
586    ?>
587
588    <!-- Planets -->
589
590    <MovableEntity
591        position="<?lua printC(cPlanet1) ?>"
592        scale="3000"
593        collisionType="dynamic"
594        linearDamping="0.8"
595        angularDamping="0"
596        mass="5000000"
597        pitch="0"
598        rotationaxis="1,0,0"
599        rotationrate="1.0"
600        collisiondamage=2
601        enablecollisiondamage=true
602    >
603      <attached>
604        <Planet
605            mesh="planets/muunilinst.mesh"
606            atmosphere="atmosphere1"
607            atmospheresize="80.0f"
608            imagesize="1024.0f"
609            visible=true
610            active=ture
611        >
612          <attached>
613            <ForceField position="0,0,0" mode="sphere" diameter="6000" velocity="-500" />
614          </attached>
615        </Planet>
616      </attached>
617      <collisionShapes>
618        <SphereCollisionShape radius="3000" position="0,0,0" />
619      </collisionShapes>
620    </MovableEntity>
621
622    <?lua
623        dofile("includes/asteroidField.lua")
624        asteroidBelt(cPlanet1[1], cPlanet1[2], cPlanet1[3], 30, 20, 100, 20, 40, 3400, 3700, 400, 1)
625    ?>
626
627    <MovableEntity
628        position="<?lua printC(cPlanet2) ?>"
629        scale="2000"
630        collisionType="dynamic"
631        linearDamping="0.8"
632        angularDamping="0"
633        mass="5000000"
634        pitch="0"
635        rotationaxis="1,0,0"
636        rotationrate="1.0"
637        collisiondamage=2
638        enablecollisiondamage=true
639    >
640      <attached>
641          <Planet
642            mesh="planets/ganymede.mesh"
643            atmosphere="atmosphere1"
644            atmospheresize="80.0f"
645            imagesize="1024.0f"
646            visible=true
647            active=true
648          >
649            <attached>
650              <ForceField position="0,0,0" mode="sphere" diameter="4000" velocity="-500" />
651            </attached>
652          </Planet>
653      </attached>
654      <collisionShapes>
655        <SphereCollisionShape radius="2000" position="0,0,0" />
656      </collisionShapes>
657    </MovableEntity>
658
659    <?lua
660        dofile("includes/asteroidField.lua")
661        asteroidBelt(cPlanet2[1], cPlanet2[2], cPlanet2[3], 30, 20, 100, 20, 40, 3400, 3700, 400, 1)
662    ?>
663
664    <!-- EnemyPlanet(s) -->
665
666    <MovableEntity
667        position="<?lua printC(cEnemyBasePlanet) ?>"
668        scale="5000"
669        collisionType="dynamic"
670        linearDamping="0.8"
671        angularDamping="0"
672        mass="5000000"
673        pitch="0"
674        rotationaxis="1,0,0"
675        rotationrate="1.0"
676        collisiondamage=2
677        enablecollisiondamage=true
678    >
679      <attached>
680        <Planet
681            mesh="planets/jupiter.mesh"
682            atmosphere="atmosphere1"
683            atmospheresize="80.0f"
684            imagesize="1024.0f"
685            visible=false
686            active=false
687          >
688          <attached>
689            <ForceField position="0,0,0" mode="sphere" diameter="10000" velocity="-500" />
690          </attached>
691        </Planet>
692      </attached>
693      <collisionShapes>
694        <SphereCollisionShape radius="5000" position="0,0,0" />
695      </collisionShapes>
696    </MovableEntity>
697
698    <?lua
699      xi = 5
700      zi = 5
701      for k = 1, xi, 1
702      do
703    ?>
704    <?lua
705      for j = 1, zi, 1
706      do
707      x = -2500+k*100
708      z = -4400+j*100
709    ?>
710    <SpaceShip visible=false active=false name="enemyStalled" radarname="Attacker" position="-11000,<?lua print(z)?>,<?lua print(x)?>" lookat="0,0,0" team=1>
711        <templates>
712            <Template link="spaceshippirate" />
713        </templates>
714        <events>
715            <visibility>
716                <EventListener event="reachedEnemyStation" />
717            </visibility>
718        </events>
719    </SpaceShip>
720    <?lua end ?>
721    <?lua end ?>
722
723    <SpaceShip visible=false active=false name="enemy" radarname="Guard" position="-2700,-800,-800" lookat="0,0,0" team=1>
724      <templates>
725        <Template link=spaceshippirate />
726      </templates>
727      <events>
728          <visibility>
729              <EventListener event="reachedEnemyStation" />
730          </visibility>
731          <activity>
732              <EventListener event="reachedEnemyStation" />
733          </activity>
734      </events>
735      <controller>
736        <WaypointPatrolController active=false accuracy=40 alertnessradius=2000 team=1>
737            <events>
738                <activity>
739                    <EventListener event="reachedEnemyStation" />
740                </activity>
741            </events>
742          <waypoints>
743            <StaticEntity position="-3400,-1200,-200" />
744            <StaticEntity position="-1600,-1000,-200" />
745            <StaticEntity position="-1700,-1400,-940" />
746            <StaticEntity position="-2100,-1200,-1250" />
747            <StaticEntity position="-2700,-800,-800" />
748          </waypoints>
749        </WaypointPatrolController>
750      </controller>
751    </SpaceShip>
752
753    <SpaceShip visible=false active=false name="enemy" radarname="Guard" position="-3400,-1200,-200" lookat="0,0,0" team=1>
754        <events>
755            <visibility>
756                <EventListener event="reachedEnemyStation" />
757            </visibility>
758            <activity>
759                <EventListener event="reachedEnemyStation" />
760            </activity>
761        </events>
762      <templates>
763        <Template link=spaceshippirate />
764      </templates>
765      <controller>
766        <WaypointPatrolController active=false accuracy=40 alertnessradius=2000 team=1>
767            <events>
768                <activity>
769                    <EventListener event="reachedEnemyStation" />
770                </activity>
771            </events>
772          <waypoints>
773            <StaticEntity position="-1600,-1000,-200" />
774            <StaticEntity position="-1700,-1400,-940" />
775            <StaticEntity position="-2100,-1200,-1250" />
776            <StaticEntity position="-2700,-800,-800" />
777            <StaticEntity position="-3400,-1200,-200" />
778          </waypoints>
779        </WaypointPatrolController>
780      </controller>
781    </SpaceShip>
782
783    <SpaceShip visible=false active=false name="enemy" radarname="Guard" position="-1600,-1000,-200" lookat="0,0,0" team=1>
784        <events>
785            <visibility>
786                <EventListener event="reachedEnemyStation" />
787            </visibility>
788            <activity>
789                <EventListener event="reachedEnemyStation" />
790            </activity>
791        </events>
792      <templates>
793        <Template link=spaceshippirate />
794      </templates>
795      <controller>
796        <WaypointPatrolController active=false accuracy=40 alertnessradius=2000 team=1>
797            <events>
798                <activity>
799                    <EventListener event="reachedEnemyStation" />
800                </activity>
801            </events>
802          <waypoints>
803            <StaticEntity position="-1700,-1400,-940" />
804            <StaticEntity position="-2100,-1200,-1250" />
805            <StaticEntity position="-2700,-800,-800" />
806            <StaticEntity position="-3400,-1200,-200" />
807            <StaticEntity position="-1600,-1000,-200" />
808          </waypoints>
809        </WaypointPatrolController>
810      </controller>
811    </SpaceShip>
812
813    <SpaceShip visible=false active=false name="enemy" radarname="Guard" position="-1700,-1400,-940" lookat="0,0,0" team=1>
814        <events>
815            <visibility>
816                <EventListener event="reachedEnemyStation" />
817            </visibility>
818            <activity>
819                <EventListener event="reachedEnemyStation" />
820            </activity>
821        </events>
822      <templates>
823        <Template link=spaceshippirate />
824      </templates>
825      <controller>
826        <WaypointPatrolController active=false accuracy=40 alertnessradius=2000 team=1>
827            <events>
828                <activity>
829                    <EventListener event="reachedEnemyStation" />
830                </activity>
831            </events>
832          <waypoints>
833            <StaticEntity position="-2100,-1200,-1250" />
834            <StaticEntity position="-2700,-800,-800" />
835            <StaticEntity position="-3400,-1200,-200" />
836            <StaticEntity position="-1600,-1000,-200" />
837            <StaticEntity position="-1700,-1400,-940" />
838          </waypoints>
839        </WaypointPatrolController>
840      </controller>
841    </SpaceShip>
842
843    <SpaceShip visible=false active=false name="enemy" radarname="Guard" position="-2100,-1200,-1250" lookat="0,0,0" team=1>
844        <events>
845            <visibility>
846                <EventListener event="reachedEnemyStation" />
847            </visibility>
848            <activity>
849                <EventListener event="reachedEnemyStation" />
850            </activity>
851        </events>
852      <templates>
853        <Template link=spaceshippirate />
854      </templates>
855      <controller>
856        <WaypointPatrolController active=false accuracy=40 alertnessradius=2000 team=1>
857            <events>
858                <activity>
859                    <EventListener event="reachedEnemyStation" />
860                </activity>
861            </events>
862          <waypoints>
863            <StaticEntity position="-2700,-800,-800" />
864            <StaticEntity position="-3400,-1200,-200" />
865            <StaticEntity position="-1600,-1000,-200" />
866            <StaticEntity position="-1700,-1400,-940" />
867            <StaticEntity position="-2100,-1200,-1250" />
868          </waypoints>
869        </WaypointPatrolController>
870      </controller>
871    </SpaceShip>
872
873    </Scene>
874</Level>
Note: See TracBrowser for help on using the repository browser.