[messages] [Module Design] Report Action problem
the_ar at freemail.gr
Tue Nov 15 09:05:19 MST 2011
Before I tell you about my problem let me thank you for the awesome job
you 're doing. :D I have found answers to almost all of my questions
by digging into those forums. :D :D :D Keep up the good work.
To my problem now. I'm creating an new module for Hannibal: Rome vs
Carthage. I have added the Replace with Other trait to a piece (Basic
Piece Name: Roman PC) with a Keyboard command to Ctrl F. This piece is
replaced by a piece named Carthaginian PC. Since I want to report this
action I added a Report Action Trait that also activates with Ctrl F.
The report format is this: $playerName$ ($playerSide$) flipped
$oldPieceName$ to $newPieceName$ in $oldLocation$ * . What I'm trying to
get here is something like this: Player (Side) flipped __Roman PC__ to
__Carthaginian PC__ in location.
The problem is that the newPieceName property stays to Roman PC. I can
get the why: The trait affects only the piece it is on and by replacing
it we create a new piece. By pressing Ctrl F the old piece's
newPieceName remains the same and the piece is removed from the board.
How can I make the Report Action trait to report the new piece's name? I
would like to avoid "hard coding" the new piece's name instead of using
a property value.
Read this topic online here:
More information about the messages