Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/trunk/data/levels/princessaeryn.oxw @ 7404

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

Adding new level notifications.oxw, to "showcase", or at this stage rather "test" Notifications.
Restoring tutorial.oxw to its old state, before it was hijacked by me for testing.

Extending Script class. Now also normal orxonox code can be executed with it, the execution of code can be triggered with Triggers (obviously) and cod can also executed on load.
I needed this to load the NotificationLayer in levels where it is needed.
Also inserted a Script that loads the NotificationQueue to display Notifications in all levels it was needed.

  • Property svn:eol-style set to native
File size: 10.9 KB
Line 
1<?lua
2  include("hudtemplates3.oxo")
3  include("stats.oxo")
4  include("templates/spaceship_assff.oxt")
5  include("templates/lodinformation.oxt")
6?>
7
8<?lua
9  dofile("includes/CuboidSpaceStation.lua")
10?>
11
12<Level
13 name     = "The Tale of Princess Aeryn"
14 description  = "The Tale of Princess Aeryn"
15>
16
17  <templates>
18    <Template link=lodtemplate_default />
19  </templates>
20
21  <Scene
22    ambientlight = "0.3, 0.3, 0.3"
23    skybox     = "Orxonox/skypanoramagen1"
24  >
25
26    <Script code="showGUI NotificationLayer false true" /
27
28    <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" />
29
30    <!-- Quest: -->
31    <GlobalQuest id="b80c2c60-e62c-4637-80f8-5aa18dc93b34">
32      <QuestDescription title="The Tale of Princess Aeryn" description="Princess Aeryn has been kidnapped by evil Mr. M and you were just a little too late to save her.\nYou have to find and save her from her captors." failMessage="You cannot fail, how did you?" completeMessage="You did it John. You're a hero. Princess Aeryn however will still not marry you." />
33      <subquests>
34        <GlobalQuest id="43766602-7e2f-4d24-976a-3f9de1474d5b">
35          <QuestDescription title="Find Aeryn's S.H.O.E.S." description="Oh, the kidnappers must have been in a hurry because they overlooked princess Aeryns S.H.O.E.S. (Super Heavily Organized Escape Ship) hidden in the asteroid field over there.\nFind it and look there for clues to Princess Aeryns whereabouts." completeMessage="You did it, Looking through her stuff you find an odd looking device - Could this be the receiver of Princess Aeryns locator beacon? - But it must be broken, the screen remains blank." />
36          <complete-effects>
37            <AddQuest questId="50845552-c8af-4091-947c-76bd850b224e" />
38          </complete-effects>
39        </GlobalQuest>
40        <GlobalQuest id="50845552-c8af-4091-947c-76bd850b224e">
41          <QuestDescription title="Repair the receiver." description="There is a space station called 'Serenity Station' near here. An engineer called Nathan Stark who shoud be able to help you lives there." completeMessage="'Yeah Nathan lives here, he'll shurely help you.'\nAnd he does, apparenty the device was just low on batteries so you're now able to locate your beloved Princess Aeryn." />
42          <hints>
43            <QuestHint id="b9b10841-b045-4797-b1d3-cfce760e1de6">
44              <QuestDescription title="The Katratzi Station" description="'We ain't buying!'\n'What do you want?'\n'No there lives no Nathan here.'\n'Fuck off.''" />
45            </QuestHint>
46            <QuestHint id="1ee785f8-b71d-4b51-b080-42cec5be8e3c">
47              <QuestDescription title="The Pegasus Station" description="'Hello friend.'\n'How can we help you?'\n'A Mr. Stark you say? Sorry no man with such a name lives here.'" />
48            </QuestHint>
49          </hints>
50          <complete-effects>
51            <AddQuest questId="97628524-b243-492c-b7b6-498f325b21d4" />
52          </complete-effects>
53        </GlobalQuest>
54        <GlobalQuest id="97628524-b243-492c-b7b6-498f325b21d4">
55          <QuestDescription title="Follow the dots" description="Just follow the dots, they'll lead you right to her." completeMessage="You found Princess Aeryn. Her captors give up at the shere sight ou you." />
56          <complete-effects>
57            <CompleteQuest questId="b80c2c60-e62c-4637-80f8-5aa18dc93b34" />
58          </complete-effects>
59        </GlobalQuest>
60      </subquests>
61    </GlobalQuest>
62
63    <!-- Create spaceship spawner: -->
64    <ParticleSpawner position="0,0,100" source="Orxonox/BigExplosion1part3" lifetime=2.0 loop=0 autostart=0>
65      <events>
66      <spawn>
67        <EventTrigger delay=1>
68        <events>
69          <trigger>
70          <SpawnPoint position="0,0,100" spawnclass=SpaceShip pawndesign=spaceshipassff />
71          </trigger>
72        </events>
73        </EventTrigger>
74      </spawn>
75      </events>
76      <attached>
77      <QuestEffectBeacon position="0,0,0" times=1>
78        <effects>
79          <AddQuest questId="b80c2c60-e62c-4637-80f8-5aa18dc93b34" />
80          <AddQuest questId="43766602-7e2f-4d24-976a-3f9de1474d5b" />
81        </effects>
82        <events>
83          <execute>
84            <EventListener event=questbeacon1 />
85          </execute>
86        </events>
87        <attached>
88          <DistanceTrigger name=questbeacon1 position="0,0,0" distance=10 target="Pawn" />
89        </attached>
90      </QuestEffectBeacon>
91      </attached>
92    </ParticleSpawner>
93
94    <!-- Create world -->
95
96      <!-- Kidnapper flying away -->
97      <MovableEntity position="200,0,0" velocity="-140,0,-140" yaw=45>
98        <attached>
99          <Model position="0,0,0" scale=4 yaw=180 pitch=-90 roll=-90 mesh="pirate.mesh" />
100          <ParticleSpawner position="0,0,10" source="Orxonox/fire3" lifetime=2.0 loop=0 autostart=1 />
101          <QuestEffectBeacon position="0,0,0" times=1 active=false name=trail >
102            <effects>
103              <CompleteQuest questId="b80c2c60-e62c-4637-80f8-5aa18dc93b34" />
104            </effects>
105            <events>
106              <execute>
107                <EventListener event=questbeacon7 />
108              </execute>
109            </events>
110            <attached>
111              <DistanceTrigger name=questbeacon7 position="0,0,0" distance=10 target="Pawn" />
112            </attached>
113          </QuestEffectBeacon>
114        </attached>
115      </MovableEntity>
116
117      <!-- Asteroid field -->
118      <StaticEntity position="-500,0,-3000">
119        <attached>
120          <?lua
121            for i = 1, 200 do
122          ?>
123            <MovableEntity position="<?lua print(math.random() * 2000 - 1000)?>, <?lua print(math.random() * 2000 - 1000) ?>, <?lua print(math.random() * 2000 - 1000) ?>" rotationaxis="<?lua print(math.random()) ?>, <?lua print(math.random()) ?>, <?lua print(math.random()) ?>" rotationrate="<?lua print(math.abs(math.random() * 30 -10)) ?>">
124              <attached>
125                <Model scale="<?lua print(math.random() * 50) ?>" mesh="ast<?lua print( math.mod(i,6) + 1) ?>.mesh" shadow=false />
126              </attached>
127            </MovableEntity>
128          <?lua end ?>
129          <!-- S.H.O.E.S -->
130          <StaticEntity position="-300,0,0">
131            <attached>
132              <Model position="0,0,0" scale=4 yaw=180 pitch=-90 roll=-90 mesh="assff.mesh" />
133              <QuestEffectBeacon position="0,0,0" times=-1>
134                <effects>
135                  <CompleteQuest questId="43766602-7e2f-4d24-976a-3f9de1474d5b" />
136                </effects>
137                <events>
138                  <execute>
139                    <EventListener event=questbeacon2 />
140                  </execute>
141                </events>
142                <attached>
143                  <DistanceTrigger name=questbeacon2 position="0,0,0" distance=50 target="Pawn" />
144                </attached>
145              </QuestEffectBeacon>
146            </attached>
147          </StaticEntity>
148        </attached>
149      </StaticEntity>
150
151
152
153      <!-- Spacestations -->
154
155      <!-- Serenity Station -->
156      <StaticEntity scale=1 position="0,0,5000" yaw=30>
157        <attached>
158          <?lua
159            createSpaceStationPar(65461,2,1,2,1,2,1,100)
160          ?>
161          <QuestEffectBeacon position="0,450,0" times=1>
162            <effects>
163              <CompleteQuest questId="50845552-c8af-4091-947c-76bd850b224e" />
164            </effects>
165            <events>
166              <execute>
167                <EventListener event=questbeacon3 />
168              </execute>
169            </events>
170            <attached>
171              <Billboard position="0,0,0" colour="1.0,1.0,0" material="Examples/Flare" />
172              <DistanceTrigger name=questbeacon3 position="0,0,0" distance=100 target="Pawn" />
173            </attached>
174          </QuestEffectBeacon>
175        </attached>
176      </StaticEntity>
177
178      <!-- Katratzi Station -->
179      <StaticEntity scale=1 position="0,5000,300" yaw=60>
180        <attached>
181          <?lua
182            createSpaceStationPar(9851,2,1,2,1,2,1,100)
183          ?>
184          <QuestEffectBeacon position="0,450,0" times=1>
185            <effects>
186              <AddQuestHint hintId="b9b10841-b045-4797-b1d3-cfce760e1de6" />
187            </effects>
188            <events>
189              <execute>
190                <EventListener event=questbeacon4 />
191              </execute>
192            </events>
193            <attached>
194              <Billboard position="0,0,0" colour="1.0,1.0,0" material="Examples/Flare" />
195              <DistanceTrigger name=questbeacon4 position="0,0,0" distance=100 target="Pawn" />
196            </attached>
197          </QuestEffectBeacon>
198        </attached>
199      </StaticEntity>
200
201      <!-- Pegasus Station -->
202      <StaticEntity scale=1 position="-5000,100,1000" roll=30>
203        <attached>
204          <?lua
205            createSpaceStationPar(3574,2,1,2,1,2,1,100)
206          ?>
207          <QuestEffectBeacon position="200,450,0" times=1>
208            <effects>
209              <AddQuestHint hintId="1ee785f8-b71d-4b51-b080-42cec5be8e3c" />
210            </effects>
211            <events>
212              <execute>
213                <EventListener event=questbeacon5 />
214              </execute>
215            </events>
216            <attached>
217              <Billboard position="0,0,0" colour="1.0,1.0,0" material="Examples/Flare" />
218              <DistanceTrigger name=questbeacon5 position="0,0,0" distance=100 target="Pawn" />
219            </attached>
220          </QuestEffectBeacon>
221        </attached>
222      </StaticEntity>
223
224      <!-- Trail -->
225      <EventDispatcher>
226        <targets>
227          <EventTarget target=trail />
228        </targets>
229        <events>
230          <visibility>
231            <QuestListener questId="50845552-c8af-4091-947c-76bd850b224e" mode="complete" />
232          </visibility>
233          <activity>
234            <QuestListener questId="50845552-c8af-4091-947c-76bd850b224e" mode="complete" />
235          </activity>
236        </events>
237      </EventDispatcher>
238
239      <?lua
240        for i = 1, 25 do
241      ?>
242        <Billboard position="<?lua print(i*5000/25) ?>,<?lua print(450+i*(5000-450)/25) ?>,5000" colour="1.0,0,0" material="Examples/Flare" name=trail visible=false/>
243      <?lua end ?>
244
245      <!-- Hideout -->
246      <StaticEntity position="5000,5000,5000" >
247        <attached>
248          <Model scale="100" mesh="ast2.mesh" shadow=false />
249        </attached>
250      </StaticEntity>
251
252      <StaticEntity position="5400,5400,5000" visible=false name=trail >
253        <attached>
254          <Model position="0,0,0" scale=4 yaw=180 pitch=-90 roll=-90 mesh="pirate.mesh" visible=false name=trail />
255          <QuestEffectBeacon position="0,0,0" times=1 active=false name=trail >
256            <effects>
257              <CompleteQuest questId="97628524-b243-492c-b7b6-498f325b21d4" />
258            </effects>
259            <events>
260              <execute>
261                <EventListener event=questbeacon6 />
262              </execute>
263            </events>
264            <attached>
265              <DistanceTrigger name=questbeacon6 position="0,0,0" distance=100 target="Pawn" />
266            </attached>
267          </QuestEffectBeacon>
268        </attached>
269      </StaticEntity>
270
271  </Scene>
272</Level>
Note: See TracBrowser for help on using the repository browser.