Skip to main content

Posts

First steps in a open world: properly designing the first quests of your RPG

As I mentioned before, I have been implementing a basic quest system, which I consider that can be greatly improved. But I'm not going to talk about it, because... well, it is crap.

But working on the quest system made me revisit the script and think about the first quest that the player will find in the starting location. Those first quests must fulfill certain basic requisites:

Introduce the player to the environment (here other elements lie encounters or conversations are important too) and give him a glimpse of what to expect.Familiarize the player with the gameplay mechanics, like using objects, trading, combat and using skills.The main quest should provide some sort of backup or redundant activities, in case the player misses some of the basic quest. They must be simple and quick. There is a reason why the first quests are easy: the player is starting the game and doesn't knows how things work, even if he/she is a hardcore RPG player. Anything taking more than five minu…
Recent posts

Two quests working

Plus many other changes! I fixed the weird problem with the experience bar, caused by C# not converting int by int division to float unless I explicitly cast one of the factors to float. Also I found another mistake I introduced in combat and noticed that current animation switching should be moved to item use function, instead of being triggered by action class. That eases dealing with an increasing number of different animations for different items and not animating at all if the item can't be used (like when it has no ammo). It is a design mistake I made when started creating the item system.

Other little addition was the death event for NPCs, once implemented that and fixed combat, one of the quests could be solved by talking or by killing, your choice! Still left a little detail: once dead, the NPCs still have some activity that needs to be properly cleared. I currently lack a death animation, so I can't further advance in making NPC death to "look good", and r…

Crafting system!

At last! Yesterday, when I went to sleep, I got an idea about the crafting system. Nothing complex, like the rest of the RPG system: just collect schematics and bring them to a crafter for building. The crafter will provide the materials, so, actually, no materials are required. That's all.

The quality of the resulting item will be determined by crafter experience. There will be several crafters, but not all of them will produce excellent items, probably just 2-3. The range of items that can be crafted is not decided yet, still have to think how does it affects the game balance. For example, should crafters be able to create implants too, or only armors and weapons? What about ammo, optical or laser sights?

Also, I decided to keep the start scene with just a couple of quests. They will cover the basics of interacting with NPCs, use of items and combat. One of those quests will have two solutions: a pacific and an aggressive one. The other will be combat only. There is another su…

Back to Unity

After playing with Unreal Engine, it is time to get back to my work with Unity3D. Had a couple of projects abandoned and decided to make a little offensive on issues that I thought  did not know how to solve, but seems that I had some extra power up hidden somewhere.

I am glad to say that at last I implemented the foundation of weapon reloading. Just the foundations, but at least it is there. I need some more work on the inventory system, to unify duplicated code, and additional checkings like if the right caliber exists, which then will lead to other issues like same caliber/different damage type ammo.

Also I added some more info to trade window, but still have to implement item comparison, same as in player inventory window. I implemented another basic quest, which in turn, required to deal with an old pending issue: events, like NPC dying.  My first approach was correct, but the implementation was totally wrong. Adding this quest needed some additions to dialog system, now it can …

My first blueprint

A couple of days ago I managed to make my first working Blueprint script. Well, it is not finished, because I took the wrong approach, but at least I found how to handle input and react to key press/release events. Not too difficult, it just takes some time to watch the official tutorials.

In the end,  a Blueprint class and a C++ class are almost the same. You can put together some components and code, that's all. Blueprint tries to help by being context sensitive and it is supposed to allow quick prototyping, if you are an expert, of course.

One of the problems I found, besides my lack of patience, was that unlike Unity3D, where you start a project from scratch, Unreal Engine tries to provide you some base template to start. That requires changing some stuff in the GameMode class if you want to change how the camera is managed, for example. It is possible to avoid using the game framework, but I'm still far from that skill level.

So, I'm quite pleased with my progress, b…

Some fixes to AI

The prototype is under a storm of changes lately. Yesterday I spent some time trying to figure out the origin of some bugs in the AI code. Lot of time actually, because I lost one hour looking at the wrong line. But now, after moving some code to the Awake() function, and unifying some initializations that were repeated, I fixed a lot of weird errors I had. Also, I found some logical errors, preventing the NPC from properly getting into weapon's range.

Today I plan to implement separate functions to deal with each combat mode, to unclutter the Combat state. Also, I have to study the new Pluggable AI videos posted in Unity's Youtube channel. Maybe I can get some ideas to implement some way to differentiate the AI for each NPC.

The other bunch of changes deal with the process of building character mesh and equip/unequip items like armors. Currently it is a hughe mess with weird problems like incomplete characters, or complete ones that become incomplete if I close and the open …