function list 1.03

This is a moderated forum that collects tutorials, guides, and references for creating Transcendence extensions and scripts.
Post Reply
User avatar
Fleet Admiral
Fleet Admiral
Posts: 2614
Joined: Mon Oct 29, 2007 9:23 pm
Location: Decoding hieroglyphics on Tan-Ru-Dorem

Mon Aug 30, 2010 10:17 pm

New functions in 1.03:

(objGetDisposition obj targetObj) -> disposition of obj towards targetObj
(resCreateImageDesc imageUNID x y width height) -> imageDesc
(randomTable chance1 exp1 chance2 exp2 ... chancen expn) -> exp
(srvFindRepairArmor ...)
(sysPlaySound unid [sourceObj]) -> True/Nil


changed functions in 1.03

(objGetArmorType obj armorSegment) -> CArmorClass * --> (objGetArmorType obj item|armorSegment) -> type
(shpFixBlindness ship) --> (shpFixBlindness ship [noMessage])
(itmGetArmorType item) -> type (not sure, was it returning a type in 1.02 ?)
or function returns the first non-nil expression (or nil)
and function returns the last expression (or nil)


(< ...)
(<= ...)
(> ...)
(>= ...)
(abs x) -> z
(add x1 x2 ... xn) -> z
(and exp1 exp2 ... expn) -> True/Nil
(append a b [...]) -> lists are concatenated
(apply ...)
(armGetHitPoints type) -> Hit points of armor
(armGetName type) -> Name of the armor
(armGetRepairCost type) -> Cost to repair 1 hit point
(armGetRepairTech type) -> Tech level required to repair
(armIsRadiationImmune type) -> True/Nil
(atmAddEntry ...)
(atmAtomTable ...)
(atmDeleteEntry ...)
(atmList ...)
(atmLookup ...)
(block ...)
(cat s1 s2 ... sn) -> string
(cnvDrawImage x y imageDesc [screen] [ID])
(cnvDrawRect x y width height color [screen] [ID])
(cnvDrawText x y text font color alignment [screen] [ID])
(count list) -> number of items
(dbgLog string [string]*)
(dbgOutput string [string]*)
(divide x y) -> z
(enum list itemVar exp)
(enumwhile list condition itemVar exp)
DEPRECATED: Use typHasAttribute instead
(eq ...)
(errblock ...)
(error msg) -> error
(eval ...)
(filter list var boolean-exp) -> filtered list
(find source target [keyIndex]) -> position of target in source (0-based)
(fncHelp ...)
(for var from to exp)
(gamSetCrawlImage imageUNID) -> True/Nil
(gamSetCrawlText text) -> True/Nil
(geq a b) -> True if a >= b
(gr a b) -> True if a > b
(if ...)
(int ...)
(isatom ...)
(iserror ...)
(isfunction ...)
(isint ...)
(isprimitive ...)
(item list index)
(itmCreate itemUNID count) -> item
(itmCreateByName criteria name [count]) -> item
(itmCreateRandom criteria levelDistribution) -> item
(itmEnumTypes criteria item-var exp)
(itmGetActualPrice item) -> actual price of a single item
(itmGetArmorInstalledLocation item) -> segment #
(itmGetArmorType item) -> type
(itmGetAverageAppearing item) -> average number that appear randomly
(itmGetCategory item) -> item category
(itmGetCharges item) -> charges
(itmGetCount item)
(itmGetDamageType item) -> damage type
(itmGetData item attrib) -> data
(itmGetFrequency item) -> frequency
(itmGetGlobalData item attrib) -> data
(itmGetImageDesc item) -> imageDesc
(itmGetInstallCost item) -> cost
(itmGetInstallPos item) -> installPos
(itmGetLevel item) -> level
(itmGetMass item) -> mass of single item in Kg
(itmGetMaxAppearing item) -> max number that appear randomly
(itmGetName item flags)
(itmGetPrice item) -> price of a single item
(itmGetStaticData item attrib) -> data
DEPRECATED: Use itmGetStaticData instead
(itmGetTypes criteria) -> list of itemUNIDs
(itmGetUNID item) -> itemUNID
(itmGetUseScreen item)
(itmHasAttribute item attrib) -> True/Nil
DEPRECATED: Use itmHasAttribute instead.
(itmHasReference item)
(itmIsDamaged item)
(itmIsEnhanced item) -> Nil or mods
(itmIsInstalled item)
(itmIsKnown item)
(itmMatches item criteria)
(itmSetCharges item charges) -> item
(itmSetCount item count) -> item
(itmSetDamaged item [True/Nil]) -> item
(itmSetData item attrib data [count]) -> item
(itmSetEnhanced item mods) -> item
(itmSetGlobalData item attrib data) -> True/Nil
(itmSetKnown {item | itemUNID})
(itmSetReference item)
(lambda ...)
(leq a b) -> True if a <= b
(link ...)
(list i1 i2 ... in) -> list
(lnkAppend list item) -> list
(lnkRemove list index) -> list
(lnkRemoveNil list) -> list
(lnkReplace list index item) -> list
(lookup source target keyIndex) -> found entry
(loop condition exp)
(ls a b) -> True if a < b
(max x1 x2 ... xn) -> z
(min x1 x2 ... xn) -> z
(modulo x y) -> z
(multiply x1 x2 ... xn) -> z
(not exp) -> True/Nil
(objAddBuyOrder obj criteria priceAdj) -> True/Nil
(objAddItem obj item [count])
(objAddItemEnhancement obj item enhancementType [lifetime]) -> enhancementID
(objAddOverlay obj overlayType [lifetime]) -> overlayID\n(objAddOverlay obj overlayType pos rotation [lifetime]) -> overlayID
(objAddRandomItems obj table count)
(objAddSellOrder obj criteria priceAdj) -> True/Nil
(objAddSubordinate obj subordinate) -> True/Nil
(objCanAttack obj) -> True/Nil
(objCanDetectTarget obj target) -> True/Nil
(objCharge obj amount) -> remaining balance
(objClearIdentified obj)
(objClearShowAsDestination obj)
(objCommunicate obj senderObj msg [obj] [data])
(objCredit obj amount) -> new balance
(objDamage obj weaponType objSource [posVector])
(objDepleteShields obj)
(objDestroy obj [objSource]) -> True/Nil
(objEnumItems obj criteria itemVar exp)
(objFireEvent obj event) -> result of event
(objFireItemEvent obj item event) -> result of event
(objFireOverlayEvent obj overlayID event) -> result of event
(objFixParalysis obj)
(objGateTo obj node entrypoint [effectID])
(objGetArmorDamage obj armorSegment) -> damage to armor segment
(objGetArmorLevel obj item|armorSegment) -> 0-100
(objGetArmorName obj armorSegment) -> name of armor (e.g., 'forward', etc.)
(objGetArmorType obj item|armorSegment) -> type
(objGetBalance obj) -> balance
(objGetBuyPrice obj item) -> price
(objGetCargoSpaceLeft obj) -> space left in Kg
(objGetCombatPower obj) -> 0-100
(objGetDamageType obj) -> damage type
(objGetData obj attrib) -> data
(objGetDataField obj field) -> data
(objGetDestiny obj) -> 0-359
(objGetDisposition obj targetObj) -> disposition of obj towards targetObj
(objGetDistance obj destObj) -> distance in light-seconds
(objGetEventHandler obj) -> unid or Nil
(objGetGlobalData obj attrib) -> data
(objGetID obj) -> objID
(objGetImageDesc obj) -> imageDesc
(objGetInstalledItemDesc obj item) -> 'installed as forward armor'
(objGetItems obj criteria) -> list of items
(objGetLevel obj) -> level
(objGetMass obj) -> mass in tons
(objGetMaxPower obj) -> power (in 1/10 MWs)
(objGetName obj [flags]) -> Name of the object
(objGetNamedItems obj name) -> list of items
(objGetNearestStargate obj) -> obj
(objGetObjByID objID) -> obj
(objGetObjRefData obj attrib) -> obj
(objGetOpenDockingPortCount obj) -> count of open docking ports
(objGetOrderGiver obj [destroyReason]) -> obj
(objGetOverlayData obj overlayID attrib) -> data
(objGetOverlayPos obj overlayID) -> vector
(objGetOverlayRotation obj overlayID) -> rotation
(objGetOverlays obj) -> list of overlayIDs
(objGetOverlayType obj overlayID) -> type
(objGetPos obj) -> vector
(objGetSellPrice obj item) -> price
(objGetShieldLevel obj) -> 0-100 (or -1 for no shields)
(objGetSovereign obj) -> sovereignID
(objGetStaticData obj attrib) -> data
DEPRECATED: Use typGetStaticData instead.
(objGetTarget obj) -> obj
(objGetType obj) -> unid
(objGetVel obj) -> velVector
(objGetVisibleDamage obj) -> damage
(objHasAttribute obj attrib) -> True/Nil
(objHasItem obj item [count]) -> number of items (or Nil)
(objIncData obj attrib [increment]) -> new value
(objIncItemCharges obj item [increment] [count]) -> itemStruct
(objIncOverlayData obj overlayID attrib [increment]) -> new value
(objIncVel obj velVector) -> velVector
(objIsAbandoned obj) -> True/Nil
(objIsAngryAt obj targetObj) -> True/Nil
(objIsDeviceSlotAvailable ship) -> True/Nil
(objIsDockedAt obj stationObj) -> True/Nil
(objIsEnemy obj target) -> True/Nil
(objIsIdentified obj) -> True/Nil
(objIsKnown obj)
(objIsParalyzed obj)
(objIsShip obj) -> True/Nil
(objIsUnderAttack obj) -> True/Nil
(objJumpTo obj posVector)
(objLowerShields obj)
(objMakeParalyzed obj ticks)
(objMatches obj source filter) -> True/Nil
(objMoveTo obj posVector)
(objProgramDamage obj hacker progName aiLevel code)
(objRegisterForEvents target obj)
(objRegisterForSystemEvents target range)
(objRemoveItem obj item [count])
(objRemoveItemEnhancement obj item enhancementID)
(objRemoveOverlay obj overlayID)
(objRepairArmor ship armorSegment [hpToRepair]) -> hp repaired
(objResume obj)
(objSendMessage obj sender msg)
(objSetData obj attrib data)
(objSetDeviceActivationDelay obj deviceItem [delay]) -> True/Nil
(objSetEventHandler obj unid) -> True/Nil
(objSetGlobalData obj attrib data)
(objSetIdentified obj)
(objSetItemCharges obj item charges [count]) -> itemStruct
(objSetItemData obj item attrib data [count]) -> itemStruct
(objSetKnown obj)
(objSetName obj name [flags])
(objSetObjRefData obj attrib obj)
(objSetOverlayData obj overlayID attrib data)
(objSetOverlayRotation obj overlayID rotation)
(objSetPos obj vector)
(objSetShowAsDestination obj [show dist/bearing] [autoclear])
(objSetSovereign obj sovereignID) -> True/Nil
(objSetVel obj velVector)
(objSuspend obj)
(objUnregisterForEvents target obj)
(objUnregisterForSystemEvents target obj)
(or exp1 exp2 ... expn) -> True/Nil
(plyChangeShip player newShip) -> True/Nil
(plyCharge player [currency] charge)
(plyClearShowHelpRefuel ...)
(plyComposeString player string [arg1 arg2 ... argn]) -> string
(plyCredit ...)
(plyDestroyed ...)
(plyGetCredits ...)
(plyGetGenome player) -> 'humanMale | 'humanFemale
DEPRECATED: Use resurrection infrastructure instead.
(plyGetItemStat player stat criteria) -> value
(plyGetRedirectMessage ...)
(plyGetStat player stat) -> value
DEPRECATED: Use resurrection infrastructure instead.
DEPRECATED: Use resurrection infrastructure instead.
(plyMessage ...)
(plyRecordBuyItem player item totalPrice [count])
(plyRecordSellItem player item totalPrice [count])
(plyRedirectMessage ...)
(power x y) -> z
(quote exp) -> unevaluated exp
(random from to)\n(random list)
(randomTable chance1 exp1 chance2 exp2 ... chancen expn) -> exp
(resCreateImageDesc imageUNID x y width height) -> imageDesc
(rollDice count sides bonus)
(scrEnableAction ...)
(scrExitDock ...)
(scrGetCounter ...)
(scrGetInputText ...)
(scrGetItem ...)
DEPRECATED: Use scrGetItem instead
(scrGetListEntry ...)
(scrIsFirstOnInit ...)
(scrRemoveItem ...)
(scrSetActionLabel screen action label [key])
(scrSetCounter ...)
(scrSetDesc screen text [text...])
(scrSetDisplayText screen ID text [text...])
(scrSetInputText ...)
(scrSetListFilter ...)
(scrShowAction screen action shown)
(scrShowPane ...)
(scrShowScreen screenGlobal screen [pane])
(seededRandom seed from to)\n(seededRandom seed list)
(set ...)
(setq ...)
DEPRECATED: Use objAddOverlay instead
(shpCancelOrders ship)
(shpCanInstallArmor ship item) -> result
(shpCanInstallDevice ship item) -> result
(shpCanRemoveDevice ship item) -> result
(shpConsumeFuel ship fuel)
(shpDamageArmor obj armorSegment damageType damage)
(shpDamageItem ship item)
(shpDecontaminate ship)
(shpEnhanceItem ship item [mods]) -> True/Nil
(shpEnhanceSRS ship)
(shpFixBlindness ship [noMessage])
(shpGetArmor ship armorSegment) -> item struct
(shpGetArmorCount ship) -> number of armor segments
(shpGetArmorMaxHitPoints obj armorSegment) -> damage to armor segment
DEPRECATED: Use objGetType instead
(shpGetClassName class flags) -> class name
DEPRECATED: Use typGetDataField instead
(shpGetDirection ship) -> angle
(shpGetDockObj ship) -> dockObj
(shpGetFuelLeft ship) -> fuel left
(shpGetFuelNeeded ship item) -> items needed
DEPRECATED: Use typGetGlobalData instead
(shpGetImageDesc class [rotationAngle]) -> imageDesc
DEPRECATED: Use itmGetCharges instead
(shpGetItemDeviceName ship item) -> device name of item (or -1)
(shpGetMaxSpeed ship) -> max speed in of lightspeed
(shpGetOrder obj) -> order
(shpGetOrderDesc obj) -> orderDesc
(shpGetOrderTarget obj) -> obj
(shpGetShieldDamage ship) -> damage to shields
(shpGetShieldItemUNID ship) -> UNID (or Nil)
(shpGetShieldMaxHitPoints ship) -> max hp of shields
(shpInstallArmor ship item armorSegment)
(shpInstallAutopilot ship)
(shpInstallDevice ship item)
(shpInstallTargetingComputer ship)
(shpIsAutopilotInstalled ship)
(shpMakeBlind ship)
(shpIsFuelCompatible ship item) -> True/Nil
(shpIsRadiationImmune ship [item])
(shpIsRadioactive ship)
(shpIsSRSEnhanced ship)
(shpIsTargetingComputerInstalled ship)
(shpMakeBlind ship blindTime)
(shpMakeRadioactive ship)
(shpOrder ship order [target] [count]) -> True/Nil
DEPRECATED: Use (shpOrder ship 'attack target) instead
DEPRECATED: Use (shpOrder ship 'dock target) instead
DEPRECATED: Use (shpOrder ship 'escort obj [formation]) instead
DEPRECATED: Use (shpOrder ship 'follow target) instead
DEPRECATED: Use (shpOrder ship 'gate [gate]) instead
DEPRECATED: Use (shpOrder ship 'goto obj) instead
DEPRECATED: Use (shpOrder ship 'guard target) instead
DEPRECATED: Use (shpOrder ship 'hold [time]) instead
DEPRECATED: Use (shpOrder ship 'loot obj) instead
DEPRECATED: Use (shpOrder ship 'mine baseObj) instead
DEPRECATED: Use (shpOrder ship 'patrol baseObj dist) instead
DEPRECATED: Use (shpOrder ship 'wait [time]) instead
(shpRechargeItem ship item charges)
(shpRechargeShield ship hpToRecharge)
(shpRefuelFromItem ship item) -> True/Nil
(shpRemoveDevice ship item) -> item
(shpRepairItem ship item)
(shpSetCommandCode ship code) -> True/Nil
(shpSetController ship controller) -> True/Nil
DEPRECATED: Use typSetGlobalData instead
(shpSetPlayerWingman ship [isWingman]) -> True/Nil
(shuffle list) -> shuffled list
(sovGetDisposition sovereignID targetSovereignID) -> disposition of sovereign to target
(sovSetDisposition sovereignID targetSovereignID disposition)
(sqrt x) -> z
(srvFindRepairArmor ...)
(staClearFireReconEvent station)
(staClearReconned station)
(staGetDockedShips station) -> list of docked ships
DEPRECATED: Use typGetGlobalData instead
(staGetImageVariant station) -> variant
(staGetMaxStructuralHP station) -> hp
(staGetStructuralHP station) -> hp
(staGetSubordinates station) -> list of subordinates (e.g., guardians)
DEPRECATED: Use objGetType instead
(staIsEncountered type) -> True/Nil
(staIsReconned station) -> True/Nil
(staSetActive station)
(staSetFireReconEvent station)
DEPRECATED: Use typSetGlobalData instead
(staSetImageVariant station variant)
(staSetInactive station)
(staSetShowMapLabel station True/Nil)
(staSetStructuralHP station hp)
(strCapitalize string) -> string
(strFind string target) -> pos of target in string (0-based)
(subset list pos [count]) -> list
(subst string arg1 arg2 ... argn) -> string
(subtract x y) -> z
(switch ...)
(symAddEntry ...)
(symCreate ...)
(symDeleteEntry ...)
(symList ...)
(symLookup ...)
(sysAddEncounterEvent delay target encounterID gate)
(sysAddEncounterEventAtDist delay target encounterID distance)
(sysAddObjRecurringTimerEvent interval obj event)
(sysAddObjTimerEvent delay obj event)
(sysAddStargateTopology [nodeID] gateID destNodeID destGateID) -> True/Nil
(sysCalcFireSolution targetPos targetVel speed) -> angle to shoot (Nil, if no solution)
(sysCalcTravelDistance speed time) -> distance in light-seconds
(sysCalcTravelTime distance speed) -> time in ticks
(sysCancelTimerEvent obj event) -> True/Nil
(sysCreateEffect effectID anchorObj posVector [rotation]) -> True/Nil
(sysCreateEncounter classID) -> True/Nil
(sysCreateMarker name pos sovereignID) -> marker
(sysCreateShip classID pos sovereignID [controller]) -> ship
(sysCreateShipwreck classID pos sovereignID) -> shipwreck
(sysCreateStargate classID posVector gateID destNodeID destGateID) -> stargate
(sysCreateStation classID posVector) -> station
(sysCreateWeaponFire weaponID objSource posVector dir speed objTarget [detonateNow] [bonus]) -> obj
(sysFindObject source filter) -> list of objects
(sysGetData [nodeID] attrib) -> data
(sysGetEnvironment vector) -> environmentUNID
(sysGetLevel [nodeID]) -> level
(sysGetName [nodeID]) -> name
(sysGetNavPathPoint sovereignID objFrom objTo B54C65D9ath) -> vector
(sysGetNode) -> nodeID
(sysGetNodes) -> list of nodeIDs
(sysGetObjectByName source name) -> obj
(sysGetStargateDestinationNode [nodeID] gateID) -> nodeID
(sysGetStargates [nodeID]) -> list of gateIDs
(sysGetSystemType [nodeID]) -> systemUNID
(sysGlobals ...)
(sysHasAttribute [nodeID] attrib) -> True/Nil
(sysPlaySound unid [sourceObj]) -> True/Nil
(sysPoolUsage ...)
(sysSetData [nodeID] attrib data) -> data
(sysStopTime duration except)
(sysTicks ...)
(sysVectorAdd vector vector) -> vector
(sysVectorAngle vector) -> angle of vector
(sysVectorDistance vector [vector]) -> distance in light-seconds
(sysVectorDivide vector scalar) -> vector
(sysVectorMultiply vector scalar) -> vector
(sysVectorPolarOffset center angle radius) -> vector
(sysVectorPolarVelocity angle speed) -> velVector
(sysVectorRandom center radius minSeparation [filter]) -> vector
(sysVectorSpeed velVector) -> of light speed
(sysVectorSubtract vector vector) -> vector
(typFind criteria) -> list of UNIDs
(typFireObjEvent unid obj event) -> result of event
(typGetDataField unid field) -> data
(typGetGlobalData unid attrib) -> data
(typGetStaticData unid attrib) -> data
(typHasAttribute unid attrib) -> True/Nil
(typIncGlobalData unid attrib [increment]) -> new value
(typSetGlobalData unid attrib data) -> True/Nil
(unvGetRealDate) -> (year month day) GMT
(unvGetTick) -> time
(unvUNID string) -> (unid 'itemtype name) or (unid 'shipclass name)
(vecSetElement ...)
(vecVector ...)

Post Reply