Calls the Waapi client with a given [param uri], [param arguments] and [param
options]. Example of usage:
[gdscript]
var json: JSON = JSON.new()
var connectResult = Waapi.connect_client("127.0.0.1", 8080)
if connectResult:
var args = {"from": {"ofType": ["Project", "Bus", "Switch", "State", "Event",
"SoundBank"]}}
var options = {"return": ["name", "type", "workunit", "path", "shortId"]}
var dict = Waapi.client_call("ak.wwise.core.object.get", JSON.stringify(args),
JSON.stringify(options))
var json_document = json.parse(dict["result_string"])
if json_document == OK:
if json.data.has("return"):
print(json.data["return"])
if Waapi.is_client_connected():
Waapi.disconnect_client()
[/gdscript]
Returns a Dictionary with keys [code]call_result[/code], [code]result_string[/code].
Calls the Waapi client with a given [param uri], [param args] and [param options], specifying a timeout in
milliseconds.[br][br]
Returns a Dictionary with keys [code]call_result[/code], [code]result_string[/code].
Connects the Waapi client at the given [param uri] and [param port]. The Wwise
authoring application
should be open and available at the given location and port in order for this call
to succeed. Example:
[gdscript]
var connect_result = Waapi.connect_client("127.0.0.1", 8080)
if connect_result:
# Do something...
[/gdscript]
Returns [code]true[/code] if the connection succeeded.
Disconnects the client.
Gets the last string result from [method subscribe], [method unsubscribe] or [method client_call]. Useful for
debugging.[br][br]
Returns a [code]result[/code] String.
Checks the connection status of the Waapi client.[br][br]
Returns [code]true[/code] if the client is connected, [code]false[/code] otherwise.
Subscribes the Waapi client to changes to the Wwise project in the authoring
app. In order to get the data dictionary with keys [code]subscription_id[/code], [code]subscribe_result[/code]
and [code]result_string.[br]
The signal wamp_event should be connected in GDScripts, e.g.
[gdscript]
Waapi.connect("wamp_event", Callable(self, "_on_wamp_event"))
func _on_wamp_event(data):
print(data)
[/gdscript]
Return a dictionary with keys [code]subscription_id[/code], [code]subscribe_result[/code]
and [code]result_string.
Subscribes the Waapi client to changes to the Wwise project in the authoring
app and returns after some timeout in milliseconds has passed. Works similarly to
[method subscribe] but with a timeout.[br][br]
Return a dictionary with keys [code]subscription_id[/code],
[code]subscribe_result[/code]
and [code]result_string.
Unsubscribes the Waapi client to changes to the Wwise project in the authoring app,
given a subscription ID.[br][br]
Returns a Dictionary with keys [code]unsubscribe_result[/code],
[code]result_string[/code].
Unsubscribes the Waapi client to changes to the Wwise project in the authoring app
with a timeout in milliseconds. Works similarly to [method unsubscribe] but with a
timeout.[br][br]
Returns a Dictionary with keys [code]unsubscribe_result[/code],
[code]result_string[/code].