feat: trail fades out

This commit is contained in:
2025-11-18 19:22:01 +01:00
parent 89fe0e0f65
commit a5add0765f
3 changed files with 17 additions and 3 deletions

View File

@@ -1,6 +1,7 @@
#ifndef SIMS_HPP
#define SIMS_HPP
#include <SDL3/SDL_pixels.h>
#include <SDL3/SDL_render.h>
#include <utility>
@@ -10,10 +11,11 @@ private:
float y;
float vx = 1;
float vy = 1;
std::pair<float, float> old_positions[100];
std::pair<float, float> old_positions[200];
public:
SDL_Renderer* renderer;
SDL_Color color = {255, 255, 255, 255}; // white
Body(int x_pos, int y_pos);