Search:

Type: Posts; User: frogfury

Search: Search took 0.29 seconds.

  1. Replies
    6
    Views
    694

    Re: Identifying calling object

    Reading copeg's example I just realized that I had set my main class to private. No wonder it wasn't working...

    Thanks a lot for your time guys!:-bd
  2. Replies
    6
    Views
    694

    Re: Identifying calling object

    It does indeed return the class "player". Is there any way to find out if the method was called with regards to a subclass like orc, elf etc?
  3. Replies
    6
    Views
    694

    Identifying calling object

    Hey guys!

    I'm trying to do this:


    int x;
    x = orc.getFrags; //orc extends player

    In class player I have:
  4. Replies
    1
    Views
    383

    Just getting started!

    What is wrong with this line of code?


    System.out.println ( "Incorrect! " + firstAddend + " + " secondAddend + " = " + sum );

    firstAddend, secondAddend and sum are variables.

    Netbeans...
Results 1 to 4 of 4