How to design a Pokémon-like Combat System

The Combat System is one of the main gameplay element in a game. Of course there are a lot of games without “combat”: puzzles, simulation games, driving games and so on. However (and you know this in the depths of your soul) that your game must have an amazing combat system because we LOVE beating the crap out of our enemies! Other games mechanics are good, but a good fight can be AMAZING.
There are several ways to implement a combat system but, at the end of the day, we can divide the heterogeneous world of combat systems into two big clusters: real time combat systems and turn-based combat systems. The first are exciting but they rapidly becomes hard to implement. We will need to do a lot of animations, tuning collision boxes and tons of graphical stuff. If you are a poor programmer like me, you cannot do that (sad face :<).
With turn-based combat system, instead, you can do the most complex things you can image! You can take into account hundreds of variables and statistics, create complex strategic combinations, evocations, magic, everything. You can use dice, cards, tokens, everything in order to emulate an epic combat between a dragon and drunk dwarf with a wooden leg. Because turn based combat systems are an explicit abstraction of a real combat, the player can absorb without complaining a bigger level abstraction. The same cannot be said for a real-time combat system in which just an ugly animation can be labeled as “ugly designed and sluggish combat” and provide frustration to the player.
So we are going to implement a turn-based combat system! But how? Well, this obviously depends on which type of turn-based combat system you want to do. For now, we will try to do a replica of the first turn-based game I’ve ever played: the Pokemon Combat System!
This is a nice combat system to replicate as a tutorial because is not too complex (especially in Gen. 1 or 2), but contains several tricky points that we need to handle! We will explore the design and the implementation of this combat system in details. We will see how to design the combat system, how to do a first balancing and test on paper, and every implementation step! So let’s start!
Let me introduce your worst rival: yourself

Here it is a new article on Medium on a simple game to beat (or to measure) your procrastination level! :)
Let me introduce your worst rival: yourselfWhen cheating with a robot is really cheating?

Hi guys. I wrote a small reflection on the future of Artificial Intelligence. The question is always the same: when would we consider a robot as a “living beings” with self-awareness, emotions and all the human equipment? My point is that we could stop asking ourselves this question because soon or later sex-robots will provide us the answer. Anyway, this is the article I wrote on Medium. Take a look. :)
A Month of Writing: August 2015

A month ago I started questioning my ability to stay focused on thing I like. Kill the procrastination monkey is the first thing to achieve any goal in life and I felt that I was losing that battle. Last year was not easy, mostly because I started feeling incapable to achieve anything useful in work. This, in turn, feeds the procrastination monkey, causing more frustration and so on. An evil infinite explosive mental and motivational cycle that drown you, slowly, silently. I had to break the cycle!
But where I could start? I decided to stress myself on an old obsession of mine: writing. As you know I have stories in mind and I have a deep need to tell these stories. There are many ways to express these stories (music or gamedev are the most important one for me!) but writing it is much less complex: it is just you, the story and a piece of paper. There is no technology involved, no extra abilities such as visual arts, no constraints, no distractions. I did not want to feed p-monkey with a lot of fake-problems to justify myself for not doing anything every day. So, I took a piece of paper and I wrote on it: I’ll write One Million Word of fiction. It is important to have some kind of metric to measure your progress and the number of words written is a perfect metric! Every night, at the end of the day, I can update the counter, see the target approaching and feel good about myself.
A month is passed and I want to share this small step with you.
Boost Hierarchical Pathfinding with Extended Graphs

As you may already know if you follow me on Twitter (why not?), I often work with pathfinding. This thing started as a small side quest during my Ph.D. and then grew up to become the main topic of my future Ph.D. thesis. I’m still quite sure that this is not what I chose back in the day but, well, now that I’m on the dancefloor I have to keep dancing.
Returning to the subject, my work is totally focused on pathfinding with cognitive capabilities. This means that I try to embed pathfinding into a more high-level reasoning pattern or, if you prefer, to push high level elements - such as reasoning with keys and equipment - down into the pathfinding level. As a consequence I use hierarchical abstraction of the map space a lot and for “a lot” I mean that in the last year and half I’ve implemented Hierarchical Pathfinding (HPA*) at least 4-5 times in different context and languages.
Bacon Game Jam 09: Back in Business

Hi everyone! I’m here to tell you the story of my last game jam: the Bacon Game Jam 09. It was a long time since my last game jam (and my game-dev stuff in general). I was a bit distracted by other part of my life and, in general, I wasn’t in the best mood. Because of this, I’m very happy to partecipate to this jam, also if the final result is not completely satisfying.
Anyway, let’s start!
Procedural Contents Generation in Modern Videogames

8th September 2016 Update: I uploaded these slides on SlideShare. You can see them here. Hi guys! In the last month I’ve prepared a presentation on Procedural Contents Generation history and techniques in commercial videogames. I did this presentation for a Game Jam some time ago and for a series of meetings in our university. I think it is a nice summary of the main elements of PCG in commercial games, so I think it is worth to share this presentation with you!
Weekly Inspirational #2

Here we are again! For five brand new inspirational articles found on the web (mostly on Reddit to be honest, but who care). This time we will see a lot of Procedurally Contents Generation algorithms, another emulation related article, and the smallest academic paper of all time! Let’s start!
Weekly Inspirational #1

Stay inspired during the boring working week is the best way to fight procrastination and stay on board of the “do-stuff” train. There is nothing better than looking at a creative a work to say “Cool! I want to do something similar, too!” (or to lay down crying in depression, but this is another topic I suppose). For this reason I’d like to share with you 5 of the best inspirational and interesting stuff of the week that the web can provide. It is good food for your brain! (PS: Someone could say that I spend too much time reading and looking for these stuff… well… ehm… please, don’t. Let me dream.)
Javascript is not so bad, after all

I have to admit it. I was a big Javascript hater. I used to criticize the language on every possible aspect: syntax, maintainability, error prevention and management, and so on. Let me be clear, I still have a lot of concerns on all this things. I wasn’t wrong. Javascript’s syntax can be a nightmare (and this is why there are so many languages that transpile to Javascript), maintainability is a state-of-the-mind more than a language feature and a lot of Javascript design issues are an infinite-bug-spawner. But, after all, it is not so bad and it is going to improve significantly in the future.
In the last months, I get used a lot to the Javascript ecosystem and community and it becomes a language in which I feel quite happy to work with. Let’s see why (and why still is not a perfect language).
Secret Guide!
Congratulations! You discovered the secret guide!
Press ? to show/hide this guide!