Oops, I completely forgot to do that. Ha Thanks Blizz, it works now.
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Quote from: KK20 on January 18, 2013, 07:12:17 am
You forgot to put an extra 'end'.
elsif negative.include?(ai.target.ai.group) &&
Math.hypot(char.real_x-ai.target.real_x,
char.real_y-ai.target.real_y) < 384
# delete movement commands
char.force_move = []
# back off from reference target
if [1].include?(char.battler.id)
char.move_away_random(ai.target, false, ai.act.range)
end
end
Quote from: KK20 on January 05, 2013, 06:30:09 pm
The point was to make this new project have ONLY BlizzABS (a clean, uneditted one) in it. We don't care about the other scripts your project has.
If you changed that edit I made to what I recently posted, the only way you can configure what enemies retreat or not is by putting the enemy's ID in the brackets.
if [1].include?(char.battler.id)
char.move_away_random(ai.target, false, ai.act.range)
end
As you see here, the enemy of ID 1 located in the database will retreat after attacking. If your gun-weilding bandits are ID 15, replace 1 with 15. If you have another enemy that fires projectiles and is of ID 23, then you do
if [15,23].include?(char.battler.id)
char.move_away_random(ai.target, false, ai.act.range)
end
Any enemy IDs not represented in the brackets (i.e. your zombies) will not retreat after attacking.