1 package ru
.deadsoftware
.cavecraft
.game
.objects
;
3 import com
.badlogic
.gdx
.math
.Rectangle
;
4 import com
.badlogic
.gdx
.math
.Vector2
;
6 import java
.io
.Serializable
;
8 public class Player
implements Serializable
{
10 public static int ANIM_SPEED
= 6;
14 public int width
, height
, dir
, texWidth
;
15 public boolean canJump
;
17 public boolean flyMode
= false;
20 public Player(Vector2 spawnPoint
, int gameMode
) {
21 this.gameMode
= gameMode
;
22 pos
= spawnPoint
.cpy();
23 move
= new Vector2(0, 0);
30 public Rectangle
getRect() {
31 return new Rectangle(pos
.x
+ 2, pos
.y
, width
, height
);