매입상점 인첸무기 매입하게! 해주는 소스(펌)
l1샵
private void sellPremiumItems(L1PcInventory inv, L1ShopBuyOrderList orderList) {<--검색아래껄로통으로교환
//////////////////////////////////////////////////////////////
private void sellPremiumItems(L1PcInventory inv, L1ShopBuyOrderList orderList) {
if (!inv.consumeItem(41159, orderList.getTotalPrice())) {
throw new IllegalStateException("구입에 필요한 신비한 깃털을 소비할 수 없었습니다.");
}
L1ItemInstance item = null;
for (L1ShopBuyOrder order : orderList.getList()) {
int itemId = order.getItem().getItemId();
int amount = order.getCount();
int enchant = order.getItem().getEnchant();/////////<추가
item = ItemTable.getInstance().createItem(itemId);
item.setCount(amount);
item.setEnchantLevel(enchant);/////////////<추가
item.setIdentified(true);
inv.storeItem(item);
}
}
//////////////////////////////////////////////////////////////////교환
s_플레티넘샵셀
for (int i = 0; i < shopItems.size(); i++) {
shopItem = shopItems.get(i);
item = shopItem.getItem(); <검색
////////////////////////////////////////////////////////
for (int i = 0; i < shopItems.size(); i++) {
shopItem = shopItems.get(i);
item = shopItem.getItem();
dummy.setItem(item);/////////////
int price = shopItem.getPrice();
writeD(i);
writeH(shopItem.getItem().getGfxId());
writeD(price);
////////////////////////////////////////////////////////
if(shopItem.getEnchant() > 0 && shopItem.getPackCount() > 1){
writeS(("+"+shopItem.getEnchant()+" "+ dummy.getName()) + " (" + shopItem.getPackCount() + ")");
}else if(shopItem.getEnchant() > 0){
writeS("+"+shopItem.getEnchant()+" "+ dummy.getName());
}else if (shopItem.getPackCount() > 1) {
writeS(dummy.getName() + " (" + shopItem.getPackCount() + ")");
}else
writeS(dummy.getName());
////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////교환
샵테이블
private L1Shop loadShop(int npcId, ResultSet rs) throws SQLException {
List<L1ShopItem> sellingList = new ArrayList<L1ShopItem>();
List<L1ShopItem> purchasingList = new ArrayList<L1ShopItem>();
L1ShopItem item = null;
while (rs.next()) {
int itemId = rs.getInt("item_id");
int sellingPrice = rs.getInt("selling_price");
int purchasingPrice = rs.getInt("purchasing_price");
int packCount = rs.getInt("pack_count"); <검색
private L1Shop loadShop(int npcId, ResultSet rs) throws SQLException {
List<L1ShopItem> sellingList = new ArrayList<L1ShopItem>();
List<L1ShopItem> purchasingList = new ArrayList<L1ShopItem>();
L1ShopItem item = null;
while (rs.next()) {
int itemId = rs.getInt("item_id");
int sellingPrice = rs.getInt("selling_price");
int purchasingPrice = rs.getInt("purchasing_price");
int packCount = rs.getInt("pack_count");
int enchant = rs.getInt("enchant");/////
packCount = packCount == 0 ? 1 : packCount;
if (0 <= sellingPrice) {
// item = new L1ShopItem(itemId, purchasingPrice, packCount, 0);
item = new L1ShopItem(itemId, sellingPrice, packCount, enchant);//////
sellingList.add(item);
}
if (0 <= purchasingPrice) {
// item = new L1ShopItem(itemId, purchasingPrice, packCount, 0);
item = new L1ShopItem(itemId, sellingPrice, packCount, enchant);//////
purchasingList.add(item);
}
}
return new L1Shop(npcId, sellingList, purchasingList);
}
//////////////////////////////////교환
굳이교환안하고 추가된부분만 넣어주셔도되구요 다표시되어있으니 초보분들위해서 교환하시라고다올린거
그후에
나비켓에서
shop와 npc_shop여신후
npc_shop = 무인상점
shop = 일반상점
npc_shop에서 테이블설계누르셔서 인챈트부분 테이블복사하신후
shop에서 테이블설계눌러서 테이블추가누른후
붙여넣기하시면 테이블 설계끝

주일요 님의 최근 댓글
감사합니다 2024 04.12 감사합니다 2024 04.12 감사합니다 2024 04.12 감사합니다 2024 04.12 감사합니다 2024 04.12