Anders and Briegel in Python
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- function poll() {
- var ws = new WebSocket("ws://localhost:5001");
- ws.onopen = function()
- {
- console.log("Connected to server.");
- };
-
- ws.onmessage = function (evt)
- {
- var new_state = JSON.parse(evt.data);
- vops = new_state.vops;
- ngbh = new_state.ngbh;
- updateScene();
- };
-
- ws.onclose = function()
- {
- console.log("Connection was closed.");
- };
- }
|