This commit is contained in:
Miloslav Ciz 2023-08-26 09:04:43 +02:00
parent b542fa8cc1
commit 08ac61347b
2 changed files with 13 additions and 1 deletions

View file

@ -1,4 +1,10 @@
- track size: 64x64x64
- block materials:
- concrete, normal
- dirt, a bit slidy, decreases speed a bit?
- ice? super slidy (like in the old TM)
- accelerator, probably: auto-accelerates, plus increases accel.
- decelerator? decreases speed a lot?
- EFFICINT MAP DRAWING:
- map will be subdivided into subblocks (probably 16x16x16 or 8x8x8), only
nearest subblocks (and possibly only those in viewing direction will be
@ -27,6 +33,8 @@
- background textures: 128x128 with image-specific 256 color palette,
pixel access shouldn't be as time critical here
- other textures 64x64 with direct 565 values stored
- hmm or possibly 256x256 backgrounds with 16 color image specific palette
and dithering? check out how that would look
- Rendering: two pass: 1st pass renders the scaled down background (possibly not
rendering floor, can be just pure green for "grass") to prevent overflows,
second pass renders the tracks (or the nearest part of it).

View file

@ -31,7 +31,7 @@ int main(int argc, char *argv[])
screenSurface = SDL_GetWindowSurface(window);
//SDL_ShowCursor(0);
SDL_ShowCursor(0);
SDL_PumpEvents();
sdlKeyboardState = SDL_GetKeyboardState(NULL);
@ -41,6 +41,10 @@ int main(int argc, char *argv[])
SDL_PumpEvents();
sdlKeyboardState = SDL_GetKeyboardState(NULL);
running = !sdlKeyboardState[SDL_SCANCODE_Q];
SDL_RenderClear(renderer);
SDL_RenderCopy(renderer,texture,NULL,NULL);
SDL_RenderPresent(renderer);
}
SDL_DestroyTexture(texture);