It should work. Please work

This commit is contained in:
KikooDX 2020-05-15 12:27:09 +02:00
parent f227c86ab9
commit 32fdc174a3
1 changed files with 3 additions and 2 deletions

View File

@ -43,7 +43,7 @@ void draw_player(int x, int y)
void draw_level(char level[], unsigned int step, char polarity, int *start_x,
int *start_y, int tp_positions[])
{
int img_elevator_frame_count = img_elevator.width / 16;
int const img_elevator_frame_count = img_elevator.width / 16;
dclear(BG_COLOR);
unsigned int i = 0;
unsigned int x = 0;
@ -80,7 +80,8 @@ int *start_y, int tp_positions[])
dimage(x + DRAW_OFFSET_X, y + DRAW_OFFSET_Y, &img_semi_solid);
break;
case '^':
img_render_vram(img_sub(img_elevator, 0, 0, 16, 16), x, y);
img_render_vram(img_sub(img_elevator,
(step % img_elevator_frame_count) * 16, 0, 16, 16), x, y);
//dimage(x + DRAW_OFFSET_X, y + DRAW_OFFSET_Y, ani_elevator[(step/2)%16]);
break;
case 'S':