Skip to content

Commit 0327d8d

Browse files
committed
fix(plugin): use correct plugin uuid, not the one from last year
1 parent 0dd6431 commit 0327d8d

File tree

2 files changed

+15
-7
lines changed

2 files changed

+15
-7
lines changed

plugin/src/client/sc/plugin2021/AbstractClient.kt

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,15 @@ abstract class AbstractClient @Throws(IOException::class) constructor(
103103
}
104104
}
105105

106-
fun joinAnyGame() =
107-
client.joinRoomRequest(gameType)
106+
private fun start() {
107+
client.start()
108+
client.addListener(this)
109+
}
110+
111+
fun joinAnyGame() {
112+
start()
113+
client.joinRoomRequest(gameType)
114+
}
108115

109116
override fun onGameJoined(roomId: String) {}
110117
override fun onGamePrepared(response: PrepareGameProtocolMessage) {}
@@ -123,6 +130,8 @@ abstract class AbstractClient @Throws(IOException::class) constructor(
123130
}
124131
}
125132

126-
fun joinPreparedGame(reservation: String) =
127-
client.joinPreparedGame(reservation)
133+
fun joinPreparedGame(reservation: String) {
134+
start()
135+
client.joinPreparedGame(reservation)
136+
}
128137
}

plugin/src/server/sc/plugin2021/GamePlugin.kt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,11 @@ package sc.plugin2021
33
import sc.api.plugins.IGameInstance
44
import sc.api.plugins.IGamePlugin
55
import sc.api.plugins.host.IGamePluginHost
6-
import sc.plugin2020.GamePlugin
7-
import sc.plugin2020.util.Configuration.classesToRegister
6+
import sc.plugin2021.util.Configuration.classesToRegister
87
import sc.plugins.PluginDescriptor
98
import sc.shared.ScoreDefinition
109

11-
@PluginDescriptor(name = "Blokus", uuid = GamePlugin.PLUGIN_UUID, author = GamePlugin.PLUGIN_AUTHOR)
10+
@PluginDescriptor(name = "Blokus", uuid = "swc_2021_blokus", author = "")
1211
class GamePlugin: IGamePlugin {
1312

1413
companion object {

0 commit comments

Comments
 (0)