• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Model counts limited to a roster scoped tag

BGKenney

New member
Hello!

Working away on the new book for Warmachine. I'm trying to write a rule that is scoped to unit and limited to that unit's id. The model count for that unit needs to be limited to the number of warjacks in the roster +1.

I thought this would work, but it's not picking up the tagcount...any suggestions?

var jacks as number

jacks = (roster.tagcount[cmpgrp.warjack]) + 1
if (count[model] <= jacks) then
@valid = 1
endif

Thanks!
 
That was me...

Ok, been away from the board for a while and couldn't remember my password...got that sorted out.

But, yeah. Can't figure out what's up with that script. I thought I could get to the roster.tagcount from within a unit scope rule?

Anywho...working on the Cryx units in Vengeance tonight...thanks!

The Butcher
 
Odd ... have you tried putting that script into the Postlink section of the unit but changing the unit name to the tagcount (and stating the obvious sorry - removing the @valid=1 bit

That should at least give you an idea of what is being returned on the tagcount and may give you an indication where the fault lies. I've had a similar issue in the past where it was the tag not being properly assigned - it took a while but using the "Show all tags for unit" helped as well

The other obvious (sorry again!!) thing to ask is are there any Jacks in the roster you are using to test and how do they have tags assigned - are they scripted to add to the Jacks or are they "native" in the unit build in ABCreator??
 
Got it!
I switched the focus from roster.tagcount[cmpgrp.warjack]
to overall.tagcount[cmpgrp.warjack]

And it works like a charm!
Thanks for the help out, Harkan!

Butcher
 
Back
Top