Howdy,
What are the relative merits and drawbacks of the styles of issuing a Key Command to a piece ending movement on a map?
The piece receiving the command could be ending its movement on one of several maps in the module, and different actions are desired depending on which map the movement ends.
I’m currently thinking of two ways (or styles) of doing this:
-
Each map issues its own Key Command, for example MapA issues “OnMoveMapA”. Then the pieces have traits such as Trigger Actions that listen for such commands to perform the desired action depending on the command received. OR
-
All maps issue the same command such as “OnMove”, and the pieces have traits such as Trigger Actions with a Trigger when properties match expression that filters for which map the piece ended its movement on to determine which action to perform.
So for style 1 a Trigger Action could be watching for a list of possible Key Commands. For style 2 a Trigger Action could have a rather complex property match expression filter.
As I write this I’m thinking that style 1 would likely be easier to construct, interpret and debug.
I would appreciate the thoughts and comments from experienced module designers.