TCP messages from the app to the console are ASCII encoded JSON strings of the form:
{"type":<int>,"args":<any[]>,"id":<int>}
An example of this:
{"type":6,"args":[-71774.303255814,87841.2072351421,false],"id":11}
It appears that the app sends the console messages twice. It's unknown if this is intentional or not.
integer used to represent the type of the message
array array of arguments, of any type, to pass to the handler
integer starting at 1 and incrementing by one for each message sent
Sometimes the JSON messages are prefixed with some binary data. An example of this follows:
0x22 0x00 0x00 0x00 0x05 {"type":12,"args":[50308],"id":34}
0x22000000
is little-endian 34
, which is the length of the ASCII contents that follows the binary
contents. 0x05
is 5, which seems to be a type/id.
Messages are by their id and nickname below.
Sets a waypoint on the world map.
- longitude? double
- latitude? double
- ? boolean
{"type":6,"args":[-71774.303255814,87841.2072351421,false],"id":11}
Fast travel to a location
- locationId integer
{"type":9,"args":[48363],"id":15}
Changes the map to/from world view from/to local view
none
{"type":13,"args":[],"id":18}
Toggles a radio station
- ID integer Station ID
ID | Name |
---|---|
50313 | Diamond city |
50308 | Classical |
{"type":12,"args":[50308],"id":34}
Drop an item from the player's inventory
- ? integer
- pageIndex? integer
- ? integer
- items? integer[]
The following is an example of the item at index 0, a fedora, inside the apparel page (page index 1), getting dropped:
{"type":1,"args":[4207600413,1,0,[0]],"id":56}