Display NodeID value as text in Unity
Hello. I have since bought your OPCUA4Unity, and followed your tutorials in the YouTube video. I wish to refer to your Text with Delegate text. I tried doing the same thing but i am unable to output anything to my game. I am able to type in the "Text From OPCUA Node" and it comes out in the game. May I know how did you connect the script to the string that you wanted for display?
In my case, I wish to reference it to the "Value". I have tested running your OPCUA_Node and Interface and they work well (sweet!) but as we know it does not show up in the game scene. So I hope you may advise me on what are the steps needed. Thank you!
Answer
Hi,
a few questions from my side to understand the problem.
Did you checked the NodeID you want to display the text from with an OPC UA Browser (you can find several in the internet).
Is the text displaying if you use an OPCUA_Node Script - the text should be sown under value?
If both things can be answered yes the communication is correct and it is just a programming issue on your side.
What I am wondering about is, that your NodeID is called "Counter1". It seems more that it is not of type string. Maype you missed to convert the integer to a string?
Best regards
Thomas
Hi Thomas
Thank you for your advise. I edited your script as follows:
and I'm glad it works.
Allen
Customer support service by UserEcho
Hi,
a few questions from my side to understand the problem.
Did you checked the NodeID you want to display the text from with an OPC UA Browser (you can find several in the internet).
Is the text displaying if you use an OPCUA_Node Script - the text should be sown under value?
If both things can be answered yes the communication is correct and it is just a programming issue on your side.
What I am wondering about is, that your NodeID is called "Counter1". It seems more that it is not of type string. Maype you missed to convert the integer to a string?
Best regards
Thomas