mirror of
https://github.com/Nimac0/SDL_Minigame
synced 2026-01-12 10:13:42 +00:00
20 lines
397 B
C++
20 lines
397 B
C++
#pragma once
|
|
#include "SDL.h"
|
|
#include "Component.h"
|
|
|
|
class TransformComponent;
|
|
|
|
class ColliderComponent : public Component
|
|
{
|
|
public:
|
|
SDL_Rect collider;
|
|
const char* tag;
|
|
TransformComponent* transform;
|
|
bool hasCollision; //added for removing collision of destroyed projectiles
|
|
|
|
ColliderComponent(const char* tag);
|
|
|
|
void init() override;
|
|
void update() override;
|
|
void removeCollision();
|
|
}; |