Skip to content

Commit

Permalink
Save
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergey004 committed Nov 2, 2023
1 parent e7f6a06 commit 6f7286f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -398,3 +398,4 @@ FodyWeavers.xsd
*.sln.iml
/.editorconfig
/Quest2-VRC.GUI/vars.json
/Quest2-VRC.GUI/odtout.txt
13 changes: 8 additions & 5 deletions Quest2-VRC/Services/Sender.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@ static class Sender
{


public static async void Run(bool wirlessmode, bool audioEnadled)
public static async void Run(bool wirlessmode, bool audioEnadled, bool disableerrmsg)
{

var udpPort = Extensions.GetAvailableUdpPort();

int Uport = udpPort;
Console.WriteLine("OSC UDP port is {0}", Uport);
await questwd(Uport, wirlessmode, audioEnadled);
await questwd(Uport, wirlessmode, audioEnadled, disableerrmsg);
}

public static async Task questwd(int Uport, bool wirlessmode, bool audioEnadled)
public static async Task questwd(int Uport, bool wirlessmode, bool audioEnadled, bool disableerrmsg)
{
// Create a bogus port for the client
OscPacket.UdpClient = new UdpClient(Uport);
Expand Down Expand Up @@ -172,8 +172,11 @@ public static async Task questwd(int Uport, bool wirlessmode, bool audioEnadled)
{
string inputbox = "input";
LogToConsole("Error: Connection to the headset is lost! Waiting for reconnect...");
VRChatMessage MsgErr = new VRChatMessage(inputbox, "Error: Connection to the headset is lost! Waiting for reconnect...");
SendPacket(MsgErr);
if (disableerrmsg == false)
{
VRChatMessage MsgErr = new VRChatMessage(inputbox, "Error: Connection to the headset is lost! Waiting for reconnect...");
SendPacket(MsgErr);
}
await Task.Delay(3000);
}

Expand Down

0 comments on commit 6f7286f

Please sign in to comment.