You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
616 B
35 lines
616 B
10 years ago
|
package mightypork.rogue.world.item.render;
|
||
10 years ago
|
|
||
|
|
||
|
import mightypork.gamecore.render.Render;
|
||
|
import mightypork.gamecore.resources.textures.TxQuad;
|
||
|
import mightypork.gamecore.resources.textures.TxSheet;
|
||
|
import mightypork.gamecore.util.math.constraints.rect.Rect;
|
||
|
import mightypork.rogue.world.item.ItemRenderer;
|
||
|
|
||
|
|
||
|
public class QuadItemRenderer extends ItemRenderer {
|
||
|
|
||
|
private final TxQuad txq;
|
||
|
|
||
|
|
||
10 years ago
|
public QuadItemRenderer(TxQuad txq)
|
||
|
{
|
||
10 years ago
|
this.txq = txq;
|
||
|
}
|
||
|
|
||
|
|
||
10 years ago
|
public QuadItemRenderer(TxSheet txs)
|
||
|
{
|
||
10 years ago
|
this.txq = txs.getQuad(0);
|
||
|
}
|
||
|
|
||
|
|
||
|
@Override
|
||
|
public void render(Rect r)
|
||
|
{
|
||
|
Render.quadTextured(r, txq);
|
||
|
}
|
||
|
|
||
|
}
|