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