What’s the best way to do this. The idea is to have the player enter values in several different pieces and have their sum appear on another piece in a different area/zone of the same map?
Various options to sum the values, assuming that they are stored in Dynamic Properties on each piece. In each case, display the result in a Text Label on the target piece. Here’s 3 I can come up with:
-
Sum up the entered values into a Global Property as they are amended on the pieces.
-
Use some variant of SumMap() to sum the value. Use the Expression editor to get help with this (calculator icon next to the value field, e.g. in a Set Global Property trait.
-
From the target piece, form an Attachment to each of the different pieces. You can then access the values directly. This is easy when the attachment is formed 1-1, using properties of the form
<AttachmentName>_PropertyName
. For 1-many, you’ll need to use GetAttachProperty().