Jump to content
  • Advertisement
Sign in to follow this  
arunforce

Mathematical approach to item prices

This topic is 3157 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I tried originally a arbitrary price, but as time went on and I added new items, they became less "fair" and I forgot my rules of item pricing relation. So I figured I should use a mathematical approach, based on stats, and then just tack on a small number so that the cost isn't always a pretty number ending in zero. There are 6 different stats modifications for each item, (Defense and Speed) are the main stats, the rest are rarely used. Originally, I was using Sum of (stat/item cost) ~= .01 which worked relatively well for my item pricing. So if an item costed 300 and had 3 defense, it would be a relatively good base price, but then I got to the heavy armors with -1 speed, and I noticed it basically screwed up the whole system, every -1 speed was equivalent to +1 defense, which I thought I could easily correct by making the defense ratio squared, since it was the most important factor for stats. I messed around with my equation a bit till I could find a acceptable price determining factor. I couldn't find anything satisfying enough, and the more modification I tried, the worse it got. What have you used to determine item prices, or what would you suggest would be a good method to determine item worth? -edit- Also, is it smart to price items linearly (my gut says no) (each level is relatively the same price for the items), or should higher leveled items get exponentially higher in pricing? Thanks

Share this post


Link to post
Share on other sites
Advertisement
I haven't thought this through but, for combat related items, start with a standard pair of individuals and you equip one of them with the base item and one with the enhanced item. What would be the difference on HP loss after one round? Could you then use that value somehow as a modifier to the price of the base object?

Share this post


Link to post
Share on other sites
I have a base item cost to start with. Lets say a Long Sword at 250g.

Add in material bonuses. A Adamant Longsword would cost 750g (+200%). Then enhancement bonuses. The Adamant Longsword +3 would cost 1050g (+100g/+1). Finally, other enchantments each have a cost as well, multiplied by the enhancement. So a Flaming Adamant Longsword +3 would cost 4050g (1000/flaming * 3). So 250g + 500g (200%) + 300g (+3) + 1000g * 3 (flaming +3). Each enchantment has a different value, so a Holy Adamant Longsword +3 would be a bit more expensive, etc...

Selling it depends on a skill, but at no skill the player would get 10% of the item's value, and would have to pay twice it's value to buy it back.

The reason for the multiplication is the system used. A Flaming weapon adds 1d6 damage per enhancement. So a +3 Flaming would do 3d6 fire damage, on top of the base weapon damage. In case of the above sword, 2d4 base + 3d6 fire + 3 magic, or a range of 8-29 points of damage total.

Share this post


Link to post
Share on other sites
Ignoring all actual values, determine the progression and item selection you wish to have for each level. For example, a player could purchase 1 level appropriate item per level, 2 level-2 items or 3 level-4 items. Then, you take the income a player normally gets during a level and this becomes your price for a level appropriate item.

If a level 10 player needs to kill 100 monsters to level up each giving 10 gold, he will amass 1000 gold during the level. A level 10 item would then cost 1000 gold. Level 8 items would be 500 gold and level 6, 333 gold.

If that same player should be able to purchase 2 level 10 items, 3 level 9 or 4 level 8, then they would cost 500, 333 and 250 gold.

As for determining item level, you could work some formula that will give you the progression you want. The rest is number crunching until you get a system that works out.

Share this post


Link to post
Share on other sites
I haven't tried to value weapons yet, because the armors were priced ridiculously inconsistent.

@tiblanc - Trying to value items based on progression seems logical, but I don't want to tie people to a statistical curve. If I did, then item statistical damage will most likely be off and I would spend time trying to balance hundreds of weapons statistics.

@domhnall4 and kseh - those are both interesting ideas, but in relation to armor it seems a bit more complex. Testing it in battle would just be like the derivation of a formula upfront (without variation of damage).

Let me try to show an example:

Basic Chestplate - 5 defense
Advanced Chestplate - 10 defense, -1 speed

- while typing this up, I think I figured it out -

Say the basic armor is 5 defense, and I want a ratio (stat/cost) of .01.

5/cost = .01, cost = 500

That's about 100 Gold per stat.

If I changed it so that defense cost say, about 200 gold per point, and speed was 75 gold per point, an appropriate formula could be developed.

200d+75s = Cost (In the end, it won't match the desired .01 per stat, but I don't think there is a fair way to do that and not have a defensive point cost the same as a speed point).

However, in my opinion, most RPG games (especially MMO) get more difficult as the user levels up, slowing down the users rate of progression and replacing it with depth, therefore the item cost growth rate should be matching (if not exceeding) the difficulty curve (spend more time farming).

A basic exponent curve that would mimic that, for example would be itemcost^(1+itemlevel/10), the graphs seems a bit too steep, but you get the idea.

I think I have been doing it backwards, modeling the EXP/Gold data on the items, items can always be adjusted, but EXP/Gold is theoretically permanent. So that suggests that I should fix in EXP/Gold first (until I am happy), then plot the items and the appropriate stats around the player growth curve.

Does this seem right? Is there any problems with my theory?

Thanks for your responses, shredded insight into my backwards implementation method.

Share this post


