From 44cf354f43953fff2fe34c2888b57db5adc18a4b Mon Sep 17 00:00:00 2001 From: Michal Idziorek Date: Sat, 23 Sep 2017 23:28:52 +0200 Subject: added separate emscripten Makefile --- main.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'main.cpp') diff --git a/main.cpp b/main.cpp index a218da5..59e1e4a 100644 --- a/main.cpp +++ b/main.cpp @@ -447,9 +447,11 @@ void main_loop(void *arg) break; } //show map !? +#ifndef __EMSCRIPTEN__ rect={100,20,150,150}; SDL_RenderCopy(ctx->ren,ctx->textures[8],NULL,&rect); +#endif if(ctx->world.player.dead) { sdl_put_str(ctx->ren, ctx->textures[3],300, -1, 10,"LUNATIC LEMMY DIED!",250,100,100,19,ctx->win_width,ctx->win_height,1,2); @@ -506,6 +508,7 @@ int main(int, char**){ ctx->textures.push_back(sdl_load_texture("gridder02.bmp",255,255,255,ctx->ren)); ctx->textures.push_back(sdl_load_texture("gridder03.bmp",255,255,255,ctx->ren)); // PERLIN GENEARTED MAP +#ifndef __EMSCRIPTEN__ ctx->textures.push_back(SDL_CreateTexture(ctx->ren, SDL_PIXELFORMAT_RGBA8888, SDL_TEXTUREACCESS_TARGET, 1024, 768)); double seed=22; @@ -576,12 +579,9 @@ int main(int, char**){ } } SDL_SetRenderTarget(ctx->ren, NULL); - +#endif // PERLIN GENEARTED MAP OVER - - - ctx->show_tiles_size=ctx->win_height/15; ctx->show_tiles_back=ctx->win_width/ctx->show_tiles_size*0.25; -- cgit v1.2.3