Home Reference Source
public class | source

Wall

Extends:

three~EventDispatcher → Wall

A Wall is the basic element to create Rooms.

Walls consists of two half edges.

Constructor Summary

Public Constructor
public

constructor(start: *, end: *)

Constructs a new wall.

Member Summary

Public Members
public

Actions to be applied explicitly.

public

Back is the plane from end to start.

public

The back-side texture.

public

Actions to be applied on removal.

public

end: *

public

Front is the plane from start to end.

public

The front-side texture.

public

height: *

Wall height.

public

id: *

public

items: *[]

Items attached to this wall

public

Actions to be applied after movement.

public
public

onItems: *[]

public
public

start: *

public

Wall thickness.

Method Summary

Public Methods
public

distanceFrom(point: *): *

public

dontFireOnDelete(func: *)

public

fireAction(action: *)

public
public

fireOnAction(func: *)

public

fireOnDelete(func: *)

public

fireOnMove(func: *)

public
public

getClosestCorner(point: *): *

public

getEnd(): *

public

getEndX(): *

public

getEndY(): *

public

getStart(): *

public

getStartX(): *

public

getStartY(): *

public

getUuid(): *

public

oppositeCorner(corner: *): *

Return the corner opposite of the one provided.

public

relativeMove(dx: *, dy: *)

public

remove()

public
public

setEnd(corner: *)

public

setStart(corner: *)

public

snapToAxis(tolerance: *)

public
public

wallCenter(): *

public

wallLength(): *

Public Constructors

public constructor(start: *, end: *) source

Constructs a new wall.

Params:

NameTypeAttributeDescription
start *

Start corner.

end *

End corner.

Public Members

public action_callbacks: * source

Actions to be applied explicitly.

public backEdge: * source

Back is the plane from end to start.

public backTexture: * source

The back-side texture.

public deleted_callbacks: * source

Actions to be applied on removal.

public end: * source

public frontEdge: * source

Front is the plane from start to end.

public frontTexture: * source

The front-side texture.

public height: * source

Wall height.

public id: * source

public items: *[] source

Items attached to this wall

public moved_callbacks: * source

Actions to be applied after movement.

public name: string source

public onItems: *[] source

public orphan: boolean source

public start: * source

public thickness: * source

Wall thickness.

Public Methods

public distanceFrom(point: *): * source

Params:

NameTypeAttributeDescription
point *

Return:

*

public dontFireOnDelete(func: *) source

Params:

NameTypeAttributeDescription
func *

public fireAction(action: *) source

Params:

NameTypeAttributeDescription
action *

public fireMoved() source

public fireOnAction(func: *) source

Params:

NameTypeAttributeDescription
func *

public fireOnDelete(func: *) source

Params:

NameTypeAttributeDescription
func *

public fireOnMove(func: *) source

Params:

NameTypeAttributeDescription
func *

public fireRedraw() source

public getClosestCorner(point: *): * source

Params:

NameTypeAttributeDescription
point *

Return:

*

public getEnd(): * source

Return:

*

public getEndX(): * source

Return:

*

public getEndY(): * source

Return:

*

public getStart(): * source

Return:

*

public getStartX(): * source

Return:

*

public getStartY(): * source

Return:

*

public getUuid(): * source

Return:

*

public oppositeCorner(corner: *): * source

Return the corner opposite of the one provided.

Params:

NameTypeAttributeDescription
corner *

The given corner.

Return:

*

The opposite corner.

public relativeMove(dx: *, dy: *) source

Params:

NameTypeAttributeDescription
dx *
dy *

public remove() source

public resetFrontBack() source

public setEnd(corner: *) source

Params:

NameTypeAttributeDescription
corner *

public setStart(corner: *) source

Params:

NameTypeAttributeDescription
corner *

public snapToAxis(tolerance: *) source

Params:

NameTypeAttributeDescription
tolerance *

public updateAttachedRooms() source

public wallCenter(): * source

Return:

*

public wallLength(): * source

Return:

*