4 Hugues Ross - Blog: Akradion
Hugues Ross
Showing posts with label Akradion. Show all posts
Showing posts with label Akradion. Show all posts

9/6/15

General Update: Not Dead, Just Forgetful

I've been quite busy working on projects this past month, but you wouldn't know it from looking at this blog.

About 2 weeks after my last post, I made a 1000+ word update post for Halberd and promptly forgot to publish it. After that, I started remaking Akradion and totally forgot to even write any posts! I'll be posting the Halberd update(with a disclamer indicating its age), but I felt the need to put together a general update post now. This is a pretty good time to do it, since it has been about a month since the big post, and a few deadlines have passed.

The Goal, and the Results

The goal for the rest of this summer was to work on 3 things: Akradion, Halberd, and a One Game a Month entry. I wanted the OGaM entry and Akradion to be finished by now, and Halberd to have caught up with it's previous incarnation, possibly with a demo.

That was a pretty tall order, and I certainly didn't complete all of that, but I don't think I did too poorly either. I've made a decent bit of progress on Halberd, and most of the time lost comes down to figuring out and implementing things that the last version had simply left out. It's a little like finding an old todo list and realizing that half the entries still need to be finished.

As for Akradion, I actually did finish it before the start of the semester, but I don't want to release it just yet. I haven't had a chance to test out the Windows version on any actual machines running Windows, so I can't guarantee that it'll even run! It seems fine from testing it under Linux, but I still want to ensure that it works in its natural environment.

Coming Up

Obviously, I need to make a few posts. First, I'll be posting the old Halberd update shortly. Afterwards, I'll see if I can put together another update post for the project. Once I've finished testing Akradion, the game will be going up here as well. With any luck, I'll get a chance to run the testing next week, so you can probably expect it around next Friday. I also need to make one more post, specifically about school, but I think I'll leave that one to explain itself.

7/18/14

Akradion Update 8

Changelog:

Akradion

  • Added 3 new levels
  • Strong bricks now properly drop powerups
  • Strong bricks should no longer collide when disappearing
  • Strong bricks are now (slightly) less noisy
  • Explosions and balls now affect strong bricks as intended
  • Fixed a bug where powerups would occasionally bounce off the paddle without being collected
  • Fixed a bug where the split powerup could create an infinite loop and crash the game
  • Multiple variants of sounds can now be loaded to add more variety
  • Added Sound Effects for:
    • Explosions
    • Split powerup
    • Nitro powerup
    • Life powerup
    • Speed powerup
    • Slow powerup
    • Doom powerup
    • Game start
    • Launching a ball
    • Bouncing off a wall
  • Fixed a bug where dying and resetting the game wouldn't reset ball speed
  • Fixed a bug where a powerup could be collected several times
  • Fixed a bug where certain powerups could make the game crash when the next level loaded

DFEngine

  • foreach'd scripts can now include other scripts properly
  • loadSound now returns the sound's id
  • playSound can now take a numerical id instead of the sound's name

Unfortunately, despite the amount I've gotten done I don't really have much to say. Things seem to be progressing well, and I've gotten rid of tons of smaller bugs along with one or two big ones. In addition to this, I added most of the sounds I needed. I could've done all of them, but I got totally wiped out for the latter portion of the week. I think it may have been from lack of sleep. Hard to say, really.

With any luck, the game will be out next week. Sorry again for the lackluster post!

7/11/14

Akradion Update 7

Changelog:

Akradion

  • Added the usual dfEngine splash screen for when the game starts.
  • The title screen now fades out when starting a new game.
  • Running out of balls now properly ends the game, sending you back to the title screen to try again.
  • Added switches that cause special walls to become solid/non-solid when hit.
  • Added 4 new levels.
  • Added a high score which is saved across sessions.
  • Fixed a random crash bug related to level clearing
  • Added a dangerous new 'powerup' that temporarily disables your paddle.
  • Added a game over message that lets you give up your score to continue on the current level, or go back to the title screen.
  • Added some pretty fireworks to the win screen.
  • Fixed a bug where levels wouldn't always end for some reason.

