Added some JSON, much more to come.

This commit is contained in:
nossr50
2019-01-02 08:06:18 -08:00
parent 336e41b40c
commit ebec5d6f70
31 changed files with 473 additions and 278 deletions

View File

@@ -4,10 +4,9 @@ import java.util.ArrayList;
import java.util.List;
import com.gmail.nossr50.datatypes.skills.PrimarySkill;
import com.gmail.nossr50.datatypes.skills.SkillMilestone;
import com.gmail.nossr50.datatypes.skills.SubSkill;
import com.gmail.nossr50.util.player.UserManager;
import com.gmail.nossr50.util.skills.SkillMilestoneFactory;
import com.gmail.nossr50.util.SkillTextComponentFactory;
import net.md_5.bungee.api.chat.TextComponent;
import org.bukkit.entity.Player;
import com.gmail.nossr50.config.AdvancedConfig;
@@ -125,4 +124,35 @@ public class WoodcuttingCommand extends SkillCommand {
return messages;
}
@Override
protected List<TextComponent> getTextComponents(Player player) {
List<TextComponent> textComponents = new ArrayList<>();
if (canTreeFell) {
textComponents.add(SkillTextComponentFactory.getSubSkillTextComponent(player, SubSkill.WOODCUTTING_TREE_FELLER, 0, 1));
}
if (canLeafBlow) {
textComponents.add(SkillTextComponentFactory.getSubSkillTextComponent(player, SubSkill.WOODCUTTING_LEAF_BLOWER, 2, 3));
}
if (canDoubleDrop) {
textComponents.add(SkillTextComponentFactory.getSubSkillTextComponent(player, SubSkill.WOODCUTTING_HARVEST_LUMBER, 4, 5));
}
if (canSplinter) {
textComponents.add(SkillTextComponentFactory.getSubSkillTextComponent(player, SubSkill.WOODCUTTING_SPLINTER, 6, 7));
}
if(canBarkSurgeon) {
textComponents.add(SkillTextComponentFactory.getSubSkillTextComponent(player, SubSkill.WOODCUTTING_BARK_SURGEON, 8, 9));
}
if(canNaturesBounty) {
textComponents.add(SkillTextComponentFactory.getSubSkillTextComponent(player, SubSkill.WOODCUTTING_NATURES_BOUNTY, 10, 11));
}
return textComponents;
}
}