Giving two units on the same side separate recruit lists?
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.
- Flameslash
- Posts: 633
- Joined: December 21st, 2008, 12:29 pm
Giving two units on the same side separate recruit lists?
Hi everyone, I'm building a scenario in which I want the player's side to have two units, each with their own recruit lists. I've been able to give the player two leaders who can recruit, but am struggling with giving them separate lists. Here's what I have so far, can anyone let me know why it doesn't work how I want it to:
So it all seems to work fine, except Hasri uses the same recruit list as Kamir, rather than having his own list.
Code: Select all
[side]
type=Dune Explorer
name= _ "Kamir"
{GOLD 120 100 80}
unrenamable=yes
side=1
canrecruit=yes
controller=human
recruit=Dune Rover, Dune Soldier, Dune Burner, Dune Herbalist
team_name=Dunefolk
user_team_name=_"Dunefolk"
[/side]
then a bit later...
#define PLACE_HASRI X Y TRAIT1 TRAIT2
[unit]
type=Dune Sunderer
id=Hasri
name= _ "Hasri"
unrenamable=yes
canrecruit=yes
recruit=Dune Piercer, Dune Rider
x={X}
y={Y}
side=1
[/unit]
#enddef
and then finally...
{PLACE_HASRI 3 8 STRONG QUICK}
Last edited by Ravana on March 31st, 2018, 1:45 pm, edited 1 time in total.
Reason: Use [code] BBCode tags in your posts for embedding WML snippets.
Reason: Use [code] BBCode tags in your posts for embedding WML snippets.
- skeptical_troll
- Posts: 500
- Joined: August 31st, 2015, 11:06 pm
Re: Giving two units on the same side separate recruit lists?
You need to use the 'extra_recruit' key with both leaders if you want them to have separate options. 'recruit' in the [side] tag only lists the shared units.
- Flameslash
- Posts: 633
- Joined: December 21st, 2008, 12:29 pm
Re: Giving two units on the same side separate recruit lists?
Thank you. Is there any examples of that being used in mainline that I can look at to learn how it works, do you know?
- skeptical_troll
- Posts: 500
- Joined: August 31st, 2015, 11:06 pm
Re: Giving two units on the same side separate recruit lists?
I think Legend of Wesmere is a good example, Kalenz and the lady (forgot the name) have different recruits.
- Flameslash
- Posts: 633
- Joined: December 21st, 2008, 12:29 pm
Re: Giving two units on the same side separate recruit lists?
Thank you, I had a look at that and I've got it working now.