- Joined
- May 12, 2018
- Messages
- 145
Hello readers,
I want to make an AI of classical Undead that builds a base slowly from the beginning. (Like RoC NE Final chapter's Undead in Jaina and Thrall's base)
But my AI is causing problems from the testing stage. It doesn't work at all.
Undead AI doesn't build any haunted gold mine and necropolis, and etc builds and just keep sleeping forever.
www.hiveworkshop.com
I'm calmly testing one by one while reading Nowow's JASS AI tutorial, but I have no idea where the problem is. The Demo Jass Syntax Checker prints there is no problem.
this is my sample map and AI.
I want to make an AI of classical Undead that builds a base slowly from the beginning. (Like RoC NE Final chapter's Undead in Jaina and Thrall's base)
But my AI is causing problems from the testing stage. It doesn't work at all.
Undead AI doesn't build any haunted gold mine and necropolis, and etc builds and just keep sleeping forever.
Creating AI workflow
Or How I Learned to Stop Worrying and Read AI This tutorial serves one primary purpose: teaching you how to learn ai by yourself. In order to achieve that we'll go through two steps: First, we'll read through an ai script from one of blizzard's campaign maps and use it to understand how ai...

this is my sample map and AI.
JASS:
globals
player user = Player(1)
integer Tier1 = 1
constant integer UNIT_UNDEAD_WORKER = 'naco'
constant integer UNIT_UNDEAD_GHOUL = 'ugho'
constant integer UNIT_UNDEAD_FIEND = 'ucry'
constant integer UNIT_UNDEAD_GARGOYLE = 'ugar'
constant integer UNIT_UNDEAD_WAGON = 'umtw'
constant integer UNIT_UNDEAD_ABOMINATION = 'uabo'
constant integer UNIT_UNDEAD_NECRO = 'unec'
constant integer UNIT_UNDEAD_BANSHEE = 'uban'
constant integer UNIT_UNDEAD_OBSIDIAN = 'uobs'
constant integer UNIT_UNDEAD_DESTROYER = 'ubsp'
constant integer UNIT_UNDEAD_FROSTWYRM = 'ufro'
constant integer UNIT_UNDEAD_SHADE = 'ushd'
constant integer HERO_UNDEAD_DEATHKNIGHT = 'Udea'
constant integer SUMMONED_UNDEAD_SKELETON = 'u010'
constant integer SUMMONED_UNDEAD_SKELETALMAGE = 'uskm'
constant integer BUILD_UNDEAD_GOLD = 'ugol'
constant integer BUILD_UNDEAD_HALL1 = 'unpl'
constant integer BUILD_UNDEAD_HALL2 = 'unp1'
constant integer BUILD_UNDEAD_HALL3 = 'unp2'
constant integer BUILD_UNDEAD_ALTAR = 'uaod'
constant integer BUILD_UNDEAD_FARM = 'uzig'
constant integer BUILD_UNDEAD_FARMTOWER = 'uzg1'
constant integer BUILD_UNDEAD_FARMTOWERFROST = 'uzg2'
constant integer BUILD_UNDEAD_BARRACKS = 'usep'
constant integer BUILD_UNDEAD_BLACKSMITH = 'ugrv'
constant integer BUILD_UNDEAD_SLAUGHTERHOUSE = 'uslh'
constant integer BUILD_UNDEAD_TEMPLE = 'utod'
constant integer BUILD_UNDEAD_SACPIT = 'usap'
constant integer BUILD_UNDEAD_BONEYARD = 'ubon'
constant integer BUILD_UNDEAD_SHOP = 'utom'
constant integer UPG_UNDEAD_PACK = 'Rupm'
constant integer UPG_UNDEAD_ARMOR_STRUCTURE = 'R00A'
constant integer UPG_UNDEAD_WEAPON_CASTER = 'R00B'
constant integer UPG_UNDEAD_WEAPON_MELEE = 'Rume'
constant integer UPG_UNDEAD_ARMOR_MELEE = 'Ruar'
constant integer UPG_UNDEAD_WEAPON_RANGE = 'Rura'
constant integer UPG_UNDEAD_ARMOR_RANGE = 'Rucr'
constant integer UPG_UNDEAD_CANNIBALIZE = 'Ruac'
constant integer UPG_UNDEAD_GHOUL_FRENZY = 'Rugf'
constant integer UPG_UNDEAD_FIEND_BURROW = 'Rubu'
constant integer UPG_UNDEAD_FIEND_WEB = 'Ruwb'
constant integer UPG_UNDEAD_GARGOYLE_FORM = 'Rusf'
constant integer UPG_UNDEAD_WAGON_CORPSE = 'Ruex'
constant integer UPG_UNDEAD_WAGON_BLIGHT = 'R02L'
constant integer UPG_UNDEAD_DISEASECLOUD = 'Rupc'
constant integer UPG_UNDEAD_ABOMINATION_FLESH = 'R600'
constant integer UPG_UNDEAD_TRAIN_NECRO = 'Rune'
constant integer UPG_UNDEAD_TRAIN_BANSHEE = 'Ruba'
constant integer UPG_UNDEAD_OBSIDIAN_MANA = 'R025'
constant integer UPG_UNDEAD_OBSIDIAN_FORM = 'Rusp'
constant integer UPG_UNDEAD_NECRO_MASTERY = 'Rusm'
constant integer UPG_UNDEAD_FROSTWYRM_ATTACK = 'Rufb'
endglobals
function BuildOrder takes nothing returns nothing
call SetBuildUnitEx( 1,1,1, UNIT_UNDEAD_WORKER)
call SetBuildUnitEx( 1, 1, 1, BUILD_UNDEAD_GOLD)
call SetBuildUnitEx( 1, 1, 1, BUILD_UNDEAD_HALL1)
call SetBuildUnitEx( 1, 1, 1, BUILD_UNDEAD_FARM)
call SetBuildUnitEx( 1, 1, 1, BUILD_UNDEAD_BARRACKS)
call SetBuildUnitEx( 1, 1, 1, BUILD_UNDEAD_ALTAR)
call SetBuildUnitEx( 1, 1, 1, BUILD_UNDEAD_BLACKSMITH)
call SetBuildUnitEx( 1, 1, 1, BUILD_UNDEAD_SHOP)
call SetBuildUnitEx( 4, 4, 4, BUILD_UNDEAD_FARM)
call SetBuildUnitEx( 6, 6, 6, UNIT_UNDEAD_WORKER)
call SetBuildUnitEx( 4, 4, 4, UNIT_UNDEAD_GHOUL)
endfunction
function main takes nothing returns nothing
call CampaignAI(BUILD_UNDEAD_FARM, null)
call DoCampaignFarms(false)
call SetPeonsRepair(true)
set campaign_wood_peons = 8
call BuildOrder()
endfunction
Attachments
Last edited: