Posession 2: Interface Work and Good News
I’m going to preface this by saying that work on the user interface is probably my least favorite kind of programming. It’s tedious and boring, and doesn’t feel very productive. But once it’s done, it makes a world of difference. Since the first Possession was whipped together in a week, it didn’t have that much polish, though I think it was pretty good for being made in only 7 days. I’d like Possession 2 to be much more accessible, better-looking, and playable, though, so I’ve been doing some work towards that end.
The sidebars used to just be drawn as a simple square. I whipped up a border to use instead, and also made it adjust based on how much information needs to be shown rather than just taking up the entire side of the screen. It also shows you the special abilities you can use in your current body, and you can now press the number listed to use that ability instead of having to go through the spell screen.
One thing you can see in that picture is something entirely new: A menu that shows up when you right click on an enemy or square. It lists the abilities you can use on the targeted location, which means that the game can now be played entirely with the mouse, if you want. (Actually, that’s not completely true yet, you still have to use the keyboard to go up and down stairs).
Another other thing I’ve been working on is changing the stat system of the game. In Possession 1, every creature had a “Hit Chance” and a “Dodge Chance. But what made things confusing is that the actual hit chance was the “Hit Chance” of the attacker minus the “Dodge Chance” of the defender, so a 50% hit chance could in reality be, say, a 10% hit chance if the attacker had a high dodge score. This also led to silliness like some creatures having a 120% hit chance. I’ve gotten rid of that, and just gone to a basic “hit skill” and “dodge skill” system. Since those numbers aren’t quite as intuitive as hit chances, the game now shows you the chance of hitting (or being hit by) an enemy when you target them.
Here’s what the Monsterpedia, which contains information about the monsters you’re possessed, looks like now. In the first game, it was just kind of a jumble, the creatures were just listed in there based on which ones you possessed first, but now they’re sorted by level, and the list is scrollable. It also tracks your stats with the individual creatures, showing how many times you’re possessed a creature type, how many times you’ve exploded one, as well as how many kills you’re made and turns you’ve played as a creature.
I’d like to get some feedback on all these interface changes, which is hard to do without people actually playing with them. Luckily, it actually looks like the game’s going to be in a stable enough state (though still nowhere near finished, content-wise) to release a playable dev version soon. And by soon I mean “hopefully this week.” So stay tuned for that.
BROTIMES!!
Here’s my entry to the 2014 Gender Jam. The purpose of the jam was to make a game based on your personal experiences with gender.
Collect things to balance your self respect with the respect of your bros! Which is more important to you?
I don’t really know how I feel about it, to be honest. I don’t think it says what I wanted it to say very well, and in the end it didn’t end really end up that close to any personal experiences I’ve actually had. But, it’s the first time I’ve ever made a game with a…for lack of a better term…”message,” and it’s the first time I’ve made a game anywhere near autobiographical, so I still count it as a success, at least as a learning experience. Maybe I’ll write more about it later.
Here are some screenshots:
Possession 2: Some New Creatures
So I apologize for not really having posted anything recently. There’s been some work going on, but a lot of it has been kind of behind the scenes (probably worth a post, might be of interest to other game dev people), and honestly, there hasn’t been THAT much work done, either. Right now my job situation just makes it hard to put as much time in as I’d like, especially considering I’m still running and working on Pleasantville by Night.
I do still have the energy to do some conceptual work, so once I do get the time to work I have plenty of creatures already planned out. I’ve also managed to make myself do the sprites for quite a few. Here’s a look at some of them:
That’s fifteen new creatures. Possession 1 had a total of 31 creatures, not counting the ghost. Only 24 of them were possessable. The creatures in that one image alone is more than half of what the first game had!
Here’s some more info on how much bigger Possession 2 will be than Possession 1. Possession 1 was five levels long, and each level had the same group of creatures available each time. Possession 2 will be ten levels long, and eight of those levels will randomly be one of three possible levels and creature groups. If each of the levels has an average of five creatures, that’s around 130. That’s already a hundred more than the first game had, not counting bosses or summonables. And, of course, there’s going to be a wider variety of level designs and level features, not to mention all the new creature abilities.
In about two weeks, my job hours are going to drop to sane levels, so you should be seeing more from me after that point. My priority will be to get a playable version out. It won’t be complete (or probably even winnable), but you’ll finally get a chance to play around with some of the new stuff.
Possession 2 Miscellaneous Devlog 1
I’m working two jobs right now, and the past few weeks have been pretty busy for me. I have managed to continue working on Possession 2, just not as much as I’d like. Today’s post isn’t really focusing on any one aspect in particular, just highlighting some of the things I’ve been working on.
I’ve made some more AI improvements. Smarter creatures now try to avoid dangerous terrain, such as lava and fires, while dumber creatures will just walk straight through.
There’s also a few areas that are still very much in progress, a nature preserve (full of flammable grass and trees!) and the ruins of a demon city.
Possession 2: Speed Systems in Roguelikes
Speed is a problem in turn-based games. It’s much easier to just have everyone move once per turn. Anything else just gets complicated, both from a programming and a gameplay standpoint. But given that the differences between bodies are such a big deal in Possession, I really want there to be some creatures that are weak but fast, and some that are strong and slow. Not to mention the possibilities of spells or obstacles that speed/up slow down creatures, and let the player (or their enemies!) run away or escape more quickly.
(I’m going to warn you right now, this post is a bit more in-depth in the development process than other posts have been. If you’re not really interested in game dev it might not be that interesting, but I’m putting it up so hopefully someone facing the same problems might be helped by it).
At first I tried a simple system where certain creatures either got an extra turn or lost a turn every X number of turns, but implementing it got kind of ugly and annoying. I decided to look into what other people had already done. I found this post, detailing a wide variety of time systems used in roguelikes, and decided to go with an energy-based system, which is apparently what Angband uses, which is somewhat appropriate I guess because even though I don’t really like it much now, it was the first roguelike I ever played.
Anyway, the basic way it works is, every creature has a “speed” rating that is added to their “energy” stat every turn. If their energy stat is above 100, they can move, and 100 is subtracted from it. If it’s above 200 they can move twice, above 300 three times, etc. Most creatures just have speed 100, meaning they move once a turn.
For example:
| Creature | Speed | Energy, Turn 1 | Energy, Turn 2 | Energy, Turn 3 |
| Bat | 150 | 150 (moves once, reduces to 50) | 200 (moves twice, reduces to 0) | 150 (moves once, reduces to 50) |
| Zombie | 50 | 50 (doesn’t move) | 100 (moves once, reduces to 0) | 50 (doesn’t move) |
| Caretaker | 100 | 100 (moves once, reduces to 0) | 100 (moves once, reduces to 0) | 100 (moves once, reduces to 0) |

The ghost moves faster than most creatures, so the player has a chance to run away. Click to enlarge.
Same goes for the player, of course. If they have above 100 energy, they can move, if not, a turn happens without them. If they have above 200 energy, their move is an “extra” move. They still move, as does any creature with more than 100 energy, but nobody’s energy increases that turn.
This system worked pretty well as-is, but it does run into a weird problem. I had bats and ghosts both faster than normal, but the ghost was slightly faster than the bat. It got an extra turn every two turns, and the bat got an extra turn every three. This resulted in, one turn, the ghost would move twice and the bat wouldn’t move, the next turn the bat would move twice and the ghost wouldn’t move. It didn’t make much sense.
So, the get around that, I made it so that if the player is faster than a creature, the creature saves up enough energy to take an extra turn, it doesn’t actually take its extra turn until the player takes their extra turn. That seems to work pretty well so far. Might take some more tweaking as things continue, but we’ll see.
Possession 2: Special Level, The Tombs
Not only will Possession 2 feature greater variety in its regular levels, but there will also be several “special levels” which you will sometimes visit instead of a regular level. The special levels are themed, featuring special tiles and design, and creatures that fit the theme. More interestingly, they usually feature special tiles, features, effects or layouts.
The Tombs are the first special level I’ve made. They’re a series of rooms connected by corridors. Inside, you might be lucky(?) enough to find mummified kings sleeping amongst massive piles of treasure!
Being a ghost, you don’t really have much use for gold. But the mummies don’t know that, and if you touch their gold, they’ll come to life and attack!
There are also cultists scattered throughout the tombs, who wander until they find a mummy, then begin worshipping it. While the cultists aren’t very strong (and the mummies themselves are a bit on the weak side, too), if you’re not careful you could find yourself being chased by a mob!
There’s an upside, though. If you possess a mummy, unaligned cultists may start worshipping and following you instead!
There are other creatures in the tombs, too, such as deadly sphinxes, adventurous archeologists, as well as our old “friends” the tourists:
Possession 2: New Level Designs and Graphics
Happy New Year! It’s been a while since I’ve posted. Writing devlog posts just kind of fell behind over the holidays, but work has continued.
Today I’m going to talk about the levels. Possession 1 had just one level generator. It worked pretty well, and made pretty good-looking caves, but there wasn’t much variation.
I’ve added some more randomness to the cave generator, so that sometimes it makes more open cave and sometimes more enclosed ones, but I’ve also added three more level generators. They all will receive some more tweaking as work continues, but here’s what they look like so far:
The “BSP Tree“:
The standard seen in most roguelikes, this generates a bunch of rooms and links them together with corridors.
The Maze:
Pretty self-explanatory. Generates a maze. To make it more interesting, I remove all the dead ends (except two, where I place the entrance and exit), and add some extra passages and rooms.
The “Drunk Walker”:
It needs a little more work to ensure that more of the level is open, but this builds random, more natural-looking tunnels across the level.
There’s more new stuff in levels besides changes in their shape, though. There are going to be special levels (the first of which is almost finished and will be the subject of a later post), as well as modifications that can be made to basic levels, such as adding rivers (of water, lava, blood, slime, etc.) and chasms, or covering the level in (flammable!) grass and trees:
I’ve also written the graphics code for tiles in the levels themselves. There are seperate tiles for walls depending on what other walls they connect to, and various floor tiles to make the level look more varied. You can also see a chasm on the left. Chasms can be crossed by flying creatures, but not by others, and you can knock your enemies into chasms if you have abilities that let you push them around!
Not all levels will look the same in graphics mode, either. Special levels will have special tilesets. For example, here’s the “graveyard” tileset from the first level:
All the environment graphics are pretty ugly, I know…I just made them quickly for testing, the final versions will look better.
Possession 2: Programmer Art, and First New Creature!
As I mentioned earlier, I have someone working on graphics for the game, and hopefully I’ll be seeing what he’s done sometime this weekend.
For the time being, though, I’ve made some quick little pixelly sprites on my own, to test the graphics code with (and also to make screenshots more interesting).
I’d also like to introduce the first new creature in the game: the caretaker! He’s found on the first level, and is a sort of stealth-based character.
He has some unique abilities that aren’t really like anything in the first game. First of all is Undead Repellant, which keeps undead from noticing you (though they’ll still notice you if you attack them!). The second one is Undead Bait. If you throw it at an empty square, it will make nearby undead congregate around it. But, if you throw it at another creature, it will make all nearby undead attack THEM instead!
(Unfortunately, the screenshot I just took reveals that the creature will also attack ITSELF, so that needs to be fixed).
Possession 2 Announcement
I am working on a sequel to Possession: Escape from the Nether Regions, the 7-day game I made earlier this year. I’m currently calling it Possession 2: Return to the Nether Regions, because it is a terrible name. Whether it’ll stick or not depends, but it’s growing on me.
I’ve actually been working on it for a while, since the beginning of the month, which is nice because that means I can slack off for a few days and still post up something and pretend it’s something new I’ve been working on. While the majority of the changes will be adding new content, I also am going to make some changes to the basic mechanics of the game, involving how possession works. Specifically, I want to make it so that there’s more risk involved, so that it’s not always the best choice to immediately possess a new individual of the creature you’re already possessing.
To that end, here’s a development version. It has the same content as the old game (though it does have some interface improvements, but I’ll talk about that later), but trying to possess something now ejects you from the old body whether you succeed or not (unless you’re next to the new body), and causes your ghost form to zoom to the new target. If you fail to possess the target, they’re stunned (so they won’t just immediately kill you), but other enemies near them aren’t.
Windows Version (untested)
.love file (Usable on Mac, Windows or Linux, requires LÖVE Client)
This isn’t in the above version, but this is what I got done today. A system for projectiles, and giving ranged attacks to creatures. In this case, apparently a skeleton throwing its own bones at people.

