28 lines
637 B
Java
28 lines
637 B
Java
/*
|
|
* To change this license header, choose License Headers in Project Properties.
|
|
* To change this template file, choose Tools | Templates
|
|
* and open the template in the editor.
|
|
*/
|
|
package com.darkrp2d.entities;
|
|
|
|
import com.badlogic.ashley.core.Entity;
|
|
import com.darkrp2d.entities.components.PositionComponent;
|
|
|
|
/**
|
|
*
|
|
* @author Julian
|
|
*/
|
|
public class Character {
|
|
|
|
//Singletone
|
|
private static Entity character;
|
|
public static Entity create() {
|
|
if(character == null) {
|
|
character = new Entity();
|
|
character.add(new PositionComponent());
|
|
}
|
|
return character;
|
|
}
|
|
|
|
}
|