changing level system from one class to eight

Posted by Phobos on Tue 09 Oct 2007 07:27 PM — 3 posts, 17,687 views.

#0
I'm running SMAUG and i am rather new to coding. My question is how might i change the level system from only being able to level one thing to a level system more like what SWR muds run, below is how i want to set it up instead of all exp going to one level max

----------------------------------------------------------------------------
Combat Level: 1 Max: 150 Exp: 0 Next: 500
Piloting Level: 1 Max: 40 Exp: 0 Next: 500
Engineering Level: 1 Max: 2 Exp: 0 Next: 500
Bounty hunting Level: 1 Max: 1 Exp: 0 Next: 500
Smuggling Level: 1 Max: 26 Exp: 0 Next: 500
Diplomacy Level: 1 Max: 9 Exp: 0 Next: 500
Leadership Level: 1 Max: 75 Exp: 0 Next: 500
Force Level: 1 Max: ??? Exp: ??? Next: ???
Slicer Level: 1 Max: 16 Exp: 0 Next: 500
-----------------------------------------------------------

Now if someone could be kind enough to assist me in changing this over i would be greatfull. My hand kind of needs to be held with this because like i said im newer to coding.
USA #1
You need to keep separate experience tallies: you would have not just one but many fields in the char_data structure. Then you would need to decide when and how those tallies get updated: during combat? talking? something else? So before you even start coding, you need to figure out precisely how your system is going to be designed.

You might want to look at snippets for multi-classing to get an idea, but those typically assume that experience is divided among the classes evenly.

By the way, this post really shouldn't be in the Area Editor section...
Australia Forum Administrator #2
I have moved the post into the SMAUG section.

I you are new to coding I would start with something simpler to get your hand in. Something like the current level is pretty ingrained into the source.

For example, a quick check found that there are 1507 lines in the source with the word "level" in them - so if you made 8 different levels that is 1507 changes, at least, to indicate which level you want.

However you could conceivably leave all those alone as the "combat level" and simply add new fields to the character structure (like engineering level).

One approach that might save you grief is to look at the stuff I did for questing:

http://www.gammon.com.au/forum/bbshowpost.php?bbtopic_id=119

The changes I made there (to incorporate Lua) required only minimal changes to the source.

You could do that, and like I did with quests (tasks), handle things like Engineering levels and so on in Lua.