Open PeachesMLG opened 5 months ago
Bit of extra info, we call this method here:
@Override
public List<Placeholder> getPlaceholders(Optional<Island> optional) {
return optional.isPresent() ? getPlaceholders(optional.get()) : defaultPlaceholders;
}
Which then calls two different methods, one with an Island, and the other for if there is no island present. Which means we have two lists to maintain, and these two lists have differences in them now which is the issue.
So if you have a PAPI plugin (e.g. a scoreboard) a placeholder e.g. island_enhancement_size_level
would work if I have an island, however if I dont have an island, instead of showing N/A
it wont process anything and will stay as %iridiumskyblock_island_enhancement_size_level
(Also, make sure there are no duplicated Placeholders in this list, e.g. island_visitors, also extra bonus brownie points for how we can prevent this, again maybe unit tests?)
i want to add the command "/is go" to my server, if it type the command it should go to the island, if the island doesn't exist then the island should be created
Can you help me
1) this is not related to the current issue 2) if you need help, join our discord server and head to #skyblock, we can help you there 3) if you do not want to use discord, create a NEW issue and follow the issue guidelines
The Placeholders between when you have an island, and dont have an island is different
https://github.com/Iridium-Development/IridiumSkyblock/blob/master/src/main/java/com/iridium/iridiumskyblock/placeholders/IslandPlaceholderBuilder.java
Extra bonus points if we can think about how to stop this in the future, add some unit tests? recode it somehow?