Rocologo / BagOfGold

Economy plugin for Minecraft Servers
13 stars 6 forks source link

Balance not updating #25

Closed Zznorbo closed 6 years ago

Zznorbo commented 6 years ago

I was testing for my server and then:

I checked my balance using the sign. had 70 bag of gold in there. then I killed some mobs got about 37 bag of gold clicked the sign with it I made to (deposit 100 sign) it took the 37 bag of gold but when I check balance it still says I have only 70 bag of gold. I thought hold on a minute. So I tested it again the same thing. same thing happened?

Is there any way to fix this?

Only plugins for economy related im running currently are:

SavageFactions Jobs Bag of Gold (Vault) Essentials

Rocologo commented 6 years ago

Yes I am having some troubles with the balance and bankbalance and have had it for a while. Initially I tried to deny users to use BagOfGold while being in Creative, trying not to ruin the server economy. F.ex. you was not allowed to pickup BagOfGold while being in Creative and many more rules. In the end I gave up and decided to make same rules as when using Essentials (to be 100% Essentials complaint). I last version I changed the rules and yesterday I found another bug. The big problems began when the player changed gamle mode Survival->Creative->Survival, opening and closing the inventory, but I worked on this yesterday and HOPE I solved the bug.

I need to test more, but I would be happy if you would like to help with the testing? I have placed my newest DEV version her: https://www.dropbox.com/s/t3vcrw8z2l9ltn8/BagOfGold-1.1.3-SNAPSHOT-BTestBuild.jar?dl=0 https://www.dropbox.com/s/13upn0swfho6lmu/MobHunting-5.7.0-SNAPSHOT-BTestBuild.jar?dl=0

It is very important that you use debug mode, so you are able to see whats going on. Using /mh debug & /bag debug also you MUST open and close the inventory using the "E" button in both Survival and Creative modes before start testing.

The reason for this is that each time you close the Inventory the balance in database is checked against the amount og BagOfGold in your inventory, and the database is updated if the is a difference.

Zznorbo commented 6 years ago

Sure thing, I can do that now for you. Gimme 10-30 Minutes to follow those instructions and ill report back. I just got on my server again this time after a restart and tested and everything was fine. I was in Survival GM the all time though so that could explain it. Ill try switching survival creative open close open invo first on this version to confirm the Bug. then ill download your revision version and test the same process. :) Always happy to help. I truly do love the ideas behind your plugin and your feature set is 100% necessary for me to do what I would like with my server economy. So helping with the Testing is the least I can do.

Zznorbo commented 6 years ago

Okay Hi, I have done some small Testing to help out. Here are my Findings with your latest Dev Version:

Zznorbo commented 6 years ago

Okay I did Just have an instance where:

Zznorbo commented 6 years ago

This Shouldn't be a problem for me really. because I plan to only let players be in Survival mode, However If I ever wanted to open a Survival Section for my Server for free-style building or for some reason to have people help build etc. It could become an issue.

Rocologo commented 6 years ago

I forgot something. I strongly recommend that you use the plugin "PerWorldInventory" I have not yet tested the new DEV version without this plugin. Sorry I forgot to tell this. PerWorldInventory should solve the issue when changing gamemode.

PS Im at work for the ned 6-7 hours so I cant do much here...

Zznorbo commented 6 years ago

Not a problem Rocologo thanks so much for your help so far! 👍 You're doing a world of good for the Minecraft Server world!

I can't wait to get my Server going. I work a lot so its coming slow but I have spent years on different ideas and such etc. been doing it since i was like 13. now I'm nearly 22 still going. I had a server in the UK once when i was about 15 had it getting 100 unique players on a day was so awesome. But I am aiming for my next server to be a Nice Factions Server, Shops, Main City, Buyable/Rentable Plots, PvP Factions Worlds with bi-monthly Resets. etc. Leaderboards, High Risk High Reward setup in Australia :) You're plugin will go a long way to that, it will be the contributing factor of how the server will work.

I did have one question with your plugin. Would it be a possibility to have say, The Physical currency when you bank it turn into a Virtual Currency that can be spent at stores etc. So Like:

Player 1 kills a mob, gets 30 bagofgold, banks 30 bagofgold, that turns into $30 in digital currency which is accessible everywhere you go, like a debit card haha but still have bags of gold drop that can be lost on death, stolen by others who raid etc. but when they get to say 200 bag of gold they can go deposit that to keep it safe, but there should be a minimum amount to deposit so people dont just warp to city every 5 secs to deposit 30gold so a minimum like 200 or 300 etc.

Rocologo commented 6 years ago

Hi, have you tested V1.1.3 ?

You should use the plugin PerWorldInventory too.... https://www.spigotmc.org/resources/per-world-inventory.4482/

Zznorbo commented 6 years ago

Hi I have, I am just doing more tests now to check stuff, because it will be such a vital plugin for my server

Zznorbo commented 6 years ago

I was having a problem when using the BagOfGold NPC Banker with Citizens 2 where on server restarts it lost all the balance info in the bank so lost money, I thought the update fixed it but its actually still doing it. first it changes the bank balance and moves the number into the normal balance line, and then it gets reset down to 0 when clicking again.

zenturaclj commented 6 years ago

Please create a new ticket when you find new bugs :-) So I dont get confused :-)

Could you please descibe step by step (in details) what you do so I know how to test / reproduce this bug.

If I can reproduce the bug, I can fix it :-)

Zznorbo commented 6 years ago

oops sorry haha first time on github. So Step by step:

Create the Banking Npc with BagOfGold / Citizens

Give myself Gold (2000) or whatever number, doesnt matter.

Deposit to banking npc.

Run server command /save-all Run Server Command /stop Restart the Server

When back on click the banking Npc

Now the balance has been reset to 0, so my banked money is lost.

(Personally this doesnt bother me, I plan to have players use an enderchest, But I stumbled upon the bug, trying it out so I thought I'd report anyway to help ya out.)

Thanks!

zenturaclj commented 6 years ago

Thank you! I will try to fix this tonighty when Im back from work...

Rocologo commented 6 years ago

I forgot to ask if you are using Per World Inventory ? (This is strongly recommended - even if you only have one world)

Rocologo commented 6 years ago

I have found the bug it was VERY hard to find - it took me at least 2 hours. But it was worth it, because the error was actually very serious. And I had made the same error in MobHunting!!!

Thank you for help me. Please test newest build https://fractal.lindegaard.one:8181/job/BagOfGold/ https://fractal.lindegaard.one:8181/job/MobHunting/

Please let me know if it works!

Zznorbo commented 6 years ago

Hi, Thanks so much for that, I actually have been using perworldinventories and that fixed the other bug where swapping gamemode and opening inventory duped the gold and then made one dupe useless and eventually the real one useless too. now there was just this npc banker one. Ill give it a go now and keep you updated.

Also thank you so much for your on-going support with this plugin, I know it takes a lot of time and Effort put into something like this, And I would be very sad to see it go, So I am hoping you devote a bit of time over the next few years to keep it going through the updates. Do you have a donation page?

Zznorbo commented 6 years ago

Hi, So I have tested it out and it seems to be fixed so far! great job!. Hi I haven't had a chance to see if this is possible already or not because I have been working a lot of recent. But I was curious if it was possible to do something. So I want to setup Deathchest on my server so players keep their custom items like weapons. But at the same time I still want people to be able to lose their gold to other players if they die or maybe even a percentage of the gold that they hold, is this a possibility?

Rocologo commented 6 years ago

I forgot to answer your question about a donation page. I only have Paypal: http://paypal.me/rocologo

Im not sure what a Deathchest is??? Is it a plugin? Where their dropped items is stored when they die?

I might be able to interate to DeathChest. But you can also configure in MobHuntings config.yml what the cost is, when the player dies (Killed by a mob or robbed/kill by a player).

Rocologo commented 6 years ago

Found it : https://www.spigotmc.org/resources/deathchest.35800/

Please create a new ticket if you want me to make integration to Deathchest, so vi can discuss how it should work???

Im not 100% sure that I can make the integration or if I willl need help from the Dev of Deathchest

Rocologo commented 6 years ago

Please test V1.1.6

When you use PerWorldInventory you should set

player.economy: false

in PWI config.yml

Rocologo commented 6 years ago

And now we are on V1.1.7

Zznorbo commented 6 years ago

Hi Rocologo, Thanks for that. I have that setting as false btw. I havn't tested the Robbed feature of yours yet. It may already do what I am looking for so ill hold off on asking more about that until I get to test it haha. Thanks though! I'll be giving you a small donation shortly, its just small but I want to show some form of appreciation for your hard work!

Zznorbo commented 6 years ago

Hey roco, So I have been testing it with DeathChest Plugin, which stores your inentory in a chest on death. and Have attempted to configure your mobhunting/bagofgold plugin to have it so mobs steal 30% and Players steal 50% but these don't seem to work when I recover items from the death chest the amount of gold remains unchanged from point of death. (so not losing any money from dying which is a feature I am looking to do) perhaps its a deathchest thing? Ill test without and get back to you

Zznorbo commented 6 years ago

Okay, have tested with and without deathchest, the rob feature doesn't appear to be working so far.

Rocologo commented 6 years ago

Donation received! :-) Thank you M. It is of cause nice when some buy me a cup of coffe - it makes me happy that people do this by them selves. :-) Another thing you could do is to enable bStats (if disabled) I follow the numbers and the more users I have the more happy. The data collected by bStats is 100% anonymous.

