PDA

View Full Version : Experience System feasible? (C-dawg)



DarkFlameWolf
11-14-2007, 01:52 PM
Here is my experience system idea(mainly aimed at C-dawg to see if he can do it):
Everything you do increases the experience you get.
For example, the more times you swing your sword and actually HIT an enemy with it, you get a specific amount of 'sword experience.' Get a certain amount and you can level up your sword strength. (basically the same thing as getting a new sword)
Same thing goes with the bow/arrow: use the arrows and STRIKE something (can't be misses or you could spam these attack weapons) with the arrow, you get 'arrow experience'. And you level up the strength of your arrows once it reaches a certain amount.
Use your candle, wand, boots and/or lens long enough, you get 'magic experience' and you can physically decide if you want a more powerful candle or more powerful wand, boots that use less magic, or a lens that can see farther, etc. (may be hard to script)
Use your hammer or hookshot enough times, you get 'hammer' and 'hookshot' experience which allows you to do more damage (new hammer) with the hammer and reach farther with the hookshot. (which should start off with a small chain until your 'character' can work with it more.
Finally, instead of HC Pieces, you have experience points. Every enemy is worth 1 xp point with exception of stronger enemies, which are worth 2 and the very rare, 3 xp points. Bosses are worth 4 xp each.
Once the experience has reached a pre-defined number, you get a HC Piece in your menu. And you must do this 4 times to get a full heart for your meter, maxing out at 16 or 24, whichever the quest designer prefers.

So...is this all possible?

Russ
11-14-2007, 02:54 PM
It seems feasible. Maybe not item specific, but you could easily make a script that gives Link a certain amount of experiance whenever he kills an enemy, based off the enemies I.D. number. Then, it gives him a better sword and a heart container piece when he gets enough points. I might be able to make this. Someone else will have to do the meter that shows experiance though, as I have no idea how to use drawtile.

C-Dawg
11-14-2007, 04:06 PM
Yea, this is do-able.

(1) Global variable for each kind of experience.
(2) Global or FFC script modifying inventory based on experience variables.
(3) Item scripts that change the global variables.

Only the third bit requires some complicated coding. For instance, there is no way to directly tell when an enemy is hit by Link's sword. But you could have two scripts, item and FFC, that together do this:

(1) Check which enemies are on the screen and in the target area for a sword attack. (Close to the player perhaps). Store their HPs each frame and keep track of which enemy has which HP. This is not trivial.
(2) The frame after Link swings the sword, re-check those enemies for any loss of hit points. Then increment the variable accordingly. This is also not trivial.

As for other sorts of leveling up, pretty much anything you can think of can be implemented with varying degrees of difficulty. There's no direct way to check whether the hookshot hit a hookshot target, for example, but you certainly can check whether there is a hookshot combo in range when the hookshot is fired.

DarkFlameWolf
11-14-2007, 07:07 PM
yeah, I know this experience system would be a lot of headache to make. but it would pay off it successfully implemented.
The reason why its so restrictive on item leveling (for the sword must hit enemies, arrow must hit enemies, hookshot must hit targets, etc.) is because we want to prevent level 'spamming' early on and force players to actually use the skills properly.

Gleeok
11-14-2007, 07:43 PM
I gave up on the script for "standardized exp points" or whatever the fuck you want to call it, and I opted to create something similar but actually more balanced and to prevent power leveling, which I have succeeded greatly.

The woes of scripts i've found to be as such: multiple scripts checking enemy data every frame MASSIVELY slows down zc. couple that with reading subscreen data, weapon scripts, multiple ffc's and you're basically condemning the players with slower computers to stick that quest file in the trash can. //end sad truth mode

As I said, I've gone the route for an alternate exp system. One that needs a few lines of code and doesn't affect the above mentioned. Why would anyone want to re-invent the wheel though, it's always been wobbly from day one.

C-Dawg
11-14-2007, 08:41 PM
You've got slowdown? I guess it depends on how many enemies. I'm able to execute quick checks on the position of each enemy on the screen without a problem. You don't need to write to the subscreen each frame, either. You could have a "level" variable that keeps track of the exp needed. When the experience is above the level, THEN and ONLY THEN does the game check your inventory, update as necessary, and increase the "level" variable. Then again, it might be a processor issue. I run a four year old 2.6 ghz machine and I'm ok with very intense, un-optimized script activity.

Anyway, it'd take some coding finesse, but yes, it's feasible. However, you can't stop the spamming. You could hookshot back and forth repeatedly over a chasm, for example.

One possibility might be to have experience caps that increase when you get collectibles in the game. Secret of Mana did this with the Orb system, remember? You could only level your sword up to the number of orbs you had so far. This would stop spamming.

Are you doing special moves as well? Or perhaps enabling slash, spinning, etc as the swords level up? Some of that can be accomplished through mere item editing.

DarkFlameWolf
11-14-2007, 10:45 PM
well, my next quest idea would be a huge, expansive world similar to Oblivion where it has a basic over-arching story, but you can do whatever, go anywhere and take on any quest. Of course, this would be script intensive for every quest you could ever do in it. So this quest would be a hell of a long time in the making. I'm just wondering if something like this is even doable in ZC or should I just look to RPGmaker instead? (which is worse in the puzzle/dungeon aspect of a game)

Gleeok
11-15-2007, 09:51 AM
Sorry, I had to run before I could finish my post. Where was I...

Yes, all that is easy enough(minus the labor intensiveness) with scripting. The problem I was getting at was: With an enemy based exp system you'll never be able to stop player power leveling, or spamming. Final Fantasy failed, DW failed, and most every rpg ever made has failed. There are many exeptions though, and alot of these games don't use the enemy exp system. If you're going to cap player levels based on inventory, and inventory levels based on player exp, why even mess with enemy exp to start with?

Of coarse, in argument against all that I should say that it's easy enough to give huge exp bonuses once an area/boss/level is completed, perhaps balancing out the equation a bit. Also maybe give more exp for enemies that never return after death...

Just suggesting to maybe plan everything out first so you know how well it would work. Basically what i'm doing is such(I'm pretty certain I'm about the only one crazy enough to do so):

Instead of items, there are spells. Many spells. From fire to shield magic to tornados and teleport magic, ooh! and telekinesis(take control of an enemy and throw it around!):D (It can be done) And each spell has it's own set of exp points. Since they use magic and each cannot exeed the player level, AND the player level cannot exeed the spell level, both of which cannot exeed the game level, bam, spam proof. All with some global variables.

..Any way, ...to sum up: Yeah your idea will work with some set-up, and if planned out, should work very well at that. Like C- stated though, some items could be tricky, players could just hookshot for five minutes and level it up, or hammer posts the same way. Or any room where there's 8 Zols, they could just level up rather quickly by re-entering.

Have you messed with rpg maker at all? I downloaded the 30-day trail version about a year ago, and while I was impressed overall, I wasn't too fond of the graphical and gameplay presentation.

DarkFlameWolf
11-15-2007, 10:24 AM
of course I've worked with rpgmaker, I've made two full games out of it. But I was looking more into a Zelda-themed game maker where puzzles and in-game mini-games are much easier to pull off than they would be for rpgmaker.

C-Dawg
11-15-2007, 11:13 AM
Well, like I said, I'll help you out in your next quest endeavors.

I'll work on a sword-based experience system next week. No time this weekend. We'll get that working first and go on from that.

DarkFlameWolf
11-15-2007, 12:17 PM
well, another way we 'could' tackle this, which may be the easier route. I'm not sure..is this:
Every enemy has a experience value of 1, 2, rare 3, and bosses are 4.
After so many (set value) experience points, you gain a level. You can then choose to spend that level on a HC piece, a better sword (may require more than one level to 'buy' a new sword), a better arrow (may require more than one level to 'buy' a new arrow) etc. So in this way, you give the player the choice how he wants to level up his character. Would that be a more simpler method?

Dark Nation
11-15-2007, 12:24 PM
Post-2.5, I'd like to have NPC-based scripts. Every NPC would have 4 scripts: load, run, die, and unload. Load is executed when the NPC is created, before it appears. Run is executed every frame that the NPC is alive. Die is executed when the NPC's hp hits 0, but before the game engine acts on this fact. Unload is executed after the NPC is deleted from the active NPC list. There should also be a variable stored by each NPC stating what the last weapon to hit them was.

DarkFlameWolf
11-26-2007, 10:54 PM
Got a even more complex request/concept/idea for you C-dawg in your PM box.
Don't want to reveal it here just in case it doesn't come through or is even possible so people's hopes don't get dashed. (that and the idea stolen) :P

C-Dawg
11-29-2007, 01:18 AM
Don't want to reveal it here just in case it doesn't come through or is even possible so people's hopes don't get dashed. (that and the idea stolen) :P

This? This I don't get. We're not designing nuclear warheads. We don't have to keep our ideas safe from the Communists.

What are you worried about, anyway? 99.9% of people in this community never finish anything, god bless 'em. Whatever idea you have, I guarantee that you will stay ahead of your "compeditors" just by, you know, executing.

Don't strive to hide any innovations you do come up with, either. If you're really all that concerned about people "stealing" your precious ideas, just keep coming up with MORE ideas. You'll always be ahead of anyone who is just copying.

I'm usually quiet about this sort of thing, but come on. Development communities thrive on openness and sharing.

DarkDragon
11-29-2007, 03:51 AM
If you need a "perfect" experience point system, where each killed enemy adds a certain amount of experience points, then, at least in 2.50, you'll need to do a lot of (very expensive) checking each frame, as mentioned above.

However, if you just need to keep track of roughly how many enemies Link has killed, the following might be easier: attach to each item dropped by an enemy a script that increments experience points. You can then give bigger chunks of experience for certain special events, such as killing bosses, getting a special item, etc.

The player will then level up roughly proportional to how many enemies he kills, and probably will be none the wiser to what's really going on under the hood.

C-Dawg
11-29-2007, 12:14 PM
That's a little better than using ruppees as experience, but the same principle. I gather she wants Secret of Mana style experience, where it's the action, not the target, that gives experience.

jman2050
11-29-2007, 12:25 PM
Just as an FYI, I implemented internal counter variables for a reason...