Results 1 to 2 of 2

Thread: Npc AI

  1. #1
    SupeRoBug78 is offline Member
    Join Date
    Apr 2012
    Rep Power

    Question Npc AI

    For my game I'm working on, I've started working on an AI thingy (not sure of the right term :P) for pigs, because they're relatively slow and stupid. I think it will be something like a random number generator, 1-3 every 3 seconds. If 1, it keeps walking the same direction; if 2, it stops walking for the next 3 seconds; if 3, it goes to random number gen. 2. In number generator 2, it goes 1-3 again, to go up,down,right,or left (minus the one it was already going). I'm not sure how to code this though. Any help would be appreciate, and I'm kind of a n00b at java, so sorry :/

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Madgaon, Goa, India
    Rep Power

    Default Re: Npc AI

    Moved from Java 2D

    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts