diff options
author | Aleksey Veresov <aleksey@veresov.pro> | 2021-03-04 12:20:09 +0300 |
---|---|---|
committer | Aleksey Veresov <aleksey@veresov.pro> | 2021-03-04 12:20:09 +0300 |
commit | f9cc5b35e228eec935b15eb7575ffb0ef826111f (patch) | |
tree | be6a1124184f2cfaa9bab0059531f7a0b72151cb /src | |
parent | 80eb56304c48f273adca0e11042b8501ab9f5ccc (diff) | |
download | takethis-f9cc5b35e228eec935b15eb7575ffb0ef826111f.tar takethis-f9cc5b35e228eec935b15eb7575ffb0ef826111f.tar.xz takethis-f9cc5b35e228eec935b15eb7575ffb0ef826111f.zip |
Fix.
Diffstat (limited to 'src')
-rw-r--r-- | src/game.c | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -1197,24 +1197,24 @@ void changeroom(int out) SDL_Color c = { 255, 255, 255, 255 }; SDL_Surface *s = TTF_RenderText_Blended(ttfont, b->msg, c); - SDL_Texture *t = SDL_CreateTextureFromSurface(ttrdr, s); - SDL_Rect dst = { 50 + b->x + fullx + transx, - 20 + b->y + fully + transy, s->w, s->h }; + SDL_Texture *t = SDL_CreateTextureFromSurface(ttrdr, s); + SDL_Rect dst = { 50 + b->x + transx, 20 + b->y + transy, + s->w, s->h }; SDL_RenderCopy(ttrdr, t, 0, &dst); SDL_DestroyTexture(t); SDL_FreeSurface(s); } } - r = ttplayer.room; + r = ttplayer.room->neighbours[out]; for (i = 0; i != r->bodies_count; ++i) { tt_body *b = r->bodies + i; if (b->msg) { SDL_Color c = { 255, 255, 255, 255 }; SDL_Surface *s = TTF_RenderText_Blended(ttfont, b->msg, c); - SDL_Texture *t = SDL_CreateTextureFromSurface(ttrdr, s); - SDL_Rect dst = { 50 + b->x + transx, 20 + b->y + transy, - s->w, s->h }; + SDL_Texture *t = SDL_CreateTextureFromSurface(ttrdr, s); + SDL_Rect dst = { 50 + b->x + fullx + transx, + 20 + b->y + fully + transy, s->w, s->h }; SDL_RenderCopy(ttrdr, t, 0, &dst); SDL_DestroyTexture(t); SDL_FreeSurface(s); |