Main Menu
  • Welcome to The RPG Maker Resource Kit.

skill database management question

Started by Shinami, December 24, 2010, 04:53:04 AM

0 Members and 1 Guest are viewing this topic.

Shinami

I'm curious as to what other scripters think about this but first, a bit of background info on what this surrounds...

I'm currently working on a combat system that relies on die rolls and a part of that combat system involves a skill system that revolves around passive and usable skills that LEVEL UP as a way of improving one's survivability. There are also going to be a lot of actors in the actor database, many of which will revolve around a basic setup of the same skills with their own unique skill or three. Each actor will have their own progression.

This makes a flexible, dynamic database neccessary. Otherwise, the player would raise SkillA and find SkillA has been increased for all actors instead of just one since all the actors use a lot of the same passive skills. Question is...how would you do the basic setup for such a thing?

It's not that I've run out of ideas on this. It's just I have too many options that are good but I'm not sure what to choose. X3 Not to mention I might hear multiple good ideas that I hadn't thought of.

I can make ALMOST anything in scripts so don't limit the ideas to what my scripting ability may or may not be.

modern algebra

Well, I recently wrote something similar for RMVX. It was an addon for another script but the part relating to what you are thinking of is contained almost entirely in this post: http://rmrk.net/index.php/topic,39569.msg464112.html#msg464112

There is a lot there that is RMVX specific, but the basic idea I had was to create a wrapper class for the basic array and use that to hold the basic data. However, for each additional level of a skill, I added another with the index of the original skill + 1000. So if the Fire skill had the ID 102, then level 2 of it had the ID 1102, level 3 2102, etc...

Those additional skills were held in a hash and merely accessible via the $data_skills global variable.

As that means all skill levels have a unique ID and are accessible via the regular $data_skills, all that was left to do to distinguish between actors was add that unique ID to the array when they learned the new level of the skill and remove the old one (if it was a replacement system). That said, that solution is pretty well as heavy as it gets on memory usage, but it seemed to me to be a fairly good way to do it.

Shinami

Remember this modern? My item system issue? That's the basic idea I had for this. =3 For the determining of passive skills, a quick module containing that and a few parameters on how the skills react as passive skills and active skills can help sort out the rest of the things needed. Just gotta be sure to pass off each skill learned as a new instance to ensure nobody is using the exact same skill. Memory intensive? Most likely after a while when there's 30 or so actors with their own unique instance of skills.

I'm still interested in how others would do this though. I like hearing how other people would do the same thing but in a different manner. I believe that by considering the same objective from multiple angles, we come to see more options and ideas on how to implement things in a more effective and efficient manner. So, by all means...keep thinking people. =3

Shinami

Seriously people...I wanna hear the basis of how yall would setup a system like this. o.o; I know there're more scripters than me, modern, and Zeriab here. X3