Search:

Type: Posts; User: Rexoa

Search: Search took 0.25 seconds.

  1. Checking if an int is the lowest out of 4? (Small issue)

    I'm trying to find the int with the lowest value, and I only know how to set it up like this:

    Let's say x1 is the lowest.


    int x1, x2, x3, x4;

    if (x1 < x2 && x1 < x3 && x1 < x4)...
  2. [SOLVED] Re: Game Combat: Fighting one enemy at a time? (Issue with static/non-static?)

    Well... I learned to use it in a different way.
    I solved the problem by adding 2 lists: currentEnemy and otherEnemies.

    If the enemy is the first to be attacked, it gets added to the currentEnemy...
  3. [SOLVED] Re: Game Combat: Fighting one enemy at a time? (Issue with static/non-static?)

    Ahh, objects, the things I never really knew how to work with. :P
    I tried to look up some tuts about objects and instances, but nothing really helped much.

    Nooby question time:
    Where would I...
  4. [SOLVED] Re: Game Combat: Fighting one enemy at a time? (Issue with static/non-static?)

    Ah, yes. I have a feeling it has to do with my boolean "fighting."
    It is set to false to begin with, until I start fighting anything. Then turns back to false when I run away.
    (I didn't add a...
  5. [SOLVED] Game Combat: Fighting one enemy at a time? (Issue with static/non-static?)

    Hello again.

    So I'm making a combat system for a game I'm working on.
    The combat is basically like old-school Runescape's, where the 2 participating combatants take turns hitting each other....
  6. Re: Using Modulus to alternate between 2 functions?

    After looking up how to properly increment and loop a value, I got it to work without any delay at all.
    Thanks.:cool:
  7. Re: Using Modulus to alternate between 2 functions?

    Ah, now you guys can tell how new I am to this.
    I didn't even provide enough information to get the help that I needed.

    enemyAttacksPlayer() is called 60 times per second when I'm close enough to...
  8. Using Modulus to alternate between 2 functions?

    Hello.
    This code is for a game I'm making.
    I'm new to using modulus, and I've been looking all over the place for a tutorial that I can understand. No luck. :\

    What I'm trying to do is get the...
  9. Replies
    6
    Views
    201

    [SOLVED] Re: Method sharing question.

    Indeed, down is initialized by this line:

    public AnimatedSprite down = new AnimatedSprite(SpriteSheet.dummy_down, 32, 32, 4);

    Nothing in that line is null, so I'm guessing it all has to do with...
  10. Replies
    6
    Views
    201

    [SOLVED] Re: Method sharing question.

    Oh, haha. Sorry if it hurt your head, I was showing that animSprite's value is supposed to change according to direction.
    This is the whole method I should have shown before:

    public void...
  11. Replies
    6
    Views
    201

    [SOLVED] Re: Method sharing question.

    That was exactly what I was looking for. :)
    Making variables IN the method while make a constructor solved part of my problem, but now I have an issue with one certain variable.

    Say I have 4...
  12. Replies
    6
    Views
    201

    [SOLVED] Method sharing question.

    Just a quick question. What is a way this could be coded?

    Imagine this:

    I have a class called "Monster."
    Class "Werewolf" extends "Monster."
    "Werewolf" has a method called "update()" for...
Results 1 to 12 of 12