Game Dev

First try

Well, it’s time to do some real testing now !!

I tried few things in one little level… I’d better warn you it’s not awesome, but I did it without adding a single line of code ! I just used state machines to check inputs, trigger actions, enable gravity and so on. And I think this is the cool part cause anybody could do that (even without programming skills I mean).

I did the whole thing quickly so I didn’t pay attention to gameplay (running speed is too fast, dash move is a bit weird, gravity is too high etc.), but I could tune it easily.

I found some nice sprites of Zero (you know, the character from Megaman / Rockman !). This version is from “SNK Vs Capcom”. I used it as a placeholder for the player.

In this video, you will see (there are some things I mentioned in previous posts but never showed by the way) :
– “Ghosts” for movements
– Layers : several layers with different speed.. It’s maybe too fast, but you’ll get the idea.
– Animations
– Collisions (red polygons show the collison maps. By  the way I noticed I used rectangles only, but it could be other convex or even concave polygons)
– Events (once the player reached the zone, it triggers dialog box and shader distortion)
– Shader (the distortion I added last week) -> I coded this shader before even starting my engine actually (I’ve been waiting a whole year !!)

I still have some things to do to improve collisions and I think I should add a tool to create collision maps directly in the level editor… Right now when you create a new static object you can draw a colmap for it (then it’s used for every instances of the same object). I should be able to draw something for the whole ground too. It’ll be useful and will spare some collision calculation.

I didn’t use sound nor Fx (I could… while running, jumping, and so on). It’s lame. Next time, for sure.

Here comes the Level Event Manager I did for this level :

1. I’m playing FX in loop on the event zone (the one at the end of the level ! Check the pic. on the left) while the player is not detected;
2. Once the player is there, I launch the distortion shader (I added it to a shaders bank I created and its rank is 0);
3. I change the state of the player (I created a state in which there’s no action nor move allowed);
4. I start the dialog !

I hope it looks easy, cause since I’m used to it, I love it !

Now, let’s check one of the player’s state machine ! I took the “State_Run” cause it’s not the easiest nor the most difficult to understand ! The “State_Jump” is the worst actually.

The yellow branch is the “Entering condition” for the states who allowed the “State_Run” as a next possible state (actually, only the “State_Idle” does), don’t forget !

1. In green you see the next possible states (double click to enable/disable !). It means, while running you’ve got gravity (“Gravity” is not a real state, I just use the entering condition branch to trigger an impulse every frame), you can kneel, jump, or dash.
2. Playing the Run action from the player’s Action Bank.

Looks like everything is working well. I encountered some bugs here and there but nothing hard to fix so far. I’ll try to use the same level and add things one by one till I’m able to try every single part of my editor. I still have : lights, fx, sound… And things I didn’t even mentioned like rain effect, projectiles and material system (to trigger a specific fx/sound on different objects collision). There’s still some work before starting a real game, but it’s getting closer and closer. Yeah !

Game Dev

Dialog system almost done

Looks like I’m the worst when it comes to following my own planning ! I didn’t work on my editor last week-end and finally I did most of the work in the week. Since I’ll be off for 3 weeks starting Saturday (Holidays !! Yeah, I won’t code for 3 weeks… Strange…), I tried to finish some important tasks.

At first I wanted to do some generic methods to handle text display but in the end I just worked on dialogs… Here comes a little video to show how dialogs work right now. There are still some improvements to do and don’t pay attention to characters’ picture size or display style. It’s just a test. I tried to use different things I talked about but didn’t put in video (Level Event Manager, and so on). I’m sorry for the quality and resolution (4:3 instead of 16:9… fail).

By the way I used pictures from Guilty Gear cause I don’t have time to draw some placeholders right now. I’d like to avoid using other people works in my next videos but that’s kind of hard. But you should play Guilty Gear ! Play BlazBlue ! Play Hard Corps ! Well, that’s all I can do to make Arc System guys spare my humble life. I need to find someone cool enough to lend me some arts usable as placeholders ! The background is mine by the way… Speed painting rules.

You may also notice the frame rate is bad (~45-50), don’t worry, it’s due to the recording soft I’m using (CamStudio). I’m still at 60fps, hopefully……. With 3 pictures and some effects, it would be a shame if not…

I did a video on how does the particles engine work (based on Mercury) in my editor, but I’ll upload it tomorrow… I’m tiired.

Game Dev

Level Event Manager !

Oh Yeah !

I finally did it. It’s working ! It’s easy to use ! It’s so cool ! Maybe you don’t even know yet what I’m talking about, but this feature is the one I’ve been thinking about for a looong time.

It enables me to manage the different events in a level : Let’s say “Level Event Manager” or “LEM”.

For example : You need to trigger an event when the character reach a place (like door opening, objects falling, birds flying, or whatever…) :

The blue rectangle is the event zone (the size is editable of course). First you need to make the player move, then trigger an event once the player’s position is in the zone.

Here I did a simple state machine (on the left) for my player : Pressing the right button makes the player move to the right.

The LEM (on the right) and the State Machine just look alike. Actually, the LEM is based on a great part of my State Machine code. Then, it wasn’t so hard to create it. The event automate for this simple level is easy to understand I guess. Once the level is started, the Event zone will check if the player is detected. If the condition is true, then the player will get a vertical speed.

I added some colors to be able to follow the events in real time (well, using C# delegate/events) :

(Before and after detection)

I’ve been working for almost a year on this soft, I’m glad to see my motivations didn’t even changed a bit. Now, my editor is almost complete (well, according to what I want to do before starting). Only the text display functions remain. I’ll do that tomorrow. And this week end I should be able to start a simple game.