The Daily Click ::. Forums ::. Klik Coding Help ::. Enemy AI Problem.. Sample included.
 

Post Reply  Post Oekaki 
 

Posted By Message

Tina Petersen



Registered
  19/09/2003
Points
  350
26th August, 2006 at 15:21:20 -

Trying to make som custom AI, like range for stopping, chasing player etc.. However i got the problem when i stop one of the enemies they all stop.. And when i start one they all start..

Help!

http://www.befun.dk/JAZ.Simplifiedfortesting.zip

arrow up+down walk. left mouse, gun, right mouse sword

 
- Eternal Life, Or Your Money Back -
http://www.befun.dk/
Currently looking for a home (team)

lembi2001



Registered
  01/04/2005
Points
  608

VIP MemberIt's-a me, Mario!Wii OwnerI like Aliens!Has Donated, Thank You!PS3 OwnerI am an April Fool
26th August, 2006 at 16:37:13 -

i would have looked but i dont have the dsound extension. only joking ill download it now and have a look.

 
n/a

lembi2001



Registered
  01/04/2005
Points
  608

VIP MemberIt's-a me, Mario!Wii OwnerI like Aliens!Has Donated, Thank You!PS3 OwnerI am an April Fool
26th August, 2006 at 16:40:04 -

i just tried to download the extension but the site is down

 
n/a

Tina Petersen



Registered
  19/09/2003
Points
  350
26th August, 2006 at 16:50:52 -

http://www.gullen.pwp.blueyonder.co.uk/files/dsound2.zip

sorry bout that.

 
- Eternal Life, Or Your Money Back -
http://www.befun.dk/
Currently looking for a home (team)

deadeye



Registered
  22/07/2006
Points
  73
26th August, 2006 at 22:22:19 -

It's because you need to use spread values and fastloops.

Just a guess, I haven't looked at the sample yet.

Edit:
Yep, I was right. Check out this article (and anything else you can find about spread values and fastloops):
http://www.create-games.com/article.asp?id=106

Also, you should put any code that controls your enemies into that object's behavior, that way you can just drag and drop enemies into new frames.

Nice looking game so far, by the way.

Image Edited by the Author.

 
n/a

Tina Petersen



Registered
  19/09/2003
Points
  350
27th August, 2006 at 01:51:24 -

woaw that is brainy ;P anyone with a live example?

 
- Eternal Life, Or Your Money Back -
http://www.befun.dk/
Currently looking for a home (team)

deadeye



Registered
  22/07/2006
Points
  73
27th August, 2006 at 04:04:03 -

Yeah, sure. I threw this little example together just for you:

http://projectbrimstone.googlepages.com/spreadValues.cca

It's heavily commented. If you have any other questions, just ask.

Edit:
Oops, forgot to mention... you will need the fastloop object for this example. Kind of obvious for a fastloop tutorial, I guess, but whatever.

Image Edited by the Author.

 
n/a

Del Duio

Born in a Bowling Alley

Registered
  29/07/2005
Points
  1078

GOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!Evil klikerHasslevania 2!The OutlawSanta Boot
27th August, 2006 at 08:06:46 -

Aw, nobody makes me a spread value / fastloop example
I'm just not woman enough for you people!

 
--

"Del Duio has received 0 trophies. Click here to see them all."

"To be a true ninja you must first pick the most stealthy of our assorted combat suits. Might I suggest the bright neon orange?"

DXF Games, coming next: Hasslevania 2- This Space for Rent!

deadeye



Registered
  22/07/2006
Points
  73
27th August, 2006 at 08:58:02 -

Well, I would have if you asked I suppose you can use this one too.

And don't feel bad. I'm sure you're woman enough for somebody.

 
n/a

Del Duio

Born in a Bowling Alley

Registered
  29/07/2005
Points
  1078

GOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!Evil klikerHasslevania 2!The OutlawSanta Boot
27th August, 2006 at 09:35:27 -

LOL, thanks I think

 
--

"Del Duio has received 0 trophies. Click here to see them all."

"To be a true ninja you must first pick the most stealthy of our assorted combat suits. Might I suggest the bright neon orange?"

DXF Games, coming next: Hasslevania 2- This Space for Rent!

Tina Petersen



Registered
  19/09/2003
Points
  350
27th August, 2006 at 12:18:09 -

Thanx alot sugar. runs smoothy now.

 
- Eternal Life, Or Your Money Back -
http://www.befun.dk/
Currently looking for a home (team)
   

Post Reply



 



Advertisement

Worth A Click