Top down shooter enemy help

Hey all. I really could use some help or tips for this one. I'm building a top down shooter. Objects essentially fall from the top of the screen and when they exit the bottom- are recycled back to the top at a random x position. Thats all fine and dandy.
What i need help with is object/enemy attack movements. I don't them to just fall down the screen. I'd like for them to have various attack movements and or random movements. The trick however is that they also need to at some point reach the bottom of the screen so they can be recycled.
For whatever reason everything i've attempted has been pretty lackluster.
One tactic i attempted was for the object to fall down the screen. When it touched an invisible object on screen it changes its self attribute to an integer. When that integer is triggered i said ignore Move down (270), and instead move randomly (1,359). But it looks terrible.
Any suggestions would be extremely helpful!
Many thanks!

Comments

  • KnightStarKnightStar Member Posts: 162
    A method you can use is to create Way-Points. Essentially create 4+ points (or invisible actors) on you play area. Then, you need to draft behaviors into your 'enemy' actors in which they will 'MOVE-TO' or 'INTERPOLATE' to the way points. Each time an actor touches / comes within a certain proximity of a way-point, the actor would then advance to the next way-point. I'm assuming you will stagger the way-points all the way down.

    If you really want to get crazy, in the behaviors you create within each actor, randomly select which way-point you want your actor to move to next on their way down the screen. The final way point should always be at the bottom, below your screen - that way when the actor touches / reaches that point, it can be recycled back to the top.

    Hope this helps...
  • gamesfuagamesfua Member Posts: 723
    This might just do it! Especially if i make random passes to the waypoints. Its actually a really genius solve to this problem. Thank you so much!
  • KnightStarKnightStar Member Posts: 162
    No prob..

    As a Game Designer for several big-name game houses, we used way-points in games to simulate AI on all kinds of games.

    Good luck with your game!
  • UtopianGamesUtopianGames Member Posts: 5,692
    edited December 2012
    Sometimes way points can be a bit linear, why don't you use random?

    In this demo when they get to the edge of the scene they fall down the side fast.



    I have put together a simple unoptimised project for you.

    Darren.
Sign In or Register to comment.