nngn
Loading...
Searching...
No Matches
Entity Struct Reference

#include <entity.h>

Collaboration diagram for Entity:

Public Types

enum  Flag : std::uintptr_t { ALIVE = 1u << 0 , POS_UPDATED = 1u << 1 }
 

Public Member Functions

bool alive () const
 
bool pos_updated () const
 
void set_pos (nngn::vec3 p)
 
void set_vel (nngn::vec3 v)
 
void set_renderer (nngn::Renderer *p)
 
void set_collider (nngn::Collider *p)
 
void set_animation (nngn::Animation *p)
 
void set_camera (nngn::Camera *p)
 
void set_light (nngn::Light *l)
 
void set_parent (Entity *e)
 

Public Attributes

nngn::Flags< Flagflags = {}
 
nngn::vec3 p = {0, 0, 0}
 
nngn::vec3 v = {0, 0, 0}
 
float max_v = {}
 
nngn::vec3 a = {0, 0, 0}
 
nngn::Rendererrenderer = nullptr
 
nngn::Collidercollider = nullptr
 
nngn::Animationanim = nullptr
 
nngn::Cameracamera = nullptr
 
nngn::Lightlight = nullptr
 
Entityparent = nullptr
 

Member Enumeration Documentation

◆ Flag

enum Entity::Flag : std::uintptr_t
Enumerator
ALIVE 
POS_UPDATED 

Member Function Documentation

◆ alive()

bool Entity::alive ( ) const
inline
Here is the call graph for this function:
Here is the caller graph for this function:

◆ pos_updated()

bool Entity::pos_updated ( ) const
inline
Here is the call graph for this function:

◆ set_animation()

void Entity::set_animation ( nngn::Animation * p)

◆ set_camera()

void Entity::set_camera ( nngn::Camera * p)
Here is the call graph for this function:

◆ set_collider()

void Entity::set_collider ( nngn::Collider * p)

◆ set_light()

void Entity::set_light ( nngn::Light * l)
Here is the caller graph for this function:

◆ set_parent()

void Entity::set_parent ( Entity * e)
Here is the call graph for this function:

◆ set_pos()

void Entity::set_pos ( nngn::vec3 p)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ set_renderer()

void Entity::set_renderer ( nngn::Renderer * p)

◆ set_vel()

void Entity::set_vel ( nngn::vec3 v)

Member Data Documentation

◆ a

nngn::vec3 Entity::a = {0, 0, 0}

◆ anim

nngn::Animation* Entity::anim = nullptr

◆ camera

nngn::Camera* Entity::camera = nullptr

◆ collider

nngn::Collider* Entity::collider = nullptr

◆ flags

nngn::Flags<Flag> Entity::flags = {}

◆ light

nngn::Light* Entity::light = nullptr

◆ max_v

float Entity::max_v = {}

◆ p

nngn::vec3 Entity::p = {0, 0, 0}

◆ parent

Entity* Entity::parent = nullptr

◆ renderer

nngn::Renderer* Entity::renderer = nullptr

◆ v

nngn::vec3 Entity::v = {0, 0, 0}

The documentation for this struct was generated from the following files: