Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/presentation3/data/levels/presentationHS09b.oxw @ 7009

Last change on this file since 7009 was 7007, checked in by dafrick, 15 years ago

Tested and cleaned all levels (except for the ones that someone is working on at the moment).
Two levels had old Pickups in them, they have been updated to work properly now.
All levels except one are working. The one that isn't is the presentationHS09b level, which crashes due to LOD.

  • Property svn:eol-style set to native
File size: 8.9 KB
Line 
1<?lua
2  include("stats.oxo")
3  include("hudtemplates3.oxo")
4?>
5
6<?lua
7  include("templates/spaceship_assff.oxt")
8  include("templates/spaceship_pirate.oxt")
9  include("templates/spaceship_ghost.oxt")
10  include("templates/spaceship_HXY.oxt")
11  include("templates/spaceship_Transporter.oxt")
12  include("templates/spaceship_HXY_SL.oxt")
13  include("templates/spaceship_Transporter_SL.oxt")
14?>
15
16<Level
17 name         = "Sample"
18 description  = "Just a few tests"
19 gametype     = TeamDeathmatch
20>
21  <Scene
22    ambientlight = "0.8, 0.8, 0.8"
23    skybox       = "Orxonox/Starbox"
24  >
25
26    <AmbientSound ambientSource="Mars.ogg" looping="true" playOnLoad="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    <?lua
31      for i = 1, 50, 1 do
32        x = math.random() * 2000  + 4000
33        y = math.random() * 4000 - 2000
34        z = math.random() * 2000 - 1000
35        s = math.random() * 100
36    ?>
37      <MovableEntity collisiontype=dynamic mass=<?lua print(s*10)?> position="<?lua print(x) ?>,<?lua print(y) ?>,<?lua print(z) ?>" linearDamping=0.01 angularDamping=0 rotationaxis="<?lua print(math.random()) ?>, <?lua print(math.random()) ?>, <?lua print(math.random()) ?>" rotationrate="<?lua print(math.random() * 100 - 15) ?>">
38        <attached>
39          <Model position="0,0,0" scale=<?lua print(s) ?> mesh="asteroid_UV.mesh" />
40        </attached>
41        <collisionShapes>
42          <SphereCollisionShape radius="<?lua print(s*0.9) ?>" />
43        </collisionShapes>
44      </MovableEntity>
45      <ParticleSpawner position="<?lua print(x) ?>,<?lua print(y) ?>,<?lua print(z) ?>" source="Orxonox/Steam" lifetime=3.0 loop=1 />
46    <?lua end ?>
47
48    <?lua
49      elements = {"BodyDebris1.mesh", "CockpitDebris.mesh", "LightningGun.mesh", "WingDebris1.mesh", "WingDebris2.mesh", "satellitedish.mesh", "Thruster.mesh"}
50      sizes = {4, 4, 4, 4, 4, 10, 20}
51     
52      elements.length = function()
53        return table.getn(elements)
54      end
55     
56      for i = 1, 100, 1 do
57        x = math.random() * 750 - 4500
58        y = math.random() * 1000 + 2000
59        z = math.random() * 500 + 1000
60        e = math.floor(math.random()*elements.length()+1)
61    ?>
62      <MovableEntity mass=90000 position="<?lua print(x) ?>,<?lua print(y) ?>,<?lua print(z) ?>" linearDamping=0.8 angularDamping=0.8 rotationaxis="<?lua print(math.random()) ?>, <?lua print(math.random()) ?>, <?lua print(math.random()) ?>" rotationrate="<?lua print(math.random() * 30- 15) ?>">
63        <attached>
64          <Model position="0,0,0" scale="<?lua print(sizes[e]) ?>" mesh="<?lua print( elements[e]) ?>" />
65        </attached>
66      </MovableEntity>
67    <?lua end ?>
68
69    <?lua
70      for i = 1,12, 1 do
71    ?>
72      <SpaceShip position="<?lua print(math.random()*500 + 4500) ?>,<?lua print(-(math.random()*500 -250)) ?>,<?lua print(i*50 - 150) ?>" >
73        <templates>
74          <Template link=spaceshipHXYSL />
75        </templates>
76        <controller>
77          <WaypointPatrolController alertnessradius=4000 team=0 active=true>
78            <waypoints>
79              <StaticEntity position="5000,<?lua print(math.random()*50)?> ,<?lua print(i*50 -150) ?>" />
80            </waypoints>
81          </WaypointPatrolController>
82        </controller>
83      </SpaceShip>
84    <?lua end ?>
85
86    <SpaceShip position="5000,100,100" >
87      <templates>
88        <Template link=spaceshipTransporterSL />
89      </templates>
90      <controller>
91        <WaypointPatrolController name=pirate  target=pirate alertnessradius=1000 team=0 active=false>
92          <waypoints>
93            <StaticEntity position="5000,100,1100" />
94          </waypoints>
95        </WaypointPatrolController>
96      </controller>
97    </SpaceShip>
98
99    <Destroyer
100      position          = "-5000,100 ,100"
101      collisionType     = dynamic
102      mass              = 100000
103      angularDamping    = 0.9999999
104      health            = 1000
105      maxhealth         = 1000
106      initialhealth     = 1000
107    >
108      <controller>
109        <WaypointPatrolController team=1 />
110      </controller>
111      <attached>
112        <Model mesh="Carrier.mesh" scale="5" />
113        <Backlight
114          mainstate=activity
115          active=false
116          scale=0.4
117          name=bltest
118          position=" 7.6, 0, 6"
119          colour="0.2, 0.65, 1.0, 1.0"
120          width=15
121          length=1500
122          lifetime=2
123          elements=50
124          trailmaterial="Trail/backlighttrail"
125          turnontime=1
126          turnofftime=1
127          material="Flares/ThrusterFlare1"
128        />
129        <?lua
130          for i=0,8,1 do
131        ?>
132          <BlinkingBillboard
133            position="<?lua print(200-270/8*i)?> ,15,2"
134            material="Examples/Flare"
135            colour="1.0, 0.5, 0.3"
136            phase=<?lua print(-360/8*i)?>
137            amplitude=0.1
138            frequency=0.5
139            quadratic=1
140          />
141
142          <BlinkingBillboard
143            position="<?lua print(200-270/8*i)?>,-15,2"
144            material="Examples/Flare"
145            colour="1.0, 0.5, 0.3"
146            phase=<?lua print(-360/8*i)?>
147            amplitude=0.1
148            frequency=0.5
149            quadratic=1
150          />
151        <?lua end ?>
152
153        <Backlight
154          scale=1
155          position=" 169, 75, -15"
156          colour="1, 0.85, 0.5, 0.5"
157          width=40
158          length=1000
159          lifetime=5
160          elements=15
161          trailmaterial="Trail/backlighttrail"
162          material="Examples/Flare"
163        />
164        <Backlight
165          scale=1
166          position=" 169, -75, -15"
167          colour="1, 0.85, 0.5, 0.5"
168          width=40
169          length=1000
170          lifetime=5
171          elements=15
172          trailmaterial="Trail/backlighttrail"
173          material="Examples/Flare"
174        />
175      </attached>
176      <collisionShapes>
177        <BoxCollisionShape position="70,0,-25"      halfExtents="150, 50, 25" />
178        <BoxCollisionShape position="95,75,-16"     halfExtents="70, 10, 12" />
179        <BoxCollisionShape position="95,-75,-16"    halfExtents="70, 10, 12" />
180        <BoxCollisionShape position="77,47,30"      halfExtents="110, 2, 30" />
181        <BoxCollisionShape position="77,-47,30"     halfExtents="110, 2, 30" />
182        <BoxCollisionShape position="77,0,50"       halfExtents="110, 45, 6" />
183        <BoxCollisionShape position="167,0,70"      halfExtents="17, 20, 20" />
184      </collisionShapes>
185    </Destroyer>
186
187    <?lua
188      for i = 1, 50, 1 do
189        x = -(math.random() * 2000  + 4000)
190        y = math.random() * 4000 - 2000
191        z = math.random() * 2000 - 1000
192        s = math.random() * 100
193    ?>
194      <MovableEntity collisiontype=dynamic mass=<?lua print(s*10)?> position="<?lua print(x) ?>,<?lua print(y) ?>,<?lua print(z) ?>" linearDamping=0.01 angularDamping=0 rotationaxis="<?lua print(math.random()) ?>, <?lua print(math.random()) ?>, <?lua print(math.random()) ?>" rotationrate="<?lua print(math.random() * 100 - 15) ?>">
195        <attached>
196          <Model position="0,0,0" scale=<?lua print(s) ?> mesh="asteroid_ice.mesh" />
197        </attached>
198        <collisionShapes>
199          <SphereCollisionShape radius="<?lua print(s*0.9)?>" />
200        </collisionShapes>
201      </MovableEntity>
202      <ParticleSpawner position="<?lua print(x) ?>,<?lua print(y) ?>,<?lua print(z) ?>" source="Orxonox/Steam" lifetime=3.0 loop=1 />
203    <?lua end ?>
204
205    <!-- EventDispatcher>
206      <targets>
207        <EventTarget target=attack />
208        <EventTarget target=wait />
209      </targets>
210      <events>
211        <activity>
212          <DistanceTrigger position="0, 0, 4500" distance=100 target="SpaceShip" stayactive=true />
213        </activity>
214      </events>
215    </EventDispatcher>
216
217    <EventDispatcher>
218      <targets>
219        <EventTarget target=wait />
220      </targets>
221      <events>
222        <activity>
223          <DistanceTrigger position="0, 0, 4500" distance=100 target="SpaceShip" stayactive=false />
224        </activity>
225      </events>
226    </EventDispatcher -->
227
228    <?lua
229      for i = 1,25, 1 do
230    ?>
231      <SpaceShip position="<?lua print(-(math.random()*500 + 4500)) ?>,<?lua print(-(math.random()*500 -250)) ?>,<?lua print(i*50 - 150) ?>" >
232        <templates>
233          <Template link=spaceshipghost />
234        </templates>
235        <controller>
236          <WaypointPatrolController name=attack alertnessradius=15000 team=1 active=false>
237            <events>
238              <activity>
239                <DistanceTrigger position="-5000, 100, 100" distance=2000 target="Camera" stayactive=true />
240              </activity>
241            </events>
242          </WaypointPatrolController>
243        </controller>
244      </SpaceShip>
245    <?lua end ?>
246
247    <AmbientSound ambientSource="Earth.ogg" looping="true" playOnLoad="false">
248      <events>
249        <activity>
250          <DistanceTrigger position="2000,0,0" distance=500 target="Camera" />
251        </activity>
252      </events>
253    </AmbientSound>
254
255    <SpawnPoint position="5000,0,2000" spawnclass=SpaceShip pawndesign=spaceshipassff  team=0 />
256   
257  </Scene>
258</Level>
Note: See TracBrowser for help on using the repository browser.