Capital-SurvivalEconomy : Real item backed stable economic system.

Discussion in 'Plugin Requests' started by roracle, Jul 11, 2016.

Thread Status:
Not open for further replies.
  1. Offline

    roracle

    WARNING: This is a HUGE request, but might be well worth it for a good 1.10.2 economy plugin. IF I MISSED ANYTHING (which I'm sure I had to) PLEASE leave a comment! If you think this is impossible or "already done by iConomy/CraftConomy so why?" please don't even bother! This is a real request to solve real issues in Minecraft economy plugins.


    Plugin category: Economy

    Minecraft version: 1.10.2

    Suggested name: Capital-SurvivalEconomy

    What I want: An economy plugin that has an item-backed system built in. This way, money can be traded from in the player’s account OR cash-in-hand. This should also include a shop system, banking system, a server lottery, and a server-only vault.

    The problem with most servers is they back their economy with time and effort, which isn’t a bad thing until you realize the main issue. That is, when a player first joins, he’s far behind those who have played for a long time, so far as money goes. This is usually not the economy plugin at fault though, as JobsReborn or MCmmo like to give money for leveling or doing something at all. It’s possible to turn that off, of course, but not many people do.

    So the goal here is to provide a system of economic stability and encourage low inflation rates. Server owners will HAVE to limit the amount of cash to keep prices low, and to keep new players competitive with older players. This will require turning off cash-outs from MCmmo and JobsReborn. MCmmo will still level your skills and give you the benefits of that, while JobsReborn has a wonderful system now that allows POINTS to be given instead of money so that points can unlock server-prizes or even add people to permission groups (since selling in-game benefits for real money is now against the TOS, this provides a wonderful alternative to incentivize players to actually play).

    One thing while you read this to keep in mind: when I say “money” or “debit” I refer to the same thing, which is the normal thing you’d see when you type /balance or /money in most economy plugins. When I say “cash” or “gems” I am referring to items in the inventory that are of the configured system, but haven’t been added into the /balance variable yet.

    With that being said, let’s get started on fleshing this whole thing out!

    *********************

    First, let’s talk about backing our economy. Items should be backed by actual items. This will induce a “gold rush” from players, to mine up all gold and diamond, OR whatever the configured currency is.

    Basic player/server interaction goes like this: player brings backed item to the bank, player right-clicks ServerShop sign, and it gives the player virtual money. The player can then trade that virtual money right back for the item they just traded if they wish. The item is worth the same both ways, as the virtual money is a promissory note that a gold ingot will always cost the price they traded it for.

    There should be a configurable system for this, but the most basic would be the following:

    Gold Nuggets = $1.00
    Gold Ingots = $9.00
    Gold Blocks = $81.00
    Diamond = $729.00
    Diamond Block = $6,561.00
    *Emerald = $59,049.00
    *Emerald Block = $531,441.00

    *Emerald should ONLY be used as a form of currency IF Villager Trading is disabled. The plugin should have an option to turn off villager trading completely because of this. The reasoning is to avoid inflation by players who understand how the villager trade system works. Personally, I’ll live fine without emerald trades, as these prices should be plenty of money using the settings for gold and diamond to work with in regards to any given land ownership system.

    However, because players can set prices at the penny, it should start at Nuggets being worth $0.01 to give a better system for cash exchange.

    Another option is to not let players trade to the penny via config options.

    Or set it where all penny exchanges are done through debit alone by rounding up the cash needed and depositing the change into the buyers debit account.

    If you think about it, 0.01 for nugget, 0.09 for inot, 0.81 for block, then 7.29 for diamond, and 65.61 for diamond block is perfect for a super stable system.

    Another more reasonable option would be to use IRON as a lesser currency, since it is so plentiful:
    Iron Ingot = $0.01
    Iron Block = $0.09
    Gold Nugget = $0.81
    Gold Ingot = $7.29
    Gold Block = $65.61
    Diamond = $590.49
    Diamond Block = $5,314.41
    *Emerald = $47,829.69
    *Emerald Block = $430,467.21


    *********************

    Second, let’s talk about payers. Because of Java limitations, players can only carry so much money in their balance. Because of this, players need a vault to store their precious cash-items. The player, let’s call him Steve, with an empty inventory, takes a gold ingot from his vault. When he types /cash, he will see he has $9.00 in cash because of the gold ingot in his inventory. Then he brings his gold ingot to a server bank where he can trade that gold ingot for $9.00. When he trades that ingot into the server bank, he should get $9.00 in his debit, so when he types /money it will show “$9.00” as his balance for his debited money. But this is only one part of this.

    The player should be able to, no matter what, if he has any of the server-tradable items on hand, type /cash and this command will calculate how many nuggets, ingots, and blocks of any configurable type and output how much cash-on-hand the player has. Calculating this would go like: check for gold nuggets, count gold nuggets and put in variable N, multiply N by specified value of nuggets (1) for NV. check for gold ingots, count gold ingots and put in variable G, multiply G by specified value of ingots (9) GV. Repeat for each backed item. Once all variables are in, add all variables. In this case imagine having two gold nuggets and 5 gold ingots. NV=2 and GV=45. So NV+GV=TotalValue, so TV=47, and player would see “You have $47.00 in cash”.

    Now the player should be able to set up a shop, and if a player has enough money in his debit, he can trade at that shop. A fancy “item on top the chest” shop could be awesome, and also the ability to link the shop to other chests would be awesome, too, but not necessary. The player should be able to set it up much like QuickShop-NotLikeMe does it, but allow the item’s nametag to display and not item type, so custom items can be easily sold (such as SlimeFun things, in QS will show as “playerhead” but it’s actually a robot core or something). Players should have a global OR specific shop preference, to trade for the item cash or for debit. If the item is traded for cash, the player setting up the shop must first have a vault set up.

    Each player should be able to define the preferences of how they wish to pay for trades. By default it should be “pay by debit”, but they should be able to use “pay in cash” as an option (thereby the player would have to have the cash-on-hand to buy from said shop). An option to “cash first, then debit” should also be available. The reason for debit to be default is this scenario: the player needs a new diamond sword, so he grabs some diamond from the bank, and sees a shop selling sticks, so he buys a bundle. If cash pay option was on, it would trade his diamonds for it, forcing him to go back to the bank to get another diamond.

    Player shop prefs and player trade prefs should NOT have to be the same. IE: If someone wants to pay with debit, but the shop is set to be cash only, the player should still be able to pay in debit, but it is translated into the cash on the shop-owner’s side and deposited into their vault.

    *********************

    Third, let’s talk about the server/admin side of this plugin. The server admin should set up a place for players to trade their cash for debit money. When a player brings, say, a gold ingot to trade, and he right-clicks the ServerShop to trade the ingot in, that ingot should go into a Server Vault.

    Okay kids this is where it gets complicated. The server should offer to take money and give a traded item back. Yet the admins could easily set a preference that would TAX a player for withdrawing money, but that taxed money should NEVER just go away. The Server should not just have a vault, but an account of its own, too! This account would be used in various ways, all of which are fun for the players.

    One way to use the server owned money is to offer a lottery for players. In the config file, where we see the taxes settings, there should be an option to put a percentage of the tax into the lottery, and a percentage into another account for (in example) backing a stock market (which can be handled by another plugin all together).

    The server could impose a global tax on all shops to accomplish a quick lottery or market backing. This is especially important since most players will not participate in the stock exchange but just trade their own stocks via personal shops, but new players might find solace in competitive prices at the stock exchange if the demand is low for some of the basic blocks they might need in comparison to what a player might sell the same block for.

    Under the tax setting in the config, it should look like this:

    Bank-Taxes: 0%
    Global-Taxes: 8%
    Distribution:
    Server-Lottery: 75%
    Server-Market: 25%

    In this example, when a player trades money for an item back at the bank, he is never taxed. But when a player trades at another player shop, he IS taxed. That tax is then split into two server-owned accounts, one named Server-Lottery and another named Server-Market.

    Server-Lottery should be managed by this plugin, as a lottery system that can pull from this specific account would be distributed to the winners of said lottery. Lottery should be “buy no more than 10 tickets”, “each ticket is one number 1-100”, and “winners get even splits”. Max tickets should be configurable, and max random number should be default 100 but also should be configurable. Tickets should cost configurable amount each, but I’ll say $1 by default, and when a player buys a ticket that money should go to the Server-Lottery account.

    *********************

    Fourth, we will discuss the banking procedure. The player should be able to store his debit money in a secure banking account, which would help grow available money the player can have. If a player reaches his limit of cash (because of Java limits, again) he could deposit all he has into a bank account and start building up again. Each player should only have one account. Because money cannot come out of thin air, there should be NO interest built on this. If the server wishes to have interest, it should be no more than 8%. This will ensure a small inflation of the economy, and could even inspire investment in a separate plugin that handles a stock exchange.

    *********************

    Finally let’s talk about the ever-beloved Gold Sink! No no, you don’t wash your hands in a gold sink, but instead this is a term used by MMOs all over. Most MMOs and even most Minecraft servers like to “get rid” of gold to keep the economy low, and they do this by offering server shops. In World of Warcraft, it’s any vendor that isn’t a player vendor. You get your item and poof! Money gone from the world forever.In this method, however, the gold sink is the player. The player will NEED to make tools, namely diamond tools, which as we can tell, diamond is worth a lot of money. So three diamonds to make a pickaxe would cost a player $2,187.00 to make, in diamond alone. Therefore, it is taking that money OUT of the economy FOREVER once the item is made.The limiting of money in the economy is how you have a stable economic system, and the less money in a system, the cheaper people will price things.*********************

    Ideas for commands:

    PLAYERS:
    /money OR /debit OR /balance : show current debit balance

    /cash OR /gems : show current in-hand money balance

    /lotto buy <x> : buy a lottery ticket with a random number or the number specified in <x>

    /lotto bal : checks lottery pot

    /vault : shows balance of vault

    /shop set <price> : set price per item at focused shop

    /shop remove : remove focused shop (keeps chest and items, just can’t sell, also breaking shop sign would do the same thing)

    /money top OR /vault top

    ADMIN:

    /capital : admin commands


    Ideas for permissions:

    PLAYERS:

    capital.bal.debit : get balance for debit

    capital.bal.cash : get balance for cash

    capital.bal.vault : balance for private vault (might not want this for players)

    capital.bal.top.* : show top DEBIT account, and nothing else

    capital.shop.use

    capital.shop.createcapital.pref.* : set user preferences such as “pay with debit/cash/both” or “buy for debit/cash”.

    capital.bank.deposit : can deposit money into a bank account

    capital.bank.withdraw : can withdraw money from a bank account

    capital.lotto.buy : buy a lottery ticket

    capital.lotto.bal : check how much the lottery pot is

    capital.pay : pay another player

    MODS and ADMINS:

    capital.bal.others.debit : get balance of another player’s debit

    capital.bal.others.cash : get balance of another player’s cash

    capital.bal.others.vault : get balance of another player’s vault

    capital.bal.server.debit : get balance of server-owned debit account

    capital.bal.server.vault : get balance of server-owned vault

    capital.bal.server.lotto : get current balance of lottery holdings

    capital.give : give a player money (admin must not overuse this)capital.take : take money from a player (admin must not overuse this)

    When I'd like it by: Time is gems?
     
    Last edited: Jul 11, 2016
  2. Offline

    htmlman1

    @roracle

    I think that this plugin is far from impossible, but it will take a lot of time to program and debug (the latter probably being the most time-consuming). Even so, I'm willing to take it on as long as you're willing to wait.

    Before I do, though, let me first state my understanding of your request, so we can see if we differ on any important points:

    1. Money will be based on items.

    Players will only be able to obtain money by trading items, either with the server or with other players in shops. The server, however, will only accept a small range of items - namely precious metals and ores like iron, gold, and diamond. Other items can be given player-defined prices and exchanged in shops (right down to the penny, unless otherwise configured), but will have no "official" backing. Villager trades will be disabled to prevent other income and trade from villagers.

    2. Players will have access to two different kinds of wealth.
    The first is purely material-based, and is calculated on the fly and converted to a number (e.g. one iron ingot will be worth x dollars). The second is a numerical value recorded by the server, which is modified as players convert items to their calculated values and then add them to their balances. Players should be able to choose which kind of wealth they trade in, so as to prevent unintentional depletion of resources or debit.

    3. Servers will have a "bank", which will be the interface through which players interact with it.
    This is where players will exchange their resources for wealth in debit. They'll deposit into this account by right clicking on a sign prefaced [ServerShop], and will receive debit wealth in return. If players withdraw from the server bank, they will lose debit wealth, but gain an equal amount in material wealth.

    4. Players will be taxed, depending on what context they trade in.
    The configuration will have two different nodes for trading contexts: one for server-driven trades, and the other for purely player-driven trades. Each will have a different tax rate.

    5. The server is also a player, economically speaking.
    The server itself will have an account, which is split into two parts: one account to be used as a pool for a lottery, and another to be used as the backing for a stock market. Every time the server gets income from taxes, it will be split into each section of the server's account based on configured values.

    That's how I see it right now. There are, of course, smaller details and commands that you requested, but for now I'm focusing on the most fundamental concepts of your economy system.

    Did I get anything wrong? (Probably.) Did I miss anything? (Definitely.) Just tell me, and once we've cleared up the aspects of this plugin request I'll get to work on it.
     
  3. Offline

    roracle

    You have done well comprehending this! What I would point out, is that the Server as a player isn't just going to be Lotto or Stock, but the admin should be able to specify various other places to put taxes. Those were just two examples of how taxes could be spent.

    You see, if a server also has Towny, they could specify that Towny taxes go somewhere, too, probably a stock market, where something like Hyperconomy could hook into that stock market account as it's own backing. (I know, I told you this could be complicated lol).

    But you pretty much nailed it!
     
  4. Offline

    htmlman1

    Oh, haha, I'm actually pretty surprised - I was expecting a large set of corrections here and there. Glad to know I've got the gist of your request. I'll try and implement support for other plugins' economies too.

    EDIT: I just saw something I somehow missed the first time I read your suggestion. What are /vault top and /money top supposed to do? Also - do you want a player's vault to be a virtual chest inventory that they can access? In this case, do you want their storage to be restricted only to server-backed items?

    Also, would you mind if I turned the result of this request into a submission on BukkitDev? Since this is something that could potentially be used by many other plugins, and is also something that could be somewhat error-prone, it'd be easier to coordinate updates, releases, and API information on a BukkitDev page as opposed to a forum thread. I'd be sure to credit this thread as inspiration, of course.
     
    Last edited: Jul 11, 2016
  5. Offline

    roracle

    /vault top and /money top would be a list of the top accounts or vaults. I think it would be neat in for pure PVP servers to allow /vault top so factions could have an easier time with knowing who needs to be taken down. I use Towny on my server, and it's a semi-PVP but more an RP server. This economy system is really geared toward the more RP aspect of the game, because it is so open when players CAN pvp but aren't forced to, but some people love that kind of stuff, and would utilize /vault top more than anything.

    Also I wanted to say /vault would show a player's personal vault in the chat, something like "56 gold ingots, 32 gold blocks 12 diamonds, 3 diamond blocks." But the vault would be it's own chest/double chest, and should not allow hoppers to take from it (if possible).

    Also, go ahead and submit it to BukkitDev. I'm not opposed to this at all.

    @htmlman1

    I should note that server shops should be set up like player shops, selling only one of the items each (or buying) so that each item has its own shop.

    There should be no shopping or banking done in consoles, players should have to physically go to the banks or shops (this is survival after all).

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited: Jul 11, 2016
  6. Offline

    htmlman1

    Quick question about how you want this to work out. Do you want the server's account to have unlimited debit, but a vault with "actual", "registered" inventory, so that people can deposit gems and receive money in return - but not buy an unlimited number of gems back from the server? (In other words, unlimited debit to exchange with players in return for items, but a vault that can run out of hard materials after a while.)

    Sorry, this was a question I didn't think to ask until now.
     
  7. Offline

    roracle

    Great question. Since no money is made without tradable items, the goal would be to offer unlimited back and forth, but a tight lid economy might want to offer gems back, and if the gems wanted are unavailable, the server could calculate what gems there are and if it can make said valued gem requested and make change in its vault.

    However, it's okay to not allow this, but it would require turning off the vault.

    I'm glad you thought of that question, it hadn't occurred to me how terrible that math was lol.

    Unlimited would allow players to get what they need, diamond or gold or iron, without hurting the economy but it adds a level of ease. Not unlimited could cause loopholes in available gems unless it can calculate total gems possible based on what is available.

    It would be nice to have a method of checking money dished out to the public against what's been traded and in the vault, so exploits could be found.

    What could be done is all trades could add to a server account the same amount a player received, so the server account could keep a rolling total, and if a player withdraws, that total is depleted for the exact cost of what gem is being withdrawn.

    I cannot stop players from trading gems directly, but it would help to have checks and balances between player and server activity.

    The thing to remember in that method is to not let admins or moderators dip into the server account's funds, or just hide the server funds in a separate way so it's not in an account listing (like top accounts).

    I have to say, even if it's not unlimited but well balanced and calculated, there is no way a depression could occur. If a run on the bank were to happen, if balanced out, the bank will yield exactly the correct amount to every player.

    In a way it's the same as unlimited as no money is backed without the required gems. And money only gets created when a new gem is traded to the bank. So I guess it's balancing itself. We don't have the possibility of flawed men stealing all the gold in Minecraft, or at least we're safer from such a thing.
     
    Last edited: Jul 16, 2016
  8. Offline

    htmlman1

    Ah, that's right - good point. Hadn't thought of that for some reason haha. I guess for now, then, I'll just implement an unlimited version of the server's account and vault, since frankly I don't have too much time to work on a limited version - lots of checks and extra functions to write in that case, and I'd rather you have a finished version of the plugin sooner.

    True, when it's generating every new chunk that the player walks!
     
    roracle likes this.
  9. Offline

    roracle

    @htmlman1

    I have this idea...and it doesn't HAVE to be implemented...but it's just another "currency" to represent the economics. Much like the BankNote plugin, I enjoy the idea of having paper-tradable money. I think if I were designing a server, with a stable economy, $1, $5, $10, $20, $50, $100, $1000, $10000, and $100000 notes would be cool. With a customer server texture pack using NBT data (like with optifine packs), that would allow us to use the NBT data to specify new textures for Bills (or Notes).

    This could replace using Gem currency, as it's easier to calculate pricing on a base 10 number system instead of a base 9 one. The Gems would all be base-9 still of course, but players could swap between cash and debit, and pay with cash instead of gems.

    I like the BankNote plugin, as after a while people will run out of space (Java limits) and can store 1,000,000 in a note and deposit that into their "Bank Vault" (which I set up currently as an elaborate room with an ender chest in it). What do you think about this?

    EDIT:
    The following is what I have in mind, for the final outcome of a server using Optifine and a server-specific texture pack, but should be optional for those not wanting to go that far with it:

    With the NBT data, we can use a system which SAYS your 0.01 coin (NBT: Penny, ItemID: spidereye) is backed by iron. Then you can have a 0.05, 0.10, & 0.25 coin as well, each using a different ItemID and NBT name. The ItemID cannot be a solid placable block, however. It must be paper or something non-consumable on right click (by the player such as bread or mobs such as wheat for cows).

    Each item would then get its own textures. Right now on my server, I have BankNotes and using this method, with emerald as the ItemID, and Bank Note as the NBT data. Then I point the nbt config file (banknote.properties) to the sprite used. Yes, anyone could re-label an Emerald as Bank Note and get the texture, but it doesn't redeem the item. These are 128x128 sprites. Here's what that in practice looks like:

    [​IMG]
     
    Last edited: Jul 16, 2016
  10. Offline

    CeramicTitan

    @htmlman1 I'd be keen to collaborate with you. Hopefully we can knock this out over the next 6 weeks while i'm still on holidays.

    EDIT: SO essentially, this economy works based on supply and demand?
     
  11. Offline

    htmlman1

    I'll look into BankNotes, then, and see if there's an API for it. It'd be easier to plug into this system you have on your server already rather than reinvent the wheel (faster too).
    Sure, if you want to PM me or discuss this in some way I'm down for it.
    Yeah, we as programmers actually have less of a job to do than the players, who will actually have to get the system working :p
     
  12. Offline

    roracle

    @CeramicTitan
    @htmlman1

    I've been looking for solutions to market pricing, that can calculate prices based on supply and demand, and do so dynamically and linked to other items based on them. Much like HyperConomy works, actually, including the ability to set finite prices on some items (like regulated gems for item backing) and the ability to get an MSRP on any item a player wants to sell. However, I would like the money-backed gems to also keep a trade value that goes up and down outside of the set value of the item as sold to or bought from players.

    The actual cost of that item should influence the hyperbolic curve also, not just that it was sold, but that it was sold at market price, or at a higher or lower price. This allows players to suggest worth of something, which could let some players take advantage of shorting the market by setting their own prices super low, intentionally crashing it. That would be awesome player interaction, actually. People could think they have amassed fortunes in a market item then someone can screw with pricing, bringing down the value. This means there should be an option to never sell an item below MSRP.

    I guess you figured out MSRP means Market (not manufacturer) Suggested Retail Price, and is dynamically changing. In the same way, a shop selling for a higher price could soon find their items marked at the MSRP if the MSRP is higher than they set the price at originally (or lower than the MSRP, if enabled to sell low, the price wouldn't be pushed around, just remain at set price).

    Another spasm you say? It's not uncommon for the free market price of an item to be worth something to most players but still be possible for the share itself to be worth far less.

    This includes various reasoning, such as price to book ratio, along with other factors like supply and demand. We're talking liquid value vs speculated worth. In this way, players will often do good for the economic market both in stock and in free trade.

    ANOTHER THING TO DO, and might be it's own plugin: Find a way of tracking what original-seed-spawned blocks break, as those items are not yet circulating in the market, but there is someone holding, and we could do shares, too! That way people buy shares of a stock, profit off gain, and sell that to other players, or they could liquidate the share by selling it to the bank who would just offer it right back. The shares would gain value as more of said block is broken. Price of a share could be determined by the market price against the overall supply. Or any way you'd want really.

    This could allow players to trade ON iron, gold, and diamond, and profit off them in a new and interesting way. Let's take gold, for example. What we look for is the amount of gold ORE that is mined up and take a count of that. It should not count if re-placed and re-broken. Now, Steve decides to buy a share of gold. Default price is $7.29 a share (for example, could be a more round number). Now the more gold ore is mined, the higher the stock of it. But what are gold products selling for, exactly? Most will trade gold in at the bank early on, so it's a good early investment for sure! Gold rush much?

    Anyways, so players start mining up their gold. The one gold share that he bought is now increasing. What was once one gold, is now worth two whole golds. Soon it'll be worth a 64 stack! He's now made money off people making money, but these are only virtual shares he's bought. A share of any kind sold to bank will yield only debit in return. Of course, with gold shares, they aren't direct related to the gold in the market. It's simply a futures type of trading, what to expect, when to buy, when to sell...basically you invest in the server's future itself. Save your diamonds, trade futures. *hint hint...lots of cobblestone will be mined up by everyone....*

    Also see this posting for a similar idea but in a different way...not futures trading, but public corporation shares. I'm sure both ideas could be one plugin: https://bukkit.org/threads/capitalism-survival-business.424967/
     
    Last edited: Jul 17, 2016
Thread Status:
Not open for further replies.

Share This Page