aboutsummaryrefslogtreecommitdiff
path: root/src/scalevalapokalypsi/Model/Entities/Player.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/scalevalapokalypsi/Model/Entities/Player.scala')
-rw-r--r--src/scalevalapokalypsi/Model/Entities/Player.scala5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/scalevalapokalypsi/Model/Entities/Player.scala b/src/scalevalapokalypsi/Model/Entities/Player.scala
index f231c28..cac5bf1 100644
--- a/src/scalevalapokalypsi/Model/Entities/Player.scala
+++ b/src/scalevalapokalypsi/Model/Entities/Player.scala
@@ -41,7 +41,7 @@ class Player(name: String, initialLocation: Area) extends Entity(name, initialLo
*/
def setSingEffect(effect: SingEffect): Unit =
this.pendingSingEffect = Some(effect)
-
+
def getSingEffectTarget: Option[Entity] =
this.pendingSingEffect.map(_.target)
@@ -66,8 +66,7 @@ class Player(name: String, initialLocation: Area) extends Entity(name, initialLo
val quality =
s"Laulu on ${qualityDescriptions(0)} ja sen vaikutus on ${qualityDescriptions(1)}."
val event = res.map(ev => Event(
- ev.target,
- s"$quality\n${ev.inFirstPerson}",
+ ev.inFirstPersons.map((k, v) => (k, s"$quality\n$v")),
s"$quality\n${ev.inThirdPerson}"
))
event.foreach(this.location.observeEvent(_))