Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changes between Version 57 and Version 58 of content/LevelHowTo


Ignore:
Timestamp:
Sep 7, 2015, 2:23:50 PM (9 years ago)
Author:
fvultier
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • content/LevelHowTo

    v57 v58  
    202202Have a look at "asteroids.oxw" and "theTimeMachine.oxw", to see how to make ForceFields visible in the level.
    203203
    204 == Space boundaries ==
     204== SpaceBoundaries ==
    205205If you want to restrict the position of pawns to certain areas, space boundaries may be useful. They are commonly used to avoid that a Pawn leaves the level.
    206206{{{
     
    209209}}}
    210210
    211 Have a look at "myTestLevel.oxw" and "SpaceBoundaries.h", to see how space boundaries hork in detail.
     211Have a look at "myTestLevel.oxw" and "SpaceBoundaries.h", to see how space boundaries work in detail.
     212
     213== Portals ==
     214Portals allow to teleport through space.
     215First you need to place at least two PortalEndPoint. Give each end point a unique id using e.g. id=1. Then you need the PortalLink class to define which PortalEndPoint is connected to which other PortalEndPoint.
     216The attribute target of a PortalEndPoint may be used to restrict the classes that can use the PortalEndPoint. By default all Pawn instances can use it. By typeing target="MobileEntity" all MobileEntity instances can use the PortalEndPoint.
     217The templates in the example below only hve the purpose to make the end points visible. Use the design attribute of a PortalEndPoint to automatically apply the specified template to it.
     218{{{
     219#!xml
     220<Template name=PortalDefault>
     221    <PortalEndPoint>
     222        <attached>
     223            <Billboard material="Portals/Default" />
     224        </attached>
     225    </PortalEndPoint>
     226</Template>
     227
     228<Template name=PortalBig>
     229    <PortalEndPoint>
     230        <attached>
     231            <Billboard material="Portals/Big" />
     232        </attached>
     233    </PortalEndPoint>
     234</Template>
     235
     236<PortalEndPoint position="0,0,0" id="1" distance="40" target="Pawn" design="PortalDefault"/>
     237<PortalEndPoint position="-100,0,0" id="2" distance="40" target="MobileEntity" design="PortalBig"/>
     238<PortalLink fromID="1" toID="2" />
     239<PortalLink fromID="2" toID="1" />
     240}}}
     241
     242Have a look at "Portals.dox", "portals.oxw", "PortalLink.h" and "PortalEndPoint.h", to see how portals work in detail.
    212243
    213244== Lua ==