@casual-simulation/aux-custom-portals
Advanced tools
Changelog
V1.5.24
math.normalizeVector()
and math.vectorLength()
functions.Changelog
V1.5.23
inventoryPortal
to miniPortal
.
#inventoryPortalHeight
-> #miniPortalHeight
#inventoryPortalResizable
-> #miniPortalResizable
os.getInventoryPortalDimension()
-> os.getMiniPortalDimension()
os.hasBotInInventory()
-> os.hasBotInMiniPortal()
os.getPortalDimension("inventory")
-> os.getPortalDimension("mini")
os.getCameraPosition("inventory")
-> os.getCameraPosition("mini")
os.getCameraRotation("inventory")
-> os.getCameraRotation("mini")
os.getFocusPoint("inventory")
-> os.getFocusPoint("mini")
miniPortalHeight
tag was changed from being a number between 1 and 10 that represented the number of bots that should fit in the portal. Now it is a number between 0 and 1 that represents the percentage of the screen height it should take. Note that when #miniPortalWidth
is less than 1 the height of the portal will be more like 80% of the screen height when set to 1. This is because of the mandatory spacing from the bottom of the screen to be somewhat consistent with the spacing on the sides.#miniPortalWidth
tag.
Changelog
V1.5.22
os.enableCustomDragging()
function to disable the default dragging behavior for the current drag operation.
os.focusOn()
would not work with bots in the inventory portal.Changelog
V1.5.21
Improved os.focusOn()
to support focusing on menu bots that have #form
set to input
.
Added the ability to snap dragged to a specific axis.
let snapAxis: {
/**
* The direction that the axis travels along.
*/
direction: { x: number; y: number; z: number };
/**
* The center point that the axis travels through.
*/
origin: { x: number; y: number; z: number };
/**
* The distance that the bot should be from any point along the
* axis in order to snap to it.
*/
distance: number;
};
Changelog
V1.5.19
labelPaddingX
and labelPaddingY
tags to allow controlling the padding along the width and height of labels separately.cursor
and portalCursor
tags.cursorHotspotX
, cursorHotspotY
, portalCursorHotspotX
, and portalCursorHotspotY
tags to allow specifying the location that clicks should happen at in the custom cursor image. For example, a cursor that is a circle would have the hotspot in the middle but the default cursor has the hotspot at the top left.Changelog
V1.5.17
cursor
and portalCursor
tags.
cursor
tag specifies the mouse cursor that should be shown when the bot is being hovered.portalCursor
tag specifies the mouse cursor that should be used by default for the page portal.labelPadding
tag to control how much space is between the edge of the bot and edge of the label.Changelog
V1.5.16
setInterval()
with clearTimeout()
and cancel setTimeout()
with clearInterval()
.
Changelog
V1.5.15
Changelog
V1.5.14
clearInterval()
and clearTimeout()
.
clearInterval(timerId)
is useful for clearing intervals created by setInterval()
.clearTimeout(timerId)
is useful for clearing timeouts created by setTimeout()
Changelog
V1.5.11
shared
, tempShared
, and remoteTempShared
spaces to use a faster and more efficient storage mechanism.
SHARED_PARTITIONS_VERSION
which controls whether the new spaces are used. Use v1
to indicate that the old causal repo based system should be used and use v2
to indicate that the new system should be used.math.areClose(first, second)
function to determine if two numbers are within 2 decimal places of each other.
math.areClose(1, 1.001)
will return true.atPosition()
and inStack()
bot filters to use math.areClose()
internally when comparing bot positions.clearAnimations()
would error if given a null bot.