Bidirectional Webbrowser Control for Unity Application

the goal is to set up some variables within a webbrowser for a Unity application.

The communication needs to be bidirectional, because we also need to get first some information from Unity (which gameObjects/actions/… exists) for some pop up menus and secondly we have to fill out the “form” on the website which information should be sended to the Unity application in order to start the scene.

Does anyone has any ideas?

I already tried to work with this tutorial (

), but unfortunately Network.perrType is not available for Unity version 2019.2.9f1 anymore.

one option:

  • webpage connects to server using websockets
  • server is running node.js/python or anything that acts as a websocket server
  • unity client/app connects to that server using tcp/websockets also

i’ve done exactly that and it worked well enough
(tested up to 70 users at the same time, server was simple node.js server - basically just passing messages between clients and or webpage user, who was controlling the class)

Yeah I was already thinking of this option because this is basically a simple web application project with two clients (web browser and unity application)

But i was thinking if it is possible to have an option without setting up a separate server.

@ which library did you use for connecting the unity application to the server via tcp/websockets?

it was regular c# tcp sockets, and node.js server then had both tcp and websocket servers.
(because client had multiplayer features also, so websocket stuff was reserved for special commands only)