Script giving 4 mp leaders the Quick Trait

The place to post your WML questions and answers.

Moderator: Forum Moderators

Forum rules
  • Please use [code] BBCode tags in your posts for embedding WML snippets.
  • To keep your code readable so that others can easily help you, make sure to indent it following our conventions.
Post Reply
remetagross
Posts: 4
Joined: June 21st, 2016, 3:15 pm

Script giving 4 mp leaders the Quick Trait

Post by remetagross »

Hello everyone,

I have registered on the forum to ask you something. Ihave a question to which I didn't find an answer on this subforum with a quick search. Maybe I should look for it in another one ?

I have designed a faction with 4 MP leaders. I don't manage to automatically give them the Quick trait. Can you help me as to what code I need to write, and where should I write it ?

Thanks in advance.
User avatar
Ravana
Forum Moderator
Posts: 3009
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: Script giving 4 mp leaders the Quick Trait

Post by Ravana »

If you only have 4mp leaders, then core macro(QUICK_4MP_LEADERS) is good enough, see how default does it. If there are 3mp ones too, then https://github.com/ProditorMagnus/Agele ... g#L55-L114
remetagross
Posts: 4
Joined: June 21st, 2016, 3:15 pm

Re: Script giving 4 mp leaders the Quick Trait

Post by remetagross »

Ok, great !
I only have 4mp leaders. So, I just have to write down "macro(QUICK_4MP_LEADERS)", is that it ? Where should I put it ? Somewhere In the era.cfg file ?
gfgtdf
Developer
Posts: 1432
Joined: February 10th, 2013, 2:25 pm

Re: Script giving 4 mp leaders the Quick Trait

Post by gfgtdf »

Ravana wrote:If you only have 4mp leaders, then core macro(QUICK_4MP_LEADERS) is good enough, see how default does it. If there are 3mp ones too, then https://github.com/ProditorMagnus/Agele ... g#L55-L114
Hm i wonder whether we sjould just change the core macro to apply to less than 4 mp leader too then
Scenario with Robots SP scenario (1.11/1.12), allows you to build your units with components, PYR No preperation turn 1.12 mp-mod that allows you to select your units immideately after the game begins.
User avatar
Ravana
Forum Moderator
Posts: 3009
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: Script giving 4 mp leaders the Quick Trait

Post by Ravana »

I suspect you might want to keep 0mp leaders that way. But other than that, would work.
So, I just have to write down "macro(QUICK_4MP_LEADERS)", is that it ?
No, that is why I said to look how default uses it.
remetagross
Posts: 4
Joined: June 21st, 2016, 3:15 pm

Re: Script giving 4 mp leaders the Quick Trait

Post by remetagross »

Sorry, I had'nt read your post closely enough. Indeed, looking into the default structure was enough.

For those who might look after this info, here is how to go :
-Open your "Eras.cfg" file
-Paste anywhere in it the following :
Spoiler:
If I have correctly understood, this code defines the macro {QUICK_4MP_LEADERS}.
-Then, add anywhere in the file, "{QUICK_4MP_LEADERS}".

However, I have a second question. Right below the "{QUICK_4MP_LEADERS}", I could read in the Default Era file, "{TURNS_OVER_ADVANTAGE}". The code of that macro seemed quite obscure to me. Do you know what it does ?

Thank you :):)
User avatar
Ravana
Forum Moderator
Posts: 3009
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: Script giving 4 mp leaders the Quick Trait

Post by Ravana »

The code defines macro yes, but as it is core macro, you do not need to define it yourself, it is already there.

It shows some message that tries to guess which side has advantage, I guess it looks gold and units.
remetagross
Posts: 4
Joined: June 21st, 2016, 3:15 pm

Re: Script giving 4 mp leaders the Quick Trait

Post by remetagross »

Ok, thank you !
Post Reply