[ADD] custom rendering system

This commit is contained in:
Menno
2021-05-18 11:20:57 +02:00
parent e46e26c729
commit 0bb4cc5e1d
29 changed files with 8840 additions and 805 deletions

29
src/entities/Entity.cpp Normal file
View File

@@ -0,0 +1,29 @@
#include "Entity.h"
#include <iostream>
namespace entities
{
Entity::Entity(const models::TexturedModel& model, const glm::vec3& position, const glm::vec3& rotation, float scale)
: model(model),
position(position),
rotation(rotation),
scale(scale)
{
}
void Entity::increasePosition(const glm::vec3& distance)
{
position.x += distance.x;
position.y += distance.y;
position.z += distance.z;
}
void Entity::increaseRotation(const glm::vec3& rotation)
{
this->rotation.x += rotation.x;
this->rotation.y += rotation.y;
this->rotation.z += rotation.z;
}
}