Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changes between Version 43 and Version 44 of content/LevelHowTo


Ignore:
Timestamp:
Dec 22, 2013, 11:48:39 AM (10 years ago)
Author:
jo
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • content/LevelHowTo

    v43 v44  
    252252
    253253So far your level design is static. Everything is placed in the level, when it is loaded (except the spawned objects) and doesn't change its behaviour once loaded. Via the trigger/event system you can make the level react on what the player does.
    254 A trigger is like a button. When you activate it, something happens.
     254A trigger is like a button. When you activate it an event is created. This event can change the status of objects.
     255This way objects can be activated/deativated and be made visible/invisible.
     256=== Distance Triggers ===
    255257{{{
    256258#!xml
     
    280282        <Model mesh="HydroHarvester.mesh" mass=10 position="0,0,0" scale=50 />
    281283    </attached>
    282     <collisionShapes>
    283         <BoxCollisionShape  position="-560,0,0" halfExtents="115,100,245" />
    284         < ... >
    285     </collisionShapes>
    286284</SpaceShip>
    287285}}}
     
    295293
    296294<!-- By this Spaceship -->
    297 <SpaceShip position  = "10,-202, -42" ... >
     295<SpaceShip position  = "100,300,900" ... >
    298296    <attached>
    299297        <DistanceTriggerBeacon name="coolSpaceship" />
    300298        <Model mesh="HydroHarvester.mesh" mass=10 position="0,0,0" scale=50 />
    301299    </attached>
    302     <collisionShapes>
    303         <BoxCollisionShape  position="-560,0,0" halfExtents="115,100,245" />
    304         < ... >
    305     </collisionShapes>
    306300</SpaceShip>
    307 
    308 }}}
     301}}}
     302
     303=== Other event sources ===
     304{{{
     305#!xml
     306    <!-- When this Pawn is destroyed -->
     307    <Pawn health=30 position="0,300,0" direction="0,-1,0" collisionType="dynamic" mass="100000" name="kaboom" radarname = "Box 1">
     308        <attached>
     309            <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     310        </attached>
     311        <collisionShapes>
     312           <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
     313        </collisionShapes>
     314    </Pawn>
     315
     316  <!-- an event called "kaboom" is created -->
     317  <SimpleNotification message="Right click on the next target." broadcast="true">
     318        <events>
     319            <trigger>
     320                <EventListener event="kaboom" />
     321            </trigger>
     322        </events>
     323    </SimpleNotification>
     324}}}
     325
     326=== ===
     327
     328=== What events can do ===
     329 * Making objects visible:
     330{{{
     331#!xml
     332
     333    <Pawn health=30 position="0,300,0" direction="0,-1,0" collisionType=dynamic mass=100000 name=box radarname = "Box 1">
     334        <events>
     335          <visibility>
     336            <EventListener event="flying4" />
     337          </visibility>
     338        </events>
     339        <attached>
     340            <Model position="0,0,0" mesh="crate.mesh" scale3D="3,3,3" />
     341        </attached>
     342        <collisionShapes>
     343           <BoxCollisionShape position="0,0,0" halfExtents="15,15,15" />
     344        </collisionShapes>
     345        <controller>
     346            <WaypointController team=1>
     347            </WaypointController>
     348        </controller>
     349    </Pawn>
     350}}}
     351 * (De)activating objects:
     352{{{
     353#!xml
     354
     355}}}
     356 * Executing ConsoleCommands (= executing code):
     357{{{
     358#!xml
     359
     360}}}
     361
    309362
    310363== Quests ==