how to replace AMLA?

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
User avatar
ERROR1025
Posts: 46
Joined: February 23rd, 2020, 10:18 am

how to replace AMLA?

Post by ERROR1025 »

i hope use my AMLA plans replace
AMLA_DEFAULT
in a mod-add-on
how do?
User avatar
beetlenaut
Developer
Posts: 2832
Joined: December 8th, 2007, 3:21 am
Location: Washington State
Contact:

Re: how to replace AMLA?

Post by beetlenaut »

This is not a specific question that is easy to answer, but maybe this is all you need: Use replace=yes in the [effect].

If you need more information: Add the [effect] with [object] or [modify_unit]. The [effect] needs to apply_to a new_advancement. The [advancement] tag defines the new AMLA. You can have multiple [advancement] tags in the [effect] to create more options.
Campaigns: Dead Water,
The Founding of Borstep,
Secrets of the Ancients,
and WML Guide
User avatar
ERROR1025
Posts: 46
Joined: February 23rd, 2020, 10:18 am

Re: how to replace AMLA?

Post by ERROR1025 »

i hope if my mod-add-on is on,have this effect:
all use
{AMLA_DEFAULT}
unit use my AMLA,Not use AMLA_DEFAULT
User avatar
beetlenaut
Developer
Posts: 2832
Joined: December 8th, 2007, 3:21 am
Location: Washington State
Contact:

Re: how to replace AMLA?

Post by beetlenaut »

I think I already answered that question. If I didn't answer it, I need you to ask a specific question about one part that is difficult. I'm not going to write a whole mod for you.

If you can only write a clearer, more complete question in another language, you should try that. There is probably someone here who would understand that better.
Campaigns: Dead Water,
The Founding of Borstep,
Secrets of the Ancients,
and WML Guide
User avatar
Ravana
Forum Moderator
Posts: 3075
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: how to replace AMLA?

Post by Ravana »

As [modification] you do not have opportunity to replace {AMLA_DEFAULT}, that way only works for [era]. For other types of addons you should use unit_placed event.
User avatar
Atreides
Posts: 1090
Joined: March 30th, 2019, 10:38 pm
Location: On the 2nd story of the centre village of Merwuerdigliebe turning the lights on and off

Re: how to replace AMLA?

Post by Atreides »

I think I understand the question. His mod when enabled should replace all unit's amla default macros with his custom one.
User avatar
Ravana
Forum Moderator
Posts: 3075
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: how to replace AMLA?

Post by Ravana »

Sure, just that isnt possible. Each addon uses different preprocessing context so macro changes only affect own addon.
User avatar
ERROR1025
Posts: 46
Joined: February 23rd, 2020, 10:18 am

Re: how to replace AMLA?

Post by ERROR1025 »

oh,i can inspection a unit "use" or "not use" {AMLA_DEFAULT}?
i hope only give {AMLA_DEFAULT} unit new AMLA
Post Reply