Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

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

Last change on this file since 9139 was 9139, checked in by mentzerf, 12 years ago
  • Fixed some formatting, some comments and some logs. Done for today.
File size: 3.6 KB
Line 
1<!-- TODO: Update the level's image-->
2<LevelInfo
3 name = "Tower Defense"
4 description = "Defend your Spacestation from incoming waves."
5 tags = "gametype"
6 screenshot = "emptylevel.png"
7/>
8
9<?lua
10  include("stats.oxo")
11  include("HUDTemplates3.oxo")
12  include("templates/lodInformation.oxt")
13?>
14
15<?lua
16  include("templates/spaceshipAssff.oxt")
17  include("templates/spaceshipPirate.oxt")
18?>
19
20<!--  Hallo erstmal.
21Ich habe das Grundgerüst des Levels mal zum Laufen gebracht.
22Bei mir hat es das Playfield_ME.mesh allerdings nicht angezeigt; deswegen habe ich mit dem crate.mesh als testobjekt gearbeitet.
23Das Level macht genau das was ihr vermutlich erreichen wolltet. Wahrscheinlich wird die Funktionalität der "statischen Kamera" aber
24bloß in einer abgewandelten Art umgesetzt: In Pong und Tetris sind die Kameras nicht an das Spielfeld, sondern an ein ControllableEntity,
25das vom Spieler gesteuert wird gekoppelt.
26-->
27
28<!-- Specify the position of the camera -->
29<Template name=centerpointmarkcamera defaults=0>
30  <Pawn>
31    <camerapositions>
32      <CameraPosition position="0,0,20"/>
33    </camerapositions>
34  </Pawn>
35</Template>
36
37<!-- Loads a mesh to mark the center-->
38<Template name=centerpointmark>
39  <Pawn camerapositiontemplate=centerpointmarkcamera>
40    <attached>
41      <Model position="0,0,0" mesh="cylinder.mesh" scale3D="1,1,1" /> <!-- the camera is attached to this -->
42    </attached>
43  </Pawn>
44</Template>
45
46
47<!-- Template for a tower -->
48<Template name=towertemplate>
49  <Tower>
50    <attached>
51      <Model position="0,0,0" scale3D="0.5,0.5,2" mesh="cube_green.mesh" />
52    </attached>
53  </Tower>
54</Template>
55
56<Level gametype = "TowerDefense">
57  <templates>
58    <Template link=lodtemplate_default />
59  </templates>
60 
61  <?lua include("includes/notifications.oxi") ?>
62
63  <Scene
64    ambientlight = "0.8, 0.8, 0.8"
65    skybox       = "Orxonox/Starbox"
66  >
67 
68        <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"/>
69   
70        <!-- Spawns the camera, attached to a crate -->
71        <SpawnPoint team=0 position="0,0,0" spawnclass=Pawn pawndesign=centerpointmark />
72       
73        <!--SpawnPoint team=1 position="0,0,10" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff  /-->
74        <!--SpawnPoint team=0 position="0,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff /-->
75       
76        <!--SpaceShip position="-10,0,20" lookat="0,0,0">
77      <templates>
78        <Template link=spaceshipassff />
79      </templates>
80      <controller>
81        <WaypointController accuracy=3>
82          <waypoints>
83            <Model mesh="cube.mesh" scale=1 position="110,90,20" />
84            <Model mesh="cube.mesh" scale=2 position="290,90,20" />
85            <Model mesh="cube.mesh" scale=3 position="290,-90,20" />
86            <Model mesh="cube.mesh" scale=4 position="110,-90,20" />
87          </waypoints>
88        </WaypointController>
89      </controller>
90    </SpaceShip-->
91   
92
93        <!-- PlayField -->
94        <TowerDefenseCenterpoint
95        name=towerdefensecenter
96        width=16
97        height=16
98        towerTemplate=towertemplate
99        position="0,0,0"
100        direction="0,0,0"
101        collistionType=static
102        mass=100000>
103                 
104                 <attached>
105               
106                        <Model position="-0.5,-0.5,0" mesh="Playfield_ME.mesh" scale=0.8 />
107                       
108                        <!-- This was used to mark the playfield, let's let it be here for now -->
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                        <!--Model position="8,-8,0" mesh="crate.mesh" scale3D="0.3,0.3,0.3" /-->
112                        <!--Model position="8,8,0" mesh="crate.mesh" scale3D="0.3,0.3,0.3" /-->
113                       
114        </attached>
115    </TowerDefenseCenterpoint>
116
117  </Scene>
118</Level>
119
Note: See TracBrowser for help on using the repository browser.