Skip to content

Commit f052240

Browse files
committed
feat: add global playercount calculation on join and quit
1 parent 7277292 commit f052240

File tree

4 files changed

+5
-2
lines changed

4 files changed

+5
-2
lines changed

.idea/kotlinc.xml

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ dependencies {
115115

116116
quark("com.squareup.okhttp3:okhttp:5.3.2")
117117

118-
implementation("dev.bypixel:LettuceWrapper:0.3.2+2f11145")
118+
implementation("dev.bypixel:LettuceWrapper:0.3.2+4cdda92")
119119
quark("io.lettuce:lettuce-core:7.2.1.RELEASE") {
120120
exclude(group = "org.jetbrains.kotlinx", module = "kotlinx-coroutines-core")
121121
exclude(group = "org.jetbrains.kotlinx", module = "kotlinx-coroutines-reactive")

src/main/kotlin/dev/bypixel/redivelocity/event/DisconnectListener.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ object DisconnectListener {
3434

3535
RediVelocityCoroutineScope.launch(Dispatchers.IO) {
3636
PlayercountUtil.setProxyPlayercount()
37+
PlayercountUtil.calcGlobalPlayercount()
3738
RediVelocity.instance.lettuceClient.sendMessage(JSONObject().apply {
3839
put("action", "UPDATE")
3940
}, "redivelocity:global-player-updates")

src/main/kotlin/dev/bypixel/redivelocity/event/PostLoginListener.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ object PostLoginListener {
8888
}, "redivelocity:global-player-updates")
8989

9090
PlayercountUtil.setProxyPlayercount()
91+
PlayercountUtil.calcGlobalPlayercount()
9192

9293
RediVelocity.instance.lettuceClient.sendMessage(JSONObject().apply {
9394
put("action", "POST_LOGIN")

0 commit comments

Comments
 (0)