Function Reference

Every LSL function mapped to its poqpoq TypeScript equivalent. Auto-generated from source.

190 functions across 28 categories

Communication

LSL Functionpoqpoq APIReturnOriginStatusNotes
llSay this.say(channel, message) void SL mapped
llWhisper this.whisper(channel, message) void SL mapped
llShout this.shout(channel, message) void SL mapped
llRegionSay this.world.regionSay(channel, message) void SL mapped
llRegionSayTo this.world.regionSayTo(id, ch, msg) void SL mapped
llListen this.listen(channel, name, id, message) integer SL mapped
llListenRemove handle.remove() void SL mapped Uses handle pattern instead of integer ID
llInstantMessage this.world.instantMessage(av, msg) void SL mapped
llOwnerSay this.say(0, message) void SL mapped Channel 0 to owner only
llMessageLinked this.sendLinkMessage(link, num, str, id) void SL mapped Broadcasts within container; supports LINK_SET, LINK_THIS, LINK_ROOT, LINK_ALL_OTHERS, LINK_ALL_CHILDREN

Object Manipulation

LSL Functionpoqpoq APIReturnOriginStatusNotes
llSetPos this.object.setPosition(pos) void SL mapped Returns Promise, no 0.2s delay
llGetPos this.object.getPosition() vector SL mapped
llSetRot this.object.setRotation(rot) void SL mapped
llGetRot this.object.getRotation() rotation SL mapped
llSetScale this.object.setScale(scale) void SL mapped
llGetScale this.object.getScale() vector SL mapped
llSetColor this.object.setColor(color, face) void SL mapped
llSetAlpha this.object.setAlpha(alpha, face) void SL mapped
llSetTexture this.object.setTexture(texture, face) void SL mapped
llSetText this.object.setText(text, color, alpha) void SL mapped
llSetPrimitiveParams this.object.setMaterial(config, face) void SL partial Uses MaterialConfig instead of rule list
llGetObjectName this.object.name string SL mapped
llGetObjectDesc this.object.description string SL mapped
llGetKey this.object.id key SL mapped
llGetCreator this.object.creatorId key SL mapped
llGetOwner this.owner.id key SL mapped
llGetNumberOfPrims this.object.getLinkCount() integer SL mapped
llGetLinkKey this.object.getLink(num)?.id SL mapped

Physics

LSL Functionpoqpoq APIReturnOriginStatusNotes
llApplyImpulse this.object.applyImpulse(force, local) void SL mapped
llApplyRotationalImpulse this.object.applyTorque(torque, local) void SL mapped
llSetForce this.object.applyForce(force, local) void SL mapped
llGetVel this.object.getVelocity() vector SL mapped
llSetBuoyancy this.object.setPhysics({ gravity: false }) void SL partial
llMoveToTarget this.object.setPosition(target, { duration }) void SL mapped Uses animation options instead of tau
llSetPhysicsMaterial this.object.setPhysics(config) SL mapped

Agent Interaction

LSL Functionpoqpoq APIReturnOriginStatusNotes
llDetectedKey detected[index].id key SL mapped Uses array index instead of function
llDetectedName detected[index].name SL mapped
llDetectedPos detected[index].position vector SL mapped
llDetectedRot detected[index].rotation rotation SL mapped
llDetectedVel detected[index].velocity vector SL mapped
llDetectedType detected[index].type integer SL mapped
llGetAgentSize agent.getPosition() SL partial
llRequestPermissions this.requestPermissions(agent, perms) void SL mapped
llSitTarget this.object.setSitTarget(offset, rot) void SL mapped
llAttachToAvatar this.world.attachToAvatar(point) SL mapped
llAttachToAvatarTemp this.world.attachToAvatarTemp(point) SL mapped
llDetachFromAvatar this.world.detachFromAvatar() SL mapped
llGetAttached this.object.getAttached() integer SL mapped

Effects & Sound

LSL Functionpoqpoq APIReturnOriginStatusNotes
llParticleSystem this.object.particles(config) void SL mapped Uses ParticleConfig instead of rule list
llPlaySound this.object.playSound(sound) void SL mapped
llLoopSound this.object.loopSound(sound, volume) void SL mapped
llStopSound this.object.stopSound() void SL mapped
llTriggerSound this.object.playSound(sound, { spatial: false }) void SL mapped
llSetLinkPrimitiveParamsFast this.object.getLink(link)?.setMaterial(config) void SL partial

Timer & Sleep

LSL Functionpoqpoq APIReturnOriginStatusNotes
llSetTimerEvent this.setTimer(interval) void SL mapped Supports multiple named timers
llSleep async await this.delay(seconds) void SL mapped Does NOT block other scripts (async)

Perception & Sensors

