On the
first week of Game Engine Design our professor, Saad R. Khattak, stated that
there are certain terms and concepts that every student must know and must be
familiar with.
Terms you must know:
-
Stack: A stack is an area of the computer’s memory that
temporary stores variables, and automatically manages memory for you. The size
of the stack changes as functions push and pop local variables, but the stack
does have a size limit on the variables that it can store. The stack can access
variables faster than the heap, but can only access local variables.
-
Heap: A heap is an area of the computer’s memory
that temporary stores variables, but does not automatically manage memory for
you. The heap does not have a limit on memory size and can be accessed globally,
but it is slower to access those variables due to the use of pointers to access
the memory on the heap. The heap can cause memory leaks in your program if you
do not allocate and deallocate memory properly.
Concepts you must be familiar with:
-
Pointers: The value of a pointer is the value
of another object that is stored elsewhere in the computer’s memory using its
address.
-
Containers: Containers are classes, data
structures, or abstract data type that are used to store objects in an
organized way.
-
Iterators: An iterator is an object that
enables a programmer to navigate a container.
-
Templates: Template is a feature that allows
functions and classes to operate with any data type.
-
Template Inheritance: Template inheritance is a method to
manage templates. Template inheritance can inherit contents of one template to
another, and can change certain contents.
-
Callback Functions: Callback is part of a code that is
passed as an argument to another code, which is then expected to execute in a
different point in time.
-
Macros: Macros are a set of instruction that tells how
certain inputs should be mapped in order to a replacement output.
-
Algorithms: Algorithms are a list of procedures
for calculations.
-
String Manipulation: String manipulation is how to
manage or handle a sequence of characters.
Our
professor also introduced a topic called "Entity Component System (ECS)".
Entity Component System (ECS)
-
An
engine is a data driven design that needs a component and a system to operate. There
are three components to the ECS are the entity, the component, and the system.
o
Entity: The entity is a general purpose object,
usually only consists of a unique ID. The entity can be thought to be like a key
without a purpose.
o
Component: The component is the raw data for
the object, and how it interacts with the world. The component can be thought
to be like the characteristics to give a key a purpose.
o
System: Each system runs and performs actions continuously
on every entity that possess the same component with that system. The system
can be thought to be like a lock that only works with correct key.