avec le mp3 ça devrait mieux marcher...
This commit is contained in:
parent
4856b3aa03
commit
82f8eeb13c
BIN
core/assets/sounds/effects/clickbutton.mp3
Normal file
BIN
core/assets/sounds/effects/clickbutton.mp3
Normal file
Binary file not shown.
|
@ -11,6 +11,9 @@ import com.badlogic.gdx.graphics.Texture;
|
||||||
import com.badlogic.gdx.graphics.g2d.Batch;
|
import com.badlogic.gdx.graphics.g2d.Batch;
|
||||||
import com.badlogic.gdx.graphics.glutils.ShapeRenderer;
|
import com.badlogic.gdx.graphics.glutils.ShapeRenderer;
|
||||||
import com.badlogic.gdx.math.MathUtils;
|
import com.badlogic.gdx.math.MathUtils;
|
||||||
|
import com.badlogic.gdx.audio.Sound;
|
||||||
|
|
||||||
|
import sagittarius.SagittariusGame;
|
||||||
|
|
||||||
public class Player extends EntityQuad {
|
public class Player extends EntityQuad {
|
||||||
|
|
||||||
|
@ -21,6 +24,7 @@ public class Player extends EntityQuad {
|
||||||
private ArrayList<Texture> texture;
|
private ArrayList<Texture> texture;
|
||||||
private int T = 0;
|
private int T = 0;
|
||||||
|
|
||||||
|
|
||||||
// ---------- CONSTRUCTORs ----------
|
// ---------- CONSTRUCTORs ----------
|
||||||
|
|
||||||
public Player(Planet home, Color color) {
|
public Player(Planet home, Color color) {
|
||||||
|
@ -89,10 +93,15 @@ public class Player extends EntityQuad {
|
||||||
|
|
||||||
if (active) {
|
if (active) {
|
||||||
if (Gdx.input.isKeyPressed(Keys.LEFT)) {
|
if (Gdx.input.isKeyPressed(Keys.LEFT)) {
|
||||||
|
|
||||||
this.angle += 100.0f / home.getRadius();
|
this.angle += 100.0f / home.getRadius();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
if (Gdx.input.isKeyPressed(Keys.RIGHT)) {
|
if (Gdx.input.isKeyPressed(Keys.RIGHT)) {
|
||||||
this.angle -= 100.0f / home.getRadius();
|
this.angle -= 100.0f / home.getRadius();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue