mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-05-11 19:53:52 +00:00
parent
8a2a62ea1d
commit
119bff3514
1373 changed files with 12049 additions and 12049 deletions
|
|
@ -11,11 +11,11 @@ PaintingRenderer::PaintingRenderer()
|
|||
random = new Random();
|
||||
}
|
||||
|
||||
void PaintingRenderer::render(std::shared_ptr<Entity> _painting, double x, double y, double z, float rot, float a)
|
||||
void PaintingRenderer::render(shared_ptr<Entity> _painting, double x, double y, double z, float rot, float a)
|
||||
{
|
||||
// 4J - dynamic cast required because we aren't using templates/generics in our version
|
||||
std::shared_ptr<Painting> painting = dynamic_pointer_cast<Painting>(_painting);
|
||||
|
||||
shared_ptr<Painting> painting = dynamic_pointer_cast<Painting>(_painting);
|
||||
|
||||
random->setSeed(187);
|
||||
|
||||
glPushMatrix();
|
||||
|
|
@ -33,7 +33,7 @@ void PaintingRenderer::render(std::shared_ptr<Entity> _painting, double x, doubl
|
|||
glPopMatrix();
|
||||
}
|
||||
|
||||
void PaintingRenderer::renderPainting(std::shared_ptr<Painting> painting, int w, int h, int uo, int vo)
|
||||
void PaintingRenderer::renderPainting(shared_ptr<Painting> painting, int w, int h, int uo, int vo)
|
||||
{
|
||||
float xx0 = -w / 2.0f;
|
||||
float yy0 = -h / 2.0f;
|
||||
|
|
@ -113,7 +113,7 @@ void PaintingRenderer::renderPainting(std::shared_ptr<Painting> painting, int w,
|
|||
|
||||
}
|
||||
|
||||
void PaintingRenderer::setBrightness(std::shared_ptr<Painting> painting, float ss, float ya)
|
||||
void PaintingRenderer::setBrightness(shared_ptr<Painting> painting, float ss, float ya)
|
||||
{
|
||||
int x = Mth::floor(painting->x);
|
||||
int y = Mth::floor(painting->y + ya/16.0f);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue