🎮 Adds shadows, dynamic sliders and livestream to emulation
This commit is contained in:
@@ -22,6 +22,14 @@ export const connect = (url:string) => {
|
||||
_socket.onclose = _disconnected;
|
||||
_socket.onmessage = _message;
|
||||
socket.set(_socket)
|
||||
|
||||
servoBuffer.subscribe(data => {
|
||||
if(_socket.readyState !== 1) return
|
||||
const buffer = []
|
||||
buffer[0] = 1
|
||||
buffer.push(...data)
|
||||
_socket.send(new Int8Array(buffer))
|
||||
})
|
||||
}
|
||||
|
||||
const _connected = () => {
|
||||
|
||||
@@ -4,6 +4,6 @@ export const sidebarOpen = writable(false);
|
||||
|
||||
export const emulateModel = writable(true);
|
||||
|
||||
export const input = writable({left:{x:0, y:0}, right:{x:0, y:0}, height:0, speed:0});
|
||||
export const input = writable({left:{x:0, y:0}, right:{x:0, y:0}, height:70, speed:0});
|
||||
|
||||
export const outControllerData = writable(new Uint8Array(6));
|
||||
|
||||
Reference in New Issue
Block a user