Commit Graph

68 Commits

Author SHA1 Message Date
Phoenix616
9a08e8897b
Don't allow opening of shops via sign by default
This has caused lots of confusion in the past regarding the first time
setup and might be a feature that people don't even want to have.
(e.g. to allow coloring of the signs with dyes)
2020-10-31 20:59:15 +01:00
Phoenix616
f0bf9a08ec
Add message to access and creative mode ignoring 2020-10-31 20:59:07 +01:00
Brice Frisco
8d98958c2d
Stock Counter (Resolves #365) (#368) 2020-10-30 22:45:16 +01:00
Phoenix616
493784c2dd
Fix that the legacy locale is not automatically used 2020-07-03 17:15:36 +01:00
Phoenix616
a0630db6f8
Fix typo in iteminfo book generation message key 2020-06-28 18:09:00 +01:00
Phoenix616
6ee7c4759a
Add multi-language and component message support (Requires Spigot)
Message configs are now selected based on the client's language (can be
 toggled in the config) and will use MineDown formatting to allow
 display of component messages as well as usage of RGB colors in 1.16.
If found the legacy local.yml will be used instead of the per-language
 files. Move your local.yml to the correct lang config to if you want to
 use the per-client language option.
Version was also changed to 3.11 due to the many internal changes that
 have accumulated over time
2020-06-28 18:00:09 +01:00
Phoenix616
183c724583 Improve Metrics and add /csmetrics command
This adds some more logging to the metrics for some interesting plugin
 settings as well as player account and transaction counts. This data
 about account count and average transaction and item counts is also
 exposed ingame via the /csmetrics command.

This also removes the outdated mcstats metrics as that site is long dead
 now, the last data is from two years ago...
2020-06-19 21:47:28 +01:00
Phoenix616
7161c0bfdf Add Jenkins test build notifier
This will only send a notification into the log once for each new build
 and can be disabled in the config or the new jenkinsBuildNotifier.yml
