package com.ady.timerunner;

import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.Sprite;
import com.badlogic.gdx.math.Vector2;

/**
 * Created by ADY on 26.1.2018.
 */

public class World {
    public Sprite sprite2;
    public Sprite sprite;
    Vector2 center = new Vector2(0, 0);
    float acc = 1.4f;
    float size = 0;
    public float projectileg = 0.0001f;

    public World(Texture text, Texture text2, float size) {
        sprite = new Sprite(text);
        sprite2 = new Sprite(text2);
        //  sprite.setOrigin(512,512);


        //  sprite.setCenter(size/2f,size/2f);
        this.size = size;

        sprite.setCenter(960, -size / 2 + 250);
        sprite.setScale(6.85f);
        sprite2.setCenter(960, -size / 2 + 250);
        sprite2.setScale(6.85f);
        center.set(960, -size / 2 + 250);

    }

    public void changeCenter(float x, float y) {
        center.set(x, y);
        sprite.setCenter(x,y);
        sprite2.setCenter(x,y);
    }
}
