@casual-simulation/aux-vm
Advanced tools
Changelog
V1.1.6
:boom: Breaking Changes
aux
prefix.:rocket: Improvements
server.storyPlayerCount()
function.
server.totalPlayerCount()
function.
server.stories()
function.
:bug: Bug Fixes
Changelog
V1.1.5
:boom: Breaking Changes
aux
prefix. However, any tag not listed below should continue to work with the aux
prefix without any changes.auxUniverse
to story
.auxCreator
to creator
.
creator
variable in scripts remains the same.auxConfigBot
to configBot
.
config
variable in scripts remains the same.auxGLTFVersion
to gltfVersion
.auxPagePortal
to pagePortal
.auxSheetPortal
to sheetPortal
.auxInventoryPortal
to inventoryPortal
.auxMenuPortal
to menuPortal
.auxLeftWristPortal
to leftWristPortal
.auxRightWristPortal
to rightWristPortal
.auxPagePortalConfigBot
to pagePortalConfigBot
.auxSheetPortalConfigBot
to sheetPortalConfigBot
.auxInventoryPortalConfigBot
to inventoryPortalConfigBot
.auxMenuPortalConfigBot
to menuPortalConfigBot
.auxLeftWristPortalConfigBot
to leftWristPortalConfigBot
.auxRightWristPortalConfigBot
to rightWristPortalConfigBot
._auxEditingBot
to _editingBot
.auxUniverse
-> story
onUniverseAction
-> onStoryAction
onUniverseStreaming
-> onStoryStreaming
universe
property has been renamed to story
onUniverseStreamLost
-> onStoryStreamLost
universe
property has been renamed to story
onUniverseSubscribed
-> onStorySubscribed
universe
property has been renamed to story
onUniverseUnsubscribed
-> onStoryUnsubscribed
universe
property has been renamed to story
player.downloadUniverse()
-> player.downloadStory()
player.loadUniverse()
-> player.loadStory()
load_universe
to load_story
.player.unloadUniverse()
-> player.unloadStory()
unload_universe
to unload_story
.player.getCurrentUniverse()
-> player.getCurrentStory()
player.checkout()
processingUniverse
property has been renamed to processingStory
.player.showJoinCode()
universe
property on the show_join_code
action has been renamed to story
server.restoreHistoryMark()
universe
property on the restore_history_mark
action has been renamed to story
.server.restoryHistoryMarkToUniverse()
-> server.restoreHistoryMarkToStory()
server.setupUniverse()
-> server.setupStory()
setup_universe
to setup_story
.:rocket: Improvements
adminSpace.unlock(password)
function.
password
is the password that should be used to unlock the admin space. If incorrect, admin space will remain locked.webhook()
and webhook.post()
functions to return promises.
data
- The data returned from the webhook. If the returned data was JSON, then this will be an object. Otherwise, it will be a string.status
- The numerical HTTP status code that was returned.statusText
- The name of the HTTP status code that was returned.headers
- The HTTP headers that were included in the response.neighboring()
function to allow omitting the direction
parameter.
front
, right
, back
, and left
.renameTag(bot, originalTag, newTag)
function which makes it easy to rename a tag on a bot or list of bots.
bot
is the bot or list of bots that should have the tag renamed.originalTag
is the name of the tag that should be renamed.newTag
is the new name that the tag should have.:bug: Bug Fixes
player.run()
to execute an invalid script would cause other actions to fail.#anchorPoint
was set to something other than bottom
.Changelog
V1.1.4
Changelog
V1.1.2
:rocket: Improvements
#auxLabelFontAddress
tag to allow specifying a custom font for a label.
#id
tag not clickable.:bug: Bug Fixes
Changelog
V1.1.18
:rocket: Improvements
player.run()
function to return a promise that can be awaited to get the result of the script (or wait until the script has been executed).server.loadErrors()
function to return a promise that can be awaited to get the list of bots that were loaded.server.destroyErrors()
function to return a promise that resolves once the error bots are destroyed.server.loadFile()
function to return a promise that resolves once the file is loaded.server.saveFile()
function to return a promise that resolves once the file is saved.server.setupStory()
function to return a promise that resolves once the story is setup.server.browseHistory()
function to return a promise that resolves once the history is loaded.server.markHistory()
function to return a promise that resolves once the history is saved.server.restoreHistoryMark()
function to return a promise that resolves once the history is restored.server.restoreHistoryMarkToStory()
function to return a promise that resolves once the history is restored.@onBotAdded
and @onAnyBotsAdded
listen tags.
@onCreate
because you will be notified whenever a bot is added to the state even if it has already been created.otherPlayers
space. You cannot create bots in this space but you will be notified via @onBotAdded
and @onAnyBotsAdded
.@onBotAdded
is triggered on the bot that was added. There is no that
.@onAnyBotsAdded
is triggered on every bot whenever one or more bots are added.
that
is an object with the following properties:
bots
- The array of bots that were added.@onAnyBotsRemoved
listen tags.
@onDestroy
because you will be notified whenever a bot is removed from the state even if it has not been explicitly destroyed.otherPlayers
space. When another player disconnects no @onDestroy
is fired but you will get a @onAnyBotsRemoved
.@onAnyBotsRemoved
is triggered on every bot whenever one or more bots are removed.
that
is an object with the following properties:
botIDs
- The array of bot IDs that were removed.@onBotChanged
and @onAnyBotsChanged
listen tags.
otherPlayers
space. You cannot update bots in this space but you will be notified via @onBotChanged
and @onAnyBotsChanged
.@onBotChanged
is triggered on the bot that was changed.
that
is an object with the following properties:
tags
- The list of tags that were changed on the bot.@onAnyBotsAdded
is triggered on every bot whenever one or more bots are added.
that
is an array containing objects with the following properties:
bot
- The bot that was updated.tags
- The tags that were changed on the bot.pageCameraPositionX
pageCameraPositionY
pageCameraPositionZ
inventoryCameraPositionX
inventoryCameraPositionY
inventoryCameraPositionZ
pageCameraRotationX
pageCameraRotationY
pageCameraRotationZ
inventoryCameraRotationX
inventoryCameraRotationY
inventoryCameraRotationZ
mousePointerPositionX
mousePointerPositionY
mousePointerPositionZ
mousePointerRotationX
mousePointerRotationY
mousePointerRotationZ
mousePointerPortal
rightPointerPositionX
rightPointerPositionY
rightPointerPositionZ
rightPointerRotationX
rightPointerRotationY
rightPointerRotationZ
rightPointerPortal
leftPointerPositionX
leftPointerPositionY
leftPointerPositionZ
leftPointerRotationX
leftPointerRotationY
leftPointerRotationZ
leftPointerPortal
null
- Button is not pressed.down
- Button was just pressed.held
- Button is being held down.mousePointer_left
mousePointer_right
mousePointer_middle
leftPointer_primary
leftPointer_squeeze
rightPointer_primary
rightPointer_squeeze
keyboard_[key]
[key]
with the key that you want the state of.keyboard_a
to get the state of the a
key.player.getCameraPosition(portal?)
function.
portal
is optional and is the portal (page
or inventory
) that the camera position should be retrieved for.x
y
z
player.getCameraRotation(portal?)
function.
portal
is optional and is the portal (page
or inventory
) that the camera rotation should be retrieved for.x
y
z
player.getPointerPosition(pointer?)
function.
pointer
is optional and is the pointer (mouse
, left
or right
) that the position should be retrieved for.x
y
z
player.getPointerRotation(pointer?)
function.
pointer
is optional and is the pointer (mouse
, left
or right
) that the rotation should be retrieved for.x
y
z
player.getInputState(controller, button)
function.
controller
is the controller (mousePointer
, leftPointer
, rightPointer
, keyboard
or touch
) that the button state should be retrieved from.button
is the name of the button that should be retrieved.null
if the button is not pressed.
"down"
means that the button just started to be pressed."held"
means that the button is being held down.null
means that the button is not pressed.player.getInputList()
function.
player.getInputState()
function.:bug: Bug Fixes
Changelog
V1.1.0
:rocket: Improvements
autoSelect
property to the options in player.showInput()
and player.showInputForTags()
.
#auxScaleMode
tag to control how a custom mesh is scaled to fit inside a bot. It supports the following options:
fit
- The mesh is scaled to fit inside the bot's unit cube. (default)absolute
- The mesh uses whatever scale it originally had.:bug: Bug Fixes
destroy()
function where it improperly handled non-bot objects.@onAnyBotClicked
shouts.Changelog
V1.0.27
:rocket: Improvements
player.share(options)
function.
options
is an object with at least one of the following properties:
url
- The URL to share. (optional)text
- The text to share. (optional)title
- The title of the document that is being shared. (optional)auxLabelAlignment
tag.
center
- Aligns the text in the center of the label. (default)left
- Aligns the text to the left of the label.right
- Aligns the text to the right of the label.auxPointable
tag to affect whether iframes are interactable.:bug: Bug Fixes
Changelog
V1.0.26
:boom: Breaking Changes
player.loadUniverse()
function and the BotManager
API.otherAuxPlayer.com/*/universeToLoad
https://otherAuxPlayer.com?auxUniverse=universeToLoad
player.loadUniverse("myUniverse")
:rocket: Improvements
player.showInputForTag()
modal.
player.showInput(value, options)
function.
value
is a string containing the value that shouldoptions
is an object that takes the same properties that the options for player.showInputForTag()
takes.await
keyword in scripts.
await
tells the system to wait for a promise to finish before continuing.:bug: Bug Fixes
Changelog
V1.0.25
:boom: Breaking Changes
billboardZ
auxOrientationMode option to billboardTop
.:rocket: Improvements
server.loadErrors(bot, tag)
function to make loading error bots from the error space easy.
bot
is the bot or bot ID that the errors should be loaded for.tag
is the tag that the errors should be loaded for.server.destroyErrors()
function to clear all the errors in the universe.billboardFront
auxOrientationMode option to billboard the front of a bot instead of its top.auxFormAnimation
to an array.
experiment.localFormAnimation(bot, animation)
function to play an animation locally.
:bug: Bug Fixes
getMod()
function.Changelog
V1.0.24
:rocket: Improvements
auxError
must be true
auxErrorBot
must be the ID of the bot whose script is in the editor.auxErrorTag
must be the name of the tag that is being edited.auxErrorName
is the name of the error that occurred.auxErrorMessage
is the message that the error contained.:bug: Bug Fixes