LSL Functionpoqpoq APIReturnOriginStatusNotes
llSensor this.sensor(name, id, type, range, arc) void SL mapped
llSensorRepeat this.sensorRepeat(name, id, type, range, arc, rate) void SL mapped
llSensorRemove this.sensorRemove() void SL mapped
llCastRay this.world.raycast(start, end) list SL mapped
llGetRegionAgentCount this.world.getAgentCount() integer SL mapped
llGetAgentList this.world.getAgents() list SL mapped

Data & HTTP

LSL Functionpoqpoq APIReturnOriginStatusNotes
llGetNotecardLine async await this.world.storage.get(key) key SL mapped Key-value storage replaces notecard reading
llHTTPRequest async await this.world.http.get(url) key SL mapped Returns Promise, no callback
llGetFreeMemory /* no equivalent — no memory limit */ integer SL deprecated No 64KB limit in poqpoq
llGetNumberOfNotecardLines async await this.world.getNumberOfNotecardLines(name) key SL mapped Async — returns key, triggers dataserver

Math

LSL Functionpoqpoq APIReturnOriginStatusNotes
llVecDist v1.distanceTo(v2) float SL mapped
llVecNorm v.normalize() vector SL mapped
llVecMag v.length() float SL mapped
llRot2Euler rot.toEuler() vector SL mapped
llEuler2Rot Quaternion.fromEuler(v) rotation SL mapped
llAxes2Rot Quaternion.fromAxisAngle(axis, angle) rotation SL mapped
llFrand Math.random() * max float SL mapped
llAbs Math.abs(val) integer SL mapped
llFloor Math.floor(val) integer SL mapped
llCeil Math.ceil(val) integer SL mapped
llRound Math.round(val) integer SL mapped
llSqrt Math.sqrt(val) float SL mapped
llPow Math.pow(base, exp) float SL mapped
llSin Math.sin(val) float SL mapped
llCos Math.cos(val) float SL mapped
llTan Math.tan(val) float SL mapped
llAsin Math.asin(val) float SL mapped
llAcos Math.acos(val) float SL mapped
llAtan2 Math.atan2(y, x) float SL mapped

String

LSL Functionpoqpoq APIReturnOriginStatusNotes
llStringLength str.length integer SL mapped
llSubStringIndex str.indexOf(substr) integer SL mapped
llGetSubString str.substring(start, end) string SL mapped
llDeleteSubString str.slice(0, start) + str.slice(end + 1) string SL mapped
llToLower str.toLowerCase() string SL mapped
llToUpper str.toUpperCase() string SL mapped
llParseString2List str.split(separator) list SL mapped
llStringTrim str.trim() string SL mapped

List / Array

LSL Functionpoqpoq APIReturnOriginStatusNotes
llGetListLength arr.length integer SL mapped
llList2String arr[index] string SL mapped TypeScript arrays are typed
llList2Integer arr[index] integer SL mapped
llList2Float arr[index] float SL mapped
llList2Vector arr[index] vector SL mapped
llListSort arr.sort() list SL mapped
llListFindList arr.findIndex() integer SL mapped
llList2CSV arr.join(',') string SL mapped
llCSV2List str.split(',') list SL mapped
llListInsertList arr.splice(pos, 0, ...items) list SL mapped
llDeleteSubList arr.splice(start, count) list SL mapped

Environment

LSL Functionpoqpoq APIReturnOriginStatusNotes
llGetTimeOfDay this.world.environment.getTimeOfDay() float SL mapped
llGetSunDirection this.world.environment.getSunDirection() vector SL mapped
llGetRegionName this.world.getRegionName() string SL mapped
llGetUnixTime this.world.getUnixTime() integer SL mapped
llGround this.world.getGroundHeight(pos) float SL mapped
llSetRegionSunDirection this.world.environment.setTimeOfDay(hour) SL partial

OSSL — NPC

LSL Functionpoqpoq APIReturnOriginStatusNotes
osNpcCreate async this.world.npc.create(name, pos, appearance) key OSSL mapped
osNpcRemove async npc.remove() void OSSL mapped
osNpcMoveTo async await npc.moveTo(pos) void OSSL mapped Returns Promise
osNpcSay npc.say(message, channel) void OSSL mapped
osNpcSit npc.sit(target) void OSSL mapped
osNpcStand npc.stand() void OSSL mapped
osNpcPlayAnimation npc.playAnimation(anim) void OSSL mapped
osNpcStopAnimation npc.stopAnimation(anim) void OSSL mapped
osNpcSetRot npc.setRotation(rot) void OSSL mapped

OSSL — Data

LSL Functionpoqpoq APIReturnOriginStatusNotes
osGetNotecard async await this.world.storage.get(key) string OSSL mapped
osParseJSON JSON.parse(str) string OSSL mapped Native JSON support

OSSL — Terrain

