- Joined
- Feb 2, 2006
- Messages
- 1,498
I have created custom campain AI scripts for custom races in my map like: https://raw.githubusercontent.com/tdauth/wowtsr/master/ai/BloodElf.ai
As you can see I use three different custom town hall buildings:
However, instead of only upgrading the one keep they build with tier 1, they build a second castle and maybe a third one (not sure). They still upgrade one tier to the last one.
This does NEVER happen with my custom AI for existing races like undead: https://raw.githubusercontent.com/tdauth/wowtsr/master/ai/Undead.ai
Although the script is almost the same but only with different units and upgrades.
I have also classified my custom buildings as town halls and tier 2 and 3 in the gameplay constants. Does it have something to do with some hardcoded stuff or maybe in the common.ai file?
I found a similar issue here: [Solved] - AI Builds Multiple Halls
He solved it by adding some conditions to the object editor but I cant see them anymore.
Here it wasn't solved: AI town hall spam
This wasn't solved either: AI doesn't recognise tier halls
I could try to limit the unit type or add some conditions but I don't know which.
Maybe it has something to do with SetReplacements?
As you can see I use three different custom town hall buildings:
Code:
constant integer BLOOD_ELF_CASTLE = 'h00B' // castle
constant integer BLOOD_ELF_KEEP = 'h00A' // keep
constant integer BLOOD_ELF_LUMBER_MILL = 'h00F' // lumber mill
constant integer BLOOD_ELF_TOWN_HALL = 'h009' // town hall
However, instead of only upgrading the one keep they build with tier 1, they build a second castle and maybe a third one (not sure). They still upgrade one tier to the last one.
This does NEVER happen with my custom AI for existing races like undead: https://raw.githubusercontent.com/tdauth/wowtsr/master/ai/Undead.ai
Although the script is almost the same but only with different units and upgrades.
I have also classified my custom buildings as town halls and tier 2 and 3 in the gameplay constants. Does it have something to do with some hardcoded stuff or maybe in the common.ai file?
I found a similar issue here: [Solved] - AI Builds Multiple Halls
He solved it by adding some conditions to the object editor but I cant see them anymore.
Here it wasn't solved: AI town hall spam
This wasn't solved either: AI doesn't recognise tier halls
I could try to limit the unit type or add some conditions but I don't know which.
Maybe it has something to do with SetReplacements?