- Joined
- Mar 16, 2008
- Messages
- 824
There are separate natives for AI scripts but I'm wondering if I could throw something like this into the script and have the AI purchase a specific item when it acquires another specific item. Would it matter what part of the script I throw this into? Attacking section or building section?
Or should I just do this with some elaborate GUI system? Thinking if the AI could handle something like the above it'd be easier just to add it to the AI's script.
Thank you.
JASS:
if ( ( UnitHasItemOfTypeBJ(udg_Red_King, 'I002') == true ) ) and
if ( ( GetPlayerState(Player(0), PLAYER_STATE_RESOURCE_GOLD) >= 3000 ) ) then
call IssueNeutralTargetOrder ( GetPlayerID(Player(0), udg_King_Vendor, I015)
Or should I just do this with some elaborate GUI system? Thinking if the AI could handle something like the above it'd be easier just to add it to the AI's script.
Thank you.
Last edited: