You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This document serves as a guide for integrating and using the new ``UnityPoco.sendMessage()`` and ``UnityPoco.invoke()`` functions in your Unity project.
141
+
These functions facilitate communication between your Unity game and Poco, allowing for simple calls with single string arguments or calls with custom arguments.
142
+
143
+
Getting Started
144
+
````````````````
145
+
146
+
Before using the new interfaces, ensure that you have the latest version of the Poco SDK that includes the changelog updates mentioned. This functionality relies on the updates provided in https://github.com/AirtestProject/Poco-SDK/pull/123.
147
+
148
+
Using the ``sendMessage()`` Function
149
+
`````````````````````````````````````
150
+
151
+
The ``UnityPoco.sendMessage()`` function allows you to send simple messages with a single string argument from Poco to Unity.
152
+
153
+
Poco-side
154
+
~~~~~~~~~
155
+
156
+
To use the ``sendMessage()`` function on the Poco side, you just need to call it and pass the message.
157
+
158
+
.. code-block:: python
159
+
160
+
poco = UnityPoco()
161
+
poco.sendMessage("Your message here")
162
+
163
+
164
+
165
+
Using the ``invoke()`` Function
166
+
```````````````````````````````
167
+
168
+
The ``UnityPoco.invoke()`` function allows for more complex interactions with custom arguments.
169
+
170
+
Poco-side
171
+
~~~~~~~~~
172
+
173
+
To use the ``invoke()`` function on the Poco side, you'll need to specify the listener and the arguments you want to pass.
0 commit comments