author | Wuzzy |
Thu, 25 May 2023 13:05:11 +0000 | |
changeset 2232 | 09bf7a4d5411 |
parent 2218 | eb6eef27205c |
permissions | -rw-r--r-- |
308
06767accef5a
Edited wiki page HWPlaySchemeSyntax through web user interface.
vittorio.giovara@gmail.com
parents:
307
diff
changeset
|
1 |
#summary The Hedgewars URL scheme handler |
307
1fff0c4471bc
Created wiki page through web user interface.
vittorio.giovara@gmail.com
parents:
diff
changeset
|
2 |
|
1495 | 3 |
= Hedgewars server links = |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
4 |
== Overview == |
2218
eb6eef27205c
HWPlaySchemeSyntax: Remove "room=", it is not actually supported
Wuzzy
parents:
2045
diff
changeset
|
5 |
Hedgewars supports special links for Hedgewars servers. You can join a server by using a simple link. These links always start with “`hwplay://`” and look like this: |
1492 | 6 |
|
7 |
`hwplay://hedgewars.example.org` |
|
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
8 |
|
1495 | 9 |
If your system is set-up to handle `hwplay` URLs, it will start Hedgewars and puts you immediately in the server. |
1492 | 10 |
|
1495 | 11 |
The following link goes to the official Hedgewars server, you can try it out right now: |
1492 | 12 |
|
13 |
[hwplay://netserver.hedgewars.org] |
|
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
14 |
|
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
15 |
== Usage == |
1492 | 16 |
Your browser and other software needs to learn first how to deal with `hwplay`. |
1493 | 17 |
We recommend to first click on “Assign file types” in the Settings menu, Advanced tab, this should set things up automatically for you. |
1492 | 18 |
|
1963 | 19 |
If an application (like a browser) is confused about `hwplay`, point it to the Hedgewars program (`hedgewars.exe` on Windows, `hedgewars` on GNU/Linux and macOS). |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
20 |
|
732 | 21 |
Hedgewars itself also can use a `hwplay` URL as a command-line argument. See [CommandLineOptions#Frontend] for more information. |
22 |
||
1492 | 23 |
`hwplay` URLs are of course optional, you can join any server from the main menu by selecting the network game, then “local network”, then by selecting a server from the list or entering its address directly after clicking on the “Connect to” button. |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
24 |
|
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
25 |
== Creating `hwplay` URLs == |
1501 | 26 |
When you are about to start a server in Hedgewars (Main menu → Network game → Local network → Start server), Hedgewars will create a `hwplay` URL for you. You can copy it into the clipboard if you click on the “invite” button. |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
27 |
|
1492 | 28 |
Note the generated URL might only work in your LAN and not world wide, so please check the IP address. You can obtain your Internet IP address on http://myip.is/ (for example). |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
29 |
|
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
30 |
Of course, you can also try to create the URLs from hand (see below). |
307
1fff0c4471bc
Created wiki page through web user interface.
vittorio.giovara@gmail.com
parents:
diff
changeset
|
31 |
|
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
32 |
== Syntax == |
1495 | 33 |
`hwplay` is an unofficial URL scheme supported by Hedgewars. The syntax of the “hwplay” URL scheme is: |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
34 |
|
2218
eb6eef27205c
HWPlaySchemeSyntax: Remove "room=", it is not actually supported
Wuzzy
parents:
2045
diff
changeset
|
35 |
`hwplay://<HOST>[:<PORT NUMBER>]` |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
36 |
|
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
37 |
Parts in square brackets are optional. |
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
38 |
Parts enclosed in less-then and greater-than signs are parameters, where |
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
39 |
|
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
40 |
* `<HOST>` is the IP address or host name of the server |
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
41 |
* `<PORT NUMBER>` stands for the TCP port number of the server |
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
42 |
|
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
43 |
If the port number is omitted, Hedgewars assumes the default port 46631. |
731 | 44 |
|
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
45 |
== Examples == |
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
46 |
Here are some example `hwplay` URLs: |
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
47 |
|
1492 | 48 |
* [hwplay://netserver.hedgewars.org]: Points to the lobby of the official server. This is the same as if you'd click on the “official server” button in the main menu |
730
917fd6b57b16
HWPlaySchemeSyntax: (hopefully) more complete explanation of the HWPLAY URLs
Wuzzy
parents:
308
diff
changeset
|
49 |
* `hwplay://192.168.43.6:54321`: Points to the lobby on a LAN server with IP 192.168.42.6, port number 54321 |
1501 | 50 |
* `hwplay://example.com:59000`: Points to the server “example.com”, port number 59000 |