Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8980


Ignore:
Timestamp:
Dec 14, 2011, 2:38:37 PM (12 years ago)
Author:
jo
Message:

teamgametype merged into trunk

Location:
code/branches/presentation2011
Files:
34 edited
4 copied

Legend:

Unmodified
Added
Removed
  • code/branches/presentation2011

  • code/branches/presentation2011/data/levels/dynamicMatch.oxw

    r8977 r8980  
    3838
    3939<!-- -----------12-Spawnpoints around the planet------------- -->
     40<!-- inner Spawnpoints -->
    4041<TeamSpawnPoint team=0 position="1000,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff/>
    4142<TeamSpawnPoint team=0 position="-1000,0,0" lookat="0,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff/>
  • code/branches/presentation2011/data/levels/fightInOurBack.oxw

    r8891 r8980  
    110110  name="Fight in our back"
    111111  description="Our fleet is far ahead of us. We need to get rid of all the enemies in its back, because we do not want our enemies to attack from everywhere. So let us clear this Sector!"
    112   gametype=TeamDeathmatch
     112  gametype=Mission
    113113>
    114114  <templates>
     
    214214<?lua for i=0,0,1 do
    215215x=800
    216 health=2050
     216health=1500
    217217?>
    218218    <!--Transporter 1-->
     
    239239
    240240<?lua for j=0,1,1 do
    241 health=1600
     241health=1300
    242242x=800
    243243z=j*300
  • code/branches/presentation2011/data/levels/includes/weaponSettingsSpacecruiser.oxi

    r8891 r8980  
    11    <weaponslots>
    2       <WeaponSlot position="-20,-15,-108" />
    3       <WeaponSlot position=" 20,-15,-108" />
    4       <WeaponSlot position="  0, -7,-110" />
    5       <WeaponSlot position="-14,-31,-184" />
    6       <WeaponSlot position=" 14,-31,-184" />
    7       <WeaponSlot position="-34,-30,-169" />
    8       <WeaponSlot position=" 34,-30,-169" />
    9 
     2      <WeaponSlot position="-20,10,2" />
     3      <WeaponSlot position=" 20,10,2" />
     4      <WeaponSlot position="  0,18,0" />
     5      <WeaponSlot position="-14,-6,-74" />
     6      <WeaponSlot position=" 14,-6,-74" />
     7      <WeaponSlot position="-34,-5,-59" />
     8      <WeaponSlot position=" 34,-5,-59" />
    109    </weaponslots>
    1110    <weaponsets>
  • code/branches/presentation2011/data/levels/lastManStanding.oxw

    r8977 r8980  
    5050                    <Model position="0,0,0" scale=140 mesh="asteroid_UV.mesh" shadow=true />
    5151                    <Model position="-160,40,28.4" scale=1 mesh="sphere.mesh" /><!--EasterEgg indicator-->
    52                     <PickupSpawner position="-160,40,17" triggerDistance="20" respawnTime="5" maxSpawnedItems="15"><!--EasterEgg-->
     52                    <PickupSpawner position="-160,40,17" triggerDistance="20" respawnTime="5" maxSpawnedItems="15"><!--EasterEgg : invisible pickup is hidden inside the asteroid -->
    5353                        <pickup>
    5454                            <InvisiblePickup template=hugeinvisiblepickup />
  • code/branches/presentation2011/data/levels/lastTeamStanding.oxw

    r8977 r8980  
    1616
    1717<Level
    18  gametype = "LastTeamStanding"
     18 name         = "Last Team Standing"
     19 description  = "testmap for gametype last team standing"
     20 gametype     =  "TeamGametype"
    1921>
    2022  <templates>
  • code/branches/presentation2011/data/levels/lastTeamStandingII.oxw

    r8891 r8980  
    9595   </StaticEntity>
    9696<!-- END of CUBE-->
     97
    9798<!-------------- Centered Thin Gate -------------->
    9899
     
    412413    <TeamSpawnPoint team=3 position="845,350,835" direction="0,0,-1" spawnclass=SpaceShip pawndesign=spaceshipassff />
    413414    <TeamSpawnPoint team=3 position="845,-300,835" direction="-1,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff />
    414 <Bot />
     415<Bot /><!-- at least one bot is needed to stat the game properly. Else the game finishes. This could be avoided, if the menue allows a preselection of the number of players. -->
    415416
    416417  </Scene>
  • code/branches/presentation2011/data/levels/missionOne.oxw

    r8891 r8980  
    2222 name         = "Mission One"
    2323 description  = "How to steer a spaceship."
     24 gametype     = "Mission"
    2425>
    2526  <templates>
     
    4748    ?>
    4849
    49     <WorldAmbientSound source="Mars.ogg" looping="true" playOnLoad="true" /> <!-- AlphaCentauri.ogg-->
     50    <WorldAmbientSound source="Earth.ogg" looping="true" playOnLoad="true" /> <!-- AlphaCentauri.ogg, Mars.ogg-->
    5051
    5152    <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"/>
    52     <TeamSpawnPoint team=0 position="800,700,600" direction="-1,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff />
    53 
    54 
    5553<!-- END OF INCLUDES & NECESSARITIES -->
    5654
     55<!-- SPAWNPOINT & START OF QUESTS via spawntrigger -->
     56    <EventMultiTrigger name=spawntrigger>
     57        <events>
     58            <trigger>
     59                <TeamSpawnPoint team=0 position="800,700,600" direction="-1,0,0" spawnclass=SpaceShip pawndesign=spaceshipassff>
     60                  <EventTrigger invert=true>
     61                    <events>
     62                      <trigger>
     63                        <EventListener event="attack" />
     64                      </trigger>
     65                    </events>
     66                  </EventTrigger>
     67                </TeamSpawnPoint>
     68            </trigger>
     69        </events>
     70    </EventMultiTrigger>
     71
     72        <QuestEffectBeacon times=1>
     73            <effects>
     74                <AddQuest questId="missionOne.basicFlying" />
     75                <!--AddQuestHint hintId ="quest1hint3" /-->
     76            </effects>
     77            <events>
     78                <execute>
     79                    <EventListener event=spawntrigger />
     80                </execute>
     81            </events>
     82        </QuestEffectBeacon>
     83
     84        <QuestEffectBeacon times=1>
     85            <effects>
     86                <CompleteQuest questId="missionOne.basicFlying" />
     87            </effects>
     88            <events>
     89                <execute>
     90                    <EventListener event="flying4" />
     91                </execute>
     92            </events>
     93        </QuestEffectBeacon>
     94
     95        <QuestEffectBeacon times=1>
     96            <effects>
     97                <CompleteQuest questId="missionOne.navigation" />
     98            </effects>
     99            <events>
     100                <execute>
     101                    <EventListener event="navigationend" />
     102                </execute>
     103            </events>
     104        </QuestEffectBeacon>
     105
     106<!--helper trigger to end the weaponsystemI quest -->
     107    <DistanceTrigger name="boxend" position="0,0,0" distance=950 target="SpaceShip" stayActive="false" delay=0.1>
     108              <EventTrigger>
     109                <events>
     110                  <trigger>
     111                    <EventListener event="boxtrigger4" />
     112                  </trigger>
     113                </events>
     114              </EventTrigger>
     115    </DistanceTrigger>
     116
     117        <QuestEffectBeacon times=1>
     118            <effects>
     119                <CompleteQuest questId="missionOne.weaponsystemI" />
     120            </effects>
     121            <events>
     122                <execute>
     123                    <EventListener event="boxend" />
     124                </execute>
     125            </events>
     126        </QuestEffectBeacon>
     127
     128<!--helper trigger to end the weaponsystemII quest -->
     129    <DistanceTrigger name="piratesend" position="0,0,0" distance=2000 target="SpaceShip" stayActive="false" delay=0.1>
     130              <EventTrigger>
     131                <events>
     132                  <trigger>
     133                    <EventListener event="movingpirates2" />
     134                  </trigger>
     135                </events>
     136              </EventTrigger>
     137    </DistanceTrigger>
     138
     139        <QuestEffectBeacon times=1>
     140            <effects>
     141                <CompleteQuest questId="missionOne.weaponsystemII" />
     142            </effects>
     143            <events>
     144                <execute>
     145                    <EventListener event=piratesend />
     146                </execute>
     147            </events>
     148        </QuestEffectBeacon>
     149
     150<!--helper trigger to end the DuBallStation quest -->
     151    <DistanceTrigger name="duballend" position="-1000,-300,700" distance=2000 target="SpaceShip" stayActive="false" delay=0.1>
     152              <EventTrigger>
     153                <events>
     154                  <trigger>
     155                    <EventListener event="duball3" />
     156                  </trigger>
     157                </events>
     158              </EventTrigger>
     159    </DistanceTrigger>
     160
     161
     162        <QuestEffectBeacon times=1>
     163            <effects>
     164                <CompleteQuest questId="missionOne.DuballStation" />
     165            </effects>
     166            <events>
     167                <execute>
     168                    <EventListener event=duballend />
     169                </execute>
     170            </events>
     171        </QuestEffectBeacon>
     172
     173        <QuestEffectBeacon times=1> <!--  alternative quest end  -->
     174            <effects>
     175                <CompleteQuest questId="missionOne.DuballStation" />
     176            </effects>
     177            <events>
     178                <execute>
     179                    <EventListener event=toHydroFarmer />
     180                </execute>
     181            </events>
     182        </QuestEffectBeacon>
     183
     184<!--helper trigger to end the getHelp quest -->
     185    <DistanceTrigger name="getHelpEnd" position="-47000,-1000,1300" distance=1400 target="SpaceShip" stayActive="false" delay=0.1>
     186              <EventTrigger>
     187                <events>
     188                  <trigger>
     189                    <EventListener event="ondock" />
     190                  </trigger>
     191                </events>
     192              </EventTrigger>
     193    </DistanceTrigger>
     194
     195        <QuestEffectBeacon times=1>
     196            <effects>
     197                <CompleteQuest questId="missionOne.getHelp" />
     198            </effects>
     199            <events>
     200                <execute>
     201                    <EventListener event=getHelpEnd />
     202                </execute>
     203            </events>
     204        </QuestEffectBeacon>
     205
     206<!--helper trigger to end the getHome quest -->
     207    <DistanceTrigger name="getHomeEnd" position="0,0,0" distance=4000 target="SpaceShip" stayActive="false" delay=0.1>
     208              <EventTrigger>
     209                <events>
     210                  <trigger>
     211                    <EventListener event="attack" />
     212                  </trigger>
     213                </events>
     214              </EventTrigger>
     215    </DistanceTrigger>
     216
     217        <QuestEffectBeacon times=1>
     218            <effects>
     219                <CompleteQuest questId="missionOne.getHome" />
     220            </effects>
     221            <events>
     222                <execute>
     223                    <EventListener event=getHomeEnd />
     224                </execute>
     225            </events>
     226        </QuestEffectBeacon>
     227
     228<!--helper trigger to end the defence quest -->
     229    <DistanceTrigger name="defenceEnd" position="0,0,0" distance=4000 target="SpaceShip" stayActive="false" delay=0.1>
     230              <EventTrigger>
     231                <events>
     232                  <trigger>
     233                    <EventListener event="attacktrigger6" />
     234                  </trigger>
     235                </events>
     236              </EventTrigger>
     237    </DistanceTrigger>
     238
     239        <QuestEffectBeacon times=1>
     240            <effects>
     241                <CompleteQuest questId="missionOne.defence" />
     242            </effects>
     243            <events>
     244                <execute>
     245                    <EventListener event=defenceEnd />
     246                </execute>
     247            </events>
     248        </QuestEffectBeacon>
     249
     250<!-- End the quest after own destruction of spacecruiser -->
     251        <QuestEffectBeacon position="-100,0,0" times=1>
     252            <effects>
     253                <FailQuest questId="missionOne.getHelp" />
     254            </effects>
     255            <events>
     256                <execute>
     257                    <EventListener event="failQuest" />
     258                </execute>
     259            </events>
     260            <attached>
     261                <DistanceTrigger name="failQuest" position="-47000,-1000,1300" distance=2300 target="SpaceShip">
     262                  <EventTrigger>
     263                    <events>
     264                      <trigger>
     265                        <EventListener event="gameEnd" />
     266                      </trigger>
     267                    </events>
     268                  </EventTrigger>
     269                </DistanceTrigger>
     270            </attached>
     271        </QuestEffectBeacon>
     272
     273
     274
     275
    57276    <LocalQuest id="missionOne.basicFlying">
    58         <QuestDescription title="Flying" description="INSERT STORY HERE. The first thing you have to learn is flying. Use 'W' to accelerate and steer with your mouse. In order to know where to fly there are two detection systems. The navigation markers highlite important objects directly in the level. If you can't directly see those objects, there are arrows which indicate how you have to steer. The second device is the radar. There you get an overview of all objects near you. In order to find an object that you spotted on radar, you have to steer in a way that the corresponding dot is in the center of the radar. Now you can find the corresponding object straight ahead. Your goal is to fly to the first waypoint. It's that orange dot on the radar." failmessage="" completeMessage="Well done." />
     277        <QuestDescription title="Flying" description="Can you see the blinking light straight ahead? Your goal is to fly through it.
     278Use (W) to accelerate and steer with your mouse.
     279
     280Further flying moves:
     281break (S)
     282roll     (Q) and (E)
     283boost (Space)
     284
     285Whenever a new quest is added you can view it by pressing (F3). Quit this menu via (Esc)." failmessage="" completeMessage="" />
    59286        <complete-effects>
    60             <AddQuest questId="missionOne.weaponsystem" />
     287            <AddQuest questId="missionOne.navigation" />
    61288        </complete-effects>
    62289    </LocalQuest>
    63290
    64     <LocalQuest id="missionOne.weaponsystem">
    65         <QuestDescription title="Weaponsystem" description="INSERT STORY HERE." failmessage="" completeMessage="All right." />
    66         <subquests>
     291    <LocalQuest id="missionOne.navigation">
     292        <QuestDescription title="Navigation" description="The next goal is to find and move towards the test targets for your weaponsystem. The three arrows that just appeared down in the right corner of your screen indicate in which direction you have to turn your spacefighter to find your next targets.
     293
     294Alternative navigation: There's a green circle in the left corner - the radar. The red dots on the radar represent your targets. If you manage to move your spaceship in a way such that a dot is at the center of the radar, you will be able to see the concerning object straight ahead." failmessage="" completeMessage="" />
     295        <complete-effects>
     296            <AddQuest questId="missionOne.weaponsystemI" />
     297        </complete-effects>
     298    </LocalQuest>
     299
    67300            <LocalQuest id ="missionOne.weaponsystemI">
    68                 <QuestDescription title="Destroy Boxes" description="Test your four different weapons on the four boxes. The four weapons are laser (left click), plasma (right click), self targeting rockets (middle click) and manual rockets (press 'T'). Attention if you use manual rockets: Press 'T' only once to start the rocket. If you miss your target you can get out of the rocket, by clicking or pressing 'T' once more." failmessage="" completeMessage="" />
     301                <QuestDescription title="Destroy the Boxes" description="Test your four different weapons on the four boxes:
     3021. laser (left click)
     3032. plasma (right click)
     3043. target seeking rockets (middle click)
     3054. manual rockets (T)
     306
     307Attention if you use manual rockets: Press (T) only once to start the rocket. If you miss your target you can get out of the rocket, by clicking or pressing (T) once more." failmessage="" completeMessage="" />
     308                    <hints>
     309                        <QuestHint id="missionOne.weaponsystem.laser">
     310                            <QuestDescription title="Laser" description="The laser is a standard weapon. It is fast and precise but does not deal much damage." />
     311                        </QuestHint>
     312                        <QuestHint id="missionOne.weaponsystem.lightningGun">
     313                            <QuestDescription title="Lightninggun" description="That was the lightning gun. Its plasma munition is quite slow, but a normal spaceship can't take more than three hits of such a strong weapon. That could be your favourite weapon for close range combat or if you want to hit a really slow enemy." />
     314                        </QuestHint>
     315                        <QuestHint id="missionOne.weaponsystem.targetSeekingRocket">
     316                            <QuestDescription title="Target Seeking Rocket" description="The target seeking rockets follow slow targets on their own." />
     317                        </QuestHint>
     318                        <QuestHint id="missionOne.weaponsystem.manualrocket">
     319                            <QuestDescription title="Manual Rocket" description="Manual rockets are your most powerful weapon. But since you have to steer it to your target yourself, you will leave your spaceship unprotected for a while. The total amount of both manual and target seeking rockets is limited to 10." />
     320                        </QuestHint>
     321                    </hints>
    69322                <complete-effects>
    70323                    <AddQuest questId="missionOne.weaponsystemII" />
    71324                </complete-effects>
    72325            </LocalQuest>
     326
    73327            <LocalQuest id="missionOne.weaponsystemII">
    74                 <QuestDescription title="" description="" failmessage="" completeMessage="" />
     328                <QuestDescription title="Kill the pirates" description="Get rid of the patrolling pirates.
     329Find out which weapon is best to tackle moving targets. Get close enough." failmessage="" completeMessage="" />
    75330                <complete-effects>
    76331                    <AddQuest questId="missionOne.DuballStation" />
    77332                </complete-effects>
    78333            </LocalQuest>
    79         </subquests>
    80         <hints>
    81             <QuestHint id="missionOne.weaponsystem.laser">
    82               <QuestDescription title="Laser" description="The laser is a standard weapon. It is fast and precise but does not deal much damage." />
    83             </QuestHint>
    84             <QuestHint id="missionOne.weaponsystem.lightningGun">
    85               <QuestDescription title="Lightninggun" description="That was the lightning gun. Its plasma munition is quite slow, but a normal spaceship can't take more than three hits of such a strong weapon. That could be your favourite weapon for close range combat or if you want to hit a really slow enemy." />
    86             </QuestHint>
    87             <QuestHint id="missionOne.weaponsystem.targetSeekingRocket">
    88               <QuestDescription title="Target Seeking Rocket" description="The target seeking rockets follow slow targets on their own." />
    89             </QuestHint>
    90             <QuestHint id="missionOne.weaponsystem.manualrocket">
    91               <QuestDescription title="Manual Rocket" description="Manual rockets are your most powerful weapon. But since you have to steer it to your target yourself, you will leave your spaceship unprotected for a while. The total amount of both manual and target seeking rockets is limited to 10." />
    92             </QuestHint>
    93         </hints>
    94         <complete-effects>
    95         </complete-effects>
    96     </LocalQuest>
    97334
    98335    <LocalQuest id="missionOne.DuballStation">
    99         <QuestDescription title="Duball Space Station" description="Fly towards the Duball Space Station. The grey radar marker will lead you to its position." failmessage="" completeMessage="Well done." />
     336        <QuestDescription title="Duball Space Station" description="Fly towards the Duball Space Station. The grey radar marker will lead you to its position." failmessage="" completeMessage="" />
    100337        <complete-effects>
    101338            <AddQuest questId="missionOne.getHelp" />
     
    104341
    105342    <LocalQuest id="missionOne.getHelp">
    106         <QuestDescription title="Get Help" description="There are enemies approaching. You can't handle it on your own. Fortunately there's a shortcut to the next friendly unit. Use the portal (grey dot) to get near the Hydrogen Farmer. There you might get help - as far as we know there should be a stronger spaceship docked to the Hydrogen Farmer. In order to be able to use that stronger spaceship you have to dock to the Hydrogen Farmer. Simply fly to the center of the Hydrogen Farmer, which is between its three legs." failmessage="" completeMessage="Well done." />
     343        <QuestDescription title="Get Help" description="There are several enemies approaching. You can't handle it on your own. Fortunately there's a shortcut to the next friendly unit. Use the portal (grey dot) to get near the Hydrogen Farmer.
     344The Hydrogen Farmer is a large spaceship with three legs.
     345There you might get help - as far as we know there should be a strong spaceruiser docked to the Hydrogen Farmer. In order to be able to use that stronger spaceship, you have to dock to the Hydrogen Farmer.
     346Simply fly to the center of the Hydrogen Farmer, which is between its three legs.
     347
     348How to dock: Accept the dialogue, take your hands off the keyboard and watch." failmessage="" completeMessage="" />
    107349        <complete-effects>
    108350            <AddQuest questId="missionOne.getHome" />
     
    111353
    112354    <LocalQuest id="missionOne.getHome">
    113         <QuestDescription title="Return ASAP" description="" failmessage="" completeMessage="Well done." />
     355        <QuestDescription title="Return ASAP" description="So you managed to get the spacecruiser. Use the portal to return to the DuBall Space Station.
     356Hurry! Your help is desperately needed." failmessage="" completeMessage="" />
    114357        <complete-effects>
    115358            <AddQuest questId="missionOne.defence" />
     
    118361
    119362    <LocalQuest id="missionOne.defence">
    120         <QuestDescription title="Defence" description="" failmessage="" completeMessage="Well done." />
     363        <QuestDescription title="Defence" description="Seven enemies were detected that seem to launch a coordinated attack.
     364Do not hesitate to fight or you will be the target.
     365
     366Always take care of the enemy that is the closest to you." failmessage="" completeMessage="Yeah! You did it." />
    121367    </LocalQuest>
    122 
    123 
    124         <QuestEffectBeacon position="800,700,600" times="1">
    125             <effects>
    126                 <AddQuest questId="missionOne.basicFlying" />
    127             </effects>
    128             <events>
    129                 <execute>
    130                     <EventListener event="questStart"/>
    131                 </execute>
    132             </events>
    133             <attached>
    134                 <DistanceTrigger name="questStart" position="0,0,0" distance="50" target="Pawn" beaconMode="identify" targetname="PlayerDistanceTrigger" delay="2" />
    135             </attached>
    136         </QuestEffectBeacon>
    137 
    138 
    139 <!-- TUTORIAL-TODO: -->
    140 <!-- 1. Flying & manoeuvring (basic flying, using pickups, forcefields, docks & portals) --> <!-- "W","S","SPACE"-->
    141 <!-- 2. Aiming & Weapons (static targets, moving targets, dangerous targets)--> <!-- 3 Mouse buttons + "T"-->
    142 <!-- 3. Game handling (quests, knowing when a game is over :-), pausing, chat, ... ) --> <!--"F3", "F2", "ESC" -->
    143 <!-- 4. Extras (other things to discover) --> <!-- "Q","E","A","D","C", "CTRL", "", ... -->
    144 
    145 <!--
    146 
    147 "Lets start flying. Use W to accelerate and S to brake. The goal is to reach the spacestation which is displayed on the radar. If you want to be faster you can temporarily boost by hitting additionally the space button. If you use too much boost your engine heats up and you won't be able to use boost for a while. By the way boost could be useful during combat .."
    148 
    149 -->
    150 
    151     <DistanceTrigger name="spawndelaytrigger0" position="800,700,600" target="Pawn" distance=10 stayActive="true"/>
    152     <SimpleNotification message="Welcome to the Orxonox Tutorial.">
     368<!-- --------------------- END OF QUESTS -------------------------- -->
     369
     370
     371    <DistanceTrigger name="spawndelaytrigger0" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=2/>
     372    <SimpleNotification message="Press (F3) to see your mission briefing.">
    153373        <events>
    154374            <trigger>
     
    158378    </SimpleNotification>
    159379
    160 <BlinkingBillboard position="-900,640,600" frequency=0.4 amplitude=2 material="Flares/lensflare" colour="1,1,0">
     380<!-- Blinking Billboard should be replaced with WAYPOINT -->
     381<BlinkingBillboard position="-900,640,600" frequency=0.6 amplitude=3 material="Flares/lensflare" colour="1,1,0.05">
    161382          <events>
    162383            <visibility>
     
    184405          </events>
    185406</Billboard>
     407
    186408<!-------------------------------------- PART ZERO: How to fly --------------------------------------->
    187     <DistanceTrigger name="flying1" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=4/>
     409
     410    <DistanceTrigger name="flying1" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=6/>
    188411    <SimpleNotification message="Let's fly to the blinking light.">
    189412        <events>
     
    194417    </SimpleNotification>
    195418
    196     <DistanceTrigger name="flying2" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=8/>
    197     <SimpleNotification message="Use 'W' to accelerate and the mouse to steer.">
     419    <DistanceTrigger name="flying2" position="800,700,600" target="Pawn" distance=10 stayActive="true" delay=10/>
     420    <SimpleNotification message="Use (W) to accelerate and the mouse to steer.">
    198421        <events>
    199422            <trigger>
     
    203426    </SimpleNotification>
    204427
    205     <!--DistanceTrigger name="flying3" position="800,700,600" target="Pawn" distance=20 stayActive="true" delay=12/>
    206     <SimpleNotification message="Point with the mouse to the blinking light.">
    207         <events>
    208             <trigger>
    209                 <EventListener event="flying3" />
    210             </trigger>
    211         </events>
    212     </SimpleNotification-->
    213 
    214     <DistanceTrigger name="flying4" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=1/>
    215     <SimpleNotification message="Three red arrows just appeared.">
     428<!-- QUEST-Trigger && Message Trigger: navigationend is activated after flying4 was triggered -->
     429    <DistanceTrigger name="navigationend" position="0,0,0" distance=950 target="SpaceShip" stayActive="false" delay=1.1>
     430        <DistanceTrigger name="flying4" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=1/>
     431    </DistanceTrigger>
     432
     433
     434    <SimpleNotification message="Three arrows just appeared.">
    216435        <events>
    217436            <trigger>
     
    222441
    223442    <DistanceTrigger name="flying5" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=5/>
    224     <SimpleNotification message="Follow those red arrows.">
     443    <SimpleNotification message="Follow those arrows.">
    225444        <events>
    226445            <trigger>
     
    230449    </SimpleNotification>
    231450
    232 
    233 
    234451<!-------------------------------------- PART ONE : Destroy boxes --------------------------------------->
    235     <DistanceTrigger name="spawndelaytrigger1" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=9 />
    236     <SimpleNotification message="Destroy the four boxes.">
     452<!-- @ triggers: spawndelaytriggerX: textoutput only if no box was destroyed -->
     453    <Trigger name="spawndelaytrigger1" mode="and" stayActive="true">
     454        <DistanceTrigger position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=9 />
     455        <EventTrigger activations="1" invert="true">
     456          <events>
     457            <trigger>
     458              <EventListener event="boxtrigger1" />
     459            </trigger>
     460          </events>
     461        </EventTrigger>
     462    </Trigger>
     463
     464    <Trigger name="spawndelaytrigger2" mode="and" stayActive="true">
     465        <DistanceTrigger position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=13 />
     466        <EventTrigger activations="1" invert="true">
     467          <events>
     468            <trigger>
     469              <EventListener event="boxtrigger1" />
     470            </trigger>
     471          </events>
     472        </EventTrigger>
     473    </Trigger>
     474
     475    <Trigger name="spawndelaytrigger3" mode="and" stayActive="true">
     476        <DistanceTrigger position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=17 />
     477        <EventTrigger activations="1" invert="true">
     478          <events>
     479            <trigger>
     480              <EventListener event="boxtrigger1" />
     481            </trigger>
     482          </events>
     483        </EventTrigger>
     484    </Trigger>
     485
     486<!-- @Text: How to shoot-->
     487    <SimpleNotification message="Destroy the four boxes." broadcast="true">
    237488        <events>
    238489            <trigger>
     
    242493    </SimpleNotification>
    243494
    244     <DistanceTrigger name="spawndelaytrigger2" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=13 />
    245     <SimpleNotification message=" 1. Aim the a red cycle.">
     495    <SimpleNotification message=" 1. Aim the a red cycle." broadcast="true">
    246496        <events>
    247497            <trigger>
     
    251501    </SimpleNotification>
    252502
    253     <DistanceTrigger name="spawndelaytrigger3" position="-900,640,600" target="Pawn" distance=60 stayActive="true" delay=17 />
    254     <SimpleNotification message="2. Click! (hold the left mouse button)">
     503    <SimpleNotification message="2. Click! (hold the left mouse button)" broadcast="true">
    255504        <events>
    256505            <trigger>
     
    261510
    262511<!-- @Objects: 4 boxes (uncontrolled pawns) -->
    263                 <Pawn health=30 position="0,0,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box >
    264                     <events>
    265                       <visibility>
    266                         <EventListener event="flying4" />
    267                       </visibility>
    268                     </events>
    269                     <attached>
    270                         <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
    271                     </attached>
    272                     <collisionShapes>
    273                         <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
    274                     </collisionShapes>
    275                 </Pawn>
    276 
    277                 <Pawn health=30 position="0,100,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box visible="true">
    278                     <events>
    279                       <visibility>
    280                         <EventListener event="flying4" />
    281                       </visibility>
    282                     </events>
    283                     <attached>
    284                         <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
    285                     </attached>
    286                     <collisionShapes>
    287                         <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
    288                     </collisionShapes>
    289                 </Pawn>
    290                 <Pawn health=30 position="0,200,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box >
    291                     <events>
    292                       <visibility>
    293                         <EventListener event="flying4" />
    294                       </visibility>
    295                     </events>
    296                     <attached>
    297                         <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
    298                     </attached>
    299                     <collisionShapes>
    300                         <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
    301                     </collisionShapes>
    302                 </Pawn>
    303                 <Pawn health=30 position="0,300,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box >
    304                     <events>
    305                       <visibility>
    306                         <EventListener event="flying4" />
    307                       </visibility>
    308                     </events>
    309                     <attached>
    310                         <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
    311                     </attached>
    312                     <collisionShapes>
    313                         <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
    314                     </collisionShapes>
    315                 </Pawn>
     512    <Pawn team=1 health=30 position="0,0,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box RVName = "Box 1" >
     513        <events>
     514          <visibility>
     515            <EventListener event="flying4" />
     516          </visibility>
     517        </events>
     518        <attached>
     519            <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     520        </attached>
     521        <collisionShapes>
     522            <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
     523        </collisionShapes>
     524    </Pawn>
     525
     526    <Pawn team=1 health=30 position="0,100,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box RVName = "Box 2">
     527        <events>
     528          <visibility>
     529            <EventListener event="flying4" />
     530          </visibility>
     531        </events>
     532        <attached>
     533           <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     534        </attached>
     535        <collisionShapes>
     536            <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
     537        </collisionShapes>
     538    </Pawn>
     539
     540    <Pawn health=30 position="0,200,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box team=1 RVName = "Box 3">
     541        <events>
     542          <visibility>
     543            <EventListener event="flying4" />
     544          </visibility>
     545        </events>
     546        <attached>
     547           <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     548        </attached>
     549        <collisionShapes>
     550            <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
     551        </collisionShapes>
     552    </Pawn>
     553
     554    <Pawn health=30 position="0,300,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box team=1 RVName = "Box 4">
     555        <events>
     556          <visibility>
     557            <EventListener event="flying4" />
     558          </visibility>
     559        </events>
     560        <attached>
     561            <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     562        </attached>
     563        <collisionShapes>
     564           <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
     565        </collisionShapes>
     566    </Pawn>
    316567
    317568<!-- @Triggers: boxtrigger1 <-> one   box   destroyed
     
    365616    </SimpleNotification>
    366617
    367 
    368   <SimpleNotification message="Aim at the last target and press 'T'." broadcast="true">
     618  <SimpleNotification message="Aim at the last target and press (T)." broadcast="true">
    369619        <events>
    370620            <trigger>
     
    386636
    387637<!-- @Objects: 2 pirates moving in squares, nonlethal -->
    388                 <SpaceShip position="0,2000,200" lookat="0,0,0" name="movingtarget" >
     638                <SpaceShip position="0,2000,200" lookat="0,0,0" name="movingtarget" RVName="Pirate">
    389639                            <events>
    390640                                <visibility>
     
    396646                    </templates>
    397647                    <controller>
    398                       <WaypointController>
     648                      <WaypointController team=1>
    399649                         <waypoints>
    400650                          <Model mesh="cube.mesh" scale=8 position="  0,1700,-200" />
     
    407657                </SpaceShip>
    408658
    409                 <SpaceShip position="0,2000,400" lookat="0,0,0" name="movingtarget">
     659                <SpaceShip position="0,2000,400" lookat="0,0,0" name="movingtarget" RVName="Pirate">
    410660                            <events>
    411661                                <visibility>
     
    417667                  </templates>
    418668                  <controller>
    419                     <WaypointController>
     669                    <WaypointController team=1>
    420670                      <waypoints>
    421671                        <Model mesh="cube.mesh" scale=8 position="  0,2400,1000" />
     
    473723    </DistanceTrigger>
    474724
    475     <EventTrigger name="duball2" activations="1" stayactive="true" delay=4 >
    476       <events>
    477         <trigger>
    478           <EventListener event="duball1" />
    479         </trigger>
    480       </events>
    481     </EventTrigger>
    482 
    483     <EventTrigger name="duball3" activations="1" stayactive="true" delay=4 >
    484       <events>
    485         <trigger>
    486           <EventListener event="duball2" />
    487         </trigger>
    488       </events>
    489     </EventTrigger>
     725    <Trigger name="duball2" mode="and" stayActive="true">
     726        <EventTrigger activations="1" stayactive="true" delay=4 >
     727           <events>
     728              <trigger>
     729                 <EventListener event="duball1" />
     730              </trigger>
     731           </events>
     732        </EventTrigger>
     733        <EventTrigger activations="1" invert="true">
     734          <events>
     735            <trigger>
     736              <EventListener event="toHydroFarmer" />
     737            </trigger>
     738          </events>
     739        </EventTrigger>
     740    </Trigger>
     741
     742    <Trigger name="duball3" mode="and" stayActive="true">
     743        <EventTrigger activations="1" stayactive="true" delay=4 >
     744           <events>
     745              <trigger>
     746                 <EventListener event="duball2" />
     747              </trigger>
     748           </events>
     749        </EventTrigger>
     750        <EventTrigger activations="1" invert="true">
     751          <events>
     752            <trigger>
     753              <EventListener event="toHydroFarmer" />
     754            </trigger>
     755          </events>
     756        </EventTrigger>
     757    </Trigger>
     758
    490759
    491760    <SimpleNotification message="Welcome to the Duball Space Station!">
     
    520789        <Model scale=13 mesh="DuBall2.mesh" position = "100,0,0"/>
    521790        <Billboard scale=7 material="Examples/Flare" colour="0.5,0.5,0.5" position = "-100,0,0"/>
    522         <Billboard scale=7 material="Examples/Flare" colour="0.5,0.5,0.5" position = "100,0,0"/>       
     791        <Billboard scale=7 material="Examples/Flare" colour="0.5,0.5,0.5" position = "100,0,0"/>
    523792      </attached>
    524793      <collisionShapes>
     
    657926
    658927
    659     <SimpleNotification message="Dock to the Hydrogen Farmer.">
     928    <SimpleNotification message="Dock to the Hydrogen Farmer." broadcast="true">
    660929        <events>
    661930            <trigger>
     
    665934    </SimpleNotification>
    666935
    667 <!-------------------------------------- PART FOUR : Get Help --------------------------------------->   
    668     <DistanceTrigger name="famer1" position="-48200,100,0" target="Pawn" distance=650 stayActive="true" delay=0 />
    669     <SimpleNotification message="We just received a message from DuBall.">
     936<!-------------------------------------- PART FOUR : Get Help --------------------------------------->
     937
     938    <Trigger name="famer1" mode="and" stayActive="true">
     939        <DistanceTrigger position="-48200,100,0" target="Pawn" distance=650 stayActive="true" delay=0 />
     940        <EventTrigger name="notGameEnd" activations="1" invert="true">
     941          <events>
     942            <trigger>
     943              <EventListener event="gameEnd" />
     944            </trigger>
     945          </events>
     946        </EventTrigger>
     947    </Trigger>
     948
     949    <Trigger name="famer2" mode="and" stayActive="true">
     950        <DistanceTrigger position="-48200,100,0" target="Pawn" distance=650 stayActive="true" delay=4 />
     951        <EventTrigger activations="1" invert="true">
     952          <events>
     953            <trigger>
     954              <EventListener event="gameEnd" />
     955            </trigger>
     956          </events>
     957        </EventTrigger>
     958    </Trigger>
     959
     960    <SimpleNotification message="We just received a message from DuBall." broadcast="true">
    670961        <events>
    671962            <trigger>
     
    675966    </SimpleNotification>
    676967
    677     <DistanceTrigger name="famer2" position="-48200,100,0" target="Pawn" distance=650 stayActive="true" delay=4 />
    678     <SimpleNotification message="We will lend you our strongest ship.">
     968
     969    <SimpleNotification message="We will lend you our strongest ship." broadcast="true">
    679970        <events>
    680971            <trigger>
     
    686977
    687978<!-- @Objects: HYDROGEN FARMER & DOCKING -->
    688     <SpaceShip position="-48900,100,0" roll=90 yaw=0 pitch=20 mass=10000 health=100000 name="HydroFarmer">
     979    <SpaceShip
     980        team     = 0
     981        position = "-48900,100,0"
     982        roll     = 90   yaw=0  pitch=20
     983        mass     = 10000
     984        health   = 100000 initialhealth=100000 maxhealth="100000"
     985        name     = "HydroFarmer"
     986        RVName   = "Hydrogen Farmer" >
    689987      <attached>
    690988        <!-- Docking -->
     
    7301028    </SpaceShip>
    7311029
    732     <Billboard position="-48900,0,0" material="Examples/Flare" colour="0.6,0,0" scale=3/>
    7331030    <Dock position="-48900,0,0" roll=90 yaw=180 >
    7341031        <animations>
     
    7421039                <EventListener event="dockMe" />
    7431040            </execute>
     1041            <activity>
     1042                <EventListener event=notGameEnd />
     1043            </activity>
    7441044        </events>
    7451045        <attached>
     
    7481048            />
    7491049        </attached>
     1050
    7501051    </Dock>
    7511052
    752     <SpaceShip template="spaceshipspacecruiser" position="-48900,800,0" orientation="-0.14, 0.68, 0.68, 0.223" health="300" maxhealth="400" initialhealth="300" name="cruiser" >
     1053<!--@Objects: SpaceCruiser as docking target -->
     1054    <SpaceShip
     1055        template            = "spaceshipspacecruiser"
     1056        team                = "0"
     1057        position            = "-48900,800,0"
     1058        orientation         = "-0.14, 0.68, 0.68, 0.223"
     1059        health              = "400"
     1060        initialhealth       = "400"
     1061        maxhealth           = "500"
     1062        shieldhealth        = "80"
     1063        initialshieldhealth = "80"
     1064        maxshieldhealth     = "120"
     1065        shieldabsorption    = "0.8"
     1066        reloadrate          = "1"
     1067        reloadwaittime      = "1"
     1068        name                = "cruiser"
     1069        RVName              = "Spacecruiser" >
    7531070      <attached>
    7541071        <DockingTarget name="spaceShip" />
     
    7561073    </SpaceShip>
    7571074
    758 <!-- TESTBOX-->
    759 
    760 <!-- TESTBOX-->
    761 
     1075
     1076<!-- cruiserKilled: if cuiser is killed & player hasn't taken control of spacecrusier -->
    7621077          <Trigger name="cruiserKilled" mode="and" stayActive="true">
    7631078            <EventTrigger  stayActive="true">
     
    7781093
    7791094
     1095<!-- triggers when either hydrofarmer or cruiser is killed -->
     1096            <Trigger mode=or name="gameEnd">
     1097                <EventTrigger activations="1">
     1098                  <events>
     1099                    <trigger>
     1100                      <EventListener event="HydroFarmer" />
     1101                    </trigger>
     1102                  </events>
     1103                </EventTrigger>
     1104                <EventTrigger activations="1">
     1105                  <events>
     1106                    <trigger>
     1107                      <EventListener event="cruiserKilled" />
     1108                    </trigger>
     1109                  </events>
     1110                </EventTrigger>
     1111            </Trigger>
     1112
     1113<!-- triggers delayed when either hydrofarmer or cruiser is killed -->
    7801114            <EventTrigger delay=4 name="earlyEnd">
    7811115              <events>
    7821116                <trigger>
    783                   <EventListener event="cruiserKilled" />
     1117                  <EventListener event="gameEnd" />
    7841118                </trigger>
    7851119              </events>
     
    7911125            </EventTrigger>
    7921126
    793             <EventTrigger delay=4 name="earlyEnd">
    794               <events>
    795                 <trigger>
    796                   <EventListener event="HydroFarmer" />
    797                 </trigger>
    798               </events>
    799               <events>
    800                 <activity>
    801                   <EventListener event="movingpirates2" />
    802                 </activity>
    803               </events>
    804             </EventTrigger>
    805 
    806 
    8071127
    8081128    <SimpleNotification message="Oh no! You killed the Hydrogen Farmer!" broadcast="true">
     
    8221142    </SimpleNotification>
    8231143
    824     <SimpleNotification message="Press 'Esc' and restart the mission." broadcast="true">
     1144    <SimpleNotification message="Press (Esc) and restart the mission." broadcast="true">
    8251145        <events>
    8261146            <trigger>
     
    8291149        </events>
    8301150    </SimpleNotification>
    831 
    8321151
    8331152<!-- hydrogen farmer & docking END -->
     
    8721191    >
    8731192      <!--attached>
    874         <ForceField position="0,0,0" mode="sphere" diameter="10000" velocity="-50" /> 
     1193        <ForceField position="0,0,0" mode="sphere" diameter="10000" velocity="-50" />
    8751194      </attached-->  <!-- Forcefield kills HYDROGEN FARMER-->
    8761195      <collisionShapes>
     
    8811200
    8821201<!-------------------------------------- The attack --------------------------------------->
    883 
    8841202<!-- TODO:
    8851203     - update spaceshipTransporter
    886      - bots do friendly fire (is drone function reusable?) 
     1204     - bots do friendly fire (is drone function reusable?)
    8871205-->
     1206
     1207<!-- Fallback Spawnpoint: on cruiserdeath caused by pirates. Unfortunately unstable behaviour concerning activity. -->
     1208    <TeamSpawnPoint team=0 position="2000,1500,-1500" direction="-1,-1,1" spawnclass=SpaceShip pawndesign=spaceshipspacecruiser>
     1209        <events>
     1210            <activity>
     1211                <EventListener event="attack" />
     1212            </activity>
     1213        </events>
     1214    </TeamSpawnPoint>
    8881215
    8891216<!-- @Triggers: toHydroFamer <-> first  portal usage
     
    8911218                attack       <-> second portal usage -->
    8921219
    893     <DistanceTrigger name="attack" position="-1400,-500,800" target="Pawn" distance=100 stayActive="true" >
     1220    <DistanceTrigger name="attack" position="-1400,-500,800" target="Pawn" distance=100 stayActive="true" mode="and">
    8941221        <EventTrigger name="ondock" activations="1" stayactive="true" delay=6>
    8951222          <events>
     
    8981225            </trigger>
    8991226          </events>
    900             <DistanceTrigger name="toHydroFarmer" position="-47000,-1000,1300" target="Pawn" distance=100 stayActive="true" />
     1227            <Trigger mode=and>
     1228              <DistanceTrigger name="toHydroFarmer" position="-47000,-1000,1300" target="Pawn" distance=100 stayActive="true" />
     1229              <EventTrigger activations="1" invert="true">
     1230                <events>
     1231                  <trigger>
     1232                    <EventListener event="gameEnd" />
     1233                  </trigger>
     1234                </events>
     1235              </EventTrigger>
     1236            </Trigger>
     1237        </EventTrigger>
     1238        <EventTrigger activations="1" invert="true">
     1239          <events>
     1240            <trigger>
     1241              <EventListener event="earlyEnd" />
     1242            </trigger>
     1243          </events>
    9011244        </EventTrigger>
    9021245    </DistanceTrigger>
    9031246
    904     <SimpleNotification message="Return before it's too late. Boost with 'Space'." broadcast="true">
     1247    <SimpleNotification message="Return before it's too late. Boost with (Space)." broadcast="true">
    9051248        <events>
    9061249            <trigger>
     
    9191262
    9201263
    921 
    9221264<!-- @Objects: 6 pirates, heading towards DuBall, attacking  -->
     1265<!-- TODO: re-hide pirates on early end-->
    9231266<!-- 1 -->
    9241267    <SpaceShip position="3000,-4000,4000" lookat="-1300,-600,900" name="attacker"visible="true">
     
    10651408        </controller>
    10661409    </SpaceShip>
     1410
    10671411
    10681412<!-- @Triggers: attacktriggerX <-> X enemies destroyed , X is an element of [1,6] -->
     
    11421486      </events>
    11431487    </SimpleNotification>
     1488
    11441489    <SimpleNotification message="One enemy left!" broadcast="true">
    11451490      <events>
     
    11491494      </events>
    11501495    </SimpleNotification>
     1496
    11511497    <SimpleNotification message="Well done. You finished this tutorial." broadcast="true">
    11521498      <events>
     
    11581504
    11591505<!-- @Triggers: postAttack <-> delayed attacktrigger6 -->
    1160     <EventTrigger name="postAttack1" activations="1" stayactive="true" delay=3>
     1506    <EventTrigger name="postAttack1" activations="1" stayactive="true" delay=4.1>
    11611507      <events>
    11621508        <trigger>
     
    11661512    </EventTrigger>
    11671513
    1168     <EventTrigger name="postAttack2" activations="1" stayactive="true" delay=6>
     1514    <EventTrigger name="postAttack2" activations="1" stayactive="true" delay=8.2>
    11691515      <events>
    11701516        <trigger>
     
    11741520    </EventTrigger>
    11751521
    1176     <SimpleNotification message="Either quit by pressing 'Esc' or ..." broadcast="true">
     1522    <SimpleNotification message="Either quit by pressing (Esc) or ..." broadcast="true">
    11771523      <events>
    11781524        <trigger>
     
    11921538<!-------------------------------------- |Bonus Part| --------------------------------------->
    11931539<!-- @Triggers: "bonusX" <->  delayed "attacktrigger6" -->
    1194     <EventTrigger name="bonus1" activations="1" stayactive="true" delay=10>
     1540    <EventTrigger name="bonus1" activations="1" stayactive="true" delay=12.3>
    11951541      <events>
    11961542        <trigger>
     
    11991545      </events>
    12001546    </EventTrigger>
    1201     <EventTrigger name="bonus2" activations="1" stayactive="true" delay=16>
     1547    <EventTrigger name="bonus2" activations="1" stayactive="true" delay=16.4>
    12021548      <events>
    12031549        <trigger>
     
    12131559      </events>
    12141560    </EventTrigger>
    1215     <EventTrigger name="bonus4" activations="1" stayactive="true" delay=28>
     1561    <EventTrigger name="bonus4" activations="1" stayactive="true" delay=28.1>
    12161562      <events>
    12171563        <trigger>
     
    12201566      </events>
    12211567    </EventTrigger>
    1222     <EventTrigger name="bonus5" activations="1" stayactive="true" delay=32.1>
     1568    <EventTrigger name="bonus5" activations="1" stayactive="true" delay=32.3>
    12231569      <events>
    12241570        <trigger>
     
    12271573      </events>
    12281574    </EventTrigger>
    1229     <EventTrigger name="bonus6" activations="1" stayactive="true" delay=36.2>
     1575    <EventTrigger name="bonus6" activations="1" stayactive="true" delay=36.5>
    12301576      <events>
    12311577        <trigger>
     
    12341580      </events>
    12351581    </EventTrigger>
    1236     <EventTrigger name="bonus7" activations="1" stayactive="true" delay=4>
     1582    <EventTrigger name="bonus7" activations="1" stayactive="true" delay=4.1>
    12371583      <events>
    12381584        <trigger>
     
    12441590
    12451591
    1246     <SimpleNotification message="Rotate your ship. Press 'Q' or 'E'. "  broadcast="true">
     1592    <SimpleNotification message="Rotate your ship. Press (Q) or (E). "  broadcast="true">
    12471593        <events>
    12481594            <trigger>
     
    12521598    </SimpleNotification>
    12531599
    1254     <SimpleNotification message="Switch the camera's position. Press 'C'. "  broadcast="true">
     1600    <SimpleNotification message="Switch the camera's position. Press (C). "  broadcast="true">
    12551601        <events>
    12561602            <trigger>
     
    12601606    </SimpleNotification>
    12611607
    1262     <SimpleNotification message="360° view: press 'Ctrl' + use the mouse "  broadcast="true">
     1608    <SimpleNotification message="360° view: press (Ctrl) + use the mouse "  broadcast="true">
    12631609        <events>
    12641610            <trigger>
     
    12921638    </SimpleNotification>
    12931639
    1294     <SimpleNotification message="Press 'Esc' and return to the main menu."  broadcast="true">
     1640    <SimpleNotification message="Press (Esc) and return to the main menu."  broadcast="true">
    12951641        <events>
    12961642            <trigger>
     
    13191665  </Scene>
    13201666</Level>
    1321 <!-- TODO:
    1322 ! Quest Interface
    1323 - Foolproof text messages (e.g. verspätete Nachrichten unterdrücken)
    1324 - Radar visibility & Hud Markers (done)
     1667
     1668<!-- TODO:
     1669- Story & more precise Questmessages; more quest hints; fail-quest;
     1670- Colouring: Show who is friend or foe via the colour
     1671- Waypoints: show the player the way
     1672- Foolproof text messages (e.g. verspätete Nachrichten unterdrücken ~done )
    13251673- End Tutorial, if either the Hydrogen Farmer or the SpaceCruiser gets destroyed. (~done)
    1326 
    13271674 -->
  • code/branches/presentation2011/data/levels/pirateAttack.oxw

    r8977 r8980  
    2727   
    2828<Level
    29  gametype = "TeamDeathmatch"
     29name="Dani's Testlevel"
     30description="Erste Versuche mit den Quests"
     31gametype=Mission
    3032>
    3133
     
    251253                    </events>
    252254                </QuestEffectBeacon>
    253         <!--Stick found-->
     255        <!--Stick found-->zz
    254256        <QuestEffectBeacon position="4800,5785,-10725" times=1>
    255257                    <attached>
  • code/branches/presentation2011/data/levels/templates/spaceshipSpacecruiser.oxt

    r8891 r8980  
    1111   initialhealth     = 300
    1212
    13    shieldhealth        = 60
    14    initialshieldhealth = 60
    15    maxshieldhealth     = 80
    16    shieldabsorption    = 0.8
     13   shieldhealth        = 75
     14   initialshieldhealth = 75
     15   maxshieldhealth     = 90
     16   shieldabsorption    = 0.9
    1717   reloadrate          = 1
    1818   reloadwaittime      = 1
     
    4545    </engines>
    4646    <attached>
    47       <Model position="12,-30,-120" yaw=90 pitch=-90 roll=0 scale=6 mesh="spacecruiser.mesh" />
     47      <Model position="12,-5,-10" yaw=90 pitch=-90 roll=0 scale=6 mesh="spacecruiser.mesh" />
    4848      <!--Model mesh="cube.mesh" mass=10 position="0,-30,-108" scale3D="38,6,62" />
    4949      <Model mesh="cube.mesh" mass=10 position="0,-20,-108" scale3D="20,6,40" />
     
    5757    </attached>
    5858    <collisionShapes>
    59       <BoxCollisionShape position="0,-30,-108"   halfExtents="38,6,62" />
    60       <BoxCollisionShape position="0,-20,-108"   halfExtents="20,6,40" />
    61       <BoxCollisionShape position="-16,-35,-112" halfExtents="15,5,57" roll=-14 pitch=3.5/>
    62       <BoxCollisionShape position="16,-35,-112"   halfExtents="15,5,57" roll=14 pitch=3.5/>
    63       <BoxCollisionShape position="19,-21.5,-108" halfExtents="18,5,52" roll=-21 />
    64       <BoxCollisionShape position="-19,-21.5,-108"halfExtents="18,5,52" roll=21 />
    65       <BoxCollisionShape position="0,-21,-169"halfExtents="18,1,16" pitch=-30x />
     59      <BoxCollisionShape position="0,-5,2"     halfExtents="38,6,62" />
     60      <BoxCollisionShape position="0,5,2"      halfExtents="20,6,40" />
     61      <BoxCollisionShape position="-16,-10,-2" halfExtents="15,5,57" roll=-14 pitch=3.5/>
     62      <BoxCollisionShape position="16,-10,-2"  halfExtents="15,5,57" roll=14 pitch=3.5/>
     63      <BoxCollisionShape position="19,3.5,2"  halfExtents="18,5,52" roll=-21 />
     64      <BoxCollisionShape position="-19,4.5,2"  halfExtents="18,5,52" roll=21 />
     65      <BoxCollisionShape position="0,4,-59"    halfExtents="18,1,16" pitch=-30/>
    6666
    6767    </collisionShapes>
    6868<?lua
    69   include("includes/weaponSettingsSpacecruiser.oxi")
     69  include("../includes/weaponSettingsSpacecruiser.oxi")
    7070?>
    7171  </SpaceShip>
     
    7575  <SpaceShip>
    7676    <camerapositions>
    77       <CameraPosition position="0,10,  40" drag=true mouselook=true />
    78       <CameraPosition position="0,20,  80" drag=true mouselook=true />
    79       <CameraPosition position="0,30, 120" drag=true mouselook=true />
    80       <CameraPosition position="0,20,-260" drag=true mouselook=true yaw=180/>
    81       <CameraPosition position="0,30,-350" drag=true mouselook=true yaw=180/>
    82       <!--CameraPosition position="0,150,-25" pitch=-90 drag=true />
    83       <CameraPosition position="0,0,-40" yaw=180 drag=true />
    84       <CameraPosition position="0,3,-14" yaw=0 />
    85       <CameraPosition position="-50,5,-8" yaw=-90 drag=true />
    86       <CameraPosition position="50,5,-8" yaw=90 drag=true /-->
     77      <CameraPosition position="0,40, 170" drag=true mouselook=true />
     78      <CameraPosition position="0,55, 230" drag=true mouselook=true />
     79      <CameraPosition position="0,65, 460" drag=true mouselook=true />
    8780    </camerapositions>
    8881  </SpaceShip>
     
    9386   boostfactor    = 2
    9487
    95    speedfront     = 150
    96    speedback      =  50
    97    speedleftright =  50
    98    speedupdown    =  50
     88   speedfront     = 200
     89   speedback      =  70
     90   speedleftright =  70
     91   speedupdown    =  70
    9992
    10093   defEngineSndNormal = "sounds/Engine_low.ogg"
     
    111104    </EffectContainer>
    112105    <EffectContainer condition="not idle">
    113       <FadingBillboard mainstate=activity active=false scale=0.1 position="20, -25, -40" colour="0.2, 0.65, 1.0, 1.0" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
    114       <FadingBillboard mainstate=activity active=false scale=0.1 position="-20, -25, -40" colour="0.2, 0.65, 1.0, 1.0" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
     106      <FadingBillboard mainstate=activity active=false scale=0.1 position="20,  0, 70" colour="0.2, 0.65, 1.0, 1.0" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
     107      <FadingBillboard mainstate=activity active=false scale=0.1 position="-20, 0, 70" colour="0.2, 0.65, 1.0, 1.0" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
    115108    </EffectContainer>
    116109    <EffectContainer condition="normal or brake">
     
    118111    </EffectContainer>
    119112    <EffectContainer condition="normal or boost">
    120       <Backlight mainstate=activity active=false scale=0.4 name=bltest position=" 20, -25, -40" colour="0.2, 0.65, 1.0, 1.0" width=15 length=1300 lifetime=2 elements=50 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Flares/ThrusterFlare1" />
    121       <Backlight mainstate=activity active=false scale=0.4 name=bltest position="-20, -25, -40" colour="0.2, 0.65, 1.0, 1.0" width=15 length=1300 lifetime=2 elements=50 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Flares/ThrusterFlare1" />
     113      <Backlight mainstate=activity active=false scale=0.4 name=bltest position=" 20, 0, 70" colour="0.2, 0.65, 1.0, 1.0" width=15 length=1300 lifetime=2 elements=50 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Flares/ThrusterFlare1" />
     114      <Backlight mainstate=activity active=false scale=0.4 name=bltest position="-20, 0, 70" colour="0.2, 0.65, 1.0, 1.0" width=15 length=1300 lifetime=2 elements=50 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Flares/ThrusterFlare1" />
    122115    </EffectContainer>
    123116    <EffectContainer condition="boost">
    124       <Backlight mainstate=activity active=false scale=0.4 name=bltest position=" 20, -25, -40" colour="0.6, 0.75, 0.8, 0.7" width=40 length=800 lifetime=1 elements=30 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Examples/Flare" />
    125       <Backlight mainstate=activity active=false scale=0.4 name=bltest position="-20, -25, -40" colour="0.6, 0.75, 0.8, 0.7" width=40 length=800 lifetime=1 elements=30 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Examples/Flare" />
     117      <Backlight mainstate=activity active=false scale=0.4 name=bltest position=" 20, 0, 70" colour="0.6, 0.75, 0.8, 0.7" width=40 length=800 lifetime=1 elements=30 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Examples/Flare" />
     118      <Backlight mainstate=activity active=false scale=0.4 name=bltest position="-20, 0, 70" colour="0.6, 0.75, 0.8, 0.7" width=40 length=800 lifetime=1 elements=30 trailmaterial="Trail/backlighttrail" turnontime=1 turnofftime=1 material="Examples/Flare" />
    126119    </EffectContainer>
    127120<!--    <EffectContainer condition="brake">
    128       <FadingBillboard mainstate=activity active=false scale=0.3 position=" 20, -25, -40" colour="0.5, 0.0, 0.0, 0.3" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
    129       <FadingBillboard mainstate=activity active=false scale=0.3 position="-20, -25, -40" colour="0.5, 0.0, 0.0, 0.3" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
    130       <FadingBillboard mainstate=activity active=false scale=0.15 position="20, -25, -40" colour="1.0, 0.0, 0.0, 1.0" material="Flares/backlightflare" turnontime=0.5 turnofftime=0.5 />
    131       <FadingBillboard mainstate=activity active=false scale=0.15 position="-20, -25, -40" colour="1.0, 0.0, 0.0, 1.0" material="Flares/backlightflare" turnontime=0.5 turnofftime=0.5 />
     121      <FadingBillboard mainstate=activity active=false scale=0.3 position=" 20,  0, 70" colour="0.5, 0.0, 0.0, 0.3" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
     122      <FadingBillboard mainstate=activity active=false scale=0.3 position="-20,  0, 70" colour="0.5, 0.0, 0.0, 0.3" material="Examples/Flare" turnontime=0.5 turnofftime=0.5 />
     123      <FadingBillboard mainstate=activity active=false scale=0.15 position="20,  0, 70" colour="1.0, 0.0, 0.0, 1.0" material="Flares/backlightflare" turnontime=0.5 turnofftime=0.5 />
     124      <FadingBillboard mainstate=activity active=false scale=0.15 position="-20, 0, 70" colour="1.0, 0.0, 0.0, 1.0" material="Flares/backlightflare" turnontime=0.5 turnofftime=0.5 />
    132125    </EffectContainer>
    133126-->
  • code/branches/presentation2011/src/libraries/core/GUIManager.cc

    r8862 r8980  
    223223
    224224    GUIManager* GUIManager::singletonPtr_s = 0;
    225     /*static*/ const std::string GUIManager::defaultScheme_ = "TaharezGreen";
     225    /*static*/ const std::string GUIManager::defaultScheme_ = "Orxonox"; //TaharezGreen
    226226
    227227    SetConsoleCommand("showGUI", &GUIManager::showGUI).defaultValue(1, false).defaultValue(2, false);
  • code/branches/presentation2011/src/modules/pong/Pong.cc

    r8858 r8980  
    3737#include "core/EventIncludes.h"
    3838#include "core/command/Executor.h"
     39#include "core/ConfigValueIncludes.h"
    3940
    4041#include "gamestates/GSLevel.h"
     42#include "chat/ChatManager.h"
    4143
    4244#include "PongCenterpoint.h"
     
    4547#include "PongBot.h"
    4648#include "PongAI.h"
    47 
    4849namespace orxonox
    4950{
     
    7576        // Set the type of Bots for this particular Gametype.
    7677        this->botclass_ = Class(PongBot);
     78        this->scoreLimit_ = 10;
     79        this->setConfigValues();
    7780    }
    7881
     
    280283        }
    281284
     285        // If a palyer gets 21 points, he won the game -> end of game
     286       
     287        PlayerInfo* player1 = this->getLeftPlayer();
     288        PlayerInfo* player2 = this->getRightPlayer();
     289        if(player1==NULL||player2==NULL) return; //safety
     290        if(this->getScore(player1) >= scoreLimit_)
     291        {
     292            std::string name1=player1->getName();
     293            std::string message(name1 + " has won!");
     294            ChatManager::message(message);
     295            this->end();
     296        }
     297        else if(this->getScore(player2) >= scoreLimit_)
     298        {
     299             std::string name2=player2->getName();
     300             std::string message2(name2 + " has won!");
     301             ChatManager::message(message2);
     302             this->end();
     303        }
    282304        // Restart the timer to start the ball.
    283305        this->starttimer_.startTimer();
     306
    284307    }
    285308
     
    321344            return 0;
    322345    }
     346
     347    /**
     348     @brief
     349         Make scoreLimit_ configurable e.g. in the menu.
     350     */
     351    void Pong::setConfigValues()
     352    {
     353        SetConfigValue(scoreLimit_, 10).description("The player first reaching those points wins.");
     354    }
    323355}
  • code/branches/presentation2011/src/modules/pong/Pong.h

    r8351 r8980  
    8181            void setCenterpoint(PongCenterpoint* center)
    8282                { this->center_ = center; }
    83 
    84             PlayerInfo* getLeftPlayer() const; //!< Get the left player.
     83            void setConfigValues(); //!< Makes scoreLimit configurable.
     84           
     85            PlayerInfo* getLeftPlayer() const; //!< Get the left player.
    8586            PlayerInfo* getRightPlayer() const; //!< Get the right player.
    8687
     
    9495            WeakPtr<PongBall> ball_; //!< The Pong ball.
    9596            WeakPtr<PongBat> bat_[2]; //!< The two bats.
    96             Timer starttimer_; //!< A timer to delay the start of the game.
     97            Timer starttimer_; //!< A timer to delay the start of the game.
     98            int scoreLimit_; //!< If a player scored that much points, the game is ended.
    9799    };
    98100}
  • code/branches/presentation2011/src/modules/pong/PongAI.h

    r8108 r8980  
    8080            void delayedMove(); //!< Is called, when a delayed move takes effect.
    8181
    82             PongBall* ball_; //!< A pointer to the ball.
     82            WeakPtr<PongBall> ball_; //!< A weak pointer to the ball.
    8383            Vector2 ballDirection_; //!< Vector to store the (x,z) direction in which the ball is flying.
    8484            float ballEndPosition_; //!< The calculated end position of the ball.
  • code/branches/presentation2011/src/modules/pong/PongScore.cc

    r8108 r8980  
    6060        this->bShowLeftPlayer_ = false;
    6161        this->bShowRightPlayer_ = false;
     62        this->player1_ = NULL;
     63        this->player2_ = NULL;
    6264    }
    6365
     
    98100        if (this->owner_ != NULL)
    99101        {
    100             // Get the two players.
    101             PlayerInfo* player1 = this->owner_->getLeftPlayer();
    102             PlayerInfo* player2 = this->owner_->getRightPlayer();
    103 
    104             std::string name1;
    105             std::string name2;
    106 
    107             std::string score1("0");
    108             std::string score2("0");
    109 
    110             // Save the name and score of each player as a string.
    111             if (player1 != NULL)
     102            if(!this->owner_->hasEnded())
    112103            {
    113                 name1 = player1->getName();
    114                 score1 = multi_cast<std::string>(this->owner_->getScore(player1));
    115             }
    116             if (player2 != NULL)
    117             {
    118                 name2 = player2->getName();
    119                 score2 = multi_cast<std::string>(this->owner_->getScore(player2));
     104                //get the two players
     105                player1_ = this->owner_->getLeftPlayer();
     106                player2_ = this->owner_->getRightPlayer();
    120107            }
    121108
    122             // Assemble the strings, depending on what should all be displayed.
    123             std::string output1;
    124             if (this->bShowLeftPlayer_)
     109            if(this->owner_->hasStarted())
    125110            {
    126                 if (this->bShowName_ && this->bShowScore_ && player1 != NULL)
    127                     output1 = name1 + " - " + score1;
    128                 else if (this->bShowScore_)
    129                     output1 = score1;
    130                 else if (this->bShowName_)
    131                     output1 = name1;
    132             }
     111                // Get the two players.
    133112
    134             std::string output2;
    135             if (this->bShowRightPlayer_)
    136             {
    137                 if (this->bShowName_ && this->bShowScore_ && player2 != NULL)
     113                std::string name1;
     114                std::string name2;
     115
     116                std::string score1("0");
     117                std::string score2("0");
     118
     119                // Save the name and score of each player as a string.
     120                if (player1_ != NULL)
     121                {
     122                    name1 = player1_->getName();
     123                    score1 = multi_cast<std::string>(this->owner_->getScore(player1_));
     124                }
     125                if (player2_ != NULL)
     126                {
     127                    name2 = player2_->getName();
     128                    score2 = multi_cast<std::string>(this->owner_->getScore(player2_));
     129                }
     130
     131                // Assemble the strings, depending on what should all be displayed.
     132                std::string output1;
     133                if (this->bShowLeftPlayer_)
     134                {
     135                    if (this->bShowName_ && this->bShowScore_ && player1_ != NULL)
     136                         output1 = name1 + " - " + score1;
     137                    else if (this->bShowScore_)
     138                         output1 = score1;
     139                    else if (this->bShowName_)
     140                         output1 = name1;
     141                }
     142
     143                std::string output2;
     144                if (this->bShowRightPlayer_)
     145                {
     146                if (this->bShowName_ && this->bShowScore_ && player2_ != NULL)
    138147                    output2 = score2 + " - " + name2;
    139148                else if (this->bShowScore_)
     
    143152            }
    144153
    145             std::string output("PONG");
    146             if (this->bShowName_ || this->bShowScore_)
    147             {
    148                 if (this->bShowLeftPlayer_ && this->bShowRightPlayer_)
    149                     output = output1 + ':' + output2;
    150                 else if (this->bShowLeftPlayer_ || this->bShowRightPlayer_)
    151                     output = output1 + output2;
     154                std::string output("PONG");
     155                if (this->bShowName_ || this->bShowScore_)
     156                {
     157                    if (this->bShowLeftPlayer_ && this->bShowRightPlayer_)
     158                        output = output1 + ':' + output2;
     159                    else if (this->bShowLeftPlayer_ || this->bShowRightPlayer_)
     160                        output = output1 + output2;
     161                }
     162                this->setCaption(output);
    152163            }
    153 
    154             this->setCaption(output);
    155164        }
    156165    }
  • code/branches/presentation2011/src/modules/pong/PongScore.h

    r8108 r8980  
    122122            bool bShowLeftPlayer_; //!< Whether the left player is shown.
    123123            bool bShowRightPlayer_; //!< Whether the right player is shown.
     124            PlayerInfo* player1_; //!< Store information about left player permanently.
     125            PlayerInfo* player2_; //!< Same for the right player. To end the game properly.
    124126    };
    125127}
  • code/branches/presentation2011/src/modules/weapons/projectiles/Rocket.cc

    r8891 r8980  
    6666        this->localAngularVelocity_ = 0;
    6767        this->lifetime_ = 100.0f;
    68         this->bIsRocket_= true;
    6968
    7069        if (GameMode::isMaster())
     
    135134        if(this->isInitialized())
    136135        {
    137             this->bIsRocket_= false;
    138136            if (GameMode::isMaster())
    139137            {
  • code/branches/presentation2011/src/modules/weapons/weaponmodes/LightningGun.cc

    r8855 r8980  
    5252        this->reloadTime_ = 1.0f;
    5353        this->damage_ = 0.0f;
    54         this->speed_ = 250.0f;
     54        this->speed_ = 700.0f;
    5555
    5656        this->setMunitionName("LaserMunition");
  • code/branches/presentation2011/src/orxonox/controllers/AIController.cc

    r8891 r8980  
    7474            }
    7575
    76             // search enemy
    77             random = rnd(maxrand);
    78             if (random < (15 + botlevel_* 20) && (!this->target_))
    79                 this->searchNewTarget();
    80 
    81             // forget enemy
    82             random = rnd(maxrand);
    83             if (random < ((1-botlevel_)*6) && (this->target_))
    84                 this->forgetTarget();
    85 
    86             // next enemy
    87             random = rnd(maxrand);
    88             if (random < (botlevel_*20) && (this->target_))
    89                 this->searchNewTarget();
    90 
    91             // fly somewhere
    92             random = rnd(maxrand);
    93             if (random < 50 && (!this->bHasTargetPosition_ && !this->target_))
    94                 this->searchRandomTargetPosition();
    95 
    96             // stop flying
    97             random = rnd(maxrand);
    98             if (random < 10 && (this->bHasTargetPosition_ && !this->target_))
    99                 this->bHasTargetPosition_ = false;
    100 
    101             // fly somewhere else
    102             random = rnd(maxrand);
    103             if (random < 30 && (this->bHasTargetPosition_ && !this->target_))
    104                 this->searchRandomTargetPosition();
    105 
    106             // shoot
    107             random = rnd(maxrand);
    108             if (!(this->passive_) && random < (75 + botlevel_*25) && (this->target_ && !this->bShooting_))
    109                 this->bShooting_ = true;
    110 
    111             // stop shooting
    112             random = rnd(maxrand);
    113             if (random < ((1 - botlevel_)*25) && (this->bShooting_))
    114                 this->bShooting_ = false;
    115 
    116             // boost
    117             random = rnd(maxrand);
    118             if (random < botlevel_*100 )
    119                 this->boostControl();
    120 
    121             // update Checkpoints
    122             /*random = rnd(maxrand);
    123             if (this->defaultWaypoint_ && random > (maxrand-10))
    124                 this->manageWaypoints();
    125             else //if(random > maxrand-10) //CHECK USABILITY!!*/
    126             if (this->waypoints_.size() == 0 )
    127                 this->manageWaypoints();
    128 
     76            this->defaultBehaviour(maxrand);
    12977        }
    13078
     
    13684        if (this->state_ == MASTER)
    13785        {
    138 
    139 
    14086            this->commandSlaves();
    14187
     
    170116                    this->searchNewMaster();
    171117
    172                 // search enemy
    173                 random = rnd(maxrand);
    174                 if (random < (botlevel_)*25 && (!this->target_))
    175                     this->searchNewTarget();
    176 
    177                 // forget enemy
    178                 random = rnd(maxrand);
    179                 if (random < (1-botlevel_)*6 && (this->target_))
    180                     this->forgetTarget();
    181 
    182                 // next enemy
    183                 random = rnd(maxrand);
    184                 if (random < 10 && (this->target_))
    185                     this->searchNewTarget();
    186 
    187                 // fly somewhere
    188                 random = rnd(maxrand);
    189                 if (random < 50 && (!this->bHasTargetPosition_ && !this->target_))
    190                     this->searchRandomTargetPosition();
    191 
    192 
    193                 // fly somewhere else
    194                 random = rnd(maxrand);
    195                 if (random < 30 && (this->bHasTargetPosition_ && !this->target_))
    196                     this->searchRandomTargetPosition();
    197 
    198                 // shoot
    199                 random = rnd(maxrand);
    200                 if (!(this->passive_) && random < 25*(botlevel_)+1 && (this->target_ && !this->bShooting_))
    201                 {
    202                     this->bShooting_ = true;
    203                     this->forceFreeSlaves();
    204                 }
    205 
    206                 // stop shooting
    207                 random = rnd(maxrand);
    208                 if (random < ( (1- botlevel_)*25 ) && (this->bShooting_))
    209                     this->bShooting_ = false;
    210 
    211                 // boost
    212                 random = rnd(maxrand);
    213                 if (random < botlevel_*100 )
    214                     this->boostControl();
    215 
    216                 // update Checkpoints
    217                 /*random = rnd(maxrand);
    218                 if (this->defaultWaypoint_ && random > (maxrand-10))
    219                     this->manageWaypoints();
    220                 else //if(random > maxrand-10) //CHECK USABILITY!!*/
    221                 if (this->waypoints_.size() == 0 )
    222                     this->manageWaypoints();
     118                this->defaultBehaviour(maxrand);
    223119            }
    224120        }
    225 
    226121    }
    227122
     
    321216        {   //Vector-implementation: mode_.back() == ROCKET;
    322217            if(controllable)
    323             {
    324                 if(controllable->getRocket())//Check wether the bot is controlling the rocket and if the timeout is over.
     218            {//Check wether the bot is controlling the rocket and if the timeout is over.
     219                if(controllable->getIdentifier() == ClassByString("Rocket"))
     220
    325221                {
    326222                    this->follow();
     
    342238    }
    343239
     240    void AIController::defaultBehaviour(float maxrand)
     241    {       float random;
     242            // search enemy
     243            random = rnd(maxrand);
     244            if (random < (botlevel_* 100) && (!this->target_))
     245                this->searchNewTarget();
     246
     247            // forget enemy
     248            random = rnd(maxrand);
     249            if (random < ((1-botlevel_)*20) && (this->target_))
     250                this->forgetTarget();
     251
     252            // next enemy
     253            random = rnd(maxrand);
     254            if (random < (botlevel_*30) && (this->target_))
     255                this->searchNewTarget();
     256
     257            // fly somewhere
     258            random = rnd(maxrand);
     259            if (random < 50 && (!this->bHasTargetPosition_ && !this->target_))
     260                this->searchRandomTargetPosition();
     261
     262            // stop flying
     263            random = rnd(maxrand);
     264            if (random < 10 && (this->bHasTargetPosition_ && !this->target_))
     265                this->bHasTargetPosition_ = false;
     266
     267            // fly somewhere else
     268            random = rnd(maxrand);
     269            if (random < 30 && (this->bHasTargetPosition_ && !this->target_))
     270                this->searchRandomTargetPosition();
     271
     272            if (this->state_ == MASTER) // master: shoot
     273            {
     274                random = rnd(maxrand);
     275                if (!(this->passive_) && random < (100*botlevel_) && (this->target_ && !this->bShooting_))
     276                {
     277                    this->bShooting_ = true;
     278                    this->forceFreeSlaves();
     279                }
     280            }
     281            else
     282            {
     283                // shoot
     284                random = rnd(maxrand);
     285                if (!(this->passive_) && random < (botlevel_*100) && (this->target_ && !this->bShooting_))
     286                    this->bShooting_ = true;
     287            }
     288
     289            // stop shooting
     290            random = rnd(maxrand);
     291            if (random < ((1 - botlevel_)*50) && (this->bShooting_))
     292                this->bShooting_ = false;
     293
     294            // boost
     295            random = rnd(maxrand);
     296            if (random < botlevel_*50 )
     297                this->boostControl();
     298
     299            // update Checkpoints
     300            /*random = rnd(maxrand);
     301            if (this->defaultWaypoint_ && random > (maxrand-10))
     302                this->manageWaypoints();
     303            else //if(random > maxrand-10) //CHECK USABILITY!!*/
     304            if (this->waypoints_.size() == 0 )
     305                this->manageWaypoints();
     306    }
     307
    344308}
  • code/branches/presentation2011/src/orxonox/controllers/AIController.h

    r8729 r8980  
    4444            virtual ~AIController();
    4545
    46             virtual void tick(float dt);
     46            virtual void tick(float dt); //<! Carrying out the targets set in action().
    4747
    4848        protected:
    49             virtual void action();
     49            virtual void action(); //<! action() is called in regular intervals managing the bot's behaviour ~ setting targets.
     50            void defaultBehaviour(float maxrand); //<! Helper function for code reusage. Some concrete commands for a bot.
    5051
    5152        private:
    5253            static const float ACTION_INTERVAL;
    5354
    54             Timer actionTimer_;
     55            Timer actionTimer_; //<! Regularly calls action().
    5556    };
    5657}
  • code/branches/presentation2011/src/orxonox/controllers/ArtificialController.cc

    r8892 r8980  
    4242#include "gametypes/TeamDeathmatch.h"
    4343#include "gametypes/Dynamicmatch.h"
     44#include "gametypes/Mission.h"
    4445#include "controllers/WaypointPatrolController.h"
    4546#include "controllers/NewHumanController.h"
     
    9293        this->target_.setCallback(createFunctor(&ArtificialController::targetDied, this));
    9394        this->bSetupWorked = false;
    94         this->botlevel_ = 0.2f;
     95        this->botlevel_ = 0.5f;
    9596        this->mode_ = DEFAULT;////Vector-implementation: mode_.push_back(DEFAULT);
    9697        this->timeout_ = 0;
     
    998999        }
    9991000
     1001        Mission* miss = orxonox_cast<Mission*>(gametype);
     1002        if (miss)
     1003        {
     1004            if (entity1->getPlayer())
     1005                team1 = miss->getTeam(entity1->getPlayer());
     1006
     1007            if (entity2->getPlayer())
     1008                team2 = miss->getTeam(entity2->getPlayer());
     1009        }
     1010
    10001011        TeamBaseMatchBase* base = 0;
    10011012        base = orxonox_cast<TeamBaseMatchBase*>(entity1);
     
    11101121        {
    11111122            Pawn* pawn = orxonox_cast<Pawn*>(this->getControllableEntity());
    1112             if(pawn)
     1123            if(pawn && pawn->isA(Class(SpaceShip))) //fix for First Person Mode: check for SpaceShip
    11131124            {
    11141125                this->weaponModes_.clear(); // reset previous weapon information
  • code/branches/presentation2011/src/orxonox/controllers/ArtificialController.h

    r8891 r8980  
    5151            void abandonTarget(Pawn* target);
    5252
    53             inline void setTeam(int team)
     53            inline void setTeam(int team) //TODO: write through to controllable entity.
    5454                { this->team_ = team; }
    5555            inline int getTeam() const
  • code/branches/presentation2011/src/orxonox/controllers/HumanController.cc

    r8858 r8980  
    195195            this->boosting_ = true;
    196196            this->boostingTimeout_.startTimer();
    197            
    198             this->controllableEntity_->boost(this->boosting_);
     197            if(this->controllableEntity_)
     198                this->controllableEntity_->boost(this->boosting_);
    199199//            orxout() << "Start boosting" << endl;
    200200        }
     
    209209        this->boosting_ = false;
    210210        this->boostingTimeout_.stopTimer();
    211 
    212         this->controllableEntity_->boost(this->boosting_);
     211        if(this->controllableEntity_)
     212            this->controllableEntity_->boost(this->boosting_);
    213213//        orxout() << "Stop boosting" << endl;
    214214    }
  • code/branches/presentation2011/src/orxonox/controllers/WaypointPatrolController.cc

    r7184 r8980  
    4242        RegisterObject(WaypointPatrolController);
    4343
    44         //this->team_ = 0;
    4544        this->alertnessradius_ = 500;
    4645
     
    5352
    5453        XMLPortParam(WaypointPatrolController, "alertnessradius", setAlertnessRadius, getAlertnessRadius, xmlelement, mode).defaultValues(500.0f);
    55 //        XMLPortParam(WaypointPatrolController, "team", setTeam, getTeam, xmlelement, mode).defaultValues(0);
    5654    }
    5755
  • code/branches/presentation2011/src/orxonox/controllers/WaypointPatrolController.h

    r7163 r8980  
    4646            virtual void tick(float dt);
    4747
    48            /* inline void setTeam(int team)
    49                 { this->team_ = team; }
    50             inline int getTeam() const
    51                 { return this->team_; } */
    52 
    5348            inline void setAlertnessRadius(float radius)
    5449                { this->alertnessradius_ = radius; }
     
    5954            void searchEnemy();
    6055
    61             //int team_;
    6256            float alertnessradius_;
    6357            Timer patrolTimer_;
  • code/branches/presentation2011/src/orxonox/gametypes/CMakeLists.txt

    r8178 r8980  
    99  LastManStanding.cc
    1010  LastTeamStanding.cc
     11  TeamGametype.cc
     12  Mission.cc
    1113)
  • code/branches/presentation2011/src/orxonox/gametypes/Gametype.cc

    r8858 r8980  
    8585        this->dedicatedKillBots_ = createConsoleCommand( "dedicatedKillBots", createExecutor( createFunctor(&Gametype::killBots, this) ) );
    8686        /* HACK HACK HACK */
     87        //this->numberOfPlayers_ = 0;
    8788    }
    8889
     
    132133                    this->gtinfo_->playerReadyToSpawn(it->first);
    133134            }
    134                    
     135
    135136            this->checkStart();
    136137        }
     
    439440            if(player->isHumanPlayer())
    440441                this->gtinfo_->playerSpawned(player);
    441            
     442
    442443            this->playerPostSpawn(player);
    443444        }
  • code/branches/presentation2011/src/orxonox/gametypes/Gametype.h

    r8706 r8980  
    123123                { return this->gtinfo_->getHUDTemplate(); }
    124124
    125             void addBots(unsigned int amount);
     125            virtual void addBots(unsigned int amount);
    126126            void killBots(unsigned int amount = 0);
    127 
    128             inline unsigned int getNumberOfPlayers() const
    129                 { return this->players_.size(); }
    130127
    131128            virtual void addTime(float t);
     
    151148
    152149            //inline bool getForceSpawn()
    153             //  { return this->bForceSpawn_; }       
     150            //  { return this->bForceSpawn_; }
    154151
    155152            virtual void resetTimer();
    156153            virtual void resetTimer(float t);
     154            inline unsigned int getNumberOfPlayers()
     155              { return this->gtinfo_->getNumberOfPlayers(); }
    157156
    158157        protected:
     
    192191            ConsoleCommand* dedicatedKillBots_;
    193192            /* HACK HACK HACK */
     193
    194194    };
    195195}
  • code/branches/presentation2011/src/orxonox/gametypes/TeamDeathmatch.h

    r5781 r8980  
    5656
    5757            int getTeam(PlayerInfo* player);
    58 
    5958            inline const ColourValue& getTeamColour(int teamnr) const
    6059                { return this->teamcolours_[teamnr]; }
  • code/branches/presentation2011/src/orxonox/infos/GametypeInfo.h

    r8706 r8980  
    119119            inline const std::string& getHUDTemplate() const
    120120                { return this->hudtemplate_; }
     121           
     122            inline unsigned int getNumberOfPlayers() const
     123                {  return this->spawnedPlayers_.size(); }
    121124
    122125            void sendAnnounceMessage(const std::string& message);
  • code/branches/presentation2011/src/orxonox/worldentities/ControllableEntity.cc

    r8891 r8980  
    7474        this->bMouseLook_ = false;
    7575        this->mouseLookSpeed_ = 200;
    76         this->bIsRocket_ = false;
    7776
    7877        this->server_position_         = Vector3::ZERO;
     
    8887        this->setPriority( Priority::VeryHigh );
    8988        this->registerVariables();
     89        this->team_ = -1;
    9090    }
    9191
     
    120120        SUPER(ControllableEntity, XMLPort, xmlelement, mode);
    121121
     122        XMLPortParam(ControllableEntity, "team", setTeam, getTeam, xmlelement, mode).defaultValues(-1);
    122123        XMLPortParam(ControllableEntity, "hudtemplate", setHudTemplate, getHudTemplate, xmlelement, mode);
    123124        XMLPortParam(ControllableEntity, "camerapositiontemplate", setCameraPositionTemplate, getCameraPositionTemplate, xmlelement, mode);
  • code/branches/presentation2011/src/orxonox/worldentities/ControllableEntity.h

    r8891 r8980  
    163163                { return this->target_.get(); }
    164164            void setTargetInternal( uint32_t targetID );
    165             inline bool getRocket() const
    166                 { return this-> bIsRocket_; }
     165
     166            inline void setTeam(int team)
     167                { this->team_ = team; }
     168            inline float getTeam() const
     169                { return this->team_; }
    167170
    168171        protected:
     
    183186
    184187            Ogre::SceneNode* cameraPositionRootNode_;
    185             bool bIsRocket_; //Workaround to see, if the controllable entity is a Rocket.
    186188
    187189        private:
     
    240242            CameraPosition* reverseCamera_;
    241243            WeakPtr<WorldEntity> target_;
     244
     245            int team_ ; //<! teamnumber
    242246    };
    243247}
  • code/branches/presentation2011/src/orxonox/worldentities/pawns/Pawn.cc

    r8891 r8980  
    129129        XMLPortParam(Pawn, "reloadrate", setReloadRate, getReloadRate, xmlelement, mode).defaultValues(0);
    130130        XMLPortParam(Pawn, "reloadwaittime", setReloadWaitTime, getReloadWaitTime, xmlelement, mode).defaultValues(1.0f);
     131
     132
    131133    }
    132134
     
    455457        SUPER(Pawn, changedActivity);
    456458
    457         this->setRadarVisibility(this->isActive());
     459        this->setRadarVisibility(this->isVisible());
    458460    }
    459461
  • code/branches/presentation2011/src/orxonox/worldentities/pawns/Pawn.h

    r8891 r8980  
    5353            inline bool isAlive() const
    5454                { return this->bAlive_; }
     55
    5556
    5657            virtual void setHealth(float health);
     
    194195                { return NULL; }
    195196
     197
    196198            float health_;
    197199            float maxHealth_;
Note: See TracChangeset for help on using the changeset viewer.