Additions:
- can pass parameters directly into rpc call by name now, see below
- can use an indexer to call a method now, see below
- can directly call methods on the `UnityComms` object now, see below
Details
Before:
All calls went via `call_rpc`, giving the method name as a parameter, and the parameters as a dictionary:
Given:
unity_comms = UnityComms()
We could make calls like:
result = unity_comms.call_rpc(method='some_method', params_dict={"message": "Hello!"})
First update above: can pass in parameters directly by name:
result = unity_comms.call_rpc(method='some_method', message="Hello!")
Second update above: can use an indexer, to give the method name:
result = unity_comms['some_method'](message="Hello!")
Third update above: can directly call methods:
result = unity_comms.some_method(message="Hello!")
Whichever approach works well for you :)