-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathVoidOpalTrade.java
49 lines (38 loc) · 1.25 KB
/
VoidOpalTrade.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*******************************************************************************
* @author Reika Kalseki
*
* Copyright 2017
*
* All rights reserved.
* Distribution of the software in any form is only allowed with
* explicit, prior permission from the owner.
******************************************************************************/
package Reika.GeoStrata;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Items;
import net.minecraft.item.ItemStack;
import net.minecraft.village.MerchantRecipe;
import Reika.DragonAPI.Interfaces.PlayerSpecificTrade;
import Reika.GeoStrata.Registry.GeoBlocks;
public class VoidOpalTrade extends MerchantRecipe implements PlayerSpecificTrade {
public static final int STACK_SIZE = 24; //was 16
public VoidOpalTrade() {
super(new ItemStack(GeoBlocks.VOIDOPAL.getBlockInstance(), STACK_SIZE), new ItemStack(Items.emerald, 3, 0));
}
@Override
public void incrementToolUses() {
//No-op to prevent expiry
}
@Override
public boolean isValid(EntityPlayer ep) {
return true;
}
@Override
public boolean hasSameIDsAs(MerchantRecipe mr) {
return mr instanceof VoidOpalTrade;
}
@Override
public boolean hasSameItemsAs(MerchantRecipe mr) {
return mr instanceof VoidOpalTrade;
}
}