Copyright (c) 2015-17 Luke Montalvo [email protected]
BasicEventEngine is an event-driven game engine which the user can interface with via the Sprite, Sound, Background, Font, Path, Timeline, Mesh, Light, Object, and Room classes. The Room class is used to organize the resources for each section of the game and the Object class is used to act upon the events from the main loop. A small example is included in the resources directory.
The available events are the virtual functions of the Object class which are on
lines 100 to 128 in the file bee/resources/object.hpp
The software is in early alpha so do not expect any sort of stability. I'm slowly adding more content to the wiki so be sure to check that out first but if you still have any questions or comments, feel free to email me. Also feel free to contribute to the engine code or make feature requests, preferably via Github. And above all, report bugs! :)
This program can compile under Arch Linux, Ubuntu 15.10, and Windows 10 but at the moment support will only be offered for Linux.
-
Intall git-lfs so that you can download the resources for the example.
# For Arch Linux, it's available in the AUR pacaur -y git-lfs
-
Install the required libraries:
# Arch Linux sudo pacman -S cmake sdl2 sdl2_image sdl2_ttf sdl2_mixer sdl2_net glew glm freeglut libxmu assimp # Ubuntu sudo apt-get install cmake libsdl2-dev libsdl2-image-dev libsdl2-ttf-dev libsdl2-mixer-dev libsdl2-net-dev libglew-dev libglm-dev freeglut3-dev libxmu-dev libassimp-dev
-
Download the additional library submodules:
git submodule update --init --recursive
-
(Optional) Edit the file
resources/resources.hpp
in order to add or remove resources which are located in their corresponding subdirectory. -
Compile and run the program with the following commands:
# Build with debug mode in the build/ subdirectory ./build.sh debug build
See the wiki page for additional uses of ./build.sh
:
Even though this program can compile on Windows 10, I am not offering any support for any Windows platform because it is terribly annoying to get anything to compile correctly. If you dare attempt to compile on Windows, then follow the below instructions.
Compiling on Windows 10 is actually much easier now with the latest CMake and Visual Studio.
-
(Recommended) Clone the project with Github Desktop for Windows to be able to easily download the resources for the example.
-
Install the required libraries from their official websites: SDL2, SDL2_image, SDL2_ttf, SDL2_mixer, SDL2_net, GLEW, GLM, and ASSIMP. The current project setup assumes that each of these libraries has its DLL in the same directory as the executable (e.g.
win/bin
), its header file in awin/include
subdirectory, and its .lib file inwin/lib
Feel free to download the libraries from here and extract them towin/
. -
Install CMake and Visual Studio Community 2017 (or your favorite CMake-compatible IDE).
-
(Optional) Edit the file
resources/resources.hpp
in order to add or remove resources which are located in their corresponding subdirectory. -
Build Bullet by running
lib/bullet3/build_visual_studio_without_pybullet_vr.bat
and then compiling BulletCollision, BulletDynamics, BulletSoftBody, and LinearMath from the generated Visual Studio Solution. -
Open the CMake GUI and set the appropriate source and build directories, e.g.
C:\Users\Luke\Documents\GitHub\BasicEventEngine
andC:\Users\Luke\Documents\GitHub\BasicEventEngine\build
. -
Configure the project and select the appropriate build system, e.g.
Visual Studio 15 2017
, and then Generate the project. -
Open the Visual Studio solution file from
build/BasicEventEngine.sln
. -
Build the ALL_BUILD target generated by CMake.
-
Run the compiled executable by copying it to the directory which contains the required resources and DLLs, e.g.
win/bin
.
This project is under the MIT License so feel free to do basically whatever you want with the code.