davidpaceway
May 22nd, 2011, 19:25
Only posting cause I saw nothing else on it. Its really simple :p
Okay to start open Trade.java
Under
public class Trade {
Put
static final int[] UNTRADEABLE = {};//your items in that blank
public enum State {
Under (the second one)
Item item = player1.getInventory().getContainer().get(slot);
if(item != null) {
Put
for (int i : UNTRADEABLE) {
if(item.getId() == i) {
player.sm("You can't trade this item.");
return;
}
}
Under (the second one..)
Item item = player2.getInventory().getContainer().get(slot);
if(item != null) {
Put
for(int i : UNTRADEABLE) {
if(item.getId() == i) {
player.sm("You can't trade this item!");
return;
}
}
Credits..
50% me
50% to Wisdom
Okay to start open Trade.java
Under
public class Trade {
Put
static final int[] UNTRADEABLE = {};//your items in that blank
public enum State {
Under (the second one)
Item item = player1.getInventory().getContainer().get(slot);
if(item != null) {
Put
for (int i : UNTRADEABLE) {
if(item.getId() == i) {
player.sm("You can't trade this item.");
return;
}
}
Under (the second one..)
Item item = player2.getInventory().getContainer().get(slot);
if(item != null) {
Put
for(int i : UNTRADEABLE) {
if(item.getId() == i) {
player.sm("You can't trade this item!");
return;
}
}
Credits..
50% me
50% to Wisdom