2020-06-18 21:19:35 +01:00
Phoenix616
d3f717deef Do not enabled automatic updates by default without user interaction 2020-06-18 18:14:53 +01:00
Phoenix616
3e061dda8d Add config option to limit trading with shops via protections 2020-06-18 17:01:52 +01:00
Phoenix616
9f84ca8551 Add option to sell/buy all with shift (#320) 2020-05-31 14:50:53 +01:00
Phoenix616
0c1b82c9d8 Fix /iteminfo coloring 2020-05-04 21:40:39 +01:00
Phoenix616
432c505806 Add more information to /iteminfo command and make messages configurable 2020-05-03 15:05:24 +01:00
Phoenix616
8c83be59ba Option to block shop creation when LWC limit is reached (Resolves #293) 2020-05-02 15:57:42 +01:00
Phoenix616
744b02a447 Add ability to configure server economy account UUID
This adds better support for fake server economy accounts by not
requiring that a player with the name already has an account but allow
automatic creation of the account with the fake UUID provided in the
config.

Old configs that only define the name will still work though.
2020-04-27 21:00:46 +01:00
Phoenix616
781e017ae9 Add debug logging for configuration loading 2020-04-17 15:10:27 +01:00
Phoenix616
bb17cc35a0 Add ability to set max amount and improve error messages 2020-03-24 00:31:08 +01:00
Phoenix616
9d6c2f8c1b Improve LWC shop protection messages 2020-02-15 18:20:55 +01:00
Phoenix616
2a37304113 Specify locale when changing case (Fixes #291) 2020-01-29 16:35:04 +01:00
Phoenix616
bd8f2dfc19 Add RedProtect support 2020-01-15 23:44:34 +01:00
Phoenix616
3d83bfdddd Add GriefPrevention support (Resolves #227)
Also slightly cleanup dependency logic loading to not have per-plugin
code in Dependencies class
2020-01-15 23:40:42 +01:00
Phoenix616
4067427650 Add ability to define type of LWC protection in config 2020-01-15 22:55:40 +01:00
Phoenix616
2075693e12 Add ability to send shop owner notifications via BungeeCord 2019-11-19 21:50:17 +01:00
Phoenix616
35dd13f917 Slightly change access_denied message to indicate container access error
This is necessary as the no_permission error was worded exactly the same making debugging more difficulty. Also this way someone who thinks he needs to access the chest doesn't think that he doesn't have access to the shop at all.
2019-11-04 17:26:22 +01:00
g--o
88a23a38db Added toggle access command (#271)
Thanks to @g--o and @JRoy
2019-09-16 12:56:30 +01:00
Phoenix616
b0523b2199 Add cooldown for empty/full shop owner notifications 2019-05-27 17:11:09 +01:00
Phoenix616
4769ae2cf7 Allow loading of different numbers to BigDecimal (Fixes #225)
Also catch wrong types when loading the config better without completely disabling the plugin and revert "Make sure special parsers are setup" and register the parsers static again.
2019-05-03 21:08:56 +01:00
Phoenix616
da1dd94705 Make sure special parsers are setup (Might prevent #225)
There might have been a case where when trying to pair the yml file with the Properties class the parsers weren't actually registered yet as nothing was called on the Properties file yet.
2019-05-02 18:35:45 +01:00
Phoenix616
f0bc277566 Move to BigDecimal in all events and use the CurrencyTransferEvent
Also add tax bypass permissions (#204, ChestShop.notax.buy/sell). When buying with that permission the buyer does not have to pay the tax (the seller will still get the reduced amount), when selling the seller will get the full amount instead of one lowered by the tax.
The permissions of the shop owner play no role due to there not being a good way of checking offline player permissions and it being a bit non-obvious for the buying/selling player if a shop would be with or without tax. This way all that gets changed is the amount the player pays/receives and not the shop owner (and the player should know their permissions/rank already)

The transfer event was necessary in order to correctly resolve who triggered the transaction. Economy adapters are now required to implement a listener for each of the events. It's also recommended that economy adapters that support transfers directly use that instead of passing it through subtract and add with the processTransfer method.
2019-04-25 18:44:22 +01:00
Phoenix616
be5f47cb1f Add config option to toggle if all shop removals should be logged
Removals that happened due to no player being present will always be logged
2019-04-01 13:49:48 +01:00
Phoenix616
20228dd645 Fix amount in price restriction not working correctly
Also fix copy and paste error in SELL_PRICE_BELOW_MIN error message.
2019-01-18 22:27:40 +01:00
Phoenix616
c8d0590614 Add different error messages when price limits are exceeded (#193) 2019-01-17 18:08:54 +01:00
Phoenix616
b853afbd52 Fix issues with the permissions for using different player names
This adds separate permissions for accessing, creating and destroying of shops.
It also adds a config entry to allow using of a shop even if someone have access to it due to their permissions.
2018-11-19 21:10:48 +01:00
Phoenix616
7adf02e532 Improve hopper protection
The InventoryMoveItemEvent is now only used for Hopper Minecarts, other blocks that could move items (Hoppers and Droppers) are checked on place. That way players that have access to a shop can just use the blocks normally but other players can't place them.
2018-10-23 19:27:39 +01:00
Phoenix616
fe85dafec5 Allow configuring what containers can be used for shops (Fixes #175) 2018-10-23 19:14:21 +01:00
Phoenix616
afab90d021 Fix wording in of incorrect item id message 2018-09-09 13:24:26 +01:00
Phoenix616
df76347697 Improve sign price corrections
This includes a new price_precision config entry to set the amount of decimal places to allow on a shop sign (set to 2 by default). Thanks to @andrewkm for this idea.
It also fixes an issue where a zero inside the decimal places was removed instead of it's end and also removes the point and zeros from prices that only have trailing zeros to avoid confusion (e.g. in languages that use the decimal point for thousands)
2018-09-05 23:07:35 +01:00
Phoenix616
836ef56864 Add more message placeholders (Fixes #159) 2018-08-23 22:10:24 +01:00
Phoenix616
036d309965 [CI-SKIP] Fix some formatting inconsistencies
Remove spaces on empty lines and changed doc comment formatting
Also includes some minor comments and import fixes
2018-05-07 15:32:51 +01:00
Phoenix616
b3e62f199f Add option to set the worlds where shops should be removed (Fixes #129)
This also adds the ability to set string lists in the config.
2018-05-05 16:23:30 +01:00
Phoenix616
6e9824e6b0 Add better item name shortening. (Fixes #112) 2018-03-12 21:01:28 +01:00
Tim222
21815197c6 Fix Vault-Accountcheck for renamed player (#106) 2018-01-27 17:12:34 +01:00
Phoenix616
b2a31b8eb2 Add ability to autofill sign by clicking it
Also disable the worldguard shop flag by default...
2018-01-07 02:11:59 +01:00
Phoenix616
ac73442643 Added ability to show item icons and hover info with ShowItem 2018-01-06 17:44:35 +01:00
Phoenix616
b23a0d238e Allow partial transactions due to missing inventory space (Fixes #88) 2018-01-05 18:30:06 +01:00
Phoenix616
d332603fb4 Do not automatically color config strings (Fixes BUKKIT-1241)
This is necessary so that we still store the messages with the & code internally as they would get saved back to the config file using the converted color code (section sign) which could lead to encoding issues on different operating systems. (It also fixes issues with strings that contain an and sign that isn't supposed to be a color code) Instead we load the real string and color messages via the prefix method which should get called in every instance where a message is send.
2017-11-13 15:11:22 +01:00
Phoenix616
0413f24e64 Fix error in config comment 2017-08-06 11:40:02 +01:00
Phoenix616
4120455974 Strings already get colored by the Breeze library 2017-07-05 23:51:49 +01:00
Phoenix616
0dea862cd0 Add full shop message, location and respect cstoggle
Inspired by @Brokkonaut's fork this adds a new NOT_ENOUGH_SPACE_IN_YOUR_SHOP message to send to the shop owner when someone tries to sell to his shop. It also adds new %world, %x, %y and %z variables to display the shop's location in the message, adds a config option to make both the full-shop and out-of-stock messages respect /cstoggle and makes values in the locale.yml support ampersand color codes.
2017-07-04 16:06:34 +01:00
Phoenix616
0b65a7cc92 Rewrite (and document) the NameManager
This should fix issues with how name changes are handled and also prevent short names of different players from clashing. It also uses guava caches instead of maps now with a configurable cache size
2017-06-30 20:28:18 +01:00