LSL Functionpoqpoq APIReturnOriginStatusNotes
osSetTerrainHeight this.world.environment.setTerrainTexture(pos, texId, radius) void OSSL mapped ADR-001 Layer 6 — Tier 3 permission required
osGetTerrainTexture this.world.getGroundTexture(pos) OSSL mapped ADR-001 — returns dominant textureId
osSetTerrainTexture this.world.environment.setTerrainTexture(pos, texId, radius) OSSL mapped ADR-001 Layer 6 — requires Tier 3 permission

OSSL — Agent

LSL Functionpoqpoq APIReturnOriginStatusNotes
osTeleportAgent await agent.teleport(destination) void OSSL mapped

OSSL — Texture

LSL Functionpoqpoq APIReturnOriginStatusNotes
osSetDynamicTextureURL this.object.setTexture(url, face) void OSSL partial

Media on a Prim

LSL Functionpoqpoq APIReturnOriginStatusNotes
llSetPrimMediaParams this.object.setMediaParams(face, rules) integer SL mapped Rules list uses PRIM_MEDIA_* constants
llClearPrimMedia this.object.clearMedia(face) integer SL mapped
llGetPrimMediaParams this.object.getMediaParams(face, rules) list SL mapped Returns list of parameter values
llSetLinkMedia this.object.getLink(link)?.setMediaParams(face, rules) integer SL mapped
llClearLinkMedia this.object.getLink(link)?.clearMedia(face) integer SL mapped
llGetLinkMedia this.object.getLink(link)?.getMediaParams(face, rules) list SL mapped

Dialog / UI

LSL Functionpoqpoq APIReturnOriginStatusNotes
llDialog this.world.dialog(av, msg, buttons, ch) void SL mapped
llTextBox this.world.textBox(av, msg, ch) SL mapped
llLoadURL this.world.loadURL(av, msg, url) void SL mapped
llMapDestination this.world.mapDestination(sim, pos, look) void SL mapped

Inventory

LSL Functionpoqpoq APIReturnOriginStatusNotes
llGetInventoryNumber this.container.getAssetCount(type) integer SL mapped
llGetInventoryName this.container.getAssetName(type, index) string SL mapped
llGetInventoryType this.container.getAssetType(name) integer SL mapped
llGetInventoryKey this.container.getAsset(name)?.id SL mapped
llGetInventoryCreator this.container.getAssetCreator(name) SL mapped
llGetInventoryPermMask this.container.getAssetPermMask(name, mask) SL mapped
llAllowInventoryDrop this.object.allowInventoryDrop(flag) SL mapped
llGiveInventory this.world.giveInventory(dest, name) void SL mapped
llGiveInventoryList this.world.giveInventoryList(dest, folder, items) void SL mapped
llRemoveInventory this.container.removeAsset(name) void SL mapped

Economy / Money

LSL Functionpoqpoq APIReturnOriginStatusNotes
llGiveMoney this.world.giveMoney(target, amount) SL mapped
llTransferLindenDollars async await this.world.transferLindenDollars(target, amount) key SL mapped Async — returns transaction key, triggers transaction_result
llSetPayPrice this.world.setPayPrice(default, buttons) void SL mapped
llGetBalance this.world.getBalance() SL mapped

NPC — Combat & Hostility

LSL Functionpoqpoq APIReturnOriginStatusNotes
world.npc.damage this.world.npcDamage(npcId, damage, source?) poqpoq mapped Deal damage to an NPC; returns true if NPC was alive
world.npc.isHostile this.world.npcIsHostile(npcId) poqpoq mapped Check whether an NPC is flagged as hostile
world.npc.setHostile this.world.npcSetHostile(npcId, hostile) poqpoq mapped Toggle NPC hostility flag on/off
world.npc.getNearestTarget this.world.npcGetNearestTarget(position, maxRange?) poqpoq mapped Find closest NPC target from a position; returns NpcTargetResult or null
world.npc.getTargetsInRadius this.world.npcGetTargetsInRadius(position, maxRange) poqpoq mapped Get all NPC targets within radius; returns NpcTargetResult[]
world.npc.respawn this.world.npcRespawn(npcId, position?) poqpoq mapped Respawn a dead NPC at original or specified position

NPC — Steering Behaviors

LSL Functionpoqpoq APIReturnOriginStatusNotes
world.npc.setSteering this.world.npcSetSteering(npcId, behaviors, maxSpeed?, maxForce?) poqpoq mapped Apply declarative steering behaviors (seek, flee, arrive, pursue, evade, wander, separation, cohesion, alignment, obstacleAvoidance, tether)
world.npc.clearSteering this.world.npcClearSteering(npcId) poqpoq mapped Remove all steering behaviors from an NPC

NPC — Spatial Queries

LSL Functionpoqpoq APIReturnOriginStatusNotes
world.npc.getPosition this.world.npcGetPosition(npcId) poqpoq mapped Get current NPC world position; returns Vec3 or null
world.npc.getRotation this.world.npcGetRotation(npcId) poqpoq mapped Get current NPC rotation; returns Quat or null

