Script problem- objGateTo
Posted: Fri Nov 09, 2007 2:34 am
What am I missing with this?
This is on a navbeacon that gets created from a player item-
And then something like this in the jump drive-
But it said Identifier expected What does that mean?
This is on a navbeacon that gets created from a player item-
Code: Select all
<OnCreate>
(block (beaconSys)
(objSetGlobalData gPlayership "beaconSys" (sysGetName gSource))
)
(block (beaconNode)
(objSetGlobalData gPlayership "beaconNode" (sysGetNode gSource))
)
(block (beaconGate)
(objSetGlobalData gPlayership "beaconGate" (sysGetNearestStargate gSource))
)
</OnCreate>
Code: Select all
<Invoke key="J" installedOnly="true">
(switch
; If we are on top of a stargate, then jump to Elysium
(leq (objGetDistance gSource (objGetNearestStargate gSource)) 3)
(objGateTo gSource "Elysium" "Start" &efStargateOut;)
; Otherwise, we jump
(block (newPos newNode)
(setq newPos (objGetGlobalData gPlayership "beaconGate"))
(setq newNode (objGetGlobalData gPlayership "beaconNode"))
(objGateTo gSource newNode newPos &efStargateOut;)
)
)
</Invoke>