You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.MD
+22-96Lines changed: 22 additions & 96 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,112 +4,38 @@ This plugin is only needed if you want to host a public SRV mode proxy instance.
4
4
5
5
## SRV ViaProxy
6
6
### Running ViaProxy in SRV mode
7
-
8
-
To use the SRV mode in ViaProxy you have to start it through the config.\
9
-
Here are The config options require to make a Public SRV mode.
10
-
```
7
+
To use the SRV mode in ViaProxy you have to change some config options.
8
+
```yaml
11
9
bind-address: 0.0.0.0:25568 # will translate to viaproxy.0-0-0-0.nip.io:25568
12
-
target-address: 127.0.0.1 # unused on srv mode.
13
-
target-version: 1.8.x # unused on srv mode.
10
+
target-address: 127.0.0.1 # unused in srv mode
11
+
target-version: 1.8.x # unused in srv mode
14
12
auth-method: OpenAuthMod
15
13
wildcard-domain-handling: PUBLIC
16
14
```
15
+
You have to replace `0.0.0.0:25568` with the address and port you want ViaProxy to run on.\
16
+
The `auth-method: openauthmod` is optional and enables [OpenAuthMod](https://github.com/RaphiMC/OpenAuthMod) authentication. Check the caution below.\
17
+
The `target-address` and `target-version` are required for ViaProxy to start but don't do anything in SRV mode.
18
+
19
+
> <b>[CAUTION]</b>\
20
+
> `auth-method: openauthmod` will not work for 1.7-1.7.10, 1.19.4+, Vanilla and Bedrock Edition.\
21
+
> Reason:\
22
+
> 1.7-1.7.10: OpenAuthMod is only available for 1.8+.\
23
+
> Bedrock: Forge and Fabric don't support Bedrock Edition.\
24
+
> 1.19.4+: OpenAuthMod was discontinued before release of 1.19.4.
17
25
18
-
You have to replace ``0.0.0.0:<bind port>`` with the port you want ViaProxy to run on.\
19
-
The ``auth-method: openauthmod`` is optional and enables the [OpenAuthMod](https://github.com/RaphiMC/OpenAuthMod) authentication. for 1.19.4 users, see the caution below.\
20
-
The ``target-address`` and ``target-version`` are required for ViaProxy to start but don't do anything in SRV mode.
21
-
> [!CAUTION]
22
-
> warning: auth-method: openauthmod will be not functional for 1.7-1.7.10, Vanilla 1.8-1.19.3, 1.19.4-1.21.1, and Bedrock Edition.\
23
-
> Reason: 1.7-1.7.10: OpenAuthMod is only available for 1.8.
24
-
> Bedrock: Forge or Fabric don't support Bedrock Edition.\
25
-
> 1.19.4+: OpenAuthMod discontinued before release of 1.19.4. use this option if you want to.
26
26
### Connecting to ViaProxy in SRV mode
27
27
To connect to ViaProxy in SRV mode you need a domain pointing to the IP of the server running ViaProxy.\
28
-
The subdomain ``viaproxy.`` is required for it to work.\
29
-
For local connections you can use ``viaproxy.127-0-0-1.nip.io``.
28
+
The subdomain `viaproxy.` is required for it to work.\
29
+
For local connections you can use `viaproxy.127-0-0-1.nip.io`.
30
30
31
-
To connect to a server through ViaProxy you have to prepend the ``server ip``, ``server port`` and ``version`` to your domain:
32
-
````
31
+
To connect to a server through ViaProxy you have to prepend the `server ip`, `server port` and `version` to your domain:
32
+
```
33
33
address_port_version.viaproxy.hostname
34
-
````
34
+
```
35
35
36
-
For example to connect to ``lenni0451.net:39999`` with the version ``C0.30-CPE`` you can use:
37
-
````
36
+
For example to connect to `lenni0451.net:39999` with the version `C0.30-CPE` you can use:
Check out the [ClassTransform](https://github.com/Lenni0451/ClassTransform/#usage) documentation for more information on how to use class transformers.
74
-
75
-
### Events
76
-
The only real way to interact with ViaProxy is through events.\
77
-
ViaProxy uses [LambdaEvents](https://github.com/Lenni0451/LambdaEvents) for event handling.\
78
-
You can register a listener using the ``register()`` method in the ``PluginManager.EVENT_MANAGER``:
79
-
````java
80
-
PluginManager.EVENT_MANAGER.register(this);
81
-
````
82
-
83
-
ViaProxy currently (at the time of writing) has the following events:
84
-
- Client2ProxyChannelInitializeEvent
85
-
- Client2ProxyHandlerCreationEvent
86
-
- ClientLoggedInEvent
87
-
- ConnectEvent
88
-
- ConsoleCommandEvent
89
-
- FillPlayerDataEvent
90
-
- GetDefaultPortEvent
91
-
- PostOptionsParseEvent
92
-
- PreConnectEvent
93
-
- PreOptionsParseEvent
94
-
- ProtocolHackInitEvent
95
-
- Proxy2ServerChannelInitializeEvent
96
-
- Proxy2ServerHandlerCreationEvent
97
-
- ProxyStartEvent
98
-
- ProxyStopEvent
99
-
- ResolveSrvEvent
100
-
- ViaLoadingEvent
101
-
102
-
Some events have pre- and post-states and some events are cancellable.
103
-
104
-
To listen to an event you have to add the ``@EventHandler`` annotation to the handler method and put the event as the only parameter:
0 commit comments