aboutsummaryrefslogtreecommitdiff
path: root/src/scalevalapokalypsi/Server/Server.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/scalevalapokalypsi/Server/Server.scala')
-rw-r--r--src/scalevalapokalypsi/Server/Server.scala12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/scalevalapokalypsi/Server/Server.scala b/src/scalevalapokalypsi/Server/Server.scala
index bfb0893..2ea8bd4 100644
--- a/src/scalevalapokalypsi/Server/Server.scala
+++ b/src/scalevalapokalypsi/Server/Server.scala
@@ -56,8 +56,7 @@ class Server(
this.writeObservations()
if this.canExecuteTurns then
this.clients.foreach(_.giveTurn())
- //this.writeClientDataToClients()
- //this.writeObservations()
+ this.adventure.foreach(_.takeNpcTurns())
this.clients.foreach(c =>
this.writeToClient(this.turnStartInfo(c), c)
)
@@ -123,12 +122,9 @@ class Server(
val target = c.player.flatMap(_.getSingEffectTarget)
target.foreach(t =>
if c.player.exists(_.isSinging) && !c.clientHasSong then
- this.writeToClient(
- s"${SING_INDICATOR}${t.getVerseAgainst}\r\n",
- // TODO: store the verse and check how close client input is when determining sing quality
- c
- )
- c.startSong()
+ val verse = t.getVerseAgainst
+ this.writeToClient(s"${SING_INDICATOR}$verse\r\n", c)
+ c.startSong(verse)
)
)