Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -220,15 +220,15 @@ public void openStation(PlayerInteractEvent e) {
StationFeedback f = station.addMaterial(p, i);
switch (f) {
case NOT_INGREDIENT:
p.sendMessage("§cThis item cannot be used for crafting");
p.sendMessage("§cThat is not a material you can work");
p.playSound(p.getLocation(), Sound.ENTITY_VILLAGER_NO, 1f, 1f);
break;
case WRONG_TYPE:
p.sendMessage("§cThis item type is not needed for the recipe");
p.sendMessage("§cThis recipe does not call for that material");
p.playSound(p.getLocation(), Sound.ENTITY_VILLAGER_NO, 1f, 1f);
break;
case CAPACITY:
p.sendMessage("§cYou already have the needed amount of this type");
p.sendMessage("§cThe piece already has enough of that material");
p.playSound(p.getLocation(), Sound.BLOCK_NOTE_BLOCK_BASS, 1f, 0.5f);
break;
case NO_PERMS:
Expand Down Expand Up @@ -354,7 +354,7 @@ public void applyHit(PlayerInteractEvent e) {
p.playSound(p.getLocation(), Sound.ENTITY_VILLAGER_NO, 1f, 1f);
break;
case WRONG_TYPE:
p.sendMessage("§cThis item cannot be used for crafting hits");
p.sendMessage("§cYou cannot work the piece with that tool");
p.playSound(p.getLocation(), Sound.ENTITY_VILLAGER_NO, 1f, 1f);
break;
case NONE:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,14 +123,14 @@ public static int resolveAlloyTier(String alloyId) {
}

public static String missingIngredientPermissionMessage(String permissionKey) {
return "§cYou need the " + getDisplayName(permissionKey) + " permission to use this material.";
return "§cYou are not skilled enough in " + getDisplayName(permissionKey) + " to work this material.";
}

public static String missingNamespaceMessage(String namespace) {
return "§cYou need at least one of the " + getDisplayName(namespace) + " permissions.";
return "§cYou are not skilled enough in " + getDisplayName(namespace) + " to make this.";
}

public static String missingExactTierMessage(String namespace, int tier) {
return "§cYou need the " + getDisplayName(namespace) + " tier " + tier + " permission to use this material.";
return "§cYour " + getDisplayName(namespace) + " training does not extend to tier " + tier + " materials.";
}
}
8 changes: 4 additions & 4 deletions src/main/resources/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,11 @@ permission-namespaces:
ingredient:
display: "#e6a817Ingredient"
iron_smith:
display: "#e6a817Iron_Smith"
display: "#e6a817Iron Smithing"
Comment thread
coderabbitai[bot] marked this conversation as resolved.
steel_smith:
display: "#e6a817Steel_Smith"
display: "#e6a817Steel Smithing"
abyssalite_smith:
display: "#e6a817Abyssalite_Smith"
display: "#e6a817Abyssalite Smithing"
mythril_smith:
display: "#e6a817Mythril_Smith"
display: "#e6a817Mythril Smithing"

Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ void interactionValidatesStructureMaterialPermissionsCapacityAndCooldown() throw
assertFalse(m.hasStation(b.getLocation()));
clearCooldown(m);
m.addIngredient(event(p, b));
assertTrue(p.nextMessage().contains("permission"));
assertTrue(p.nextMessage().contains("not skilled enough"));
p.setOp(true);
clearCooldown(m);
p.getInventory().setItemInMainHand(base.build());
Expand Down
Loading