#
Class: Force#
HierarchyHandle<force>
↳ Force
#
Constructors#
constructornew Force(): Force
Returns: Force
Defined in: handles/force.ts:6
#
Properties#
handle• Readonly
handle: force
Defined in: handles/handle.ts:6
#
Accessors#
idid(): number
Get the unique ID of the handle. The ID is recycled once you destroy the object.
Returns: number
The unique ID of a handle object.
Defined in: handles/handle.ts:18
#
Methods#
addPlayeraddPlayer(whichPlayer: MapPlayer): void
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: void
Defined in: handles/force.ts:16
#
clearclear(): void
Returns: void
Defined in: handles/force.ts:20
#
destroydestroy(): void
Returns: void
Defined in: handles/force.ts:24
#
enumAlliesenumAllies(whichPlayer: MapPlayer, filter: boolexpr | function): void
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
filter | boolexpr | () => boolean |
Returns: void
Defined in: handles/force.ts:28
#
enumEnemiesenumEnemies(whichPlayer: MapPlayer, filter: boolexpr | function): void
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
filter | boolexpr | () => boolean |
Returns: void
Defined in: handles/force.ts:32
#
enumPlayersenumPlayers(filter: boolexpr | function): void
#
Parameters:Name | Type |
---|---|
filter | boolexpr | () => boolean |
Returns: void
Defined in: handles/force.ts:36
#
enumPlayersCountedenumPlayersCounted(filter: boolexpr | function, countLimit: number): void
#
Parameters:Name | Type |
---|---|
filter | boolexpr | () => boolean |
countLimit | number |
Returns: void
Defined in: handles/force.ts:40
#
forfor(callback: function): void
#
Parameters:Name | Type |
---|---|
callback | () => void |
Returns: void
Defined in: handles/force.ts:44
#
getPlayersgetPlayers(): MapPlayer[]
Returns all player handles belonging to this force
Returns: MapPlayer[]
Defined in: handles/force.ts:51
#
hasPlayerhasPlayer(whichPlayer: MapPlayer): boolean
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: boolean
Defined in: handles/force.ts:59
#
removePlayerremovePlayer(whichPlayer: MapPlayer): void
#
Parameters:Name | Type |
---|---|
whichPlayer | MapPlayer |
Returns: void
Defined in: handles/force.ts:63
#
fromHandlestatic fromHandle(handle: force): Force
#
Parameters:Name | Type |
---|---|
handle | force |
Returns: Force
Defined in: handles/force.ts:67