Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

(Java) Timer objects 'running slow'

Name: Anonymous 2011-03-07 1:33

Hi. I have a java game I made in a course at Uni. It has three Timer objects.
When I run the game from Notepad++ it runs perfectly (sweet-as game if I may say so myself).
I have made executable .jar files so that I can share it with friends. Unfortunately sometimes the game runs 'slow' when run from the .jar.

I have the feeling this has nothing to do with errors in code (due to the randomness of the error's occurence) but rather a runtime problem (if that's the right word..).

Anyone know what the problem might be?
Also plz keep elitism to a minimum

Name: Anonymous 2011-03-07 17:53

    public static final int UP = 0;
    public static final int LEFT = UP + 1;
    public static final int DOWN = LEFT + 1;
    public static final int RIGHT = DOWN + 1;   

Ugh,  I know their constants and it doesn't really matter performance wise, but this is much easier to read.


    public static final int UP = 0;
    public static final int LEFT = 1;
    public static final int DOWN = 2;
    public static final int RIGHT = 3;

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List