AS enemy script

Game Enemy AI - Run Away from Player

Wednesday, January 7th, 2009 | Enemy AI, Game Examples AS2 | No Comments

Flash ActionScript 2 game enemy AI. This script gives your enemies the ability to run away from the player.

Download Fla Sample

Download Fla Sample

Customizable Enemy Settings

  • movement speed
  • turn rate
  • aggression range

Update
Check out the updated version of this script that incorporates different enemy behaviors in to one function, as well as creating multiple enemies at the same time: Enemy Behavior - Run Away & Follow Player

Tags: , , , , , , , , , , , , ,

Simple Enemy Random Movement

Sunday, December 14th, 2008 | Enemy AI, Game Examples AS2 | No Comments

Here is a simple AS2 enemy creation/ai script that allows you to create enemies that move about randomly inside a container movieclip. You can set custom movement boundaries/borders. When an enemy hits the border, it will “bounce off” and move in the opposite direction.

Random Movement Example

Download Fla Sample

Download Fla Sample

Tags: , , , , , , , , , , , , , , , , ,