Note:
I have two Managers: First one creates 2d block upon click. The other one, upon click, grabs a block for dragging. The reason I need them to run in specific order is because newly created block should be instantly grabbed.
Original question:
I have two managers that respond to the InputManager events.
They both should do something when InputManager
raises mouse0DownEvent
.
I need the BlockManager delegate to happen first.
I have DragManager
and BlockManager
that subscribe to same event in InputManager
: mouse0DownEvent
, but this does not give me controll over the execution order.
My ideas:
I am thinking of creating separate event in
InputManager
, but thenInputManager
would have to know about the other managers which would cause dehermetization.I could also create separate manager to wrap
InputManager
events but this would look like overengineering to me.
Whould would be a unity way of doing this?
Thanks!