-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added connection to room via Steam. Awfully glitchy.
- Loading branch information
Showing
4 changed files
with
67 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
tMediator/src/com/seroperson/mediator/utils/Connector.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package com.seroperson.mediator.utils; | ||
|
||
import com.seroperson.mediator.tori.stuff.Server; | ||
|
||
import java.awt.*; | ||
import java.net.URI; | ||
|
||
public class Connector { | ||
public static void connectToServer(Server server) | ||
{ | ||
final String room = server.getRoom(); | ||
if (!room.equals("unknown room")) { | ||
try { | ||
final String uri = "steam://run/248570//+connect%20join%20" + room; | ||
System.out.println(uri); | ||
Desktop.getDesktop().browse(new URI(uri)); | ||
} catch (Exception ex) { | ||
System.err.println(ex.getMessage()); | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters