Package | com.whirled |
Class | public class FurniControl |
Inheritance | FurniControl ![]() ![]() ![]() |
Subclasses | BackdropControl, PropControl, ToyControl |
Method | Defined by | ||
---|---|---|---|
FurniControl(disp:DisplayObject)
Create a furni interface.
| FurniControl | ||
![]() |
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
Registers an event listener.
| AbstractControl | |
![]() |
canManageRoom(memberId:int = 0):Boolean
Returns true if the local client has management privileges in the current room.
| EntityControl | |
![]() |
clearPopup():void
Clear any showing popup.
| EntityControl | |
![]() |
doBatch(fn:Function, ... args):void
Execute the specified function as a batch of commands that will be sent to the server
together.
| AbstractControl | |
![]() |
getCamera(index:String = null):Camera
Access the local user's camera.
| EntityControl | |
![]() |
getDefaultDataPack():ByteArray
Get the default datapack for this entity, or null if there is none defined.
| EntityControl | |
![]() |
getEntityIds(type:String = null):Array
Enumerates the ids of all entities in this room.
| EntityControl | |
![]() |
getEntityProperty(key:String, entityId:String = null):Object
Looks up and returns the specified property for the specified entity.
| EntityControl | |
![]() |
getEnvironment():String
Get the "environment" in which this entity is presently running.
| EntityControl | |
![]() |
getInstanceId():int
Get the id of the viewer that is viewing this instance.
| EntityControl | |
![]() |
getLogicalLocation():Array
Returns our current logical location in the scene.
| EntityControl | |
![]() |
getMemories():Object
Return an associative hash of all the memories.
| EntityControl | |
![]() |
getMemory(key:String, defval:Object = null):Object
Returns the value associated with the supplied key in this item's memory.
| EntityControl | |
![]() |
getMicrophone(index:int = -1):Microphone
Access the local user's microphone.
| EntityControl | |
![]() |
getMusicId3():Object
Get the id3 metadata of the currently playing music.
| EntityControl | |
![]() |
getMusicOwnerId():int
Get the playerId of the owner of the currently playing music, aka the player who added it
to the playlist, or 0 if there is no music currently playing.
| EntityControl | |
![]() |
getMyEntityId():String
Returns the Whirled-wide unique ID of this copy of the entity.
| EntityControl | |
![]() |
getPixelLocation():Array
Returns our current location in the scene, in pixel coordinates.
| EntityControl | |
![]() |
getRoomBounds():Array
Get the room's bounds in pixels.
| EntityControl | |
![]() |
getViewerName(id:int = 0):String
Get the non-unique display name of the user viewing a particular instance.
| EntityControl | |
![]() |
hasControl():Boolean
Detects whether this client is in control.
| EntityControl | |
![]() |
isConnected():Boolean
Are we connected and running inside the whirled environment, or has someone just
loaded up our SWF by itself?
| AbstractControl | |
![]() |
registerCustomConfig(func:Function):void
Register a function used for generating a custom config panel.
| EntityControl | |
![]() |
registerPropertyProvider(func:Function):void
Registers a function that provides custom entity properties.
| EntityControl | |
![]() |
removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
Unregisters an event listener.
| AbstractControl | |
![]() |
sendMessage(name:String, arg:Object = null):void
Send a message to other instances of this entity, resulting in a MESSAGE_RECEIVED event.
| EntityControl | |
![]() |
sendSignal(name:String, arg:Object = null):void
Send a message to all instances of all entities in this instance's current room,
resulting in a SIGNAL_RECEIVED event.
| EntityControl | |
![]() |
setHotSpot(x:Number, y:Number, height:Number):void
Set the layout "hotspot" for your item, specified as pixels relative to (0, 0) the top-left
coordinate.
| EntityControl | |
![]() |
setMemory(key:String, value:Object, callback:Function = null):void
Requests that this item's memory be updated with the supplied key/value pair.
| EntityControl | |
![]() |
setTickInterval(interval:Number):void
Configures the interval on which this item is "ticked" in milliseconds.
| EntityControl | |
showPage(token:String):Boolean
Shows the Whirled page identified by the supplied token.
| FurniControl | ||
![]() |
showPopup(title:String, panel:DisplayObject, width:Number, height:Number, backgroundColor:uint = 0xFFFFFF, backgroundAlpha:Number = 1.0):Boolean
Show a popup to the current user in the whirled.
| EntityControl | |
![]() |
triggerAction(name:String, arg:Object = null):void
Triggers an action on this scene object.
| EntityControl |
Event | Summary | Defined by | ||
---|---|---|---|---|
![]() | Dispatched when the instance in control sends a trigger action to all instances. | EntityControl | ||
![]() | Dispatched to entities when they overhear chatter in the room. | EntityControl | ||
![]() | Dispatched when this instance gains control. | EntityControl | ||
![]() | Dispatched when an entity enters the room. | EntityControl | ||
![]() | Dispatched when an entity leaves the room. | EntityControl | ||
![]() | Dispatched when an entity in the room (other than the listening entity) changes location. | EntityControl | ||
Dispatched when the local user unhovers the mouse from this sprite. | FurniControl | |||
Dispatched when the local user hovers the mouse over this sprite. | FurniControl | |||
![]() | Dispatched when the instance in control updates the memory of this digital item. | EntityControl | ||
![]() | Dispatched when any instance sends a message to all instances. | EntityControl | ||
![]() | Dispatched when id3 data is found in the currently playing song. | EntityControl | ||
![]() | Dispatched when music starts playing in the room. | EntityControl | ||
![]() | Dispatched when music stops playing in the room. | EntityControl | ||
![]() | Dispatched when any entity or AVR game sends a message to all other entities. | EntityControl | ||
![]() | Dispatched once per tick, only when this instance has control and only if tick interval is registered. | EntityControl | ||
![]() | Event.UNLOAD Dispatched when the SWF using this control has been unloaded. | AbstractControl |
Constant | Defined by | ||
---|---|---|---|
BODY_ENTERED : String = "bodyEntered" [static] An action triggered when someone arrives at the location at which
this furniture is placed, if this piece of furniture is a doorway.
| FurniControl | ||
BODY_LEFT : String = "bodyLeft" [static] An action triggered when someone leaves via this piece of doorway
furniture.
| FurniControl | ||
![]() | ENV_ROOM : String = "room" [static] A constant returned by getEnvironment() to indicate that this entity is
being viewed in a room.
| EntityControl | |
![]() | ENV_SHOP : String = "shop" [static] A constant returned by getEnvironment() to indicate that this entity is
being viewed in the shop.
| EntityControl | |
![]() | ENV_VIEWER : String = "viewer" [static] A constant returned by getEnvironment() to indicate that this entity is
being viewed in the "viewer": memories may be set and read, but they will not be saved.
| EntityControl | |
![]() | PROP_DIMENSIONS : String = "std:dimensions" [static] The entity pixel dimensions (an Array [width, height]).
| EntityControl | |
![]() | PROP_HOTSPOT : String = "std:hotspot" [static] The entity's hot spot (an Array [x, y]).
| EntityControl | |
![]() | PROP_LOCATION_LOGICAL : String = "std:location_logical" [static]
The entity's location in logical coordinates (an Array [ x, y, z ]).
| EntityControl | |
![]() | PROP_LOCATION_PIXEL : String = "std:location_pixel" [static]
The entity's location in pixel coordinates (an Array [ x, y, z ]).
| EntityControl | |
![]() | PROP_MEMBER_ID : String = "std:member_id" [static]
The unique Whirled player ID (int) of the wearer of the avatar, or the owner of the pet.
| EntityControl | |
![]() | PROP_MOVE_SPEED : String = "std:move_speed" [static] The current movement speed of an actor (Number).
| EntityControl | |
![]() | PROP_NAME : String = "std:name" [static]
The non-unique display name of the entity (a String).
| EntityControl | |
![]() | PROP_ORIENTATION : String = "std:orientation" [static]
The entity facing direction (a Number).
| EntityControl | |
![]() | PROP_TYPE : String = "std:type" [static]
The type of the entity, TYPE_AVATAR, TYPE_PET or TYPE_FURNI.
| EntityControl | |
![]() | TYPE_AVATAR : String = "avatar" [static] The type of avatar entities.
| EntityControl | |
![]() | TYPE_FURNI : String = "furni" [static] The type of furniture entities.
| EntityControl | |
![]() | TYPE_PET : String = "pet" [static] The type of pet entities.
| EntityControl |
FurniControl | () | constructor |
public function FurniControl(disp:DisplayObject)
Create a furni interface. The display object is your piece of furni.
Parametersdisp:DisplayObject |
showPage | () | method |
public function showPage(token:String):Boolean
Shows the Whirled page identified by the supplied token.
Parameterstoken:String — the token that identifies the page to be shown. This is not the full
URL, just the part after http://www.whirled.com/#. For example: passing "me" would show the
Me page. Passing "shop-l_5_343" would show the shop page for the Kawaii Knight avatar.
|
Boolean — true if the page was shown, false if it could not be shown for some reason.
|
hoverOut | event |
com.whirled.ControlEvent
com.whirled.ControlEvent.HOVER_OVER
Dispatched when the local user unhovers the mouse from this sprite. Note that normal MouseEvents are blocked when this sprite has "action", like it is a doorway. If you want the doorway to react to the mouse being over it then you should listen for this event.
An event type dispatched to Furniture and Toys when the mouse is leaves them. Note that the normal MouseEvents will be blocked if the furniture has an action, so this is necessary to make doorways that react to mouse hovering. name - unused value - unused
hoverOver | event |
com.whirled.ControlEvent
com.whirled.ControlEvent.HOVER_OVER
Dispatched when the local user hovers the mouse over this sprite. Note that normal MouseEvents are blocked when this sprite has "action", like it is a doorway. If you want the doorway to react to the mouse being over it then you should listen for this event.
An event type dispatched to Furniture and Toys when the mouse is over them. Note that the normal MouseEvents will be blocked if the furniture has an action, so this is necessary to make doorways that react to mouse hovering. name - unused value - unused
BODY_ENTERED | constant |
public static const BODY_ENTERED:String = "bodyEntered"
An action triggered when someone arrives at the location at which this furniture is placed, if this piece of furniture is a doorway.
This will arrive via an ACTION_TRIGGERED event with the name property set to BODY_ENTERED.
BODY_LEFT | constant |
public static const BODY_LEFT:String = "bodyLeft"
An action triggered when someone leaves via this piece of doorway furniture.
This will arrive via an ACTION_TRIGGERED event with the name property set to BODY_LEFT.