• 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

"chld" attribute limitations

  • Thread starter Thread starter woodywalton at hotmail.co
  • Start date Start date
W

woodywalton at hotmail.co

Guest
All,

I was wanting a child unit to inherit the stat value of its parent. I
realize I can use the chld attribute to increase or decrease a child unit's
stats, but I am unclear as to how one would "copy" the final stat of the
parent to the child. If anyone knows how to do this please let me know.

Thanks,

Woody



_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp
 
The solution is to use the "chld" attribute. If you say
"chld:foo@chld=(parnt)", then the "parnt" stat of the parent unit is
assigned to the "chld" stat of the child unit. It's also legal to use the
same stat for both parent and child if you want. This technique is used in
the CAV and Full Thrust data files if you want to take a look.

However, sequencing of options is critical to making it all work, since the
"chld" attribute is cached in advance for propogation to the children.
Basically, you need to calculate the final stat value within the parent,
THEN issue the "chld" attribute, and THEN attach the child unit.

I provided some useful background on the "chld" attribute in a post on 8/8
with the subject "Timing and the chld attribute". Please read that post for
valuable context on its use. That ought to explain the nuances that lead to
the sequence I outline above.

If any of this is still fuzzy, please let me know and I'll be happy to clarify.

Thanks, Rob


At 01:54 AM 8/12/2001 -0500, you wrote:
>All,
>
>I was wanting a child unit to inherit the stat value of its parent. I
>realize I can use the chld attribute to increase or decrease a child unit's
>stats, but I am unclear as to how one would "copy" the final stat of the
>parent to the child. If anyone knows how to do this please let me know.
>
>Thanks,
>
>Woody
 
Back
Top