From e209c9c2f1eeb2a534dd9be26a94fb6d954f0b0f Mon Sep 17 00:00:00 2001 From: onpon4 Date: Sun, 22 Jan 2017 00:22:03 -0500 Subject: [PATCH] Removed some unnecessary specificity. There was no need for specific bit sizes for these integers; the default int will do just fine. --- src/gfx.cpp | 2 +- src/player.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gfx.cpp b/src/gfx.cpp index 9f87f18..4109c0a 100644 --- a/src/gfx.cpp +++ b/src/gfx.cpp @@ -316,7 +316,7 @@ void gfx_drawCircle(int xc, int yc, int R, SDL_Surface *PIX, int col) void gfx_drawRect(SDL_Surface *dest, int x, int y, int w, int h, Uint8 red, Uint8 green, Uint8 blue) { - SDL_Rect r = {(int16_t)x, (int16_t)y, (uint16_t)w, (uint16_t)h}; + SDL_Rect r = {x, y, w, h}; SDL_FillRect(dest, &r, SDL_MapRGB(screen->format, red, green, blue)); gfx_drawLine(dest, x, y, x + w, y, SDL_MapRGB(screen->format, 255, 255, 255)); diff --git a/src/player.cpp b/src/player.cpp index 831ffd4..31f9dd1 100644 --- a/src/player.cpp +++ b/src/player.cpp @@ -112,7 +112,7 @@ void player_flushInput() while (SDL_PollEvent(&engine.event)){} } -static enum keys mapkey(uint32_t code) { +static enum keys mapkey(int code) { switch (code) { case SDLK_UP: case SDLK_KP_8: