Jump to content

My pips


Maldesto

Recommended Posts

  • Administrator

you dont know difference between a class and a enum. remove scripter rank 

public enum Direction {

ENUM_UP(0, -1),

ENUM_DOWN(0, 1),

ENUM_RIGHT(1, 0),

ENUM_LEFT(-1, 0);

private int x;

private int y;

private Direction(int x, int y){

this.x = x;

this.y = y;

}

public int getEnumX(){

return x;

}

public int getEnumY(){

return y;

}

 

 

 

}

public class Direction{

public static final Direction UP = new Direction(0, -1) ;

public static final Direction DOWN = new Direction(0, 1) ;

public static final Direction LEFT = new Direction(-1, 0) ;

public static final Direction RIGHT = new Direction(1, 0) ;

private int x ;

private int y ;

private Direction(int x, int y){

this.x = x ;

this.y = y ;

}

public int getX(){

return x;

}

public int getY(){

return y;

}

}

  • Like 1
Link to comment
Share on other sites

public enum Direction {

ENUM_UP(0, -1),

ENUM_DOWN(0, 1),

ENUM_RIGHT(1, 0),

ENUM_LEFT(-1, 0);

private int x;

private int y;

private Direction(int x, int y){

this.x = x;

this.y = y;

}

public int getEnumX(){

return x;

}

public int getEnumY(){

return y;

}

 

 

 

}

public class Direction{

public static final Direction UP = new Direction(0, -1) ;

public static final Direction DOWN = new Direction(0, 1) ;

public static final Direction LEFT = new Direction(-1, 0) ;

public static final Direction RIGHT = new Direction(1, 0) ;

private int x ;

private int y ;

private Direction(int x, int y){

this.x = x ;

this.y = y ;

}

public int getX(){

return x;

}

public int getY(){

return y;

}

}

 

SUCH WOW 

 

I expect you to write a script then.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...