(Apparently I can’t just post the animated image here, click to see it.)
The new game WILL feature graphics, so you don’t have to play with ASCII characters, but I’ve got someone else working on those, so that depends when he gets done. You might also notice some new animation, like the floating damage numbers above the creatures’ heads. I’ll talk more about that later. Also, also, I now use Twitter (it’s for marketing, I swear!) Follow @vaughantay if you want


























Possession 2: Artificially Intelligent Tourists
I’ve made some improvements to the creature AI, using a lot of the information from this article as a starting point. Different creatures now behave in different ways…most still act like they used to, blindly charging at you and attacking you. But they can also be (and become) hostile to other creatures, and fight them rather than you! Some types of creatures will even be friendly to you if you’re possessing one of their own. They also have the ability to get scared and run away, or, for more long-range creatures, try to maintain a minimum distance.
These behaviors can also be combined to result in interesting behavior. For a good example, we have Tourists. Tourists are now “hostile” to all other creatures, but they won’t attack outright. They prefer to hover around their target without getting too close, occasionally taking pictures, and running away if they’re approached. Occasionally, the creature they take a picture of will get pissed off and start chasing them trying to attack them.
(Animated image, click to view)
Recommended soundtrack
They’re a nuisance, because their camera flash will stun you, but if they’re focused on one of your enemies they can be helpful, because the camera flash will stun your enemies, too!
Sidenote: Before I had the maintain-minimum-distance code in and set the tourists as hostile to other creatures, they’d roam around the level attacking other creatures. Since I also hadn’t finished the code that makes creatures hostile to things that attack them, they offered no resistance, so the tourists were basically traveling around killing everything. Games as social commentary!
This new system also has better support for passive creatures. For example, Snailpeople are described as peaceful. In the old game, they’d only attack you if you attacked them, except that the way the AI was written, they weren’t aggressive enough to pursue you if you attacked them and then ran away, or were attacking them with a spell from far away. Now, they’ll ignore you if you leave them alone, but if you hurt them, they’ll chase you with no forgiveness. Some creatures also ignore you unless you get too close to them.
The new AI also includes AI for follower creatures, so they’re slightly better now, finding their own targets to attack rather than waiting for you to target something. Creatures are also able to follow other creatures, for example necromancers now spawn with a few zombie followers.
All of these improvements do come at a cost though. On my 6-year-old laptop, the new AI code is 10 times slower than the old code. Not much of an issue, for my computer it now takes a 10,000th of a second per creature rather than a 100,000th of a second, so there’s no noticeable change. But if it gets too much slower, there would be (and actually, there was, before I improved a certain part of the code that was being unreasonably slow).
There are still some improvements I’d like to make, but we’ll have to see how much of a hit they cause performance.
Share this: