Code: Select all
<?xml version="1.0" ?>
<!DOCTYPE TranscendenceAdventure
[
<!ENTITY unidAdventure "0xA1000100">
<!ENTITY ssTestSystem1 "0xA1000101">
<!ENTITY stShipDealer "0xA1000102">
]>
<TranscendenceAdventure
UNID= "&unidAdventure;"
version= "1.1"
name= "Changing Ships (Sample)"
>
<AdventureDesc
UNID= "&unidAdventure;"
name= "Changing Ships (Sample)"
backgroundID= ""
>
</AdventureDesc>
<!-- Ship Dealer -->
<StationType UNID="&stShipDealer;"
name= "Corporate ship dealer"
sovereign= "&svCorporate;"
dockScreen= "Main"
abandonedScreen= "&dsAbandonedStation;"
dockingPorts= "8"
canAttack= "true"
multiHull= "true"
armorID= "&itAdvancedPlasteelPlate;"
maxHitPoints= "350"
hitPoints= "350"
repairRate= "5"
explosionType= "&vtThermoExplosion1;"
ejectaType= "&vtWreckEjecta;"
attributes= "corporate,independent,friendly,envAir,envEarth,envFire,envWater,populated"
levelFrequency= "--rcu ur--- ----- ----- -----"
locationCriteria= "+planetary,-asteroids"
enemyExclusionRadius="50"
>
<Image imageID="&rsStations4;" imageX="128" imageY="192" imageWidth="128" imageHeight="256"/>
<Ships>
<Lookup count="2" table="&tbCorpDefenders;"/>
<Lookup count="1" table="&tbCommPrivateCrafts;"/>
</Ships>
<Events>
<OnCreate>
(block (theShip)
; Create a player ship and dock it to the station
(setq theShip (sysCreateShip &scEI100XPlayer; (objGetPos gSource) &svCorporate;))
(shpOrder theShip 'dock gSource)
)
</OnCreate>
<OnDestroy>
(intCorporateOnDestroy)
</OnDestroy>
</Events>
<DockScreens>
<Main
name= "=(objGetName gSource)"
>
<OnInit>
(intCorporateOnInit "Main")
</OnInit>
<Panes>
<Default
desc= "You are docked at ship dealer.">
<Actions>
<Action name="Switch" default="1" key="S">
(block (theShip)
; Find a player ship
(setq theShip (random (sysFindObject gSource "sZ O:docked; +playerClass;")))
; Do it
(if theShip
(block Nil
(plyChangeShip gPlayer theShip)
(scrExitDock gScreen)
)
)
)
</Action>
<Action name="Undock" cancel="1" key="U">
<Exit/>
</Action>
</Actions>
</Default>
</Panes>
</Main>
</DockScreens>
<DockingPorts>
<Port x="0" y="90" />
<Port x="0" y="-90" />
<Port x="60" y="60" />
<Port x="60" y="-60" />
<Port x="90" y="0" />
<Port x="-90" y="0" />
<Port x="-60" y="60" />
<Port x="-60" y="-60" />
</DockingPorts>
</StationType>
<!-- Topology -->
<SystemTopology>
<!-- NOTE: ID must be SE because that's where player ships start -->
<Node ID="SE" rootNode="true">
<System name="Test" level="1">
<System UNID="&ssTestSystem1;"/>
</System>
<StarGates>
<StarGate Name="Outbound" DestID="EndGame"/>
</StarGates>
</Node>
<Node ID="EndGame"
endGame="true"
endGameReason="escaped"
epitaph="escaped the Sample Adventure"
>
</Node>
</SystemTopology>
<!-- Test System -->
<SystemType UNID="&ssTestSystem1;">
<SystemGroup>
<Station type="&stG-TypeStar;" name="TestStar"/>
<Orbitals distance="120">
<Group>
<Marker objName="Start"/>
<Siblings arcInc="16">
<Lookup table="StargateOutbound"/>
</Siblings>
<Siblings arcInc="-16">
<Station type="&stShipDealer;"/>
</Siblings>
</Group>
</Orbitals>
</SystemGroup>
</SystemType>
</TranscendenceAdventure>