Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8800 for code


Ignore:
Timestamp:
Jul 30, 2011, 9:25:32 PM (13 years ago)
Author:
jo
Message:

Some work on the level. Pawndeath trigger doesn't work.

Location:
code/branches/ai2
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/branches/ai2/data/levels/lastTeamStandingII.oxw

    r8706 r8800  
    1717 name         = "On the fly"
    1818 description  = "testmap for gametype last team standing"
    19  gametype     =  "LastTeamStanding"
     19 gametype     = "LastTeamStanding"
    2020>
    2121  <templates>
  • code/branches/ai2/data/levels/missionOne.oxw

    r8786 r8800  
    99  include("HUDTemplates3.oxo")
    1010  include("templates/lodInformation.oxt")
    11   include("templates/spaceshipAssff2.oxt")
     11  include("templates/spaceshipAssff.oxt")
    1212  include("templates/spaceshipPirate.oxt")
     13?>
     14
     15<?lua
     16include("templates/pickupRepresentationTemplates.oxt")
    1317?>
    1418
     
    2226  <?lua include("includes/notifications.oxi") ?>
    2327
     28  <NotificationQueueCEGUI
     29    name="narrative"
     30    targets="simpleNotification"
     31    size=1
     32    displayTime=30
     33    position="0.2, 0, 0.1, 0"
     34    fontSize="24"
     35    fontColor="0.3, 1, 0.2, 0.8"
     36    alignment="HorzCentred"
     37    displaySize="0.6, 0, 0, 0"
     38    />
    2439  <Scene
    2540    ambientlight = "0.8, 0.8, 0.8"
    2641    skybox       = "Orxonox/Starbox"
    2742  >
     43    <?lua
     44      include("includes/pickups.oxi")
     45    ?>
    2846
    2947    <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"/>
    30     <SpawnPoint team=0 position="-200,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff2 />
    31 
    32 <!-- Four boxes for aiming
     48    <SpawnPoint team=0 position="-200,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff />
     49    <!-- Script code="artificialcontroller setbotlevel 0.1" /--> <!-- Does not influence waypointPatrolController-->
     50
     51<!-- END OF INCLUDES & NECESSARITIES -->
     52
     53<!-- TUTORIAL-TODO: -->
     54
     55<!-- 1. Aiming & Weapons (static targets, moving targets, dangerous targets)--> <!-- 3 Mouse buttons + "T"-->
     56<!-- 2. Flying & manoeuvring (basic flying, using pickups, forcefields, docks & portals) --> <!-- "W","S","SPACE"-->
     57<!-- 3. Game handling (quests, knowing when a game is over :-), pausing, chat, ... ) --> <!--"F3", "F2", "ESC" -->
     58<!-- 4. Extras (other things to discover) --> <!-- "Q","E","A","D","C", "CTRL", "", ... -->
     59
     60<!--
     61Four boxes for aiming
    3362TODO: Turn engine off at the beginning.
    3463TODO: display text: "Destroy those four boxes. Aim the a the box and shoot by using the left mouse button."
     
    4776"Hi. We have been attacked by a pirate lately. Please protect us. The drone pickup will help you."
    4877
    49 -->   
    50   <Pawn health=30 position="0,0,0" direction="0,-1,0" collisionType=dynamic mass=100000>
     78-->
     79<!-------------------------------------- PART ONE: Destroy boxes --------------------------------------->
     80    <DistanceTrigger name="spawndelaytrigger1" position="-200,0,0" target="Pawn" distance=10 stayActive="true" delay=1 />
     81    <SimpleNotification message="Destroy those four boxes.">
     82        <events>
     83            <trigger>
     84                <EventListener event=spawndelaytrigger1 />
     85            </trigger>
     86        </events>
     87    </SimpleNotification>
     88
     89    <DistanceTrigger name="spawndelaytrigger2" position="-200,0,0" target="Pawn" distance=10 stayActive="true" delay=2 />
     90    <SimpleNotification message=" 1. Aim the a the red cycle.">
     91        <events>
     92            <trigger>
     93                <EventListener event=spawndelaytrigger2 />
     94            </trigger>
     95        </events>
     96    </SimpleNotification>
     97
     98    <DistanceTrigger name="spawndelaytrigger3" position="-200,0,0" target="Pawn" distance=10 stayActive="true" delay=4 />
     99    <SimpleNotification message="2. Click! (hold the left mouse button)">
     100        <events>
     101            <trigger>
     102                <EventListener event=spawndelaytrigger3 />
     103            </trigger>
     104        </events>
     105    </SimpleNotification>
     106
     107    <SimpleNotification message="Right click on the next target.">
     108        <events>
     109            <trigger>
     110                <EventListener event=PawnDied1 />
     111            </trigger>
     112        </events>
     113    </SimpleNotification>
     114
     115
     116<!-- BRIEFING END-->
     117<!-- TODO: does NOT work. Intended effect: pawn death causes message to appear (and probably the next box) -->
     118  <SimpleNotification message="Right click on the next target.">
     119        <events>
     120            <trigger>
     121                <Pawn health=30 position="0,0,0" direction="0,-1,0" collisionType=dynamic mass=100000>
     122                    <attached>
     123                        <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     124                    </attached>
     125                    <collisionShapes>
     126                        <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
     127                    </collisionShapes>
     128                </Pawn>
     129            </trigger>
     130        </events>
     131    </SimpleNotification>
     132
     133  <Pawn health=30 position="0,100,0" direction="0,-1,0" collisionType=dynamic mass=100000>
    51134      <attached>
    52135        <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     
    56139      </collisionShapes>
    57140  </Pawn>
    58   <Pawn health=30 position="70,0,0" direction="0,-1,0" collisionType=dynamic mass=100000>
     141
     142  <Pawn health=30 position="0,200,0" direction="0,-1,0" collisionType=dynamic mass=100000>
    59143      <attached>
    60144        <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     
    64148      </collisionShapes>
    65149  </Pawn>
    66   <Pawn health=30 position="140,0,0" direction="0,-1,0" collisionType=dynamic mass=100000>
    67       <attached>
    68         <Model position="0,0,0" mesh="crate.mesh" scale3D="5,5,5" />
    69       </attached>
    70       <collisionShapes>
    71         <BoxCollisionShape position="0,0,0" halfExtents="25,25,25" />
     150
     151  <Pawn health=30 position="0,300,0" direction="0,-1,0" collisionType=dynamic mass=100000>
     152      <attached>
     153        <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     154      </attached>
     155      <collisionShapes>
     156        <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
    72157      </collisionShapes>
    73158  </Pawn>
    74   <Pawn health=30 position="210,0,0" direction="0,-1,0" collisionType=dynamic mass=100000>
    75       <attached>
    76         <Model position="0,0,0" mesh="crate.mesh" scale3D="5,5,5" />
    77       </attached>
    78       <collisionShapes>
    79         <BoxCollisionShape position="0,0,0" halfExtents="25,25,25" />
    80       </collisionShapes>
    81   </Pawn>
    82 
    83 
     159
     160<!--------------------------------------PART TWO: Moving targets --------------------------------------->
     161
     162    <SpaceShip position="0,1500,200" lookat="0,0,0">
     163      <templates>
     164        <Template link=spaceshippirate />
     165      </templates>
     166      <controller>
     167        <WaypointController>
     168          <waypoints>
     169            <Model mesh="cube.mesh" scale=8 position="  0,1300,-200" />
     170            <Model mesh="cube.mesh" scale=8 position="  0,1300,-700" />
     171            <Model mesh="cube.mesh" scale=8 position="500,1300,-700" />
     172            <Model mesh="cube.mesh" scale=8 position="500,1300,-200" />
     173          </waypoints>
     174        </WaypointController>
     175      </controller>
     176    </SpaceShip>
     177    <PickupSpawner position="250,1300,-450" triggerDistance="10" respawnTime="30" maxSpawnedItems="1">
     178      <pickup>
     179        <DronePickup template=dronepickup />
     180      </pickup>
     181    </PickupSpawner>
     182
     183    <SpaceShip position="0,1500,400" lookat="0,0,0">
     184      <templates>
     185        <Template link=spaceshippirate />
     186      </templates>
     187      <controller>
     188        <WaypointController>
     189          <waypoints>
     190            <Model mesh="cube.mesh" scale=8 position="  0,1300,1000" />
     191            <Model mesh="cube.mesh" scale=8 position="  0,1300,500" />
     192            <Model mesh="cube.mesh" scale=8 position="500,1300,500" />
     193            <Model mesh="cube.mesh" scale=8 position="500,1300, 1000" />
     194          </waypoints>
     195        </WaypointController>
     196      </controller>
     197    </SpaceShip>
     198
     199
     200<!--------------------------------------PART THREE: to the space station --------------------------------------->
     201    <DistanceTrigger name="duball1" position="-1000,-300,700" target="Pawn" distance=700 stayActive="true" delay=2 />
     202    <SimpleNotification message="Welcome to the Duball Space Station!">
     203        <events>
     204            <trigger>
     205                <EventListener event=duball1 />
     206            </trigger>
     207        </events>
     208    </SimpleNotification>
     209
     210    <DistanceTrigger name="duball2" position="-1000,-300,700" target="Pawn" distance=700 stayActive="true" delay=4 />
     211    <SimpleNotification message="Warning: Something big is coming.">
     212        <events>
     213            <trigger>
     214                <EventListener event=duball2 />
     215            </trigger>
     216        </events>
     217    </SimpleNotification>
     218
     219    <DistanceTrigger name="duball2" position="-1000,-300,700" target="Pawn" distance=700 stayActive="true" delay=6 />
     220    <SimpleNotification message="Be on your guard!">
     221        <events>
     222            <trigger>
     223                <EventListener event=duball3 />
     224            </trigger>
     225        </events>
     226    </SimpleNotification>
     227
     228<StaticEntity position="-1000,-300,700" collisionType=static>
     229      <attached>
     230        <Model scale=11 mesh="DuBall1.mesh" position = "-100,0,0"/>
     231        <Model scale=11 mesh="DuBall2.mesh" position = "100,0,0"/>
     232        <Billboard scale=7 material="Examples/Flare" colour="0.5,0.5,0.5" position = "-100,0,0"/>
     233        <Billboard scale=7 material="Examples/Flare" colour="0.5,0.5,0.5" position = "100,0,0"/>       
     234      </attached>
     235      <collisionShapes>
     236        <SphereCollisionShape radius="80"            position = "-100,0,0" />
     237        <SphereCollisionShape radius="120"           position = "100,0,0" />
     238        <BoxCollisionShape    halfExtents="90,25,45" position = "-155,0,40" />
     239      </collisionShapes>
     240</StaticEntity>
     241
     242    <DistanceTrigger name="duball3" position="-1000,-300,700" target="Pawn" distance=700 stayActive="true" delay=6 />
     243    <!-- SpaceShip position="-1000,900,700" lookat="0,0,0">
     244      <templates>
     245        <Template link=spaceshipTransporter />
     246      </templates>
     247      <controller>
     248        <WaypointPatrolController>
     249          <waypoints>
     250            <Model mesh="cube.mesh" scale=8 position="-1000,500,700" />
     251          </waypoints>
     252        </WaypointPatrolController>
     253      </controller>
     254        <events>
     255            <trigger>
     256                <EventListener event=duball3 />
     257            </trigger>
     258        </events>
     259    </SpaceShip -->
     260
     261<!--------------------------------------PART FOUR --------------------------------------->
    84262
    85263  </Scene>
  • code/branches/ai2/src/orxonox/controllers/ArtificialController.cc

    r8793 r8800  
    11901190
    11911191    /**
    1192         @brief Adds point of interest depending on context
     1192        @brief Adds point of interest depending on context. Further Possibilites: "ForceField", "PortalEndPoint", "MovableEntity", "Dock"
    11931193    */
    11941194    void ArtificialController::manageWaypoints()
Note: See TracChangeset for help on using the changeset viewer.