• 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

Restricting options based on unit size

  • Thread starter Thread starter shawn at electricstitch.c
  • Start date Start date
S

shawn at electricstitch.c

Guest
I am trying to find out how to restrict the number of options available
based on unit size.

Example

Unit Foo gets 'Option Alpha'
Up to 1/2 of Unit Foo may exchange their 'Option Alpha' for 'Option Beta'.

So far, I have made it so Option Alpha decreases when I add Option Beta, but
I am not sure how to make Option Beta limited to 1/2 of the unit size. The
best I could do was limit the rang to half of the maximum number in Unit
Foo. But, if less than the maximum are taken, I have to create a conflict
message. I'd prefer to make it so you are not able to add to Option Beta
unless more are added to Unit Foo.

This would be similiar to Space Wolves Blood Claws and how they can have a
number of power weapons equal to 1/5 of the models in the unit.

Please help.

Thanks,
-Shawn
 
At 12:57 20/08/2001 -0700, you wrote:
>I am trying to find out how to restrict the number of options available
>based on unit size.
>
>Example
>
>Unit Foo gets 'Option Alpha'
>Up to 1/2 of Unit Foo may exchange their 'Option Alpha' for 'Option Beta'.
>
>So far, I have made it so Option Alpha decreases when I add Option Beta, but
>I am not sure how to make Option Beta limited to 1/2 of the unit size. The
>best I could do was limit the rang to half of the maximum number in Unit
>Foo. But, if less than the maximum are taken, I have to create a conflict
>message. I'd prefer to make it so you are not able to add to Option Beta
>unless more are added to Unit Foo.

Can't be done, as far as I know; everywhere this applies to the 40k files,
there are validation rules that give error messages when you have less than
the maximum number of models in the unit.


--
Colen 'Skrillboy' McAlister, demandred@skrill.org
http://www.skrill.org/, http://www.incompetence-central.co.uk/
1 = 2, for large values of 1.
 
If you are using the "rang" attribute to control the selection count for
both options, you can't solve this directly. The trick to solving this is
to use a separate hidden stat in the background. Start with a hidden stat
named "Beta". When Option Beta is increased, use "base" to increase the
value of "Beta". Then use the "lcmp" unit attribute to verify that the
value of "Beta" is less than or equal to the model count of the unit. You
now have validation for Option Beta.

Tip! I usually create a few hidden stats that are kept in reserve just for
this purpose. You might call them "temp1", "temp2", etc. These stats are
reused for this type of thing across various units, where the specific use
differs from one unit to the next. But they serve a very useful purpose in
this regard. :-)

Hope this helps,
Rob


At 12:57 PM 8/20/2001 -0700, you wrote:
>I am trying to find out how to restrict the number of options available
>based on unit size.
>
>Example
>
>Unit Foo gets 'Option Alpha'
>Up to 1/2 of Unit Foo may exchange their 'Option Alpha' for 'Option Beta'.
>
>So far, I have made it so Option Alpha decreases when I add Option Beta, but
>I am not sure how to make Option Beta limited to 1/2 of the unit size. The
>best I could do was limit the rang to half of the maximum number in Unit
>Foo. But, if less than the maximum are taken, I have to create a conflict
>message. I'd prefer to make it so you are not able to add to Option Beta
>unless more are added to Unit Foo.
>
>This would be similiar to Space Wolves Blood Claws and how they can have a
>number of power weapons equal to 1/5 of the models in the unit.
>
>Please help.
>
>Thanks,
>-Shawn
 
Rob,

I was hoping to make it not allow increasing past, but this will do.

Your suggestion worked great.

Thanks,
-Shawn

----- Original Message -----
From: "Rob Bowes" <rob@wolflair.com>
To: ab@support.wolflair.com
Sent: Tuesday, August 21, 2001 1:05 PM
Subject: Re: [AB] Restricting options based on unit size


> If you are using the "rang" attribute to control the selection count for
> both options, you can't solve this directly. The trick to solving this is
> to use a separate hidden stat in the background. Start with a hidden stat
> named "Beta". When Option Beta is increased, use "base" to increase the
> value of "Beta". Then use the "lcmp" unit attribute to verify that the
> value of "Beta" is less than or equal to the model count of the unit. You
> now have validation for Option Beta.



------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get your FREE credit report with a FREE CreditCheck
Monitoring Service trial
http://us.click.yahoo.com/M8mxkD/bQ8CAA/ySSFAA/IMSolB/TM
---------------------------------------------------------------------~->
 
One of my goals with AB was to enforce things via validation and NOT with a
hammer. There are WAY too many groups with their own house rules,
especially for special one-of games and/or campaigns they create. If AB
forced users to comply with all the rules, then it would be a hindrance for
games that relaxed some of those rules. With validation, the errors are
flagged but can be easily ignored by mutual agreement of the players.

There are probably lots of situations where you can't have AB force the
user to comply, but there is usually a way to have AB flag an error via
validation. Personally, I think this is the optimal way to write data files
that are useful to everyone, even those with their own house rules.

Just something to keep in the back of your mind while writing data
files.... :-)

Hope this helps,
Rob


At 08:33 PM 8/21/2001 -0700, you wrote:
>Rob,
>
>I was hoping to make it not allow increasing past, but this will do.
>
>Your suggestion worked great.
>
>Thanks,
>-Shawn


---------------------------------------------------------------------------
Rob Bowes (rob@wolflair.com) (650) 726-9689
Lone Wolf Development www.wolflair.com


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get your FREE credit report with a FREE CreditCheck
Monitoring Service trial
http://us.click.yahoo.com/M8mxkD/bQ8CAA/ySSFAA/IMSolB/TM
---------------------------------------------------------------------~->
 
> Just something to keep in the back of your mind while writing data
> files.... :-)
>
> Hope this helps,
> Rob

I can respect that. Thanks.

-Shawn


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get your FREE credit report with a FREE CreditCheck
Monitoring Service trial
http://us.click.yahoo.com/M8mxkD/bQ8CAA/ySSFAA/IMSolB/TM
---------------------------------------------------------------------~->
 
Back
Top