com.ethereal.rm.game.objects.AbstractGameObject.java Source code

Java tutorial

Introduction

Here is the source code for com.ethereal.rm.game.objects.AbstractGameObject.java

Source

/*
 * 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.ethereal.rm.game.objects;

import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.math.Vector2;

/**
 *
 * @author Boris Serafimov <b.b.serafimov@gmail.com>
 * @date Feb 27, 2017
 */
public abstract class AbstractGameObject {

    public Vector2 position;
    public Vector2 dimension;
    public Vector2 origin;
    public Vector2 scale;
    public float rotation;

    public AbstractGameObject() {
        position = new Vector2();
        dimension = new Vector2(1, 1);
        origin = new Vector2();
        scale = new Vector2(1, 1);
        rotation = 0;

    }

    public void update(float deltaTime) {
    }

    public abstract void render(SpriteBatch batch);
}