From 05a3a88f83a845e58eca65f48f96eb470cdbf192 Mon Sep 17 00:00:00 2001 From: Pascal Date: Wed, 29 Jan 2020 01:19:11 -0600 Subject: [PATCH] [fix] fixed behaviour timeline map parsing - added missing config.tickfactor when a map is used --- src/main/scala/scim/components/Parser.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/scala/scim/components/Parser.scala b/src/main/scala/scim/components/Parser.scala index 8754ff6..4ec51fc 100644 --- a/src/main/scala/scim/components/Parser.scala +++ b/src/main/scala/scim/components/Parser.scala @@ -156,8 +156,8 @@ class SimulationConfigParser(input: Map[String, Any], simulationBehaviours: Simu if (!simulationBehaviours.get(name).isEmpty) funcPointer = Some((simulationBehaviours.get(name).get, args)) val output: mutable.Map[Int, Option[(SimulationBehaviour, Option[FunctionArgs])]] = mutable.Map() timeLineVector.map(tuple => { - output(tuple._1) = funcPointer - if (!tuple._2.isEmpty && !output.contains(tuple._2.get)) output(tuple._2.get) = None // only set None when it doesnt exist yet + output(tuple._1 * config.tickfactor) = funcPointer + if (!tuple._2.isEmpty && !output.contains(tuple._2.get)) output(tuple._2.get * config.tickfactor) = None // only set None when it doesnt exist yet }) output.toMap }