mirror of
https://github.com/Zrips/Jobs.git
synced 2025-02-01 04:51:26 +01:00
Fixed milking quests and Dye action not working correctly (#762)
- Added leather_horse_armor as a dyeable material.
This commit is contained in:
parent
4198a28967
commit
bedd3e5d97
@ -237,12 +237,19 @@ public class JobsPaymentListener implements Listener {
|
||||
break t;
|
||||
}
|
||||
}
|
||||
for (Quest q : prog.getJob().getQuests()) {
|
||||
if (q != null && q.hasAction(ActionType.MILK)) {
|
||||
found = true;
|
||||
break t;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!found) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if (Jobs.getGCManager().CowMilkingTimer > 0) {
|
||||
if (cow.hasMetadata(CowMetadata)) {
|
||||
long time = cow.getMetadata(CowMetadata).get(0).asLong();
|
||||
@ -634,6 +641,7 @@ public class JobsPaymentListener implements Listener {
|
||||
case LEATHER_CHESTPLATE:
|
||||
case LEATHER_HELMET:
|
||||
case LEATHER_LEGGINGS:
|
||||
case LEATHER_HORSE_ARMOR:
|
||||
leather = true;
|
||||
break;
|
||||
default:
|
||||
@ -654,7 +662,7 @@ public class JobsPaymentListener implements Listener {
|
||||
|
||||
// Check Dyes
|
||||
if (y >= 2) {
|
||||
if ((third != null && third.isDye() || second != null && second.isDye()) && leather) {
|
||||
if ((third != null && third.isDye() || second != null && second.isDye() || first != null && first.isDye()) && leather) {
|
||||
Jobs.action(jPlayer, new ItemActionInfo(sourceItems[0], ActionType.DYE));
|
||||
for (ItemStack OneDye : DyeStack) {
|
||||
Jobs.action(jPlayer, new ItemActionInfo(OneDye, ActionType.DYE));
|
||||
|
Loading…
Reference in New Issue
Block a user