erikzimmermann / TradeSystem

A highly customizable, free and open-source Minecraft plugin for trading between players.
https://www.spigotmc.org/resources/trade-system-custom-layouts.58434/
MIT License
77 stars 47 forks source link

Placeholders should return empty string #412

Closed nhanledev closed 1 year ago

nhanledev commented 1 year ago

Is your feature request related to a problem? Please describe. When using with a conditional formatter, it is hard to compare the output of the placeholders because they are returned as %trade_%.

Describe the solution you'd like It should return "" (an empty string) or a string that can be defined in the config as our like.

Describe alternatives you've considered Instead of just break the case in tradesystem's placeholder logic, return something instead.

Additional context I am trying to check if player is in a trade or not using Conditional Text Placeholder and %tradesystem_trade_partner%. It is impossible to compare that placeholder as the plugin support using placeholder inside the logic, and %tradesystem_trade_partner% always return %tradesystem_trade_partner% (yes, in full text) so it causes a loop.

Discord contact: #