Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Connect WebGL with a backend?

Discussion in 'WebGL' started by unity_250097180, Mar 2, 2021.

  1. unity_250097180

    unity_250097180

    Joined:
    Aug 19, 2019
    Posts:
    7
    Sorry that this question may be silly or previously answered but I'm super new to Unity and I almost confused myself by searching for the answer for several days by googling.

    I have a game built on WebGL but then I need to connect the game with a script written in Python (essentially the backend?) to compute in real-time and change parameters in scripts written in C# that will control GameObjects.

    I was thinking to use Cloud Service such as Google Cloud PubSub for this but then I realize I can probably just put them on the same server. However, I'm also quite new to server setup.. The only thing I learned is that I could set up a LAMP stack to deploy the game in WebGL format, but I'm not sure how C# scripts can "communicate" with python scripts after they are packed into WebGL format. Is this even possible?
     
  2. wetcircuit

    wetcircuit

    Joined:
    Jul 17, 2012
    Posts:
    1,409
    unity_250097180 likes this.
  3. unity_250097180

    unity_250097180

    Joined:
    Aug 19, 2019
    Posts:
    7
  4. adamgolden

    adamgolden

    Joined:
    Jun 17, 2019
    Posts:
    1,497
  5. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,797
    unity_250097180 likes this.