feature(foxy) Персонаж умеет бегать
This commit is contained in:
@@ -52,6 +52,14 @@ public class Main {
|
||||
}
|
||||
}
|
||||
|
||||
final int speed = 5 * 4;
|
||||
if(foxy.getState() == 1){
|
||||
if(foxy.getInverse()){
|
||||
foxy.setX(foxy.getX() - speed);
|
||||
} else {
|
||||
foxy.setX(foxy.getX() + speed);
|
||||
}
|
||||
}
|
||||
foxy.render();
|
||||
}
|
||||
|
||||
@@ -65,7 +73,7 @@ public class Main {
|
||||
GL11.glClear(GL11.GL_COLOR_BUFFER_BIT);
|
||||
render();
|
||||
Display.update();
|
||||
Display.sync(12);
|
||||
Display.sync(15);
|
||||
}
|
||||
|
||||
Display.destroy();
|
||||
|
||||
Reference in New Issue
Block a user