AMLA Teachers

Discussion of all aspects of multiplayer development: unit balancing, map development, server development, and so forth.

Moderator: Forum Moderators

Post Reply
dragonfi
Posts: 5
Joined: August 22nd, 2010, 1:01 pm

AMLA Teachers

Post by dragonfi »

Hi! This is the feedback topic for my addon "AMLA Teachers".

A small Wesnoth modification that adds a "Teacher" advancement option for units that reached AMLA. The Teacher redistributes it's own XP to units around it at every turn. This makes them gaining XP gain less wasteful, while still providing some interesting decistion in positioning units.

I basically hacked it together from Garak's ability in UtBS and the LotI custom advancements mod.

Github: https://github.com/dragonfi/AMLA_Teacher
User avatar
Ravana
Forum Moderator
Posts: 3324
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: AMLA Teachers

Post by Ravana »

From code review it does not look like you do anything that would need require_modification=yes.

I would remove distribution of local mod = teacher.experience % #students. Sorting can sort multiple units equally, so different clients may have different units get xp. And instead of teacher.experience = 0 reducing xp based on how much is moved.
dragonfi
Posts: 5
Joined: August 22nd, 2010, 1:01 pm

Re: AMLA Teachers

Post by dragonfi »

Ravana wrote: June 22nd, 2025, 9:44 am From code review it does not look like you do anything that would need require_modification=yes.

I would remove distribution of local mod = teacher.experience % #students. Sorting can sort multiple units equally, so different clients may have different units get xp. And instead of teacher.experience = 0 reducing xp based on how much is moved.
I couldn't find a good definition on when require_modification can be "no", so I just went for the safe one. Can you tell me when it's not required?

I would prefer for teacher.experience to evaporate at the beginning of every turn, otherwise, you could just send them on a solo mission and bring them back to level up some fresh recruits.

It is a valid point that the sorting is not completely deterministic, I will probably just use coordinates to disambiguate fuzzy cases.
User avatar
Ravana
Forum Moderator
Posts: 3324
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: AMLA Teachers

Post by Ravana »

Non-wml files like images are most common reason to require download. Next common is some tags like [unit_type] which are not sent over network.
dragonfi
Posts: 5
Joined: August 22nd, 2010, 1:01 pm

Re: AMLA Teachers

Post by dragonfi »

Thanks! I made the sorting deterministic by breaking ties based on position.
dragonfi
Posts: 5
Joined: August 22nd, 2010, 1:01 pm

Re: AMLA Teachers

Post by dragonfi »

Ravana wrote: June 23rd, 2025, 1:55 pm Non-wml files like images are most common reason to require download. Next common is some tags like [unit_type] which are not sent over network.
Thanks! I will still be cautious in the future, but I set it to "no" for this addon.
R831
Posts: 17
Joined: March 26th, 2020, 10:53 pm

Re: AMLA Teachers

Post by R831 »

Sorry, maybe I'm noob, but how to activate this mod? I downloaded it and though it will just start working. Is it not supposed to work with addon campaigns?

UPD: found checkbox... look like it's required to restart company to add feature. xD
Post Reply