Claude Chappe' Curse - A C Game
Logo Institut d'Informatique Claude Chappe Logo Université de Le Mans Logo Raeptor Production
 
Loading...
Searching...
No Matches
BoxCShape Class Reference
Inheritance diagram for BoxCShape:
Collaboration diagram for BoxCShape:

Public Member Functions

void constructor ()
 Constructor for the BoxCShape class.
 
void get_priority (int *priority)
 Retrieves the priority value.
 
void load ()
 Loads the box collision shape.
 
void save (FILE *file)
 Saves the current state of the BoxCShape to a file.
 
void get_model (Model **model)
 Retrieves the model associated with the BoxCShape.
 
- Public Member Functions inherited from CShape
void is_cshape (bool *cshape)
 Checks if the given shape is a cshape.
 
void get_model (Model **model)
 Retrieves the model associated with the CShape.
 
void get_shader (Shader *shader)
 Retrieves the shader information.
 
void prepare_render (mat4 modelMatrix, Shader activeShader)
 Prepares the rendering process by setting up the model matrix and activating the shader.
 
void render (mat4 modelMatrix, Shader activeShader)
 Renders the shape using the provided model matrix and active shader.
 
- Public Member Functions inherited from Node
void constructor ()
 Constructor for the Node class.
 
void initialize_node ()
 Initializes a node.
 
void get_glow_shader (Shader *shader)
 Retrieves the glow shader.
 
void get_settings_data (void ***ptr, int *length)
 Retrieves settings data.
 
void load ()
 Loads the necessary resources or data for the node.
 
void save (FILE *file)
 Saves the current state to the specified file.
 
void prepare_render (mat4 modelMatrix, Shader activeShader)
 Renders a node using the specified model matrix and shader.
 
void render ()
 Renders the node.
 
void update_global_position (vec3 pos, vec3 rot, vec3 scale)
 Updates the global position of a node.
 
void update (vec3 pos, vec3 rot, vec3 scale)
 Updates the position, rotation, and scale of a node.
 
void on_resize ()
 Handles the resize event for the node.
 
void free ()
 Frees the resources allocated by the object.
 
void is_cshape (bool *cshape)
 Checks if the current shape is a custom shape.
 
void is_body (bool *body)
 Sets the body status of the node.
 
void is_area (bool *area)
 Checks if the current node is within a specified area.
 
void is_render_target (bool *render_target)
 Sets the render target status.
 
void is_gui_element (bool *result)
 Determines if the current node is a GUI element.
 
void add_child (Node *child)
 Adds a child node to a parent node.
 
void add_child_and_realloc (Node *child)
 Adds a child node to a parent node and reallocates memory if necessary.
 
void remove_child (Node *child)
 Removes a child node from a parent node.
 
void remove_child_and_realloc (Node *child)
 Removes a child node from a parent node and reallocates memory if necessary.
 
void remove_child_and_free (Node *child)
 Removes a child node from a parent node and frees the memory of the child node.
 
void remove_child_and_free_and_realloc (Node *child)
 Removes a child node from a parent node, frees the memory of the child node, and reallocates memory if necessary.
 
int index_of_child (Node *child)
 Retrieves the index of a child node in a parent node's children array.
 
void print (int level)
 Prints the details of a node at a specified level of indentation.
 
void emit_ready (...)
 Emits the 'ready' signal for the node.
 
void emit_update (...)
 Emits an update event for the node.
 
void emit_signal (...)
 Emits a signal if the node has a script and the script has a signal handler.
 

Static Public Attributes

static Model _model = {0}
 Static instance of the Model structure.
 
- Static Public Attributes inherited from CShape
static Shader collisionShader
 Shader used for collision detection.
 
- Static Public Attributes inherited from Node
static Shader glowShader = 0
 A static Shader variable used for glow effect.
 

Additional Inherited Members

- Public Attributes inherited from Node
void * object
 
struct Node ** children
 
struct Nodeparent
 
u16 length
 
u8 type
 
u8 flags
 
vec3 pos
 
vec3 rot
 
vec3 scale
 
vec3 globalPos
 
vec3 globalRot
 
vec3 globalScale
 
Behaviorbehavior
 
BehaviorAttributeattribute
 
u8 attributes_count
 
Shader shader
 

Member Function Documentation

◆ constructor()

void BoxCShape::constructor ( )
inline

Constructor for the BoxCShape class.

This function initializes a new instance of the BoxCShape class. It sets up the necessary properties and state for the box shape.

◆ get_priority()

void BoxCShape::get_priority ( int *  priority)
inline

Retrieves the priority value.

This function assigns the priority value to the provided pointer.

Parameters
priorityA pointer to an integer where the priority value will be stored.

◆ load()

void BoxCShape::load ( )
inline

Loads the box collision shape.

This function is responsible for initializing and loading the necessary resources for the box collision shape. It sets up the vertices, indices, and other required data for rendering the box shape.

◆ save()

void BoxCShape::save ( FILE *  file)
inline

Saves the current state of the BoxCShape to a file.

This function writes the current state of the BoxCShape object to the specified file. The file should be opened in a mode that allows writing.

Parameters
fileA pointer to the FILE object where the state will be saved.

◆ get_model()

void BoxCShape::get_model ( Model **  model)
inline

Retrieves the model associated with the BoxCShape.

This function assigns the model associated with the BoxCShape to the provided pointer. The model is represented by the Model structure.

Parameters
[out]modelA double pointer to the Model structure where the model will be stored.

Member Data Documentation

◆ _model

Model BoxCShape::_model = {0}
static

Static instance of the Model structure.

This static variable holds the model data for the box shape. It is initialized to zero and used throughout the BoxCShape class to represent the box shape.


The documentation for this class was generated from the following file: