medfall

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit a87cb9b4116f3b667977eb7c0db5f17ef0fc546e
parent b26515bf61ae1777253ca42071fdcc064adbd3c9
Author: Michael Savage <mikejsavage@gmail.com>
Date:   Wed Aug 31 16:02:16 -0700

Oops

Diffstat:
pp.cc | 1-
terrain_manager.cc | 3+--
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/pp.cc b/pp.cc @@ -45,7 +45,6 @@ void write_tile( const std::string & dir, const int tx, const int ty ) { size_t compressed_len = LZ4_compress_HC( ( const char * ) tile, compressed, sizeof( tile ), LZ4_compressBound( sizeof( tile ) ), 6 ); std::ofstream comp( compfile, std::ios::out | std::ios::binary ); comp.write( compressed, compressed_len ); - comp << std::to_string( w ) + " " + std::to_string( h ); comp.close(); delete compressed; } diff --git a/terrain_manager.cc b/terrain_manager.cc @@ -75,8 +75,7 @@ static void terrain_load_tile( CompressedTile ct = tm->compressed_tiles[ tx ][ ty ]; int width, height; - // TODO: we get cracks without the + 10 and i don't understand why - size_t out_size = ( TILE_SIZE + 10 ) * ( TILE_SIZE + 10 ); + size_t out_size = ( TILE_SIZE + 1 ) * ( TILE_SIZE + 1 ); // TODO: width/height might not be TILE_SIZE on the edges of the map width = height = TILE_SIZE + 1; u8 * pixels = ( u8 * ) malloc( out_size );