Map Database  •  FAQ  •  RSS  •  Login

Static scripting help

<<

sado1

User avatar

Council Member

Posts: 1430

Joined: 21 May 2012, 19:13

KaM Skill Level: Skilled

Post 05 Aug 2014, 08:21

Static scripting help

Hey. I am trying to make AI work for my Desert Conquest map (with an aim to make The Conquest work later too, but Desert one is easier since it does not require changing the script, so I'm working on that one first). I set up some defence lines, as you can see on the screenshot here: http://screenshooter.net/1487897/jbhqmnm After those lines are filled, I want AIs to attack each others buildings, so I set an attack for them both: http://screenshooter.net/1487897/slbdlpt However, AI doesn't recruit troops anymore after it filled out the positions; not even when it could produce like 70 militia at once. Needless to say, they never attack. Where's the mistake that I am making?
<<

Vatrix

User avatar

Council Member

Posts: 410

Joined: 19 Apr 2013, 20:30

KaM Skill Level: Veteran

Location: Czech Republic

Post 05 Aug 2014, 08:31

Re: Static scripting help

If I understand correctly, then your problem is you don't have enough defence lines, if those lines I can see on screenshot are the only ones AI have, then it will not make army, because it doesn't know where the troops have to go. You just have to give AI more defence lines (that much it needs for troops, that will attack) which will be set to "Attackers". So each AI need to have at least 7 defence positions.
I fixed The Shattered Kingdom and The Peasants Rebellion here!
<<

Lewin

User avatar

KaM Remake Developer

Posts: 3822

Joined: 16 Sep 2007, 22:00

KaM Skill Level: Skilled

ICQ: 269127056

Website: http://lewin.hodgman.id.au

Yahoo Messenger: lewinlewinhodgman

Location: Australia

Post 05 Aug 2014, 11:24

Re: Static scripting help

The AI will only make troops to fill defence positions. That's the whole idea of defence lines, it controls how many troops the AI makes and where they put them. Otherwise AIs in the campaigns would end up with 1000s of troops standing outside the barracks with nothing to do :P

So as Vatrix said, add some extra defence positions set to "attackers" (previously known as "backline"). This means those troops are allowed to be used in AI attacks.
<<

sado1

User avatar

Council Member

Posts: 1430

Joined: 21 May 2012, 19:13

KaM Skill Level: Skilled

Post 05 Aug 2014, 12:42

Re: Static scripting help

Thanks, with your help I managed to do it :P

Return to “Map Design”

Who is online

Users browsing this forum: No registered users and 27 guests