summaryrefslogtreecommitdiff
path: root/sw-bot/src
diff options
context:
space:
mode:
authorJoffrey Bion <joffrey.bion@booking.com>2020-05-21 13:46:30 +0200
committerJoffrey Bion <joffrey.bion@booking.com>2020-05-21 13:58:28 +0200
commit4f3eec40a87c5e4f52fc89238642dd7a17650540 (patch)
treec910270b5477975100bfd82852d784409346f334 /sw-bot/src
parentPrevent bots with already used names (diff)
downloadseven-wonders-4f3eec40a87c5e4f52fc89238642dd7a17650540.tar.gz
seven-wonders-4f3eec40a87c5e4f52fc89238642dd7a17650540.tar.bz2
seven-wonders-4f3eec40a87c5e4f52fc89238642dd7a17650540.zip
Allow custom player icons
Diffstat (limited to 'sw-bot/src')
-rw-r--r--sw-bot/src/main/kotlin/org/luxons/sevenwonders/bot/SevenWondersBot.kt3
1 files changed, 2 insertions, 1 deletions
diff --git a/sw-bot/src/main/kotlin/org/luxons/sevenwonders/bot/SevenWondersBot.kt b/sw-bot/src/main/kotlin/org/luxons/sevenwonders/bot/SevenWondersBot.kt
index deb7e237..89630b63 100644
--- a/sw-bot/src/main/kotlin/org/luxons/sevenwonders/bot/SevenWondersBot.kt
+++ b/sw-bot/src/main/kotlin/org/luxons/sevenwonders/bot/SevenWondersBot.kt
@@ -11,6 +11,7 @@ import org.luxons.sevenwonders.model.Action
import org.luxons.sevenwonders.model.MoveType
import org.luxons.sevenwonders.model.PlayerMove
import org.luxons.sevenwonders.model.PlayerTurnInfo
+import org.luxons.sevenwonders.model.api.actions.Icon
import org.luxons.sevenwonders.model.resources.noTransactions
import kotlin.random.Random
import kotlin.time.Duration
@@ -34,7 +35,7 @@ class SevenWondersBot(
suspend fun play(serverHost: String, gameId: Long) = withTimeout(botConfig.globalTimeout) {
val session = client.connect(serverHost)
botDelay()
- session.chooseName(displayName)
+ session.chooseName(displayName, Icon("desktop"))
botDelay()
session.joinGame(gameId)
botDelay()
bgstack15