Skip to content

Commit

Permalink
Merge pull request #26 from VanOord/fix-engine-order
Browse files Browse the repository at this point in the history
fix
  • Loading branch information
Pietervanhalem committed Jan 18, 2021
2 parents 26379e2 + c2ee48c commit befa547
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions openclsim/model/move_activity.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,23 @@ class MoveActivity(GenericActivity):
by default will be to start immediately
"""

def __init__(self, mover, destination, duration=None, show=False, *args, **kwargs):
def __init__(
self,
mover,
destination,
duration=None,
show=False,
engine_order=1,
*args,
**kwargs
):
super().__init__(*args, **kwargs)
"""Initialization"""
self.destination = destination
self.mover = mover
self.duration = duration
self.print = show
self.engine_order = engine_order

def main_process_function(self, activity_log, env):
"""
Expand Down Expand Up @@ -71,7 +81,7 @@ def main_process_function(self, activity_log, env):
self.mover.activity_id = activity_log.id
yield from self.mover.move(
destination=self.destination,
engine_order=1,
engine_order=self.engine_order,
duration=self.duration,
)

Expand Down

0 comments on commit befa547

Please sign in to comment.