Functions

Functions Defined

A function can be thought of as a machine into which input is provided, and which returns output. By using functions, the same blocks of code can be used over and over again, simply by referencing them.

LSL and OSSL come with hundreds of built-in functions that allow scripts and objects to interact with their environment. The built-in functions start with “ll” or “os”.

This example calls the llSay function which is used to send chat text to the specified channel.

llSay(0, "Hello world!");

The user can define functions (even with return values) as long as the name does not conflict with a reserved word, a built-in constant, or a built-in function.

Note: As LSL and OSSL have matured, several functions have been deprecated. Be sure to use the correct function since deprecated functions are unreliable and may be removed completely at a future date. Some LSL deprecated functions do not exist in OpenSimulator.

Function Categories:

  • Particle (llParticleSystem)
  • Primitive/Object
  • Script
  • Sensor
  • Simulator (Environment/World)
  • Sound
  • String (Text/Name)
  • Teleport
  • Texture
  • Time
  • Transformation:
  • Rotation/Scaling/Translation
  • Vehicle
  • Video
  • Weather
  • XML-RPC

 

LSL Functions Status

The table will reflect ALL current LL-LSL Functions, including those which are not supported in OpenSimulator.
These unsupported functions (notably Pathfinding etc) are there to show what is implemented and what is not.

