Retain a reference to the Scene within which this Placeable Object resides
A reference to the Scene embedded Document instance which this object represents
A control icon for interacting with the object
A mouse interaction manager instance which handles mouse workflows related to this object.
Private
#highlightThe highlight of this Region.
Private
#borderThe border of this Region.
Private
#originalThe object that this object is a preview of if this object is a preview.
Private
#lastThe bounds that the placeable was added to the quadtree with.
Private
#drawingAn internal reference to a Promise in-progress to draw the Placeable Object.
Private
#drawnHas this Placeable Object been drawn and is there no drawing in progress?
Static
embeddedIdentify the official Document name for this PlaceableObject class
Static
RENDER_Static
Private
#SHARED_A temporary point used by this class.
The shapes of this Region in draw order.
The bottom elevation of this Region.
The top elevation of this Region.
The polygons of this Region.
The polygon tree of this Region.
The Clipper paths of this Region.
The triangulation of this Region.
The geometry of this Region.
Is this Region currently visible on the Canvas?
The object that this object is a preview of if this object is a preview.
A convenient reference for whether the current User has full control over the document.
The mouse interaction state of this placeable.
The id of the corresponding Document which this PlaceableObject represents.
A unique identifier which is used to uniquely identify elements on the canvas related to this object.
The named identified for the source object associated with this PlaceableObject. This differs from the objectId because the sourceId is the same for preview objects as for the original.
Is this placeable object a temporary preview?
Does there exist a temporary preview of this placeable object?
Provide a reference to the CanvasLayer which contains this PlaceableObject.
A Form Application which is used to configure the properties of this Placeable Object or the Document it represents.
An indicator for whether the object is currently controlled
An indicator for whether the object is currently a hover target
Is the HUD display active for this Placeable?
Actions that should be taken for this Placeable Object when a mouseover event occurs. Hover events on PlaceableObject instances allow event propagation by default.
The triggering canvas interaction event
Options which customize event handling
MouseInteractionManager##handlePointerOver
Actions that should be taken for this Placeable Object when a mouseout event occurs
The triggering canvas interaction event
MouseInteractionManager##handlePointerOut
Split the movement into its segments.
The waypoints of movement.
The points relative to the waypoints that are tested. Whenever one of them is inside the region, the moved object is considered to be inside the region.
Optional
options: { Additional options
Is it teleportation?
The movement split into its segments.
Clear the display of the existing object.
The cleared object
Draw the placeable object into its parent container
Optional
options: object = {}Options which may modify the draw and refresh workflow
The drawn object
Internal
Execute a partial draw.
The draw function
The drawn object
Refresh all incremental render flags for the PlaceableObject. This method is no longer used by the core software but provided for backwards compatibility.
Optional
options: object = {}Options which may modify the refresh workflow
The refreshed object
Assume control over a PlaceableObject, flagging it as controlled and enabling downstream behaviors
Additional options which modify the control request
Release any other controlled objects first
A flag denoting whether control was successful
Clone the placeable object, returning a new object with identical attributes. The returned object is non-interactive, and has no assigned ID. If you plan to use it permanently you should call the create method.
A new object with identical data
Rotate the PlaceableObject to a certain angle of facing
The desired angle of rotation
Snap the angle of rotation to a certain target degree increment
The rotated object
Internal
Determine a new angle of rotation for a PlaceableObject either from an explicit angle or from a delta offset.
An object which defines the rotation update parameters
An explicit angle, either this or delta must be provided
A relative angle delta, either this or the angle must be provided
A precision (in degrees) to which the resulting angle should snap. Default is 0.
The new rotation angle for the object
Test whether a user can perform a certain interaction regarding a Placeable Object
The User performing the action
The named action being attempted
Does the User have rights to perform the action?
Protected
_refreshProtected
_refreshProtected
_destroyProtected
_getProtected
_onProtected
_onProtected
_createProtected
Create a standard MouseInteractionManager for the PlaceableObject
Protected
_canProtected
Does the User have permission to configure the Placeable Object?
The User performing the action.
The event object.
The returned status.
Protected
_canProtected
Does the User have permission to control the Placeable Object?
The User performing the action.
The event object.
The returned status.
Protected
_canProtected
Does the User have permission to view details of the Placeable Object?
The User performing the action.
The event object.
The returned status.
Protected
_canProtected
Does the User have permission to create the underlying Document?
The User performing the action.
The event object.
The returned status.
Protected
_canProtected
Does the User have permission to left-click drag this Placeable Object?
The User performing the action.
The event object.
The returned status.
Protected
_canProtected
Does the User have permission to hover on this Placeable Object?
The User performing the action.
The event object.
The returned status.
Protected
_canProtected
Does the User have permission to update the underlying Document?
The User performing the action.
The event object.
The returned status.
Protected
_canProtected
Does the User have permission to delete the underlying Document?
The User performing the action.
The event object.
The returned status.
Protected
_propagateProtected
_onProtected
_onProtected
_onProtected
_propagateProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onProtected
_onPrivate
#initializePrivate
#updatePrivate
#createPrivate
#buildPrivate
#segmentizeSplit the movement into its segments.
The origin of movement.
The destination of movement.
The points relative to the waypoints that are tested.
Is it teleportation?
The movement split into its segments.
Private
#getGet the teleporation segment from the origin to the destination.
The x-coordinate of the origin.
The y-coordinate of the origin.
The elevation of the destination.
The x-coordinate of the destination.
The y-coordinate of the destination.
The elevation of the destination.
The samples relative to the position.
The teleportation segment, if any.
Private
#testTest whether one of the samples relative to the given position is contained within this Region.
The x-coordinate of the position.
The y-coordinate of the position.
The samples relative to the position.
Is one of the samples contained within this Region?
Private
#getSplit the movement into its segments.
The x-coordinate of the origin.
The y-coordinate of the origin.
The elevation of the destination.
The x-coordinate of the destination.
The y-coordinate of the destination.
The elevation of the destination.
The samples relative to the position.
The intervals where we have an intersection.
Private
#couldTest whether the movement could intersect this Region.
The x-coordinate of the origin.
The y-coordinate of the origin.
The x-coordinate of the destination.
The y-coordinate of the destination.
The samples relative to the position.
Could the movement intersect?
Private
#computeCompute the intervals of intersection of the movement.
The x-coordinate of the origin.
The y-coordinate of the origin.
The x-coordinate of the destination.
The y-coordinate of the destination.
The samples relative to the position.
The intervals where we have an intersection.
Private
#findFind the crossing (enter or exit) at the current position between the start and end position, if possible. The current position should be very close to crossing, otherwise we test a lot of pixels potentially. We use Bresenham's line algorithm to walk forward/backwards to find the crossing.
The start x-coordinate.
The start y-coordinate.
The current x-coordinate.
The current y-coordinate.
The end x-coordinate.
The end y-coordinate.
The samples.
Find enter? Otherwise find exit.
Private
#commit
A Region is an implementation of PlaceableObject which represents a Region document within a viewed Scene on the game canvas.
See
-