mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-29 10:49:53 +02:00
Correct Stickman appearance
This commit is contained in:
@@ -1148,7 +1148,7 @@ void Renderer::render_parts()
|
|||||||
|
|
||||||
if (colour_mode!=COLOUR_HEAT)
|
if (colour_mode!=COLOUR_HEAT)
|
||||||
{
|
{
|
||||||
if (cplayer->elem<PT_NUM)
|
if (cplayer->elem<PT_NUM && cplayer->elem > 0)
|
||||||
{
|
{
|
||||||
colr = PIXR(elements[cplayer->elem].Colour);
|
colr = PIXR(elements[cplayer->elem].Colour);
|
||||||
colg = PIXG(elements[cplayer->elem].Colour);
|
colg = PIXG(elements[cplayer->elem].Colour);
|
||||||
@@ -1204,8 +1204,6 @@ void Renderer::render_parts()
|
|||||||
glVertex2f(cplayer->legs[12], cplayer->legs[13]);
|
glVertex2f(cplayer->legs[12], cplayer->legs[13]);
|
||||||
glEnd();
|
glEnd();
|
||||||
#else
|
#else
|
||||||
s = VIDXRES;
|
|
||||||
|
|
||||||
if (t==PT_STKM2)
|
if (t==PT_STKM2)
|
||||||
{
|
{
|
||||||
legr = 100;
|
legr = 100;
|
||||||
@@ -1229,23 +1227,23 @@ void Renderer::render_parts()
|
|||||||
//head
|
//head
|
||||||
if(t==PT_FIGH)
|
if(t==PT_FIGH)
|
||||||
{
|
{
|
||||||
draw_line(nx, ny+2, nx+2, ny, colr, colg, colb, s);
|
draw_line(nx, ny+2, nx+2, ny, colr, colg, colb, 255);
|
||||||
draw_line(nx+2, ny, nx, ny-2, colr, colg, colb, s);
|
draw_line(nx+2, ny, nx, ny-2, colr, colg, colb, 255);
|
||||||
draw_line(nx, ny-2, nx-2, ny, colr, colg, colb, s);
|
draw_line(nx, ny-2, nx-2, ny, colr, colg, colb, 255);
|
||||||
draw_line(nx-2, ny, nx, ny+2, colr, colg, colb, s);
|
draw_line(nx-2, ny, nx, ny+2, colr, colg, colb, 255);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
draw_line(nx-2, ny+2, nx+2, ny+2, colr, colg, colb, s);
|
draw_line(nx-2, ny+2, nx+2, ny+2, colr, colg, colb, 255);
|
||||||
draw_line(nx-2, ny-2, nx+2, ny-2, colr, colg, colb, s);
|
draw_line(nx-2, ny-2, nx+2, ny-2, colr, colg, colb, 255);
|
||||||
draw_line(nx-2, ny-2, nx-2, ny+2, colr, colg, colb, s);
|
draw_line(nx-2, ny-2, nx-2, ny+2, colr, colg, colb, 255);
|
||||||
draw_line(nx+2, ny-2, nx+2, ny+2, colr, colg, colb, s);
|
draw_line(nx+2, ny-2, nx+2, ny+2, colr, colg, colb, 255);
|
||||||
}
|
}
|
||||||
//legs
|
//legs
|
||||||
draw_line(nx, ny+3, cplayer->legs[0], cplayer->legs[1], legr, legg, legb, s);
|
draw_line(nx, ny+3, cplayer->legs[0], cplayer->legs[1], legr, legg, legb, 255);
|
||||||
draw_line(cplayer->legs[0], cplayer->legs[1], cplayer->legs[4], cplayer->legs[5], legr, legg, legb, s);
|
draw_line(cplayer->legs[0], cplayer->legs[1], cplayer->legs[4], cplayer->legs[5], legr, legg, legb, 255);
|
||||||
draw_line(nx, ny+3, cplayer->legs[8], cplayer->legs[9], legr, legg, legb, s);
|
draw_line(nx, ny+3, cplayer->legs[8], cplayer->legs[9], legr, legg, legb, 255);
|
||||||
draw_line(cplayer->legs[8], cplayer->legs[9], cplayer->legs[12], cplayer->legs[13], legr, legg, legb, s);
|
draw_line(cplayer->legs[8], cplayer->legs[9], cplayer->legs[12], cplayer->legs[13], legr, legg, legb, 255);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
if(pixel_mode & PMODE_FLAT)
|
if(pixel_mode & PMODE_FLAT)
|
||||||
|
@@ -60,8 +60,8 @@ int Element_STKM::update(UPDATE_FUNC_ARGS)
|
|||||||
int Element_STKM::graphics(GRAPHICS_FUNC_ARGS)
|
int Element_STKM::graphics(GRAPHICS_FUNC_ARGS)
|
||||||
|
|
||||||
{
|
{
|
||||||
/**pixel_mode = PSPEC_STICKMAN;
|
*pixel_mode = PSPEC_STICKMAN;
|
||||||
if ((int)sim->player.elem<PT_NUM)
|
/*if ((int)sim->player.elem<PT_NUM)
|
||||||
{
|
{
|
||||||
*colr = PIXR(elements[sim->player.elem].pcolors);
|
*colr = PIXR(elements[sim->player.elem].pcolors);
|
||||||
*colg = PIXG(elements[sim->player.elem].pcolors);
|
*colg = PIXG(elements[sim->player.elem].pcolors);
|
||||||
|
@@ -59,8 +59,8 @@ int Element_STKM2::update(UPDATE_FUNC_ARGS)
|
|||||||
int Element_STKM2::graphics(GRAPHICS_FUNC_ARGS)
|
int Element_STKM2::graphics(GRAPHICS_FUNC_ARGS)
|
||||||
|
|
||||||
{
|
{
|
||||||
/**pixel_mode = PSPEC_STICKMAN;
|
*pixel_mode = PSPEC_STICKMAN;
|
||||||
if ((int)sim->player2.elem<PT_NUM)
|
/*if ((int)sim->player2.elem<PT_NUM)
|
||||||
{
|
{
|
||||||
*colr = PIXR(elements[sim->player2.elem].pcolors);
|
*colr = PIXR(elements[sim->player2.elem].pcolors);
|
||||||
*colg = PIXG(elements[sim->player2.elem].pcolors);
|
*colg = PIXG(elements[sim->player2.elem].pcolors);
|
||||||
|
Reference in New Issue
Block a user