Represents a Beacon stored in the KainPlan Map.
- KPBeacon
+ new KPBeacon(x
: number, y
: number): KPBeacon
Defined in src/models/KPBeacon.ts:19
Creates a new KainPlan Beacon.
Parameters:
Name | Type | Description |
---|---|---|
x |
number | X-Coordinate of the Beacon |
y |
number | Y-Coordinate of the Beacon |
Returns: KPBeacon
• x: number
Defined in src/models/KPBeacon.ts:15
X-Coordinate
• y: number
Defined in src/models/KPBeacon.ts:19
Y-Coordinate
▸ toJSON(): any
Defined in src/models/KPBeacon.ts:49
Converts the Beacon into a JSON object - will be called when using JSON.stringify(...)
Returns: any
The Beacon in its JSON form.
▸ parse(json
: any): KPBeacon
Defined in src/models/KPBeacon.ts:36
Creates and returns a new KPBeacon from the given JSON object/string.
Parameters:
Name | Type | Description |
---|---|---|
json |
any | Either an object that has already been parsed, or a JSON string. |
Returns: KPBeacon
The newly created KPBeacon.