SnYpEr® Posted May 22, 2012 Posted May 22, 2012 getActiveChar().getInventory().addItem("test", 7575, 1, activeChar, null); //here adds the weapon to char. getActiveChar().getInventory().equipitem(7575); //this equip the weapon "7575" ID to weapon! what's the mode of making the weapon equip themselves automatically after the weapon added to the inventory ???????
0 ^Wyatt Posted May 22, 2012 Posted May 22, 2012 I dunno if u mean that: player.getInventory().equipItem(ItemTable.getInstance().createItem("", ITEM_ID, 1, player, null));
0 Bleadd Posted May 22, 2012 Posted May 22, 2012 i think he wants, like demonic weapon, that when the player pick up (or get via admin give or something like that), the player is forced to equip this item.
0 SnYpEr® Posted May 22, 2012 Author Posted May 22, 2012 I dunno if u mean that: player.getInventory().equipItem(ItemTable.getInstance().createItem("", ITEM_ID, 1, player, null)); Thanks man, that was it I was looking for. :D :D :D :D :D :D :D
0 Fanky Posted May 22, 2012 Posted May 22, 2012 Thanks man, that was it I was looking for. :D :D :D :D :D :D :D locked.
Question
SnYpEr®
getActiveChar().getInventory().addItem("test", 7575, 1, activeChar, null); //here adds the weapon to char.
getActiveChar().getInventory().equipitem(7575); //this equip the weapon "7575" ID to weapon!
what's the mode of making the weapon equip themselves automatically
after the weapon added to the inventory ???????
5 answers to this question
Recommended Posts