DFEngine

  • Added a command to destroy all entities.
  • Entities can now be marked as persistent, making them stick around when the destroy all command is run.
  • Entities now have a 'type' variable, for grouping entities.
  • Added a command to make all entities of a specific type run a script immediately. Note that this script won't have access to global data, only local.

As this project nears its close, I've started trying to do a bit more testing than usual. A certain friend of mine in particular has been quite helpful. He seems to possess the amazing ability to find bugs in just about anything. He surprises me every time I show him something, and this time was no exception. He managed to break the game in 3 or 4 different ways that I'd never seen before! I think I've fixed all of the issues he uncovered at this point, but it took a lot of effort.

It this point, there are two things left to finish up: The levels, and the audio. The game currently has 12 levels, and my goal for release is 15. I always meant for Akradion to be short, and I think 15 will give the game enough flesh to take a bit of time to beat without overstaying its welcome. I should be able to finish the last three levels easily by next week, but the audio will take a bit longer. Right now, I'm not very happy with any of the game's sound effects. it isn't too surprising, since I just haphazardly ripped them from previous projects. I need to go down the list and make new sounds for everything, as well as making sure all of the audio is around the same volume. I also need a bit of music, and I've convinced Peter to compose for me again. I'm still not sure how long that'll take He's pretty busy, but I think he can probably finish that up within the next week or two, if only because of how little is needed.

Lastly, I want to try and get a decent video of Akradion's gameplay, so that I can release it alongside the game. Recording it shouldn't be too difficult, but I want to try and edit it a bit and that could make things take longer. Overall, I think the game will be finished by July 25th, although I'll try and release it earlier if possible. I've definitely overshot my original estimate, but I managed to add plenty of cool features and engine improvements that I hadn't planned on. I'm pretty happy with my progress.

7/4/14

Akradion Update 6

Changelog:

Akradion

  • Added bouncers, which bounce balls around at high speed.
  • Added a new powerup that ends the current level immediately.
  • Added 4 new levels.
  • Fixed an issue where blocks would still collide with other objects while disappearing.
  • Levels can now define their own background color.
  • Powerups now have a fancy animation displaying their name when you grab them.
  • Added screenshake. I'm not sure if I'll keep it, but it's there.
  • Removed the level begin/end animation and replaced it with a new one.

DFEngine

  • Scripts can now access collision mask data for entities.
  • Scripts can now access (and tween) the game's background color.

This week, I haven't got much to talk about. I'm also pretty tired, so this is going to be pretty short.

So, the collision mask thing was why I had objects collide while they were disappearing. I would've had this in a long time ago, but I didn't know of a decent way to alter collision masks. The main problem here is the documentation for Bullet. Bullet, while being a pretty nice physics engine, is very difficult to learn. I'd tried to find out how to alter collision masks several times before now, but to no avail. Finally, I found a forum post with the solution. (For anyone wondering, get a body's broadphase proxy with btRigidBody::getBroadphaseProxy, then alter the values there. This works for me, at least.)
This seems to be a running theme with Bullet. Whenever I need to do something, the wiki never has an answer. Then, I can't find anything in the API. Next, searches bring up forum posts providing all kinds of impractical, convoluted solutions. Finally, after what seems like an eternity, I find a simple solution in another forum thread. Checking the API again yields some more  information, tucked away in a dark corner where no one will ever find it. Needless to say, it's a pain.
With that said, I suppose I should be happy that I found the answer in the end. Hopefully getting more experience with Bullet will make future searches a bit less painful.

6/29/14

Akradion Demo 1 Released!

After a short delay, I've finished the first(only) demo of Akradion! You can get it on the games page, as always. I don't have much to write, since it's only been a couple of days, but I did make a few changes:

  • No more than 30 balls can exist on screen at a time, in order to avoid stuff like this:
This is from when I was stress testing the split powerup
  • Added an ending message
  • Added a help message that can be toggled with H
  • Got a better font
  • Fixed an issue in Windows builds that caused massive ball acceleration
  • Made a new title image
  • Added a new sprite for the volatile powerup
  • Added a new sound for starting the game

I think that's it. Have fun!

6/27/14

Akradion Update 5

Changelog:

Akradion

  • Levels are now loaded from files created with Tiled Map Editor. This makes building levels so much easier.
  • Levels can define the colors of groups of bricks.
  • Made the ball's "hit a block" tween more consistent.
  • Added a powerup that doubles the number of balls in play.
  • Made some new sprites for powerups.
  • Added a powerup that creates volatile balls. These balls explode everything they touch, but accelerate extremely quickly.
  • Changed firing mechanics. Left-click fires a ball left, right-click fires right, and middle-click fires straight up.

DFEngine

  • Made half of a change that will probably save me tons of pain in a few months.
  • Scripts can now receive keyboard input.
  • Scripts now actually display their error messages.

You might be wondering what the 'half change' listed for DFEngine is, and why I only made half of it. Wonder no longer! This change relates to scripting, specifically how I implemented Lua in my engine. When using Lua, you have to manage a lua_State, which represents the environment that a Lua script runs in. With the state, you can add, remove, and otherwise manipulate data. However, transferring all of that data from one state to another is very difficult and slow. Thus, the best way to run multiple scripts that use the same data is to run them inside the same lua_State. This is the sensible way of doing things, which is naturally not what I originally did. When I added Lua, I built a new state for pretty much every script I needed to run. 
Now, I'm trying to bring everything back to a single state. There are a few other benefits to this, but moving data around is the biggest one. For starters, once I finish this change I'll be able to fully remove the storage components from the game. Next, I'll be able to use any data type, not just numbers and text. I'll be able to make full lists, structured hierarchies of data, and more. Right now, keeping track of a set of things is all but impossible, but this change(when finished) will fix that. 
Right now, only the main game object can take advantage of this feature, so only global script-defined variables get the special treatment. The second half of the change will apply this to the individual entities in the game as well. However, I'm not adding that to the engine until after I finish Akradion. Akradion is rapidly approaching the same tipping point that AMAZE reached, where making changes gets harder. Thankfully, since Akradion is more sensibly designed I won't have to worry about making large changes to the gameplay, just the underlying engine. Anyway, this just means that the engine probably won't be getting many more updates until Akradion is done.

Speaking of which, I have some good news: The first(and only) demo is almost done. I could release it today, but I still have some things that I want to add/change first. I'll probably either release it this weekend, or early next week. Either way, it's coming. The game itself is actually quite close to completion, I think. I doubt it'll need more than another couple of weeks to reach completion, thanks in part to being so small. Still, it's difficult to believe that it's only been 2 months since AMAZE was released!

6/22/14

Akradion Update 4

Changelog:

Akradion

  • Added a title screen
  • Fixed a ton of physics glitches
  • The bat can now be used to alter the ball's direction a bit. This makes it possible to aim the ball at bricks(somewhat)
  • Added indestructible walls
  • Added exploding bricks. When hit, they destroy other bricks in a 2-block radius
  • Added a nice animation for when levels end

DFEngine

  • Made a bunch of minor tweaks to the codebase to make it easier to work with
  • You can now directly add forces to physics objects in scripts
  • Added GLSL support
  • Global data can now be tweened by giving the entity id -1
  • Global data can now be forced to immediately update by giving the entity id -1
  • Started working on getting a cross-compiler set up

Oh man, this post is really late! Sorry about that. I've been quite tired recently, and finishing this post up is proving to be much harder than expected. Hopefully things will work better next time. The game is still coming along well, and I got it running on Windows, so no issues there.

6/13/14

Akradion Update 3

With another productive week over, I'm feeling pumped! I haven't felt this good about a project in a very long time, maybe even as far back as the old rpg project. With any luck, you should be able to expect a demo some time in the near future. If it doesn't come next week, it'll almost certainly come the week after.

Changelog:

Akradion

  • Added Powerups! Currently there are 3: extra life, speed up, and speed down.
  • Added support for multiple levels! Clearing a level of bricks now takes you to the next after a short delay.
  • Made things a little bit prettier.

DFEngine

  • When creating physics components, you can now set collision masks. Basically, this lets you control what the entity can/can't collide with.
  • Added timer components.
  • Added some basic sound support. No streaming yet, and only wav files can be loaded, but it's a start!
  • Added sprite support. They're not as advanced as they were in AMAZE yet.
  • All game assets(sprites, fonts, audio, etc) are now loaded from lua scripts.

Timers:

