-
Notifications
You must be signed in to change notification settings - Fork 1
usage
"a32s" callExtension "version"
This sqf command will return the base version of the extension.
Because of the limitations on how arma calls the extension. all calls beginning with s: will only return the ticket number they are linked to. to retrieve the actual result us the call "r:tickNumber", where ticketNumber is the number returned from the call you want to retrieve.
all returns are prefixed with either a "0:" or "1:" depending on whether a multipart return is required. Example time:
"a32s" callExtension "s:tcp:new:test"
will return an integer (lets assume this si the first call so it should return 1). to check whether the socket was created succsesfully call the following sqf:
"a32s" callExtension "r:1"
This will return a status message. Hopefully
"socket created".
Version 2 or greater of the api wil prefix all returns with a second "0:" if successful or a "1" if there was an error. This will make it easy to check whether a call was succesfull from arma.
This is all really nice but what happens when
"s:tcp:recv:test"
tries to return a larger amount of data than fits in the arma 3 buffer? well the return message will be prefixed with a
"1:<totalPacketNumber>:<currentPacketNumber>:"
where totalPacketNumber is the total number of packets associated with a ticket. and currentPacketNumber is the packet currently being returned both these values are of the type int. so an example return could be:
1:3:1:this is the first part of a 3 part message