mirror of
https://github.com/ViaVersion/VIAaaS.git
synced 2024-11-21 11:55:15 +01:00
updated some deps, still not updated to 1.20.2
This commit is contained in:
parent
ab7d07a444
commit
2e7faf1ac9
@ -15,7 +15,7 @@ buildscript {
|
|||||||
plugins {
|
plugins {
|
||||||
`java-library`
|
`java-library`
|
||||||
application
|
application
|
||||||
kotlin("jvm") version "1.8.10"
|
kotlin("jvm") version "1.9.10"
|
||||||
id("maven-publish")
|
id("maven-publish")
|
||||||
id("com.github.ben-manes.versions") version "0.47.0"
|
id("com.github.ben-manes.versions") version "0.47.0"
|
||||||
id("com.github.johnrengelman.shadow") version "8.1.1"
|
id("com.github.johnrengelman.shadow") version "8.1.1"
|
||||||
@ -60,24 +60,24 @@ dependencies {
|
|||||||
implementation(kotlin("stdlib-jdk8"))
|
implementation(kotlin("stdlib-jdk8"))
|
||||||
implementation(kotlin("reflect"))
|
implementation(kotlin("reflect"))
|
||||||
|
|
||||||
val vvVer = "4.7.1-SNAPSHOT"
|
val vvVer = "4.9.0-23w40a-SNAPSHOT"
|
||||||
val vbVer = "4.7.1-SNAPSHOT"
|
val vbVer = "4.9.0-23w40a-SNAPSHOT"
|
||||||
val vrVer = "4937bab"
|
val vrVer = "3.0.3-SNAPSHOT"
|
||||||
implementation("com.viaversion:viaversion:$vvVer") { isTransitive = false }
|
implementation("com.viaversion:viaversion:$vvVer") { isTransitive = false }
|
||||||
implementation("com.viaversion:viabackwards:$vbVer") { isTransitive = false }
|
implementation("com.viaversion:viabackwards:$vbVer") { isTransitive = false }
|
||||||
implementation("com.github.ViaVersion.ViaRewind:viarewind-all:$vrVer") { isTransitive = false }
|
implementation("com.viaversion:viarewind-universal:$vrVer") { isTransitive = false }
|
||||||
implementation("net.raphimc:ViaAprilFools:2.0.8-SNAPSHOT")
|
implementation("net.raphimc:ViaAprilFools:2.0.10-SNAPSHOT")
|
||||||
implementation("net.raphimc:ViaLegacy:2.2.18-SNAPSHOT")
|
implementation("net.raphimc:ViaLegacy:2.2.21-SNAPSHOT")
|
||||||
|
|
||||||
val nettyVer = "4.1.93.Final"
|
val nettyVer = "4.1.99.Final"
|
||||||
implementation("io.netty:netty-handler-proxy:$nettyVer")
|
implementation("io.netty:netty-handler-proxy:$nettyVer")
|
||||||
implementation("io.netty:netty-resolver-dns:$nettyVer")
|
implementation("io.netty:netty-resolver-dns:$nettyVer")
|
||||||
implementation("io.netty:netty-transport-native-epoll:$nettyVer:linux-aarch_64")
|
implementation("io.netty:netty-transport-native-epoll:$nettyVer:linux-aarch_64")
|
||||||
implementation("io.netty:netty-transport-native-epoll:$nettyVer:linux-x86_64")
|
implementation("io.netty:netty-transport-native-epoll:$nettyVer:linux-x86_64")
|
||||||
implementation("io.netty:netty-tcnative-boringssl-static:2.0.61.Final:linux-aarch_64")
|
implementation("io.netty:netty-tcnative-boringssl-static:2.0.61.Final:linux-aarch_64")
|
||||||
implementation("io.netty:netty-tcnative-boringssl-static:2.0.61.Final:linux-x86_64")
|
implementation("io.netty:netty-tcnative-boringssl-static:2.0.61.Final:linux-x86_64")
|
||||||
implementation("io.netty.incubator:netty-incubator-transport-native-io_uring:0.0.21.Final:linux-aarch_64")
|
implementation("io.netty.incubator:netty-incubator-transport-native-io_uring:0.0.23.Final:linux-aarch_64")
|
||||||
implementation("io.netty.incubator:netty-incubator-transport-native-io_uring:0.0.21.Final:linux-x86_64")
|
implementation("io.netty.incubator:netty-incubator-transport-native-io_uring:0.0.23.Final:linux-x86_64")
|
||||||
|
|
||||||
implementation("com.google.guava:guava:32.0.1-jre")
|
implementation("com.google.guava:guava:32.0.1-jre")
|
||||||
implementation("com.velocitypowered:velocity-native:3.2.0-SNAPSHOT")
|
implementation("com.velocitypowered:velocity-native:3.2.0-SNAPSHOT")
|
||||||
@ -96,7 +96,7 @@ dependencies {
|
|||||||
implementation("org.jline:jline-terminal-jansi:3.23.0")
|
implementation("org.jline:jline-terminal-jansi:3.23.0")
|
||||||
implementation("org.slf4j:slf4j-api:$slf4jVer")
|
implementation("org.slf4j:slf4j-api:$slf4jVer")
|
||||||
|
|
||||||
val ktorVersion = "2.3.2"
|
val ktorVersion = "2.3.5"
|
||||||
implementation("io.ktor:ktor-network-tls-certificates-jvm:$ktorVersion")
|
implementation("io.ktor:ktor-network-tls-certificates-jvm:$ktorVersion")
|
||||||
implementation("io.ktor:ktor-server-websockets:$ktorVersion")
|
implementation("io.ktor:ktor-server-websockets:$ktorVersion")
|
||||||
implementation("io.ktor:ktor-server-netty-jvm:$ktorVersion")
|
implementation("io.ktor:ktor-server-netty-jvm:$ktorVersion")
|
||||||
|
@ -9,7 +9,7 @@ import java.util.Map;
|
|||||||
|
|
||||||
public class AspirinViaConfig extends AbstractViaConfig {
|
public class AspirinViaConfig extends AbstractViaConfig {
|
||||||
{
|
{
|
||||||
reloadConfig();
|
reload();
|
||||||
}
|
}
|
||||||
|
|
||||||
public AspirinViaConfig() {
|
public AspirinViaConfig() {
|
||||||
|
@ -13,7 +13,7 @@ public class AspirinBackwards implements ViaBackwardsPlatform {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void init() {
|
public void init() {
|
||||||
init(getDataFolder());
|
init(getDataFolder().toPath().resolve("config.yml").toFile());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -5,7 +5,6 @@ import com.viaversion.viaversion.api.protocol.version.ProtocolVersion;
|
|||||||
import com.viaversion.viaversion.libs.fastutil.ints.IntLinkedOpenHashSet;
|
import com.viaversion.viaversion.libs.fastutil.ints.IntLinkedOpenHashSet;
|
||||||
import com.viaversion.viaversion.libs.fastutil.ints.IntSortedSet;
|
import com.viaversion.viaversion.libs.fastutil.ints.IntSortedSet;
|
||||||
import com.viaversion.viaversion.libs.gson.JsonObject;
|
import com.viaversion.viaversion.libs.gson.JsonObject;
|
||||||
import de.gerrygames.viarewind.velocity.VersionInfo;
|
|
||||||
|
|
||||||
public class AspirinInjector implements ViaInjector {
|
public class AspirinInjector implements ViaInjector {
|
||||||
@Override
|
@Override
|
||||||
@ -33,9 +32,7 @@ public class AspirinInjector implements ViaInjector {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public JsonObject getDump() {
|
public JsonObject getDump() {
|
||||||
var obj = new JsonObject();
|
return new JsonObject();
|
||||||
obj.addProperty("ViaRewind version", VersionInfo.VERSION);
|
|
||||||
return obj;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
package com.viaversion.aas.platform;
|
package com.viaversion.aas.platform;
|
||||||
|
|
||||||
import de.gerrygames.viarewind.api.ViaRewindConfigImpl;
|
import com.viaversion.viarewind.api.ViaRewindPlatform;
|
||||||
import de.gerrygames.viarewind.api.ViaRewindPlatform;
|
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
@ -14,6 +13,6 @@ public class AspirinRewind implements ViaRewindPlatform {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void init() {
|
public void init() {
|
||||||
init(new ViaRewindConfigImpl(new File("config/viarewind.yml")));
|
init(new File("config/viarewind.yml"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -14,6 +14,7 @@ public class FutureTask implements PlatformTask<Future<?>> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@Deprecated
|
||||||
public @Nullable Future<?> getObject() {
|
public @Nullable Future<?> getObject() {
|
||||||
return object;
|
return object;
|
||||||
}
|
}
|
||||||
|
@ -156,7 +156,7 @@ object AspirinServer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun currentPlayers(): Int {
|
fun currentPlayers(): Int {
|
||||||
return Via.getManager().connectionManager.connections.filter { it.protocolInfo.state == State.PLAY }.count()
|
return Via.getManager().connectionManager.connections.filter { it.protocolInfo.serverState == State.PLAY }.count()
|
||||||
}
|
}
|
||||||
|
|
||||||
suspend fun updaterCheckMessage(): String {
|
suspend fun updaterCheckMessage(): String {
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
package com.viaversion.aas
|
package com.viaversion.aas
|
||||||
|
|
||||||
import com.viaversion.aas.command.VIAaaSConsole
|
import com.viaversion.aas.command.VIAaaSConsole
|
||||||
|
import com.viaversion.aas.config.VIAaaSConfig
|
||||||
import com.viaversion.aas.platform.AspirinAprilFools
|
import com.viaversion.aas.platform.AspirinAprilFools
|
||||||
import com.viaversion.aas.platform.AspirinBackwards
|
import com.viaversion.aas.platform.AspirinBackwards
|
||||||
import com.viaversion.aas.platform.AspirinLegacy
|
import com.viaversion.aas.platform.AspirinLegacy
|
||||||
@ -8,6 +9,7 @@ import com.viaversion.aas.platform.AspirinPlatform
|
|||||||
import com.viaversion.aas.platform.AspirinRewind
|
import com.viaversion.aas.platform.AspirinRewind
|
||||||
import com.viaversion.aas.protocol.registerAspirinProtocols
|
import com.viaversion.aas.protocol.registerAspirinProtocols
|
||||||
import com.viaversion.aas.web.ViaWebApp
|
import com.viaversion.aas.web.ViaWebApp
|
||||||
|
import com.viaversion.viaversion.api.Via
|
||||||
import com.viaversion.viaversion.api.protocol.version.ProtocolVersion
|
import com.viaversion.viaversion.api.protocol.version.ProtocolVersion
|
||||||
import io.ktor.server.application.*
|
import io.ktor.server.application.*
|
||||||
import kotlinx.coroutines.CoroutineScope
|
import kotlinx.coroutines.CoroutineScope
|
||||||
@ -61,6 +63,7 @@ private fun initVia() {
|
|||||||
AspirinBackwards().init()
|
AspirinBackwards().init()
|
||||||
AspirinAprilFools().init()
|
AspirinAprilFools().init()
|
||||||
AspirinLegacy().init()
|
AspirinLegacy().init()
|
||||||
|
Via.getManager().configurationProvider.register(VIAaaSConfig)
|
||||||
}
|
}
|
||||||
|
|
||||||
ProtocolVersion.register(autoProtocolId, "AUTO")
|
ProtocolVersion.register(autoProtocolId, "AUTO")
|
||||||
|
@ -3,13 +3,13 @@ package com.viaversion.aas.command
|
|||||||
import com.viaversion.viaversion.api.command.ViaCommandSender
|
import com.viaversion.viaversion.api.command.ViaCommandSender
|
||||||
|
|
||||||
object ReloadCommand : Command {
|
object ReloadCommand : Command {
|
||||||
override val info = "Alias for 'viaversion aasreload'"
|
override val info = "Alias for 'viaversion reload'"
|
||||||
|
|
||||||
override fun suggest(sender: ViaCommandSender, alias: String, args: List<String>): List<String> {
|
override fun suggest(sender: ViaCommandSender, alias: String, args: List<String>): List<String> {
|
||||||
return emptyList()
|
return emptyList()
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun execute(sender: ViaCommandSender, alias: String, args: List<String>) {
|
override fun execute(sender: ViaCommandSender, alias: String, args: List<String>) {
|
||||||
ViaAspirinCommand.execute(sender, alias, listOf("aasreload"))
|
ViaAspirinCommand.execute(sender, alias, listOf("reload"))
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,6 +1,5 @@
|
|||||||
package com.viaversion.aas.command
|
package com.viaversion.aas.command
|
||||||
|
|
||||||
import com.viaversion.aas.command.sub.AspirinReloadSubCommand
|
|
||||||
import com.viaversion.aas.command.sub.ConnectionsSubCommand
|
import com.viaversion.aas.command.sub.ConnectionsSubCommand
|
||||||
import com.viaversion.aas.command.sub.StopSubCommand
|
import com.viaversion.aas.command.sub.StopSubCommand
|
||||||
import com.viaversion.aas.command.sub.VIAaaSSubCommand
|
import com.viaversion.aas.command.sub.VIAaaSSubCommand
|
||||||
@ -14,7 +13,6 @@ object ViaAspirinCommand : ViaCommandHandler(), Command {
|
|||||||
registerSubCommand(StopSubCommand)
|
registerSubCommand(StopSubCommand)
|
||||||
registerSubCommand(VIAaaSSubCommand)
|
registerSubCommand(VIAaaSSubCommand)
|
||||||
registerSubCommand(ConnectionsSubCommand)
|
registerSubCommand(ConnectionsSubCommand)
|
||||||
registerSubCommand(AspirinReloadSubCommand)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun suggest(sender: ViaCommandSender, alias: String, args: List<String>): List<String> {
|
override fun suggest(sender: ViaCommandSender, alias: String, args: List<String>): List<String> {
|
||||||
|
@ -1,16 +0,0 @@
|
|||||||
package com.viaversion.aas.command.sub
|
|
||||||
|
|
||||||
import com.viaversion.aas.config.VIAaaSConfig
|
|
||||||
import com.viaversion.viaversion.api.command.ViaCommandSender
|
|
||||||
import com.viaversion.viaversion.api.command.ViaSubCommand
|
|
||||||
|
|
||||||
object AspirinReloadSubCommand : ViaSubCommand() {
|
|
||||||
override fun name() = "aasreload"
|
|
||||||
override fun description() = "Reloads VIAaaS config"
|
|
||||||
|
|
||||||
override fun execute(sender: ViaCommandSender, args: Array<String>): Boolean {
|
|
||||||
VIAaaSConfig.reloadConfig()
|
|
||||||
sender.sendMessage("Reloaded VIAaaS config. Some configurations may need a restart.")
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
}
|
|
@ -13,7 +13,7 @@ import java.net.URI
|
|||||||
import java.net.URL
|
import java.net.URL
|
||||||
import java.util.*
|
import java.util.*
|
||||||
|
|
||||||
object VIAaaSConfig : Config(File("config/viaaas.yml")) {
|
object VIAaaSConfig : Config(File("config/viaaas.yml")), com.viaversion.viaversion.api.configuration.Config {
|
||||||
var defaultParameters: Map<Int, AddressParser> = emptyMap()
|
var defaultParameters: Map<Int, AddressParser> = emptyMap()
|
||||||
var bindAddresses = emptyList<HostAndPort>()
|
var bindAddresses = emptyList<HostAndPort>()
|
||||||
var hostName: List<String> = emptyList()
|
var hostName: List<String> = emptyList()
|
||||||
@ -37,11 +37,11 @@ object VIAaaSConfig : Config(File("config/viaaas.yml")) {
|
|||||||
var compressionLevel: Int = 6
|
var compressionLevel: Int = 6
|
||||||
|
|
||||||
init {
|
init {
|
||||||
reloadConfig()
|
reload()
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun reloadConfig() {
|
override fun reload() {
|
||||||
super.reloadConfig()
|
super.reload()
|
||||||
reloadFields()
|
reloadFields()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2,15 +2,14 @@ package com.viaversion.aas.handler
|
|||||||
|
|
||||||
import com.viaversion.aas.codec.FrameCodec
|
import com.viaversion.aas.codec.FrameCodec
|
||||||
import com.viaversion.aas.codec.MinecraftCodec
|
import com.viaversion.aas.codec.MinecraftCodec
|
||||||
import com.viaversion.viaversion.api.protocol.version.ProtocolVersion
|
|
||||||
import com.viaversion.viaversion.connection.UserConnectionImpl
|
import com.viaversion.viaversion.connection.UserConnectionImpl
|
||||||
import com.viaversion.viaversion.protocol.ProtocolPipelineImpl
|
import com.viaversion.viaversion.protocol.ProtocolPipelineImpl
|
||||||
import io.netty.channel.Channel
|
import io.netty.channel.Channel
|
||||||
import io.netty.channel.ChannelInitializer
|
import io.netty.channel.ChannelInitializer
|
||||||
import io.netty.handler.timeout.ReadTimeoutHandler
|
import io.netty.handler.timeout.ReadTimeoutHandler
|
||||||
import net.raphimc.vialegacy.api.LegacyProtocolVersion
|
import net.raphimc.vialegacy.api.LegacyProtocolVersion
|
||||||
|
import net.raphimc.vialegacy.api.protocol.PreNettyBaseProtocol
|
||||||
import net.raphimc.vialegacy.netty.PreNettyLengthCodec
|
import net.raphimc.vialegacy.netty.PreNettyLengthCodec
|
||||||
import net.raphimc.vialegacy.protocols.release.protocol1_7_2_5to1_6_4.baseprotocols.PreNettyBaseProtocol
|
|
||||||
import java.net.InetSocketAddress
|
import java.net.InetSocketAddress
|
||||||
import java.net.URI
|
import java.net.URI
|
||||||
import java.util.concurrent.TimeUnit
|
import java.util.concurrent.TimeUnit
|
||||||
|
@ -70,7 +70,6 @@ object AspirinPlatform : ViaPlatform<UUID> {
|
|||||||
override fun getLogger() = logger
|
override fun getLogger() = logger
|
||||||
override fun getOnlinePlayers(): Array<ViaCommandSender> = emptyArray()
|
override fun getOnlinePlayers(): Array<ViaCommandSender> = emptyArray()
|
||||||
override fun isPluginEnabled() = true
|
override fun isPluginEnabled() = true
|
||||||
override fun getConfigurationProvider() = conf
|
|
||||||
override fun getPlatformName() = "VIAaaS"
|
override fun getPlatformName() = "VIAaaS"
|
||||||
override fun getPlatformVersion() = AspirinServer.version
|
override fun getPlatformVersion() = AspirinServer.version
|
||||||
override fun getPluginVersion() = VersionInfo.VERSION
|
override fun getPluginVersion() = VersionInfo.VERSION
|
||||||
|
Loading…
Reference in New Issue
Block a user