Now that objects can have timer components, a whole bunch of new possibilities have opened up. Also of note is that switching from AMAZE's 'delay' function to an asynchronous setup is intentional. Had a system like this been in place to begin with, that one crash bug from the factory stages would never have existed. Of course, this engine alone is a massive improvement over anything AMAZE was capable of, at least on the scripting side of things. Anyway, I've started using timers to try and add some more animations to things. Bricks now 'pop' a little when hit, for instance.

Sound:

Another feature that's improved the game tremendously is the addition of sound effects. I've started putting sounds in early, because putting things off in AMAZE was a terrible, terrible idea. Specifically, it made adding new aesthetic features to the game's levels extremely difficult. Rather than naturally adding things as I went along, I ended up having to go back through every level just to add these sorts of things, and then test them all again.


Finally, I should address the asset files. In the previous iteration of DFEngine, I spent lots of time and energy designing specialized asset files for my games, and yet this time around I currently only have support for regular image/audio/font files. In short, the specialized assets won't be going away, but I've realized that it really makes no sense to require them. I won't be adding them during Akradion's development, but they'll probably get put in some time this summer. The problem with only having specialized assets is that every time you make even the smallest change to the base file, the whole thing needs to be recompiled. This makes rapid development and testing much slower than it would otherwise be. Thus, I think it's best to use regular files when working on a game, then package them up once I'm ready to put up a build. That way, I can get the best of both worlds.

6/6/14

Akradion Update 2

Changelog:

Akradion

  • Added a score counter
  • Brick score values are set individually, allowing the creation of hard to reach high-value bricks.
  • Added lives
  • Launching extra balls can be done at any time, but each one costs a life.
  • Added Tough Bricks, which take several hits to break.
  • Smoothed out ball movement a bit.

DFEngine

  • Added a 'draw' script callback, which occurs when the game redraws itself. 
  • This is for more complex display stuff that the graphics component doesn't cover, like text
  • Added global script variable support
  • Added the ability to retrieve and modify object data from any script, given the object's id
  • Viewports now only display what the game wants them to, but scale the output as much as possible and letterbox the rest.
  • Mouse coordinates are now a percentage, rather than an exact pixel position. They are also clamped to the game view.

This week didn't seem too productive, but I guess I was wrong! It's now a whole lot easier to get work done thanks to some of the engine upgrades

Global Variables

Currently, this is one of the best ways for objects to all share data. All I had to do was give the game object one of the same data storage components that all of the entities use. Now, the game can hold important information, like lives or score.

Data Retrieval

This is really useful. Basically, it lets any object access another object simply by knowing its' id. This means that:
  1. Objects can make new objects, and give them specific info that they have (e.g. spawning something at their current position)
  2. Objects can exchange ids to always stay in touch, and can send signals and other data between each other.
As you can see, this is pretty sweet, and is another great feature that makes DFEngine's second incarnation easily beat the original in terms of power.

Views and the Mouse

This change should've been here originally. Now, the view only shows what the game wants, and makes this as big as possible without drawing things outside of the screen. The letterboxing and clamping mostly exist to prevent cheating and confusion, but they also make fullscreen look much nicer. Next, I'll need to make the game's view more dynamic. Being able to smoothly switch into a widescreen view for a cutscene, or zoom out for an impressive set-piece would be pretty sweet.

The Game

It feels like I can do so much now. I think within a week or two I'll be able to focus on adding tons of content, and then I can finish up Akradion. That would be impressive, and I hope I can finish it up by my birthday of June 25th. That's not a hard deadline, but I'm feeling pretty optimistic about this.

Making games is fun again!

5/30/14

Akradion Update 1

Changelog:

  • Mostly integrated Bullet into the engine
  • Added creation script callbacks for entities


Bullet Physics:

Here's some big news. While I was working on this project, I finally decided to add some proper physics into DFEngine. It's taken me quite some time, and I still haven't worked out all of the kinks, but I have an actual physics engine handling things now! That's pretty sweet! Along with other benefits, this will most likely faster and more accurate collisions, something that's been missing for quite some time. Unfortunately, this means that I don't have anything new on the game side of things. Maybe next time!


As for the callbacks, that's important but not too interesting. Basically, I can now call a script when I make an object. It's nothing new, but it helps.