I see I will have to test the robbing features it's quite a while since I last tested this, and I will test Deathchest as well. I dont not use Deathchest on my server, but I use a similar feature: DiceGraveStoneOfDeath 1.5b I want my plugin to work with both of them, so I will have to test it again.

Zznorbo commented 6 years ago

Awesome! thanks Roco, not a problem my pleasure to buy you a drink! Keep up the great work!. The end goal atm for me seems to be seeing Player Rob and Mob Rob percentage enabled and working with Deathchest :)

Rocologo commented 6 years ago

Until now BagOfGold was actually a single world economy, where I forced the plugin to work eventhough the users had more worlds and changed gamemode. I have been thinking of making it real multiworld / gamemode change compliant for a while. But sunday afternoon I deciced to start my work on V2.0.0 whch will be true multiworld. But will be a big upgrade :-)

Zznorbo commented 6 years ago

Terrific! I also had another awesome idea. Not sure if already implemented but thought I'd throw it out there. Ability for 2 different currencies, so a main one being the bag of gold and something a bit more special that you can earn at either rarer drops from rarer mobs.. crafting.. or exchange for multiple items maybe Currency and special items. Of course that could be implemented with npc shops or command signs from other plugins to trade custom items for another custom currency to then buy special things.. aesthetic plugin style things or house shops large plots of land in the hub etc.

Rocologo commented 6 years ago

I think I will start with real Multiworld support and release of MC 1.13 is very close, so I have to be ready when Spigot 1.13 is released.

Bad news is that when when all developers port to MC 1.13 the will probably not support older MC versions any more.

Zznorbo commented 6 years ago

yeah not a problem. I'm still developing my server and semi-holding off because I know 1.13 is close and want to see how that goes as far as plugins and updates.. haha you're doing an awesome job tho man keep it up!

Rocologo commented 6 years ago

Donation received! :-) Thank you M. It is of cause nice when some buy me a cup of coffe - it makes me happy that people do this by them selves. :-) Another thing you could do is to enable bStats (if disabled) I follow the numbers and the more users I have the more happy. The data collected by bStats is 100% anonymous.

I see I will have to test the robbing features it's quite a while since I last tested this, and I will test Deathchest as well. I dont not use Deathchest on my server, but I use a similar feature: DiceGraveStoneOfDeath 1.5b I want my plugin to work with both of them, so I will have to test it again.

Rocologo commented 6 years ago

Im having problems with PerWorldInventory so it is hard to test my plugin..... the new version...

https://github.com/Gnat008/perworldinventory-kt/issues/63

Rocologo commented 6 years ago

MC1.13 Only version can be found here: https://fractal.lindegaard.one:8181/job/BagOfGold/ https://fractal.lindegaard.one:8181/job/MobHunting/

Zznorbo commented 6 years ago

Awesome, I'll have to give this a go when I get to 1.13, naturally as you can imagine I will be waiting on 30 odd plugins or more to update first XD

Rocologo commented 6 years ago

Yes. Notice that v6 and v2 is still not backwards compatible. Its only for mc 1.13 but now it runs.

Next step is the new 1.13 mobs and then backwards compatibility with older versions

Rocologo commented 6 years ago

I close this ticket - only because its too long :-)

Let me hear when you decide to go to MC 1.13 :-)