Link to post
Share on other sites
Cost partially defines the how much grinding is needed. If costs increase faster then rewards, then there are longer periods between rewards as the player goes up in level. If costs and rewards grow exponentially, that will discourage safe grinding: you need to kill 500 monsters at the current level to get a new sword, but if you move on to the next level you'll only need to kill 50 (versus linear of 80 monsters this level vs 50 next, where the player can decide to stay in a safe area earning better equipment).

As for a formula, that depends on the game's complexity. You want to calculate how much 'better' a player with this item is. Unfortunately, that can be very context sensitive. In some situations a fire sword is better than an iron sword, in some situations its worse. A weapon that reduces intelligence is fine for a warrior but death for a wizard. It might be true that early in the game just getting a hit is the important part of battle, while later on damage is crucial.

If you don't mind doing the math, or writing something to run a bunch of simulations, you can produce values that tie exactly in with the value of the item in the game. But a better way might be to just put equipment into tiers: depending on the situation you might prefer any of group A, but you'll just about always choose those over group B. Then you set each group to an average price based on what the player should have for money at the relevant point in the game, and apply a random discount/markup of say up to 10%. Some equipment will be overvalued, some under, but that becomes part of the game: can you spot a good deal in the armor shop?

Share this post


Link to post
Share on other sites
I think you're over-complicating things. Armor is bought for one reason; to protect the wearer. It's made, marketed, and sold based on that function. While heavier armor does weigh more, and restrict the wearer more, than none or lighter armor, that is a side effect of armor.

So while the AC/Defense or however you designed it should be taken into account, don't take the speed penalty into account in pricing it. So your advanced breastplate, assuming 100gp per AC point, with 5 points would cost 500gp, irrespective of the -1 speed.

As far as the last question, most games I've played have you getting new equipment in loot. However, if you're going to have the player buy all their newer, better stuff, then the price increase should be reflective of how much money you're shoving at them as well as the number of characters the player controls.

So if you give them 5g a fight, at 100gp/AC you're looking at 20 fights just to get the lowest AC armor you can have. For 6 characters, that's 120 battles. Just for, say Robes. That's a lot of grinding, and something that personally turns me off. I want to get on with the story, not fight slimes over and over until I can afford a copper sword and a suit of leather armor and a buckler.

That's why I just give them the ability to buy base equipment, then rely on a combination of fixed loot in the main quest areas, with some random loot in optional areas. I can judge where they're roughly going to be at when they reach a chest, and can give them better equipment. It does mean gold has little use once the party has a character who can raise dead, heal all conditions, and incinerate entire armies at once.

Share this post


Link to post
Share on other sites
Quote:
Original post by domhnall4hSo while the AC/Defense or however you designed it should be taken into account, don't take the speed penalty into account in pricing it. So your advanced breastplate, assuming 100gp per AC point, with 5 points would cost 500gp, irrespective of the -1 speed.


That's incorrect, because different types of armors are tradeoffs. A player who opts in for the light armor 1 (5 defense 0 speed) instead of the light armor 2 (7 defense -3 speed) should pay relatively the same amount, while he is getting a slight armor increase, the defect of the armor being heavier should, in real market respect drop the price of the armor. Well, that is my opinion anyways.

However I agree, at the moment it is just a player vs player game, so I should give players access to cheaper items, since I don't think player vs player should spawn random loot rewards, or add monsters immediately.

I guess that has given me something to think about.

Thanks to both of you for your insight.

Share this post


Link to post
Share on other sites
Your players are always going to find the best weapons for the cost no matter what you do. So how are you going to balance things? You can either go for a low number of weapons and armor, and balance those really well, or you can throw tons and tons of equipment at the player and hope that enough of those are balanced.

There are lots of ways to balance equipment. The problem with trying to come up with an equation for comparing "defense" and "speed" is that if you ever change how combat works (through any means, maybe you add a new spell), those ratios change. Whether this is a good or bad thing is up to you.

I would agree that equipment cost should not increase linearly.

Interesting topic, one that I would like to be able to come up with a formula for, but I'm not sure it's possible depending on your game.

Share this post


Link to post
Share on other sites
I don't think you should try to come up with a mathematical approach to this... it's really as simple as determining how much you want the players to earn per any length of time, and then setting prices accordingly.

When I worked on an online game, I used the US dollar as a base for currency. It made things a lot easier. For example, 10g in a game could be $1 US. Which means 1g = 10 cents US. Then you can determine the cost of familiar items in a game (such as food you would typically find in real life and whatnot... and then you can price it based off real cost.

For things like special armor that doesn't exist in real life, you just figure out what a player can earn over the course of a set period of time.

For example, if a player can battle monsters and earn 1000g in roughly 1 hour, then you can decide "is this armor worth an hour's worth of real work". This way you price things based on how much time was needed to obtain the money to purchase the item.

It works for our monetary system, so I don't see why it wouldn't work here. The worst thing you could do is just come up with prices willy nilly. You really should make sure to have some sort of base item with a base price to work with, so that everything else can be adjusted to match.

Time = Money, so the thing you need to figure out is "how much time should someone need to invest in order to obtain this item?"

You can really only go off of the value of time, because that's the only thing you can easily test. If it takes 10 minutes to obtain 100g, and an item costs 100g to buy, you know that a player will need to play for 10 minutes to earn that item. I think it's a pretty solid method for determining prices.

Basing it off of level is a little bothersome, because you need to determine how long it takes a player to gain each level. It's just an extra step to calculate. It's better to just cut to the chase and look at the time investment.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!