Platformer Ai
Hi I'm a fellow game designer I guess you can say and I was wondering how to use the distance of an enemy to see at a certain distance and go after him I have tried Tshirtbooths video and it didn't work so I used the forums before and no one really responded so here is what I'm using now
Constrain Attribute
Game.player x to self.position.x
Constrain Attribute 'distancefrom'
to
game.player x-self.position.x
Attribute 'distance between' is greater than -264
and Attribute 'distance between' is less than 264,
then
change attribute insight=true
if attribute insight=true
move to
attribute game.player x
Constrain Attribute
Game.player x to self.position.x
Constrain Attribute 'distancefrom'
to
game.player x-self.position.x
Attribute 'distance between' is greater than -264
and Attribute 'distance between' is less than 264,
then
change attribute insight=true
if attribute insight=true
move to
attribute game.player x
Comments