blob: e7519b8b1c519607cd36886ac6cfbf6489dde3de (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
package ch.asynk.gdx.boardgame.ui;
import com.badlogic.gdx.graphics.g2d.Batch;
import com.badlogic.gdx.graphics.g2d.TextureRegion;
public class Bg extends Element
{
private TextureRegion region;
public Bg(TextureRegion region)
{
this.region = region;
rect.set(0, 0, region.getRegionWidth(), region.getRegionHeight());
}
@Override public void drawReal(Batch batch)
{
batch.draw(region, rect.x, rect.y, rect.width, rect.height);
}
}
|