Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/newlevel2012/data/levels/towerDefense.oxw @ 9173

Last change on this file since 9173 was 9173, checked in by mentzerf, 12 years ago
  • Fixed compile error

+ Added another OverlayText, but still not seeing anything

File size: 4.2 KB
Line 
1<!-- TODO: Update the level's image-->
2
3<!-- See TowerDefenseReadme.txt for Information on this file -->
4
5<LevelInfo
6 name = "Tower Defense"
7 description = "Defend your Spacestation from incoming waves."
8 tags = "gametype"
9 screenshot = "emptylevel.png"
10/>
11
12<?lua
13  include("stats.oxo")
14  include("HUDTemplates3.oxo")
15  include("towerdefenseHUD.oxo")
16  include("templates/lodInformation.oxt")
17?>
18
19<?lua
20  include("templates/spaceshipAssff.oxt")
21  include("templates/spaceshipPirate.oxt")
22  include("templates/tower.oxt")
23?>
24
25<!-- Specify the position of the camera -->
26<Template name=centerpointmarkcamera defaults=0>
27  <Pawn>
28    <camerapositions>
29      <CameraPosition position="0,0,2000"/>
30    </camerapositions>
31  </Pawn>
32</Template>
33
34<!-- Loads a mesh to mark the center-->
35<Template name=centerpointmark>
36  <Pawn camerapositiontemplate=centerpointmarkcamera>
37    <attached>
38      <Model position="0,0,0" mesh="cylinder.mesh" scale3D="1,1,1" /> <!-- the camera is attached to this -->
39    </attached>
40  </Pawn>
41</Template>
42
43
44<!-- Template for a tower       EDIT: new towertemplate is included with "templates/tower" -->
45<!--Template name=towertemplate>
46  <Tower>
47    <attached>
48      <Model position="0,0,0" scale=0.25 mesh="Tower_ME.mesh" />
49    </attached>
50  </Tower>
51</Template-->
52
53<Level gametype = "TowerDefense">
54  <templates>
55    <Template link=lodtemplate_default />
56  </templates>
57 
58  <?lua include("includes/notifications.oxi") ?>
59
60  <Scene
61    ambientlight = "0.8, 0.8, 0.8"
62    skybox       = "Orxonox/Starbox"
63  >
64 
65        <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"/>
66   
67        <!-- Spawns the camera, attached to a crate -->
68        <SpawnPoint team=0 position="0,0,0" spawnclass=Pawn pawndesign=centerpointmark />
69        <!--TeamSpawnPoint team=1 position="-7,7,4" direction="-1,0,0" roll=90 yaw=0 spawnclass=SpaceShip pawndesign=spaceshipassff /-->
70       
71        <!--SpawnPoint team=1 position="0,0,10" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff  /-->
72        <!--SpawnPoint team=0 position="0,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff /-->
73       
74        <SpaceShip position="-700,-500, 100" lookat="0,0,0" scale=10>
75      <templates>
76        <Template link=spaceshipassff />
77      </templates>
78      <controller>
79        <WaypointController accuracy=40>
80          <waypoints>
81                          <!-- 1,3 10,3 10,11, 13,11 -->
82            <Model mesh="cube.mesh" scale=1 position="-700,-500, 100" />
83            <Model mesh="cube.mesh" scale=1 position=" 200,-500, 100" />
84            <Model mesh="cube.mesh" scale=1 position=" 200, 300, 100" />
85            <Model mesh="cube.mesh" scale=1 position=" 500, 300, 100" />
86          </waypoints>
87        </WaypointController>
88      </controller>
89    </SpaceShip>
90   
91        <!-- PlayField -->
92        <TowerDefenseCenterpoint
93        name=towerdefensecenter
94        width=16
95        height=16
96        tileScale=100
97        towerTemplate=tower
98        position="0,0,0"
99        direction="0,0,0"
100        collistionType=static
101        mass=100000>
102                 
103                 <attached>
104                        <Model position="-50,-50,0" mesh="Playfield_ME.mesh" scale=80 />
105            <!--Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" /--> <!-- Only temporary needed to help align the collisionshape -->
106                        <!-- This was used to mark the playfield, let's let it be here for now -->
107                        <!--Model position="-8,8,0" mesh="crate.mesh" scale3D="0.3,0.3,0.3" /-->
108                        <!--Model position="-8,-8,0" mesh="crate.mesh" scale3D="0.3,0.3,0.3" /-->
109                        <!--Model position="8,-8,0" mesh="crate.mesh" scale3D="0.3,0.3,0.3" /-->
110                        <!--Model position="8,8,0" mesh="crate.mesh" scale3D="0.3,0.3,0.3" /-->
111        </attached>
112        <collisionShapes> <!-- The collisionshape forbids other worldentities that have a collisionShape to fly through it.
113       
114                               TODO: Find correct size for the collisionshape; since a collisionShape is invisible
115                               I added the crate wich currently has the same dimensions as the collisionshape.
116                               You have to adjust the crate's scale3D as well as the collisionshape's halfExtens to
117                               find the proper shape. -->
118           <BoxCollisionShape position="0,0,0" halfExtents="400,400,100" />
119        </collisionShapes>
120    </TowerDefenseCenterpoint>
121
122  </Scene>
123</Level>
124
Note: See TracBrowser for help on using the repository browser.