Page 1 of 1

Help with traits and how to activate them

Posted: Fri May 31, 2019 8:06 pm
by Wilmatron
Hi All,

I thought I'd ask this question as the Traits Wiki page is down at the moment (to which I've commented via an open issue on GitHub)...
I'm looking to have NOD launch a nuke via their Temple (Tiberian Dawn) and the documentation mentions activating the actor's "NukePower" and that it requires a Trait called "NukePower".

How do I provide this Trait? I'm assuming it is through the rules.yaml file, but I'm a little lost as to how to add it to this.
Can somebody point me in the right direction or provide an example of what it should look like?

Cheers,
Dave.

Re: Help with traits and how to activate them

Posted: Mon Jun 03, 2019 5:39 pm
by Graion Dilach

Re: Help with traits and how to activate them

Posted: Tue Jun 04, 2019 3:19 pm
by Wilmatron
Hi Graion,

I'm trying to work out how to trigger NOD (the AI enemy) to fire a nuke at the player if the temple is attacked. The API mentions 'ActivateNukePower' and that it requires the trait 'NukePower'. Would you happen to know the line of code i'd need to instigate the attack?

Cheers,