Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ SMAUG
➜ SMAUG coding
➜ Changing Exp needed for next level
Changing Exp needed for next level
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Malelder
(9 posts) Bio
|
Date
| Tue 22 Jun 2004 12:51 AM (UTC) |
Message
| I've searched around, and can't find any good answers on this one...
In stock smaug (1.4a), the formula the code uses to calculate experience needed for the next level is (lvl * lvl * lvl * exp_base) and is located in handler.c. What I'm trying to accomplish is to make the exp needed for the next lvl just be the (lvl * expbase).
I'm guessing the former formula must be adhered to, because if i change that line to just be (lvl * exp_base) then not only does experience needed not get calculated correctly, but it also seems that from that point on, the char receives no experience at all for anything they kill.
Code is still mostly stock, although i've commented out the code that gives experience for each successful hit, and plan on removing the code that gives experience for using skills and spells. I want players to only receive exp for the actual kill.
Am i looking in the wrong place? Does it need to be changed somewhere else? I've been staring at this for a couple days now, and can't see why it's not calculating correctly. I'm not the world's best coder, but I've been on a roll getting other things to work...this one is giving me a huge headache though (: Anyone?
Kurt
| Top |
|
Posted by
| Meerclar
USA (733 posts) Bio
|
Date
| Reply #1 on Tue 22 Jun 2004 12:56 AM (UTC) |
Message
|
Quote:
I'm guessing the former formula must be adhered to, because if i change that line to just be (lvl * exp_base) then not only does experience needed not get calculated correctly, but it also seems that from that point on, the char receives no experience at all for anything they kill.
Are you testing this with existing characters that already have experience and levels built up? If so, you will need to adjust their experience downward to where it would be under the new formula to do any proper testing since the old formula would very easily take them over the new xp cap after just a few levels. Also worth mentioning is that testing with immortals won't give experience on kills either. |
Meerclar - Lord of Cats
Coder, Builder, and Tormenter of Mortals
Stormbringer: Rebirth
storm-bringer.org:4500
www.storm-bringer.org | Top |
|
Posted by
| Malelder
(9 posts) Bio
|
Date
| Reply #2 on Tue 22 Jun 2004 01:20 AM (UTC) |
Message
| Yup, I've been making a brand new test char each time I've made a change, and then invoking a room full of mobs for the test char to plow through (after buffing out the test char). | Top |
|
Posted by
| David Haley
USA (3,881 posts) Bio
|
Date
| Reply #3 on Tue 22 Jun 2004 08:57 PM (UTC) |
Message
| Chances are you missed a spot or two where experience is calculated. I would trace this backwards, looking at the code that determines if the player is ready to gain and seeing what it looks at, and then find out what that looks at etc. until you find the source. This shouldn't be that hard and you shouldn't have problems like the one you describe. |
David Haley aka Ksilyan
Head Programmer,
Legends of the Darkstone
http://david.the-haleys.org | Top |
|
Posted by
| Robert Powell
Australia (367 posts) Bio
|
Date
| Reply #4 on Wed 23 Jun 2004 04:52 AM (UTC) |
Message
| On the chronicals website is a snippet for the differenc exp system that they use, there are a lot of places that get changed to make the way they do things work, my guess is that you also need to change those other things and mine is only a guess, im a tinkerer not a coder LOL |
Just a guy having a bit of fun. Nothing more, nothing less, I do not need I WIN to feel validated. | Top |
|
Posted by
| Malelder
(9 posts) Bio
|
Date
| Reply #5 on Sat 10 Jul 2004 06:39 PM (UTC) |
Message
| Thanks to all the replies (: There definately was a lot more places to look than i had originally thought. Got it to work how I wanted after playing with it a few days (: | Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
19,251 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top