Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/trunk/data/levels/dockingToASpaceStation.oxw @ 11688

Last change on this file since 11688 was 11104, checked in by fvultier, 9 years ago

Some HUDs (Health, Shield, Weapons, EnemyHealth, EnemyShield) are also displayed in FPS mode. Removed two unused redundant files.

  • Property svn:eol-style set to native
File size: 6.5 KB
Line 
1<!--  -->
2<LevelInfo
3 name = "Docking to a Space Station"
4 description = "Docking into a spacestation."
5 tags = "showcase"
6 screenshot = "emptylevel.png"
7/>
8
9<?lua
10  include("stats.oxo")
11  include("HUDTemplates3.oxo")
12  include("HUDTemplatesFPS.oxo")
13  include("templates/lodInformation.oxt")
14  include("templates/pickupRepresentationTemplates.oxt")
15?>
16
17<?lua
18  include("templates/spaceshipAssff.oxt")
19  include("templates/spaceshipPirate.oxt")
20  include("templates/spaceshipEscort.oxt")
21  include("templates/bigship.oxt")
22  include("templates/spaceshipTurret.oxt")
23  include("templates/spaceshipCollateralDamage.oxt")
24  include("templates/FPS.oxt")
25?>
26
27<Level
28  gametype = Deathmatch
29>
30  <templates>
31    <Template link=lodtemplate_default />
32  </templates>
33
34  <Scene
35    ambientlight = "0.5, 0.5, 0.5"
36    skybox       = "Orxonox/Starbox"
37    negativeWorldRange = "-100000, -100000, -100000"
38    positiveWorldRange = " 100000,  100000,  100000"
39    gravity      = "0,0,0"
40    hasPhysics   = true
41  >
42
43    <?lua
44      include("includes/pickups.oxi")
45    ?>
46
47    <Light type=directional position="0,0,0" direction="0.253, 0.593, -0.765" diffuse="1.0,1.0,1.0,0.5" specular="1.0, 0.9, 0.9, 1.0"/>
48    <SpawnPoint team=0 position="3200,0,0" lookat="2800,0,0" spawnclass=SpaceShip pawndesign=spaceshipescort />
49
50    <StaticEntity position  = "2800,0,0" mass=10000 collisionType=static >
51      <attached>
52        <Model mesh="HydroHarvester.mesh" mass=10 position="0,0,0" scale=50 />
53      </attached>
54      <collisionShapes>
55        <BoxCollisionShape  position="-560,0,0" halfExtents="115,100,245" /><!-- Three lower boxes -->
56        <BoxCollisionShape  position="290,0,-480" halfExtents="115,100,245" yaw=-120 />
57        <BoxCollisionShape  position="290,0,480" halfExtents="115,100,245" yaw=-240 />
58        <BoxCollisionShape  position="-280,0,0" halfExtents="163,50,50" /><!-- Three lower connections -->
59        <BoxCollisionShape  position="140,0,-240" halfExtents="163,50,50" yaw=-120 />
60        <BoxCollisionShape  position="140,0,240" halfExtents="163,50,50" yaw=-240 />
61        <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" /><!-- Upper Tower -->
62        <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" yaw=-120 />
63        <BoxCollisionShape  position="0,530,0" halfExtents="172,52,298" yaw=-240 />
64        <BoxCollisionShape  position="0,400,0" halfExtents="43,110,26" yaw=-30 /><!-- Middle one-->
65        <BoxCollisionShape  position="-200,100,0" halfExtents="26,50,43" /><!--Three lower legs -->
66        <BoxCollisionShape  position="100,100,-173" halfExtents="43,50,26" yaw=-30 />
67        <BoxCollisionShape  position="100,100,-173" halfExtents="43,50,26" yaw=30 />
68        <BoxCollisionShape  position="-100,264,0" halfExtents="26,105,43" roll=-49 /><!--Three upper legs -->
69        <BoxCollisionShape  position="50,264,-87" halfExtents="26,105,43" roll=-49 yaw=-120 />
70        <BoxCollisionShape  position="50,264,87" halfExtents="26,105,43" roll=-49 yaw=-240 />
71      </collisionShapes>
72    </StaticEntity>
73
74<!-- Docking  -->
75    <Dock position="2830,20,50" roll=0 yaw=0 >
76        <animations>
77            <MoveToDockingTarget target="destroyer" />
78        </animations>
79        <effects>
80            <DockToShip target="spaceShip" />
81        </effects>
82        <events>
83            <execute>
84                <EventListener event="dockMe" />
85            </execute>
86
87            <undocking>
88                <EventListener event="undockMe" />
89            </undocking>
90       
91            <activity>
92                <EventListener event=notGameEnd />
93            </activity>
94        </events>
95        <attached>
96        <!-- Trigger for docking with billboard -->
97            <Billboard position="0,0,0" material="Flares/ringflare2" colour="0.2,0.4,0.8" scale=1 />
98            <DistanceTrigger position="0,0,0" distance="200" target="Pawn"
99                beaconMode="exclude" targetname="bcnDestroyer" name="dockMe"
100            />
101        <!-- Trigger for undocking with billboard -->
102            <Billboard position="-2630,-19970,150" material="Flares/ringflare2" colour="0.2,0.4,0.8" scale=1 />
103            <DistanceTrigger position="-2630,-19970,150" distance="50" target="Pawn"
104                beaconMode="identify" targetname="bcnDestroyer" name="undockMe"
105            />
106        </attached>
107
108    </Dock>
109
110<!-- FPS Player as destination of the dock -->
111<FpsPlayer template = "fps" radarname = "First Person Player" position = "0,-19900,0" >
112      <attached>
113        <DockingTarget name="spaceShip" />
114        <DistanceTriggerBeacon name="bcnDestroyer" />
115        <DockingTarget name="destroyer" />
116      </attached>
117</FpsPlayer>
118
119
120<!-- Cube as test SpaceStation
121
122The station can either be hidden outside of the skybox, within the hull of the space station if it is big enough or within a planet.
123Complex spacestations can be placed very far away from the spaceship so it is rendered at low resolution while the player uses the space ship.
124
125-->
126  <StaticEntity position="0,-20000,0" direction="0,-1,0" collisionType=static mass=100000 friction=0.01 >
127      <attached>
128        <Model position="0,0,0" mesh="crate.mesh" scale3D="80,80,5" />
129      </attached>
130      <collisionShapes>
131        <BoxCollisionShape position="0,0,0" halfExtents="400,400,25" />
132      </collisionShapes>
133  </StaticEntity>
134
135<!-- Homogenous gravitationfield to simulate local gravity (activating the normal gravity will affect the spaceship terribly) -->
136<ForceField position="0,-20000,0" mode="homogen" diameter="2000" forcedirection = "0,-500,0" />
137
138
139<!-- Some more stuff -->
140
141    <!-- triple large belt around the planet  -->
142    <?lua
143        dofile("includes/asteroidField.lua")
144        asteroidBelt(15000, 0, 0, 30, 0, 30, 30, 50, 7190, 7800, 250, 1)
145    ?>
146    <?lua
147        dofile("includes/asteroidField.lua")
148        asteroidBelt(15000, 0, 0, 30, 0, 30, 30, 50, 10000, 11000, 300, 1)
149    ?>
150    <?lua
151        dofile("includes/asteroidField.lua")
152        asteroidBelt(15000, 0, 0, 30, 0, 30, 30, 50, 14000, 15000, 350, 1)
153    ?>
154
155    <Planet
156      position="15000,0,-1000"
157      scale="5000"
158      collisionType="dynamic"
159      linearDamping="0.8"
160      angularDamping="0"
161      mass="10000000"
162      pitch="0"
163      mesh="planets/ganymede.mesh"
164      atmosphere="atmosphere1"
165      rotationaxis="1,0,0"
166      rotationrate="1.0"
167      atmospheresize="80.0f"
168      imagesize="1024.0f"
169      collisiondamage = 2
170      enablecollisiondamage = true
171    >
172      <attached>
173        <ForceField position="5000,0,0" mode="sphere" diameter="10000" velocity="-50" />
174      </attached>
175      <collisionShapes>
176        <SphereCollisionShape radius="5000" position="0,0,0" />
177      </collisionShapes>
178    </Planet>
179
180  </Scene>
181
182</Level>
183
Note: See TracBrowser for help on using the repository browser.