Files
OLCCodeJam2020-The-Great-Ma…/The Great Machine/Camera.cpp
2020-09-02 22:04:42 +01:00

23 lines
355 B
C++

#include "Camera.hpp"
#include "Things.hpp"
#include "Logger.hpp"
void Camera::Update(float fTime)
{
if (_Track == nullptr) return;
Coords.x = _Track->Coords.x - (ViewPort.x / 2);
Coords.y = _Track->Coords.y - (ViewPort.y / 2);
}
void Camera::Input(olc::PixelGameEngine* engine)
{
}
void Camera::TrackEntity(Entity* entity)
{
_Track = entity;
}