[messages] [Module Design] Counting and indicating controlled regions

rrvs spideratj at aol.com
Sun Feb 5 15:41:28 CET 2017

Hm, I don't see the attached image for some reason.

"buttonjock" wrote:
> There are 18 images attached here, one for each faction and one for no
> control. I have highlighted image 2, with the level name "Aquitani"

This sounds fine... 18 levels then in an always active layer called:
Layer - Control Faction, if I'm getting that right.

There may be an easier way to do this, for that many factions at least,
but I'm not coming up with one at the moment.  And with 17 factions,
compiling them all into a single multi-action button might be too much
happening at once, I don't know, but worth it to try imo.

1. Create 17 Global Properties, one for each faction's total (I'll use
'AquitaniTotal' as my example), initial value 0, numeric: 0 min, 100

2. For each of those, create a Change-Property button that will set its
total to 0 (In Type, choose Set Value Directly).  (So one named
ZeroAquitaniTotal will set AquitaniTotal to 0).

3. Make a new prototype called: FactionGlobals, and add 17 'Set Global
Property' Traits into it, which will each increment its total by 1.  For
example, AquitaniTotal, numeric checked 0-100, no menu command name, key
command: RaiseFactionGlobal, increment numeric value by 1.  Place the
FactionGlobals prototype into your Control - Level prototype.

4. Create 17 Global Key Commands (one being: TotalAquitaniFaction). For
each Key Command, use RaiseFactionGlobal, and in Matching Properties
enter its faction layer name (so my example being: "Layer - Control
Faction_Name = Aquitani"

5. Create a Multi-Action Button called Faction Totals, and add all 17
button names from #2 (one being: ZeroAquitaniTotal) and then below those
all 17 GKCs from #4 (one being TotalAquitaniFaction).

6. Create one Toolbar Action Button called AquitaniReport. In Display
Message, enter "The Aquitani faction controls $AquitaniTotal$ regions." 
Add AquitaniReport to the bottom of the multi-action button list from #
5.  [The other 16 factions will need their own Toolbar Action buttons
made up and plugged into the multi-action button, but I'm just testing
one for now]

Give it a try and see if it properly reports the Aquitani faction total.
 (I'll try reading through this again later myself to see if there's any
mistakes I may have made above).

Read this topic online here:

More information about the messages mailing list