Aether Engine
April 5, 2012 in Games, Linux, My Games, My Software, Software by Raptor85
It occurs to me that I rarely update my website, though I really should be doing so. Old habits die hard I guess. (And yeah…I’ve been promising for YEARS that I’ll start uploading all my older games “soon” and it still hasn’t happened…granted most of them I’ll have to find a way now to read them off 5.25 floppy disks or tape and I’m not 100% sure how I’ll go about that)
erm….yeah..back to the point
Newest version of my game engine which now ACTUALLY has a name is nearing public release for at least the linux/windows builds(I’ve dubbed it “Aether Engine”…partly because it has somewhat to do with a project I’m working on….somewhat just because I want to stamp a “Powered By Aether” logo on everything). It DOES compile and run on Android-ndk and MAC but that’ll happen…later…at a more stable build as it takes a lot of effort to get it set up properly at the moment (Especially for MAC…since I don’t have one to really test)
Since I haven’t really posted about it before here (though I have on other sites…) A quick feature rundown.
- script engine, through which the main game logic is written
- “State” based system for controlling game flow
- “Message Pump” to dispatch control messages to any other game module (Including those written entirely in Angelscript
- “Console” and error handling systems to provide useful output when something goes wrong
- Fonts sytem for loading system-independant bitmap fonts (a small program I wrote is also available to generate a bitmapped font and font config file from a .ttf)
- OpenGL based rendering, supporting both 2d and 3d (most of the functionality is 2d based though)
- Integrated mouse/joystick/keyboard bindings, angelscript CAN directly access the states of all controls but the bindings system allows easy control-remapping for users
- Multiple scenegraph/entity types to base off of (currently only box2d based scene manager/entity system full works)..but it’s 100% possible to write one entirely in angelscript (it would just be slower)
And more, but for now I’ll post a code snip…now this isn’t how you would generally do this, but this shows some of the versatility I’m trying to design in, this spawns a few entities and adds “extra” parts to them from the main class….normally that would be a part of the entity itself but this is for testing purposes. This spawns 2 balls of different sizes in a small enclosed area, with “earth-like” gravity where they bounce around till they settle, since it sets no rendering properties default is used (which baiscly just draws collision bounding boxes at default camera position of 0,0,0) (there’s a lot of debug functions left in that won’t be in final, don’t take this as what it’ll look like when done, much of these functions don’t work in non-debug builds)
class Game : GamestateInterface
{
world @testworld;
Game()
{
@testworld = CreateWorld(Vec2D(0,-9.8));
entity @ball = testworld.CreateEntity("Ball",Vec2D(0,0),0);
entity @wall = testworld.CreateEntity("Wall",Vec2D(0,-4),0);
}
int GetDrawOrder()
{
return 0;
}
void Activate()
{
}
void Deactivate()
{
}
void Run(uint deltatime)
{
testworld.Step(deltatime);
}
void ConsoleCommand(const string &in str)
{
}
}
class Ball : PhysicsEntity
{
Ball()
{
bullet = true;
bodytype = 1;
}
void init(entity@ obj)
{
obj.AddCircle(Vec2D(0,0),0.1,1,0.5,0.5);
}
}
class Wall : PhysicsEntity
{
Wall()
{
bullet = false;
bodytype = 0;
}
void init(entity@ obj)
{
obj.AddBox(Vec2D(0,0),10,1,0,1,0.5,0.1);
obj.AddBox(Vec2D(-3,3),1,10,0,1,0.5,0.1);
obj.AddBox(Vec2D(3,3),1,10,0,1,0.5,0.1);
}
}