Commit Graph

13 Commits

Author SHA1 Message Date
Phoenix616
17bd2a1fcb
Fix issues with spaces in shortened item names 2023-08-27 16:29:06 +01:00
Phoenix616
ed642ccf3c
Compile against 1.20.1 and fix some short name issues
Partially helps with #516, #521, #549
2023-06-15 00:28:47 +01:00
Phoenix616
99a609b423
Unify sign line parsing and strip owner line whitespace 2022-01-26 20:35:42 +01:00
Phoenix616
f044938b80 0 is a legal price now, reflect that in the tests 2020-05-06 22:00:15 +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
54b3b6966c Merge branch '1.12' into 1.13
# Conflicts:
#	src/main/java/com/Acrobot/Breeze/Utils/MaterialUtil.java
#	src/test/java/com/Acrobot/Breeze/Tests/MaterialTest.java
2018-09-09 14:47:32 +01:00
Phoenix616
516eefc5b6 Allow longer item names on signs by calculating the width
This uses hardcoded widths for the main characters used in Minecraft and might not be precise for some characters but better than the previous 15 char hard limit.
2018-09-09 14:37:09 +01:00
Phoenix616
d4e39a3751 Make it compile with 1.13. No guarantees that it works without issues! 2018-07-26 00:13:06 +01:00
Phoenix616
d04e17450b Make material name shortening testable and move test to proper package 2018-03-14 15:07:13 +01:00
Andrzej Pomirski
416e15a96c Add new tests to price checking 2015-07-12 19:19:12 +02:00
Andrzej Pomirski
20e686f3b8 Add a price test 2015-03-17 11:36:37 +01:00
Andrzej Pomirski
467cd34316 Add a test for price checking 2014-03-12 13:07:34 +01:00
Acrobot
143b7a49af Add a first test case 2013-11-01 16:20:36 +01:00