Commit Graph

20 Commits

Author SHA1 Message Date
Eric-Paul Ickhorn 1e2f0f164f
Rename automatic tests to unit tests
Those tests were unit tests before, they've just been renamed due to a
deeper understanding of testing practices on the authors side.
2024-09-21 20:56:23 +02:00
Eric-Paul Ickhorn 86479af2fb Create type registry
It is useful  to have all types  registered before they  are allocated
because the memory needed for them can then be allocated before any of
it is  required, speeding up allocations because  a pool may have been
created beforehand.
2024-09-14 16:37:45 +02:00
Eric-Paul Ickhorn a8c941f041 Take UUID table as argument for ECS creation
The ECS needs a  UUID table to get UUIDs  for the entities. If none is
given into the creation function, it will create one itself.
2024-09-14 14:25:49 +02:00
Eric-Paul Ickhorn a6595f584c Add automatic tests
The first automatic  tests are for the ECS and  the utilities. None of
them are testing much.
2024-09-14 09:43:42 +02:00
Eric-Paul Ickhorn 25399640a4 Support tagging entities in ECS
The ECS previously wasn't capable of  adding tags to the entities; the
'C' of ECS wasn't there. The tagging still needs some tests.
2024-09-12 23:27:12 +02:00
Eric-Paul Ickhorn 81e10aa64b Fix a bug in the UUID assigner
In the UUID assigner, malloc() was  used somewhere where it would have
been correct to use realloc().
2024-09-12 23:25:00 +02:00
Eric-Paul Ickhorn e3e4e5ee84 Add first, inperformant version of ECS
The ECS can't handle many entities in this state; it is really slow.
This commit also doesn't contain any tests for its functions.
2024-09-11 12:18:33 +02:00
Eric-Paul Ickhorn 0408d19a72 Fix pool allocator
The pool allocator would only allocate one item and then stop, its
allocation wasn't reset correctly because of a comparison operator
being the wrong way around.
2024-09-11 11:40:58 +02:00
Eric-Paul Ickhorn 44885e161d Make windows close-able with the window buttons
A window can now be closed by  clicking on the X in the title bar. The
input  controller is  already running  in its own  thread, calling the
handler-functions given to it on an event's arrival.
2024-09-10 00:16:06 +02:00
Eric-Paul Ickhorn 3ddac3bfe0 Elaborate the root .gitignore
The gitignore  now contains  endings of common  executable and  object
code files on Windows  and Linux, as well as  some image file  endings
and, for the sole need of being complete, moving picture file endings.
2024-09-09 21:37:16 +02:00
Eric-Paul Ickhorn da3ce2dde9 Add (unsigned, signed) integer vectors
Those vectors are needed for storing a position  that is only on fixed
points on a grid. The  position and size of a window must be expressed
as integer vectors, for example.
2024-09-09 21:31:49 +02:00
Eric-Paul Ickhorn 19a7ac57ba Add GLAD OpenGL - function-loader library
The GLAD function loader library  is necessary for the renderer. While
it is possible to write one by hand, GLAD gets generated out of the GL
specification and works just fine.
2024-09-09 21:29:17 +02:00
Eric-Paul Ickhorn 79415a2929 Add engine core module
The core module will connect all other modules. Currently, it can only
display a message saying "The build-system is working!".
2024-09-09 14:54:06 +02:00
Eric-Paul Ickhorn 6644a59270 Add INI parser
The ini parser will come in handy for configurations, for example once
the time has come for adding shader packs.

The parser isn't tested yet; writing some (automatic) tests would be a
really good idea.
2024-09-09 05:49:48 +02:00
Eric-Paul Ickhorn c3fb07b871
Add first utilities
The utilities are grouped into the following categories:

- Math
  Matrices, vectors and special rounding functions are included in the
  math category. This still is severely lacking in functionality.

- Containers
  Datatypes for  storing arbitrary data in a  special way, for example
  for being able to search  through it quickly, in the  case of a map.
  Currently the only function in this category is for testing how long
  a string is, with a maximum number of bytes to check.

- Allocation
  Special-purpose memory allocators with restrictions on what they can
  allocate. The restrictions are used to be faster in those use cases.

- UUID
  Universally-unique  identifiers are  used to  identify one  specific
  object within the engine's lifetime.
2024-09-08 17:12:42 +02:00
Eric-Paul Ickhorn 004f089cf0
Modify build-script include folder keys
The key for getting the path of  the own module in the includes.txt is
no  longer '{self}', but rather '{module}', as that is a little easier
to understand.
2024-09-08 16:45:20 +02:00
Eric-Paul Ickhorn 9c691f817f
Fix bug with wrong module includes
The include statements generated  from the 'includes.txt' have'nt been
correct because of a prefixed string 'modules/' infront of the project
path. The local includes were  also not working because the 'modules/'
path element was missing between the project path and the module name.
2024-09-08 15:56:15 +02:00
Eric-Paul Ickhorn 2037f9af8f
Fix relative path in build-script
The build-script  assumed that it was nested  two levels deep from the
project's root  directory, even if  it is only nested  one level deep;
that bug is now fixed.
2024-09-07 22:11:56 +02:00
Eric-Paul Ickhorn f40ba7f27e
Add module skeletons
The "skeletons" of the modules contain a README explaining what it is
about and an includes.txt which is used by the build-script.
2024-09-07 22:11:10 +02:00
Eric-Paul Ickhorn ae29a46e8f
Add build script and gitignore
This initial commit adds a relatively advanced build-script and a very
small .gitignore file which should definitely be expanded.
2024-09-07 22:09:47 +02:00