public void EnableVRButton() { int result; #if UNITY_WEBGL && !UNITY_EDITOR result = SocketIOJSLib.EnableVRButton(); #else result = socketSim.EnableVRButton(); #endif if (result != SocketIOJSLib.SUCCESS) { connectionAdapter.DisplaySocketIOAdapterError("EnableVRButton failed."); } }
public void On_Initiation_Loading_Finished() { #if UNITY_WEBGL && !UNITY_EDITOR // Init the socket and join the session. InitSocketConnection(); // set up shared memory with js context InitSocketIOReceivePosition(position_data, position_data.Length); InitSocketIOReceiveInteraction(interaction_data, interaction_data.Length); InitReceiveDraw(draw_data, draw_data.Length); // setup browser-context handlers InitSessionStateHandler(); InitSocketIOClientCounter(); InitClientDisconnectHandler(); InitMicTextHandler(); InitBrowserReceiveMessage(); InitSessionState(); EnableVRButton(); #else // Init the socket and join the session. SocketSim.InitSocketConnection(); // set up shared memory with js context SocketSim.InitSocketIOReceivePosition(position_data, position_data.Length); SocketSim.InitSocketIOReceiveInteraction(interaction_data, interaction_data.Length); SocketSim.InitReceiveDraw(draw_data, draw_data.Length); // setup browser-context handlers SocketSim.InitSessionStateHandler(); SocketSim.InitSocketIOClientCounter(); SocketSim.InitClientDisconnectHandler(); SocketSim.InitMicTextHandler(); SocketSim.InitBrowserReceiveMessage(); SocketSim.InitSessionState(); SocketSim.EnableVRButton(); #endif }