Jump to content
  • Advertisement
Sign in to follow this  

Price Brackets

This topic is 4062 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

Hi, I'm wanting to know a formula that I could use to drop the price of an item based on quantity, but to have the price start at a maximum price and not drop below a minimum price. Here are the variables I can imagine using: MinPrice eg $2.40 MaxPrice eg $0.90 MinQty, MaxQty, Qty eg 1 to 100 This is basically what I have: Price=(MaxPrice-(Qty*((MaxPrice-MinPrice)/(MaxQty-MinQty)))) It still drops below the minimum price though, and I could probably stop that with 'logic' (eg if), but I'm interested in what is best. Thanks for any help.

Share this post

Link to post
Share on other sites
Using your formula and values:

Price=0.9 which is the min price..

Share this post

Link to post
Share on other sites
Ok, I guess the answer I have is good enough.

Though I did improve it a bit cause I want it like so:

1 for $2.40 each
100 for $0.90 each

And this does it:



Thanks anyway.

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.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!