FunctionImplemented Comments 
llAbsYes
llAcosYes
llAddToLandBanListYes
llAddToLandPassListYes
llAdjustSoundVolumeYes
llAgentInExperienceNoLL Experience Only. Not in OpenSimulator
llAllowInventoryDropYes
llAngleBetweenYes
llApplyImpulsePartial
llApplyRotationalImpulseNo
llAsinYes
llAtan2Yes
llAttachToAvatarYesWorks in OpenSim 0.9.1.0 Dev
llAttachToAvatarTempYesWorks in OpenSim 0.9.1.0 Dev with an error message in Singularity
llAvatarOnLinkSitTargetYesWorks in OpenSim 0.9.1.0 Dev
llAvatarOnSitTargetYes
llAxes2RotYes
llAxisAngle2RotYes
llBase64ToIntegerYes
llBase64ToStringYes
llBreakAllLinksYes
llBreakLinkYes
llCastRayYes
llCeilYes
llClearCameraParamsYes
llClearLinkMediaYesWorks in OpenSim 0.9.1.0 Dev
llClearPrimMediaYesWorks in OpenSim 0.9.1.0 Dev
llCloseRemoteDataChannelYes
llCloudYes
llCollisionFilterYesWorks in OpenSim 0.9.1.0 Dev
llCollisionSoundNo
llCollisionSpriteNo
llCosYes
llCreateCharacterNoNot in OpenSimulator
llCreateKeyValueNoNot in OpenSimulator
llCreateLinkYes
llCSV2ListYes
llDataSizeKeyValueNoNot in OpenSimulator
llDeleteCharacterNoNot in OpenSimulator
llDeleteKeyValueNoNot in OpenSimulator
llDeleteSubListYes
llDeleteSubStringYes
llDetachFromAvatarNo
llDetectedGrabPartial
llDetectedGroupNo
llDetectedKeyYesworks.
llDetectedLinkNumberYestested at 2011.01.25 on 0.7.1 Dev
llDetectedNameYesworks.
llDetectedOwnerYesworks.
llDetectedPosYesworks.
llDetectedRotYes
llDetectedTouchBinormalUnknown
llDetectedTouchFaceUnknown
llDetectedTouchNormalUnknown
llDetectedTouchPosUnknown
llDetectedTouchSTYes* Tested in OpenSim 0.8.0 Dev
llDetectedTouchUVYesWorks in OpenSim 0.9.1.0 Dev
llDetectedTypeYesworks.
llDetectedVelYes
llDialogYes
llDieYes-2683
llDumpList2StringYes
llEdgeOfWorldYes*
llEjectFromLandYes
llEmailYes
llEscapeURLYes
llEuler2RotYes
llEvadeNoLL Pathfinding Only. Not in OpenSimulator
llExecCharacterCmdNoLL Pathfinding Only. Not in OpenSimulator
llFabsYes-2683
llFleeFromNoNot in OpenSimulator
llFloorYes-2683
llForceMouselookYes
llFrandYes
llGenerateKeyYes
llGetAccelYes
llGetAgentInfoPartial
llGetAgentLanguagePartialWorking as of 0.8.2.0 for local avatar only
llGetAgentListYes
llGetAgentSizeYes
llGetAlphaPartialALLSIDES returns default texture, not sum, specific faces display correctly
llGetAndResetTimeYes-2750
llGetAnimationYes
llGetAnimationListYes
llGetAnimationOverrideYesworks in 0901
llGetAttachedNo
llGetAttachedListUnknown
llGetBoundingBoxPartial
llGetCameraPosYes
llGetCameraRotYes
llGetCenterOfMassNo
llGetClosestNavPointNoNot in OpenSimulator
llGetColorPartialALLSIDES returns default texture, not average, anything trying to grab more than 3 sides fails per example 2
llGetCreatorYes-2683
llGetDateYes-2683
llGetDisplayNameUnknown
llGetEnergyPartialAlways returns 1.0f
llGetEnvNo
llGetEnvironmentNo
llGetExperienceDetailsNoNot in OpenSimulator
llGetExperienceErrorMessageNoNot in OpenSimulator
llGetForceYes
llGetFreeMemoryNo
llGetFreeURLsUnknown
llGetGeometricCenterPartial
llGetGMTclockYes
llGetHTTPHeaderYestested at 2011.01.25 on 0.7.1 Dev with XEngine
llGetInventoryCreatorYes
llGetInventoryKeyYes
llGetInventoryNameYes
llGetInventoryNumberYes
llGetInventoryPermMaskYes
llGetInventoryTypeYes
llGetKeyYes
llGetLandOwnerAtYes
llGetLinkKeyYes
llGetLinkMedia* Requires testing and Verification
llGetLinkNameYes
llGetLinkNumberYes-2754
llGetLinkNumberOfSidesYes
llGetLinkPrimitiveParams
llGetListEntryTypeYes
llGetListLengthYes-2750
llGetLocalPosNoFails
llGetLocalRotYes
llGetMassYes
llGetMassMKSNo
llGetMaxScaleFactorNoRequires Implementation
llGetMemoryLimitNoRequires Implementation (Mar.01.2012)
llGetMinScaleFactorNoRequires Implementation
llGetNextEmailYes
llGetNotecardLinePartial
llGetNumberOfNotecardLinesPartial
llGetNumberOfPrimsYes
llGetNumberOfSidesYes
llGetObjectDescYes
llGetObjectDetailsPartial
llGetObjectMassYesSitting avatars are phantom, don't count for the mass.
llGetObjectNameYes-2688
llGetObjectPermMaskYes
llGetObjectPrimCountYes
llGetOmegaYes
llGetOwnerYes
llGetOwnerKeyYes
llGetParcelDetailsYes
llGetParcelFlagsYes
llGetParcelMaxPrimsYes
llGetParcelMusicURL
llGetParcelPrimCountYes
llGetParcelPrimOwnersYes
llGetPermissionsYes
llGetPermissionsKeyYes
llGetPhysicsMaterialUnknown
llGetPosYes
llGetPrimitiveParamsPartial
llGetPrimMediaParamsUnknown
llGetRegionAgentCountUnknown
llGetRegionCornerYes-2688
llGetRegionFlagsYes
llGetRegionFPSNoAlways returns 10.0f
llGetRegionNameYes-2688
llGetRegionTimeDilationYes
llGetRootPositionYes
llGetRootRotationYes
llGetRotYes
llGetScaleYes
llGetScriptNameYesworks.
llGetScriptStateYesWorks.
llGetSimStatsUnknown
llGetSimulatorHostnameYes
llGetSPMaxMemoryNoRequires Implementation (Mar.01.2012)
llGetStartParameterNoReturns always 0! Same limitations as llSetStatus
llGetStaticPathNoNot in OpenSimulator
llGetStatusYes
llGetSubStringPartial
llGetSunDirectionYes
llGetTextureYes
llGetTextureOffsetYes
llGetTextureRotYes
llGetTextureScaleYes
llGetTimeYes
llGetTimeOfDayYes
llGetTimestampYes
llGetTorqueNo
llGetUnixTimeYes
llGetUsedMemoryNo
llGetUsernameUnknown
llGetVelYes
llGetWallclockYes
llGiveInventoryYes
llGiveInventoryListYes
llGiveMoneyYesWorks
llGodLikeRezObjectNo
llGroundYes
llGroundContourYes
llGroundNormalYes
llGroundRepelNo
llGroundSlopeYes
llHTTPRequestYes
llHTTPResponseYesTested on 2011.01.25 with 0.7.1 Dev OS and xEngine
llInsertStringYes
llInstantMessageYes1
llIntegerToBase64Yes
llJson2ListYes
llJsonGetValueYes
llJsonSetValueYes
llJsonValueTypeYes
llKey2NameYes
llKeyCountKeyValueNoNot in OpenSimulator
llKeysKeyValueNoNot in OpenSimulator
llLinkParticleSystemUnknown
llLinkSitTargetUnknown
llList2CSVYes
llList2FloatYes
llList2IntegerYes
llList2JsonYes
llList2KeyYes
llList2ListYes
llList2ListStridedYes
llList2RotYes-2754
llList2StringYes
llList2VectorYes
llListenYes
llListenControlYes
llListenRemoveYes
llListFindListYes
llListInsertListYes
llListRandomizeYes
llListReplaceListYes
llListSortYes
llListStatisticsYes
llLoadURLYes
llLogYes
llLog10Yes
llLookAtYes
llLoopSoundYes
llLoopSoundMasterNo
llLoopSoundSlaveNo
llMakeExplosionNo (Deprecated)Deprecated
llMakeFireNo (Deprecated)Deprecated
llMakeFountainNo (Deprecated)Deprecated
llMakeSmokeNo (Deprecated)Deprecated
llManageEstateAccessUnknown
llMapDestinationYes
llMD5StringYes
llMessageLinkedYes
llMinEventDelayNo
llModifyLandYes
llModPowYes
llMoveToTargetYes
llName2KeyYes
llNavigateToNoNot in OpenSimulator
llOffsetTextureYes-2683
llOpenRemoteDataChannelYes
llOverMyLandYes
llOwnerSayYes
llParcelMediaCommandListYes
llParcelMediaQueryYes
llParseString2ListYesSpacers are not parsed if separator list is empty
llParseStringKeepNullsYes
llParticleSystemYes
llPassCollisionsNo
llPassTouchesNo
llPatrolPointsNoNot in OpenSimulator
llPlaySoundYes
llPlaySoundSlaveNo
llPointAtNo
llPowYes
llPreloadSoundYes
llPursueNoNot in OpenSimulator
llPushObjectYes
llReadKeyValueNoNot in OpenSimulator
llRefreshPrimURLNo
llRegionSayYes
llRegionSayToYes
llReleaseCameraNo (Deprecated)Deprecated
llReleaseControlsYes
llReleaseURLNo
llRemoteDataReplyYes
llRemoteDataSetRegionNo
llRemoteLoadScriptNo (Deprecated)Deprecated
llRemoteLoadScriptPinYes
llRemoveFromLandBanListYes
llRemoveFromLandPassListYes
llRemoveInventoryYes
llRemoveVehicleFlagsNo
llRequestAgentDataNo
llRequestDisplayNameUnknown
llRequestExperiencePermissionsNoNot in OpenSimulator
llRequestInventoryDataYes
llRequestPermissionsYes
llRequestSecureURLNo
llRequestSimulatorDataYes
llRequestURLYes
llRequestUserKeyUnknown
llRequestUsernameUnknown
llResetAnimationOverrideYes
llResetLandBanListYes
llResetLandPassListYes
llResetOtherScriptYes
llResetScriptYesThis function is ignored in the state_entry() function of the default state
llResetTimeYes-2750
llReturnObjectsByIDNo
llReturnObjectsByOwnerNo
llRezAtRootYes
llRezObjectYes
llRot2AngleYes
llRot2AxisYes
llRot2EulerYes
llRot2FwdYes
llRot2LeftYes
llRot2UpYes
llRotateTextureYes-2683
llRotBetweenYes
llRotLookAtYesWorks different than SL (better?)
llRotTargetNo
llRotTargetRemoveNo
llRoundYes
llSameGroupYes
llSayYes(2688)(limted to 1023 chars)
llScaleByFactorUnknown
llScaleTextureYes-2683
llScriptDangerYes
llScriptProfilerNoRequires Implementation (Mar.01.2012)
llSendRemoteDataYes
llSensorYesWorks beyond 96m 🙂 tested past 1000m
llSensorRemoveYesWorks
llSensorRepeatYesWorks beyond 96m 🙂 tested past 1000m
llSetAlphaYes-2688
llSetAngularVelocityNoRequires Implementation (Mar.01.2012)
llSetAnimationOverrideYesworks in 0901
llSetBuoyancyYesWorks on free objects, does not make avatars buoyant with scripted attachments. The LSL wiki suggests using llSetPhysicsMaterial for better performance, but this is not implemented yet in OpenSim.
llSetCameraAtOffsetYes
llSetCameraEyeOffsetYes
llSetCameraParamsYes
llSetClickActionUnknown
llSetColorYes-2688
llSetContentTypeNoRequires Implementation (Mar.01.2012)
llSetDamageNo
llSetForceYes
llSetForceAndTorqueNo
llSetHoverHeightYes/Noworks with ubode physic ONLY
llSetInventoryPermMaskNo
llSetKeyframedMotionYesWorked well since OpenSim 0.7.6
llSetLinkAlphaYes-2760
llSetLinkCameraNo
llSetLinkColorYes-2760
llSetLinkMediaUnknown
llSetLinkPrimitiveParamsPartialPartial - PRIM_NORMAL, PRIM_SPECULAR and PRIM_ALPHA_MODE not yet implemented
llSetLinkPrimitiveParamsFastPartial* does not highlight like normal. (in connection to llGetLinkPrimitiveParams), together they rip linked prims apart when the item is worn. but not when it is dropped on the ground - PRIM_NORMAL, PRIM_SPECULAR and PRIM_ALPHA_MODE not yet implemented
llSetLinkTextureYes
llSetLinkTextureAnimUnknown
llSetLocalRotYes
llSetMemoryLimitNoRequires Implementation (Mar.01.2012)
llSetObjectDescYes100% implemented
llSetObjectNameYes100% implemented
llSetObjectPermMaskYes
llSetParcelMusicURLYes(2826) Land update not sending changed streams to client.
llSetPayPriceYes
llSetPhysicsMaterialUnknown
llSetPosYes(2688) (now with limitation of 10m as in sl)
llSetPrimitiveParamsPartialPartial (it seems complete but needed extensive checking. Also types in list are not LSL conformant) Blackdog Ashbourne: PRIM_POSITION doesn't seem to work - certainly doesn't allow for a warpPos implementation - PRIM_NORMAL, PRIM_SPECULAR and PRIM_ALPHA_MODE not yet implemented
llSetPrimMediaParamsUnknown* Requires testing and Verification (update here plz)
llSetPrimURLNo (Deprecated)Deprecated
llSetRegionPosYesTested on the Kitely and Avacon grids.
llSetRemoteScriptAccessPinYes
llSetRotYes-2688
llSetScaleYes-2688
llSetScriptStateYesWorks.
llSetSitTextYes
llSetSoundQueueingNo
llSetSoundRadiusYes
llSetStatusYesDoesn't honor STATUS_BLOCK_GRAB STATUS_RETURN_AT_EDGE STATUS_SANDBOX
llSetTextYes-2760
llSetTextureYes-2688
llSetTextureAnimYes
llSetTimerEventYes(2688) (uses Timer plugin!)
llSetTorqueNo
llSetTouchTextYesWorks.
llSetVehicleFlagsNo
llSetVehicleFloatParamYes
llSetVehicleRotationParamYes
llSetVehicleTypeYes
llSetVehicleVectorParamYes
llSetVelocityNoRequires Implementation (Mar.01.2012)
llSHA1StringUnknown* Requires testing and Verification (update here plz)
llShoutYes(2688) (limits 1023 chars)
llSinYes-2688
llSitOnLinkUnknown
llSitTargetYes
llSleepYesThis function CAN lock script threads. This is a Partial Implementation. DO NOT USE! There are Mantii on it and it is a well known OpenSim buglet.
llSoundNo (Deprecated)Deprecated
llSoundPreloadNo (Deprecated)Deprecated
llSqrtYes-2688
llStartAnimationYes
llStopAnimationYes
llStopHoverYes
llStopLookAtNo
llStopMoveToTargetYes
llStopPointAtNo (Deprecated)Deprecated
llStopSoundYes
llStringLengthYes
llStringToBase64Yes
llStringTrimYes
llSubStringIndexYes
llTakeCameraNo (Deprecated)Deprecated
llTakeControlsYesNeeded for Kan-ed#12
llTanYes-2688
llTargetYes
llTargetOmegaYesWorks.
llTargetRemoveYes
llTeleportAgentYes
llTeleportAgentGlobalCoordsYes
llTeleportAgentHomeYes
llTextBoxYesOperational with Viewers that support it. V3 and above all do.
llToLowerYes
llToUpperYes
llTransferLindenDollarsNoRequires Implementation (Mar.01.2012)
llTriggerSoundYesWorks.
llTriggerSoundLimitedNo
llUnescapeURLYes
llUnSitYesWorks.
llUpdateCharacterNoLL Pathfinding Only. Not in OpenSimulator
llUpdateKeyValueNoLL Experience Only. Not in OpenSimulator
llVecDistYesTested in OpenSim 0.7.6 Dev
llVecMagYesTested in OpenSim 0.7.6 Dev
llVecNormYes-2688
llVolumeDetectPartialImplementation needs ODE to work, other physics engine only have a stub for this. Persistance of this feature (survive region restart) only implemented for SQLite. Semantics are slightly different to SL (switching off phantom via GUI also resets VolDet-status to off)
llWanderWithinNoLL Pathfinding Only. Not in OpenSimulator
llWaterYes
llWhisperYes(2688) (but limited to 1023 chars)
llWindYes
llXorBase64Unknown
llXorBase64StringsNo (Deprecated)Deprecated
llXorBase64StringsCorrectYes

From Opensimulator.org with changes made for Brevity and clarity.  Their license is here: