Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/trunk/data/levels/tetris.oxw @ 9978

Last change on this file since 9978 was 9832, checked in by jo, 11 years ago

More fancy colored tetris bricks.

  • Property svn:eol-style set to native
File size: 6.8 KB
RevLine 
[8246]1<LevelInfo
2 name = "Tetris"
3 description = "Tetris in space!"
[9016]4 tags = "minigame"
5 screenshot = "tetris.png"
[8246]6/>
7
8<?lua
9  include("HUDTemplates3.oxo")
10  include("stats.oxo")
[9348]11  include("tetrisHUD.oxo")
[8246]12  include("templates/lodInformation.oxt")
[9348]13  include("templates/spaceshipAssff.oxt")
14  include("templates/spaceshipGhost.oxt")
15  include("templates/spaceshipPirate.oxt")
16  include("templates/spaceshipSwallow.oxt")
17  include("templates/spaceshipTransporter.oxt")
18  include("templates/spaceshipH2.oxt")
[8246]19?>
20
21<Template name=tetrisstonecameras defaults=0>
22  <TetrisStone>
23    <camerapositions>
24      <CameraPosition position="55,75,200" absolute=true />
25    </camerapositions>
26  </TetrisStone>
27</Template>
28
29<Template name=tetrisstone>
30  <TetrisStone camerapositiontemplate=tetrisstonecameras>
31    <attached>
[9831]32      <Model position="0,0,0" mesh="CuboidBody.mesh" scale=4.5 />
[9832]33      <Model position="0,0,0" mesh="cube_orange.mesh" scale=4.3 />
[8246]34    </attached>
35  </TetrisStone>
36</Template>
37
[9348]38
39
40<Template name=tetrisbrickcameras defaults=0>
41  <TetrisBrick>
42    <camerapositions>
43      <CameraPosition position="55,75,200" absolute=true />
44      <!--CameraPosition position="0,50,160" drag=true mouselook=true />
45      <CameraPosition position="0,50,0" pitch=-90 drag=true mouselook=true /-->
46    </camerapositions>
47  </TetrisBrick>
48</Template>
49
50<Template name=tetrisbrick>
51  <TetrisBrick camerapositiontemplate=tetrisbrickcameras>
52  </TetrisBrick>
53</Template>
54
55
[8246]56<Level
[9016]57 gametype = "Tetris"
[8246]58>
59  <templates>
60    <Template link=lodtemplate_default />
61  </templates>
[8637]62  <?lua include("includes/notifications.oxi") ?>
[8246]63
64  <Scene
65   ambientlight = "0.5, 0.5, 0.5"
[9348]66   skybox       = "Orxonox/skyBoxBasic"
[8246]67  >
[9348]68<!--luke_grey_-_hypermode.ogg allgorythm-lift_up.ogg Fight1.ogg -->
69    <WorldAmbientSound
70      source="Ganymede.ogg"
71      looping="true"
72      playOnLoad="true"
73    />
74
[8246]75    <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" />
76
[9348]77
[8246]78    <?lua
79      for i = 1, 10, 1 do
80    ?>
81      <SpawnPoint position="<?lua print(math.random() * 1000 - 500) ?>,<?lua print(math.random() * 1000 - 500) ?>,<?lua print(math.random() * 1000 - 500) ?>" lookat="0,0,0" />
82    <?lua end ?>
83
[9348]84    <TetrisCenterpoint name=tetriscenter width=11 height=15 stoneSize=10 stoneTemplate=tetrisstone brickTemplate=tetrisbrick stoneSpeed=10 position="-55,-75,0">
[8246]85        <attached>
86            <Model position="55,-1,0" mesh="cube.mesh" scale3D="57,1,11" />
87            <Model position="-1,76,0" mesh="cube.mesh" scale3D="1,76,1" />
88            <Model position="111,76,0" mesh="cube.mesh" scale3D="1,76,1" />
89        </attached>
[9348]90        <!--collisionShapes>
91            <BoxCollisionShape position="55,-1,0"  halfExtents="57,1,11" />
92            <BoxCollisionShape position="-1,76,0"  halfExtents="1,76,1" />
93            <BoxCollisionShape position="111,76,0" halfExtents="1,76,1" />
94        </collisionShapes-->
[8246]95    </TetrisCenterpoint>
96
[9348]97<!-- ------------ insert eye candy here  ---------------- -->
98
99<!-- asteroidBelt(centerX, centerY, centerZ, yaw, pitch, segments, minSize, maxSize, radius0, radius1, count, fog) -->
100<!-- DONT DARE TO TURN THE FOG ON, whithout finding a better belt position -->
101    <?lua
102        dofile("includes/asteroidField.lua")
103        asteroidBelt(10000, 0, 0, -40, -90, 70, 100, 200, 24000, 20000, 500, 0)
104
105    ?>
106<!-- -------- 4 spaceships rotating around the tetris field --------- -->
107    <SpaceShip position="1000,-75,1" lookat="0,0,0">
108      <templates>
109        <Template link=spaceshipswallow />
110      </templates>
111      <controller>
112        <WaypointController team=10 accuracy=200>
113          <waypoints>
114            <Model mesh="cube.mesh" scale=0 position="1000,-75,0" />
115            <Model mesh="cube.mesh" scale=0 position="650,-75,650" />
116            <Model mesh="cube.mesh" scale=0 position="-55,-75,1000" />
117            <Model mesh="cube.mesh" scale=0 position="-700,-75,650" />
118            <Model mesh="cube.mesh" scale=0 position="-1000,-75,0" />
119            <Model mesh="cube.mesh" scale=0 position="-700,-75,-650" />
120            <Model mesh="cube.mesh" scale=0 position="-55,-75,-1000" />
121            <Model mesh="cube.mesh" scale=0 position="650,-75,-650" />
122          </waypoints>
123        </WaypointController>
124      </controller>
125    </SpaceShip>
126   
127   <SpaceShip position="-500,-500,-400" lookat="0,0,0">
128      <templates>
129        <Template link=spaceshippirate />
130      </templates>
131      <controller>
132        <WaypointController team=10>
133          <waypoints>
134            <Model mesh="cube.mesh" scale=0 position="-1000,-200,0" />
135            <Model mesh="cube.mesh" scale=0 position="-700,-150,650" />
136            <Model mesh="cube.mesh" scale=0 position="-55,-75,1000" />
137            <Model mesh="cube.mesh" scale=0 position="650,100,650" />         
138            <Model mesh="cube.mesh" scale=0 position="1000,150,0" />
139            <Model mesh="cube.mesh" scale=0 position="650,100,-650" />
140            <Model mesh="cube.mesh" scale=0 position="-55,0,-1000" />
141            <Model mesh="cube.mesh" scale=0 position="-700,-100,-650" />
142          </waypoints>
143        </WaypointController>
144      </controller>
145    </SpaceShip>
146   
147       <SpaceShip position="-700,200,651" lookat="1,0,0">
148      <templates>
149        <Template link=spaceshipghost />
150      </templates>
151      <controller>
152        <WaypointController team=10 accuracy=300>
153          <waypoints>
154            <Model mesh="cube.mesh" scale=0 position="-700,200,650" />
155            <Model mesh="cube.mesh" scale=0 position="-55,100,1000" />
156            <Model mesh="cube.mesh" scale=0 position="650,0,650" />         
157            <Model mesh="cube.mesh" scale=0 position="1000,-100,0" />
158            <Model mesh="cube.mesh" scale=0 position="650,0,-650" />
159            <Model mesh="cube.mesh" scale=0 position="-55,100,-1000" />
160            <Model mesh="cube.mesh" scale=0 position="-700,200,-650" />
161            <Model mesh="cube.mesh" scale=0 position="-1000,300,0" />
162          </waypoints>
163        </WaypointController>
164      </controller>
165    </SpaceShip>
166   
167    <SpaceShip position="1000,-75,0" lookat="0,0,0">
168      <templates>
169        <Template link=spaceshipHtwo />
170      </templates>
171      <controller>
172        <WaypointController team=10>
173          <waypoints>
174            <Model mesh="cube.mesh" scale=0 position="400,240,400" />
175            <Model mesh="cube.mesh" scale=0 position="-55,240,700" />
176            <Model mesh="cube.mesh" scale=0 position="-500,240,400" />
177            <Model mesh="cube.mesh" scale=0 position="-700,240,0" />
178            <Model mesh="cube.mesh" scale=0 position="-500,240,-400" />
179            <Model mesh="cube.mesh" scale=0 position="-55,240,-700" />
180            <Model mesh="cube.mesh" scale=0 position="400,240,-400" />
181            <Model mesh="cube.mesh" scale=0 position="700,240,0" />
182          </waypoints>
183        </WaypointController>
184      </controller>
185    </SpaceShip>
186   
187   
188   
[8246]189  </Scene>
190</Level>
Note: See TracBrowser for help on using the repository browser.