Avatar Attachments

LSL Functionpoqpoq APIReturnOriginStatusNotes
world.avatar.equip this.world.avatar.equip(pointId) poqpoq mapped Equip item to a named attachment slot (25-slot system)
world.avatar.unequip this.world.avatar.unequip(pointId) poqpoq mapped Remove item from a named attachment slot
world.avatar.setAttachmentVisible this.world.avatar.setAttachmentVisible(pointId, visible) poqpoq mapped Show or hide an attachment slot without unequipping
world.avatar.getAttachment this.world.avatar.getAttachment(pointId) poqpoq mapped Get attachment slot info (pointId, label, hasItem, itemId, visible)
world.avatar.getAttachmentPoints this.world.avatar.getAttachmentPoints() poqpoq mapped List all available attachment slots and their current state
world.avatar.adjustAttachment this.world.avatar.adjustAttachment(pointId, offset?, rotation?, scale?) poqpoq mapped Fine-tune attachment position, rotation, and scale on a slot

Physics Extensions

LSL Functionpoqpoq APIReturnOriginStatusNotes
world.physics.applyForce this.object.applyForce(force, local?) poqpoq mapped Apply continuous force to object; local flag for object-space
world.physics.applyImpulse this.object.applyImpulse(impulse, local?) poqpoq mapped Apply single-frame impulse to object
world.physics.setTorque this.object.setTorque(torque, local?) poqpoq mapped Apply rotational torque to object
world.physics.pushObject this.world.pushObject(targetId, impulse, angularImpulse, local?) poqpoq mapped Push another object with linear and angular impulse
world.physics.setStatus this.object.setStatus(flags, value) poqpoq mapped Set STATUS_PHYSICS, STATUS_PHANTOM, etc. flags on object
world.physics.setDamage this.object.setDamage(damage) poqpoq mapped Set collision damage dealt by this object
world.physics.volumeDetect this.object.volumeDetect(enabled) poqpoq mapped Enable phantom collision events without physical response
world.physics.collisionFilter this.object.collisionFilter(name, id, accept) poqpoq mapped Accept or reject collisions by name/id pattern
world.physics.setBuoyancy this.object.setBuoyancy(buoyancy) poqpoq mapped Set buoyancy factor (0 = full gravity, 1 = neutral, >1 = floats)
world.physics.stopMoveToTarget this.object.stopMoveToTarget() poqpoq mapped Cancel an active moveToTarget animation
world.physics.lookAt this.object.lookAt(target, strength, damping) poqpoq mapped Continuously orient object toward a target position
world.physics.stopLookAt this.object.stopLookAt() poqpoq mapped Cancel an active lookAt constraint
world.physics.setPhysicsShape this.object.setPhysicsShape(shapeType, params) poqpoq mapped Override physics collision shape (box, sphere, mesh, etc.)

Terrain System

LSL Functionpoqpoq APIReturnOriginStatusNotes
world.terrain.setInfluence this.object.setTerrainInfluence(config) poqpoq mapped Register this object as a terrain influence source (radius, falloff, texture, blend mode)
world.terrain.getInfluence this.object.getTerrainInfluence() poqpoq mapped Get current terrain influence config for this object; returns config or null
world.terrain.clearInfluence this.object.clearTerrainInfluence() poqpoq mapped Remove this object's terrain influence registration
world.terrain.getGroundTexture this.world.getGroundTexture(position) poqpoq mapped Query dominant ground texture at a world position
world.terrain.getInfluences this.world.getTerrainInfluences(position, radius?) poqpoq mapped Get all active terrain influences near a position
world.terrain.getEvents this.world.getTerrainEvents(position, radius, maxAge?) poqpoq mapped Get recent terrain modification events (footprints, scorches, etc.)
world.terrain.setTexture this.world.environment.setTerrainTexture(position, textureId, radius, intensity?) poqpoq mapped Paint terrain texture at a world position (requires Tier 3 permission)
world.terrain.applyEffect this.world.environment.applyTerrainEffect(position, effect) poqpoq mapped Apply a transient terrain effect (TTL-based, e.g. scorch marks, frost)

VFX (Luminary)

LSL Functionpoqpoq APIReturnOriginStatusNotes
world.vfx.trigger this.world.vfx.trigger(archetype, position, options?) poqpoq unmapped Trigger a named VFX archetype at a world position (Luminary integration pending)
world.vfx.getPalette this.world.vfx.getPalette(name) poqpoq unmapped Retrieve a named color/effect palette for VFX customization (Luminary integration pending)
world.vfx.registerArchetype this.world.vfx.registerArchetype(name, config) poqpoq unmapped Register a reusable VFX archetype definition (Luminary integration pending)