OldHero 12 Report post Posted February 8, 2017 (edited) Hello guys i install extract func from lucky arhive and i have weird prob i put gemed ring in 4rd slot and when i click extract i get this bug can help me to solve ??? Edited February 8, 2017 by OldHero Quote Share this post Link to post Share on other sites
OldHero 12 Report post Posted February 9, 2017 Bump?? Quote Share this post Link to post Share on other sites
Ximboliex 85 Report post Posted February 9, 2017 Show your scripts so they can help you in the forum! Quote Share this post Link to post Share on other sites
OldHero 12 Report post Posted February 9, 2017 Hello this is script this in function function CheckEquipHasGem(role) local Item_CanGet = GetChaFreeBagGridNum(role) if Item_CanGet < 1 then SystemNotice(role,"You need at least 1 slot in your inventory") UseItemFailed(role) return 0 end local MainEquip = GetChaItem ( role , 2 , 3 ) local Item_Stone = {} local Item_StoneLv = {} local Param = GetItemForgeParam ( MainEquip , 1 ) Param = TansferNum ( Param ) Item_Stone[0] = GetNum_Part2 ( Param ) Item_Stone[1] = GetNum_Part4 ( Param ) Item_Stone[2] = GetNum_Part6 ( Param ) Item_StoneLv[0] = GetNum_Part3 ( Param ) Item_StoneLv[1] = GetNum_Part5 ( Param ) Item_StoneLv[2] = GetNum_Part7 ( Param ) local ItemType = CheckItem_CanJinglian(Item_mainitem) if MainEquip == nil then HelpInfo(role,0,"You must put a equipment on your 4th Inventory Slot.") return 0 end if ItemType == 0 then HelpInfo(role,0,"Item type mismatch.") return 0 end if Item_Stone[0] == 0 and Item_Stone[1] == 0 and Item_Stone[2] == 0 then HelpInfo(role,0,"Your equipment is not forged with gem.") return 0 end return 1 end function GiveGemExtracted(role) if CheckEquipHasGem(role) == 0 then return end local MainEquip = GetChaItem ( role , 2 , 3 ) local Num = GetItemForgeParam ( MainEquip , 1 ) Num = TansferNum ( Num ) local lg_Num = Num local Item_Stone = {} local Item_StoneLv = {} local Item_StoneID = {} Item_Stone[0] = GetNum_Part2 ( Num ) Item_Stone[1] = GetNum_Part4 ( Num ) Item_Stone[2] = GetNum_Part6 ( Num ) Item_StoneLv[0] = GetNum_Part3 ( Num ) Item_StoneLv[1] = GetNum_Part5 ( Num ) Item_StoneLv[2] = GetNum_Part7 ( Num ) Item_StoneID[0] = StoneTpye_ID[Item_Stone[0]] Item_StoneID[1] = StoneTpye_ID[Item_Stone[1]] Item_StoneID[2] = StoneTpye_ID[Item_Stone[2]] local r1 = 0 local r2 = 0 local Item_Lv = 0 local item_tureID = 0 if Item_StoneID[0] ~= 0 then item_tureID = Item_StoneID[0] Item_Lv = Item_StoneLv[0] Item_StoneLv[0] = Item_StoneLv[0]-1 if Item_StoneLv[0] == 0 then Item_Stone[0] = 0 end elseif Item_StoneID[0] == 0 and Item_StoneID[1] ~= 0 then item_tureID = Item_StoneID[1] Item_Lv = Item_StoneLv[1] Item_StoneLv[1] = Item_StoneLv[1]-1 if Item_StoneLv[1] == 0 then Item_Stone[1] = 0 end elseif Item_StoneID[0] == 0 and Item_StoneID[1] == 0 and Item_StoneID[2] ~= 0 then item_tureID = Item_StoneID[2] Item_Lv = Item_StoneLv[2] Item_StoneLv[2] = Item_StoneLv[2]-1 if Item_StoneLv[2] == 0 then Item_Stone[2] = 0 end else HelpInfo(role,0,"Gem extraction ID error") return end r1,r2 = MakeItem ( role , item_tureID , 1 , 2 ) local Item_ture = GetChaItem ( role , 2 , r2 ) SetItemAttr ( Item_ture , ITEMATTR_VAL_BaoshiLV , Item_Lv ) Num = SetNum_Part2 ( Num , Item_Stone[0] ) Num = SetNum_Part3 ( Num , Item_StoneLv[0] ) Num = SetNum_Part4 ( Num , Item_Stone[1] ) Num = SetNum_Part5 ( Num , Item_StoneLv[1] ) Num = SetNum_Part6 ( Num , Item_Stone[2] ) Num = SetNum_Part7 ( Num , Item_StoneLv[2] ) SetItemForgeParam ( MainEquip , 1 , Num ) local cha_name = GetChaDefaultName ( role ) LG( "Extract Gem Sucessfull" ,cha_name, item_tureID , Item_Lv , lg_Num , Num ) RefreshCha(role) end and In npc sdk i added this elseif item.func == GiveGemExtracted then return GiveGemExtracted(character) hmm? Quote Share this post Link to post Share on other sites
Sultan 68 Report post Posted February 10, 2017 Change local ItemType = CheckItem_CanJinglian(Item_mainitem) To local ItemType = CheckItem_CanJinglian(MainEquip) 1 Quote Share this post Link to post Share on other sites
MonkeyCode 453 Report post Posted February 10, 2017 Hello. There is a better method that requires 2 byte to be changed at client side, then it can be extracted with the native ui. Also the lua in variable.lua Quote Share this post Link to post Share on other sites
OldHero 12 Report post Posted February 10, 2017 @Sultan ty you bro !! Quote Share this post Link to post Share on other sites
Angelix 374 Report post Posted February 10, 2017 3 hours ago, KONG said: Hello. There is a better method that requires 2 byte to be changed at client side, then it can be extracted with the native ui. Also the lua in variable.lua And you were completely ignored, hahah. Mind sharing a guide on how to do that? 3 Quote Share this post Link to post Share on other sites
Vasil 71 Report post Posted February 10, 2017 3 hours ago, Angelix said: And you were completely ignored, hahah. Mind sharing a guide on how to do that? Yeah,if you don't mind. Quote Share this post Link to post Share on other sites
Wrexor 61 Report post Posted February 10, 2017 @Angelix @Vasil Open game.exe with hex editor and go to address 0x78FD0. You should see 01 01, change to 00 00 to enable for rings and necklaces. 3 Quote Share this post Link to post Share on other sites
Ximboliex 85 Report post Posted February 10, 2017 34 minutes ago, Wrexor said: @Angelix @Vasil Open game.exe with hex editor and go to address 0x78FD0. You should see 01 01, change to 00 00 to enable for rings and necklaces. For pko 2.4? Quote Share this post Link to post Share on other sites
Wrexor 61 Report post Posted February 10, 2017 2 minutes ago, Ximboliex said: For pko 2.4? For 2.4 try at address A0224 2 Quote Share this post Link to post Share on other sites