adnzzzzZ
|
|
« Reply #80 on: January 20, 2014, 12:48:37 AM » |
|
made a tumblr for the game http://karagame.tumblr.com/found a nice bug/feature and working on a console to help me when I start making the level editor We decided that it's best to make a custom editor than to keep using Tiled. The idea is to make an editor that lets you edit levels and objects (both static and dynamic parts of a level) in game. Meaning there's no delay/reloading between designing something and seeing it work. Kinda like this except less professional and more specific to our game. On the software engineering side, making an editor like this is not that hard but it's 2-3 weeks worth of work probably, since for every object already in the game I have to come up with a proper way of spawning it in real time. For instance, spawning a chain means that I have to attach it to two bodies/objects, which means that I have to have some way of highlighting/selecting objects when I hover them with the mouse. Then I have to actually make it so that the chain spawns when you click and drag and so on... And then imagine some similarly unique mechanism for lots of different types of entities. It ends up being that I have to think more than usual about what I'm gonna start coding before diving in completely so that I don't write things in a too specific manner and then have to refactor it all... So I decided to start with the console because since the editor is going to be in real time, it also makes sense that I have some way of loading maps, restarting something, changing settings and so on while in the game. I'm really inspired by Source's console I guess, and I used it a lot when I was younger playing CS and AG, so I have some idea of what types of commands I could add. Anyway, it's a lot of "thankless" work, but you gotta do what you gotta do in order to survive in this doggy dog world.
|
|
« Last Edit: January 20, 2014, 12:57:28 AM by adnzzzzZ »
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #81 on: January 21, 2014, 01:14:41 AM » |
|
Finished with implementing the console at its most primitive functional state, pretty much with only a few commands, error checking and loading/saving of configurations. The very surprising thing about making a console is how it makes everything more organized. It sort of forces you to make all modifiable settings of your game into commands. One example of this is the bind command. It's a simple console command that rebinds keys to actions. To make this command happen I had to make a few small but significant changes to my code. After that, though, I'm able to rebind anything! And so in the future when I have to make key remapping menus I'll already have everything (except the menu UI) ready for it to work, because all I need to do is to call the bind command in the console. Overall I feel like it's gonna be a really useful tool to have as we develop the game more.
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #82 on: January 22, 2014, 05:32:23 AM » |
|
Starting to add the editor! gif shows some of the usefulness of the console, I guess.
|
|
|
Logged
|
|
|
|
Erichermit
|
|
« Reply #83 on: January 22, 2014, 06:51:00 AM » |
|
I'm loving the look of everything here. You have a good way of picking out entertaining gifs, such as the one with all the rockets.
It looks like you're doing a good job with "oomph", such as the use of minor screenshake.
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #84 on: January 23, 2014, 01:03:49 AM » |
|
I'm loving the look of everything here. You have a good way of picking out entertaining gifs, such as the one with all the rockets.
It looks like you're doing a good job with "oomph", such as the use of minor screenshake.
Thanks! The idea is to make combat in general feel rewarding on its own, something that lots of roguelike-likes (or action roguelikes) recently don't seem to pay attention to. A game that does this well is Risk of Rain, for example. And some more progress on the level editor:
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #85 on: January 23, 2014, 12:43:47 PM » |
|
All he wanted to do was go home but he had no legs
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #86 on: January 23, 2014, 04:15:38 PM » |
|
|
|
|
Logged
|
|
|
|
matwek
Guest
|
|
« Reply #87 on: January 24, 2014, 02:00:18 AM » |
|
New robot added to the family
|
|
|
Logged
|
|
|
|
|
adnzzzzZ
|
|
« Reply #89 on: January 25, 2014, 01:25:40 AM » |
|
Automatic auto tiles + handling of edge cases: Now need to figure out an algorithm to create box2d solids from those arbitrary shapes so the player can actually collide with the ground...
|
|
|
Logged
|
|
|
|
tanis
|
|
« Reply #90 on: January 25, 2014, 07:11:00 AM » |
|
@adnzzzzZ are you using physics for the main character, enemies, etc or are you just using your own collision detection and movement routines?
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #91 on: January 25, 2014, 01:46:16 PM » |
|
box2d for everything related to collision detection and a mix of box2d + my calculations for movement. Character and enemy movement I just calculate things on my side and then use box2d's setLinearVelocity to move the physics object. When the character/enemy has to behave more physically though, like when he gets pushed by an explosion, I just apply some initial velocity, disable player input and let box2d take care of the objects trajectory. It's kind of a pain sometimes to deal with (my enemy code needs a clean up because it's getting confusing) but it's better than having the game be sluggish or with a lack of control if I were just applying forces to objects.
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #92 on: January 26, 2014, 12:05:39 AM » |
|
Automatic box2d solid creation (at the end of the gif). hard work but worth The technique goes something like: 1. Flood fill to find all groups of tiles (= islands of solids = tiles that are connected to each other); 2. For each group: 2.a Find its corners (corner being defined as an actual corner or just a tile that you can expand a rectangle from (basically something on some type of edge)); 2.b Expand a rectangle from one of those corners, mark all tiles in that expanded rectangle and return a bounding box of that rectangle; 2.c Repeat 2.a, 2.b until the group has no more unmarked tiles; 3. For each bounding box returned from 2.b create a box2d solid!
|
|
« Last Edit: January 26, 2014, 12:15:46 AM by adnzzzzZ »
|
Logged
|
|
|
|
tanis
|
|
« Reply #93 on: January 26, 2014, 02:53:36 AM » |
|
@adnzzzzZ aren't you having problems with physics boxes built that way? I use a similar technique to group together tiles and create physic bodies, but with Chipmunk it happens that the player or the enemies sometime get stuck in the "gap" between the boxes. Of course there is no real gap, but the physics engine considers the corners and applies different forces based on that and the result is unmanageable. Isn't box2d behaving the same way?
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #94 on: January 26, 2014, 02:56:43 AM » |
|
I posted a picture here earlier that helps solve that problem: If you either make your objects polygons like that (with clipped corners) or circles then they won't get stuck anymore. More info here: http://www.iforce2d.net/b2dtut/ghost-verticesYou could also build your levels in such a way that horizontally there won't be (or they will be minimal) any possible "gaps". If you look at the way my algorithm up there chooses its solids you'll see that it prefers horizontal instead of vertical ones precisely because of that (since I'm not gonna make all objects in the game BSG rectangles).
|
|
|
Logged
|
|
|
|
tanis
|
|
« Reply #95 on: January 26, 2014, 03:06:57 AM » |
|
I'm going to try the route of the clipped corners and see how it goes. I pretty much try to have horizontal boxes as well, but then when I have something like a stair (horizontal rows stacked on each other at one tile to the right or left from the previous), it happens that the player or enemy tries to go in between the horizontal boxes I'll let you know if the clipped corners solve the issue with chipmunk as well.. thank so much for the tip! BTW what do you mean by BSG rectangles?
|
|
|
Logged
|
|
|
|
adnzzzzZ
|
|
« Reply #96 on: January 26, 2014, 03:13:57 AM » |
|
If you go for clipped corners then you get pretty decent movement on stairs for free. And paper in Battlestar Galactica (BSG) looks like this:
|
|
|
Logged
|
|
|
|
|
adnzzzzZ
|
|
« Reply #98 on: January 26, 2014, 06:39:01 PM » |
|
Live level editing!
|
|
|
Logged
|
|
|
|
OniWorld
|
|
« Reply #99 on: January 27, 2014, 11:39:15 AM » |
|
I love the look/feel of the UI - something I really need to work on in my editor. Is there a specific framework you're using for the UI or is it just aload of bitmaps/shapes being drawn?
|
|
|
Logged
|
|
|
|
|