azesmway / react-native-unity-play

Play an unity view in react native
MIT License
40 stars 16 forks source link

How to receive message from unity? #18

Open sneakstarberry opened 2 years ago

sneakstarberry commented 2 years ago

is there some example code of receiving message from unity? if exists, can you tell me where is it? that will be really thank you.

azesmway commented 2 years ago

is there some example code of receiving message from unity? if exists, can you tell me where is it? that will be really thank you.

Hi You can see how it's done here. https://github.com/asmadsen/react-native-unity-view

sneakstarberry commented 2 years ago

is there some example code of receiving message from unity? if exists, can you tell me where is it? that will be really thank you.

Hi You can see how it's done here. https://github.com/asmadsen/react-native-unity-view

I do that example code but there is error occured in ios. like below.

Undefined symbols for architecture arm64:
  "_onUnityMessage", referenced from:
      _UnityMessageManager_onUnityMessage_mCD8AB854AA235C61FDB03C76876A9EB7DAE0CAD5 in Assembly-CSharp.o
     (maybe you meant: _UnityMessageManager_onUnityMessage_mCD8AB854AA235C61FDB03C76876A9EB7DAE0CAD5)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I spend almost a day but I can't find way to solve it. can you help me? @azesmway