Jump to content

Angel

Members
  • Posts

    85
  • Joined

  • Last visited

Everything posted by Angel

  1. Angel

    Custom cash shop

    yup, i solve the problem yesterday checking the changeset, i forgot post the solution Fixed almost i think so ... npc_cashshop_buylis was aggregated in (Changeset 15137) its some type of revalidation i think. I add the mod by @Ind in this part and now delete the item in players inventory ( Item Currency ). i hope that at someone help Thank [member=In d] for your awesome mod ;D Index: src/map/npc.c =================================================================== --- src/map/npc.c (revision 17053) +++ src/map/npc.c (working copy) @@ -1322,11 +1322,97 @@ if( points > vt ) points = vt; // Payment Process ---------------------------------------------------- + + if( stristr(nd->name,"ITMCur") ) {//Item Currency + int count=0,ind=0,c = 0, cid = pc_readreg(sd,add_str("@RRITMCur")); + for(c = 0; c < MAX_INVENTORY; c++) + if(sd->status.inventory[c].nameid == cid ) + count += sd->status.inventory[c].amount; + if( count != pc_readaccountreg( sd, "#CASHPOINTS" ) ) + return 6; + ind = pc_search_inventory(sd, cid); + if( ind < 0 )//because checking twice is safer... + return 6; + sd->cashPoints = count; + if( sd->cashPoints < vt ) + return 6; + if( pc_delitem(sd, ind, vt, 0, 0, LOG_TYPE_NPC) )//somehow it failed to delete... + return 6; + + sd->cashPoints -= vt; + if( !pet_create_egg(sd, nameid) ) + { + struct item item_tmp; + memset(&item_tmp, 0, sizeof(struct item)); + item_tmp.nameid = nameid; + item_tmp.identify = 1; + + + pc_additem(sd,&item_tmp, amount, LOG_TYPE_NPC); + + } + if(log_config.enable_logs&0x20) + log_pick_pc(sd, LOG_TYPE_SCRIPT, amount, NULL); + pc_setaccountreg(sd,"#CASHPOINTS",sd->cashPoints);//update shop~ + return 0; + } + + if( stristr(nd->name,"CharCur") ) {//Char Reg Currency (from set REGNAME,1;) + const char* charReg = pc_readregstr(sd,add_str("@CharCurrrency$")); + int count = pc_readglobalreg(sd,charReg); + if( count != pc_readaccountreg( sd, "#CASHPOINTS" ) )//safecheck + return 6; + sd->cashPoints = count; + if( sd->cashPoints < vt ) + return 6; + sd->cashPoints -= vt; + pc_setglobalreg(sd,charReg,sd->cashPoints);//update... + if( !pet_create_egg(sd, nameid) )//give item... + { + struct item item_tmp; + memset(&item_tmp, 0, sizeof(struct item)); + item_tmp.nameid = nameid; + item_tmp.identify = 1; + + pc_additem(sd,&item_tmp, amount, LOG_TYPE_NPC); + } + if(log_config.enable_logs&0x20) + log_pick_pc(sd, LOG_TYPE_SCRIPT, amount, NULL); + pc_setaccountreg(sd,"#CASHPOINTS",sd->cashPoints);//update shop~ + return 0; + } + if( stristr(nd->name,"ACCCur") ) {//Account Reg Currency + const char* charReg = pc_readregstr(sd,add_str("@AccCurrrency$")); + int count = pc_readaccountreg(sd,charReg); + if( count != pc_readaccountreg( sd, "#CASHPOINTS" ) )//safecheck + return 6; + sd->cashPoints = count; + if( sd->cashPoints < vt ) + return 6; + sd->cashPoints -= vt; + pc_setaccountreg(sd,charReg,sd->cashPoints);//update... + if( !pet_create_egg(sd, nameid) )//give item... + { + struct item item_tmp; + memset(&item_tmp, 0, sizeof(struct item)); + item_tmp.nameid = nameid; + item_tmp.identify = 1; + + pc_additem(sd,&item_tmp, amount, LOG_TYPE_NPC); + } + if(log_config.enable_logs&0x20) + log_pick_pc(sd, LOG_TYPE_SCRIPT, amount, NULL); + pc_setaccountreg(sd,"#CASHPOINTS",sd->cashPoints);//update shop~ + return 0; + } + + if( sd->kafraPoints < points || sd->cashPoints < (vt - points) ) return 6; pc_paycash(sd,vt,points); - + // Delivery Process ----------------------------------------------------
  2. Yup, i changed skill_num for skill_id, its in the patch.
  3. Random only explain how to add the mod of Lilith manually, i don´t see any change made for he. he only said that is redundant and advised that can be better in some part of the line: map[sd->bl.m].flag.restricted && skill_db[skill_num].flag&(8*map[sd->bl.m].zone) But the mod of lilith work fine.
  4. This the patch for rev 17066 and its working. I have only one doubt, where put (int64) in this part, i put there but maybe iam wrong. md.damage = md.damage += (int64)md.damage*battle_SAD(sd, target, skill_id)/100; I hope Lilith clarify the doubt. Regards. @ emong you were right tnks. fixed Manage Skill Damage_2.0 r17066.patch
  5. Version 1.1 its working fine in rev 17058.. i will test 2.0 note: apply patch this manually
  6. This topic must go to Client & Patcher Support Follow next steps for all other skills to add add in: data\luafiles514\lua files\skillinfoz\skilltreeview.lub [JOBID.JT_SUPERNOVICE] = { [1] = SKID.SM_SWORD, [2] = SKID.SM_BASH, [3] = SKID.SM_PROVOKE, [4] = SKID.TF_DOUBLE, [5] = SKID.TF_STEAL, [6] = SKID.TF_POISON, [8] = SKID.SM_RECOVERY, [9] = SKID.SM_MAGNUM, [10] = SKID.SM_ENDURE, [11] = SKID.TF_MISS, [12] = SKID.TF_HIDING, [13] = SKID.TF_DETOXIFY, [15] = SKID.MG_STONECURSE, [16] = SKID.MG_COLDBOLT, [17] = SKID.MG_LIGHTNINGBOLT, [18] = SKID.MG_NAPALMBEAT, [19] = SKID.MG_FIREBOLT, [20] = SKID.MG_SIGHT, [22] = SKID.MG_SRECOVERY, [23] = SKID.MG_FROSTDIVER, [24] = SKID.MG_THUNDERSTORM, [25] = SKID.MG_SOULSTRIKE, [26] = SKID.MG_FIREBALL, [28] = SKID.AL_RUWACH, [29] = SKID.AL_HEAL, [30] = SKID.AL_HOLYWATER, [31] = SKID.AL_DP, [32] = SKID.MG_SAFETYWALL, [33] = SKID.MG_FIREWALL, [34] = SKID.AC_OWL, [35] = SKID.AL_TELEPORT, [36] = SKID.AL_CURE, [37] = SKID.AL_INCAGI, [38] = SKID.AL_BLESSING, [39] = SKID.AL_DEMONBANE, [40] = SKID.AL_ANGELUS, [41] = SKID.AC_VULTURE, [42] = SKID.AL_WARP, [43] = SKID.MC_INCCARRY, [44] = SKID.AL_DECAGI, [45] = SKID.MC_IDENTIFY, [46] = SKID.AL_CRUCIS, [47] = SKID.MC_MAMMONITE, [48] = SKID.AC_CONCENTRATION, [49] = SKID.AL_PNEUMA, [50] = SKID.MC_DISCOUNT, [51] = SKID.MC_OVERCHARGE, [52] = SKID.MC_PUSHCART, [53] = SKID.MC_VENDING, [22] = SKID.WZ_STORMGUST // add this add in : data\luafiles514\lua files\skillinfo\skilltreeview.lub [23] = { {"SM_SWORD", 2; Pos = 1, MaxLv = 10, NeedSkillList = {}}, {"SM_BASH", 5; Pos = 2, MaxLv = 10, NeedSkillList = {}}, {"SM_PROVOKE", 6; Pos = 3, MaxLv = 10, NeedSkillList = {}}, {"TF_DOUBLE", 48; Pos = 4, MaxLv = 10, NeedSkillList = {}}, {"TF_STEAL", 50; Pos = 5, MaxLv = 10, NeedSkillList = {}}, {"TF_POISON", 52; Pos = 6, MaxLv = 10, NeedSkillList = {}}, {"SM_RECOVERY", 4; Pos = 8, MaxLv = 10, NeedSkillList = {}}, {"SM_MAGNUM", 7; Pos = 9, MaxLv = 10, NeedSkillList = {2}}, {"SM_ENDURE", 8; Pos = 10, MaxLv = 10, NeedSkillList = {3}}, {"TF_MISS", 49; Pos = 11, MaxLv = 10, NeedSkillList = {}}, {"TF_HIDING", 51; Pos = 12, MaxLv = 10, NeedSkillList = {5}}, {"TF_DETOXIFY", 53; Pos = 13, MaxLv = 1, NeedSkillList = {6}}, {"MG_STONECURSE", 16; Pos = 15, MaxLv = 10, NeedSkillList = {}}, {"MG_COLDBOLT", 14; Pos = 16, MaxLv = 10, NeedSkillList = {}}, {"MG_LIGHTNINGBOLT", 20; Pos = 17, MaxLv = 10, NeedSkillList = {}}, {"MG_NAPALMBEAT", 11; Pos = 18, MaxLv = 10, NeedSkillList = {}}, {"MG_FIREBOLT", 19; Pos = 19, MaxLv = 10, NeedSkillList = {}}, {"MG_SIGHT", 10; Pos = 20, MaxLv = 1, NeedSkillList = {}}, {"MG_SRECOVERY", 9; Pos = 22, MaxLv = 10, NeedSkillList = {}}, {"MG_FROSTDIVER", 15; Pos = 23, MaxLv = 10, NeedSkillList = {16}}, {"MG_THUNDERSTORM", 21; Pos = 24, MaxLv = 10, NeedSkillList = {17}}, {"MG_SOULSTRIKE", 13; Pos = 25, MaxLv = 10, NeedSkillList = {18}}, {"MG_FIREBALL", 17; Pos = 26, MaxLv = 10, NeedSkillList = {19}}, {"AL_RUWACH", 24; Pos = 28, MaxLv = 1, NeedSkillList = {}}, {"AL_HEAL", 28; Pos = 29, MaxLv = 10, NeedSkillList = {}}, {"AL_HOLYWATER", 31; Pos = 30, MaxLv = 1, NeedSkillList = {}}, {"AL_DP", 22; Pos = 31, MaxLv = 10, NeedSkillList = {}}, {"MG_SAFETYWALL", 12; Pos = 32, MaxLv = 10, NeedSkillList = {18, 25}}, {"MG_FIREWALL", 18; Pos = 33, MaxLv = 10, NeedSkillList = {26}}, {"AC_OWL", 43; Pos = 34, MaxLv = 10, NeedSkillList = {}}, {"AL_TELEPORT", 26; Pos = 35, MaxLv = 2, NeedSkillList = {28}}, {"AL_CURE", 35; Pos = 36, MaxLv = 1, NeedSkillList = {29}}, {"AL_INCAGI", 29; Pos = 37, MaxLv = 10, NeedSkillList = {29}}, {"AL_BLESSING", 34; Pos = 38, MaxLv = 10, NeedSkillList = {31}}, {"AL_DEMONBANE", 23; Pos = 39, MaxLv = 10, NeedSkillList = {31}}, {"AL_ANGELUS", 33; Pos = 40, MaxLv = 10, NeedSkillList = {31}}, {"AC_VULTURE", 44; Pos = 41, MaxLv = 10, NeedSkillList = {34}}, {"AL_WARP", 27; Pos = 42, MaxLv = 4, NeedSkillList = {35}}, {"MC_INCCARRY", 36; Pos = 43, MaxLv = 10, NeedSkillList = {}}, {"AL_DECAGI", 30; Pos = 44, MaxLv = 10, NeedSkillList = {37}}, {"MC_IDENTIFY", 40; Pos = 45, MaxLv = 1, NeedSkillList = {}}, {"AL_CRUCIS", 32; Pos = 46, MaxLv = 10, NeedSkillList = {39}}, {"MC_MAMMONITE", 42; Pos = 47, MaxLv = 10, NeedSkillList = {}}, {"AC_CONCENTRATION", 45; Pos = 48, MaxLv = 10, NeedSkillList = {41}}, {"AL_PNEUMA", 25; Pos = 49, MaxLv = 1, NeedSkillList = {42}}, {"MC_DISCOUNT", 37; Pos = 50, MaxLv = 10, NeedSkillList = {43}}, {"MC_OVERCHARGE", 38; Pos = 51, MaxLv = 10, NeedSkillList = {50}}, {"MC_PUSHCART", 39; Pos = 52, MaxLv = 10, NeedSkillList = {43}}, {"MC_VENDING", 41; Pos = 53, MaxLv = 10, NeedSkillList = {52}}, {"WZ_STORMGUST", 89; Pos = 54, MaxLv = 10, NeedSkillList = {}} // Add this without skill requirement {}} Add in db/re/skill_tree.txt or db/pre-re/skill_tree.txt : //SuperNovice 23,1,9,0,0,0,0,0,0,0,0,0,0 //NV_BASIC#Basic Skill# 23,142,1,0,0,0,0,0,0,0,0,0,0 //NV_FIRSTAID#First Aid# 23,2,10,0,0,0,0,0,0,0,0,0,0 //SM_SWORD#Sword Mastery# 23,4,10,0,0,0,0,0,0,0,0,0,0 //SM_RECOVERY#Increase HP Recovery# 23,5,10,0,0,0,0,0,0,0,0,0,0 //SM_BASH#Bash# 23,6,10,0,0,0,0,0,0,0,0,0,0 //SM_PROVOKE#Provoke# 23,7,10,5,5,0,0,0,0,0,0,0,0 //SM_MAGNUM#Magnum Break# 23,8,10,6,5,0,0,0,0,0,0,0,0 //SM_ENDURE#Endure# 23,9,10,0,0,0,0,0,0,0,0,0,0 //MG_SRECOVERY#Increase SP Recovery# 23,10,1,0,0,0,0,0,0,0,0,0,0 //MG_SIGHT#Sight# 23,11,10,0,0,0,0,0,0,0,0,0,0 //MG_NAPALMBEAT#Napalm Beat# 23,12,10,11,7,13,5,0,0,0,0,0,0 //MG_SAFETYWALL#Safety Wall# 23,13,10,11,4,0,0,0,0,0,0,0,0 //MG_SOULSTRIKE#Soul Strike# 23,14,10,0,0,0,0,0,0,0,0,0,0 //MG_COLDBOLT#Cold Bolt# 23,15,10,14,5,0,0,0,0,0,0,0,0 //MG_FROSTDIVER#Frost Diver# 23,16,10,0,0,0,0,0,0,0,0,0,0 //MG_STONECURSE#Stone Curse# 23,17,10,19,4,0,0,0,0,0,0,0,0 //MG_FIREBALL#Fire Ball# 23,18,10,17,5,10,1,0,0,0,0,0,0 //MG_FIREWALL#Fire Wall# 23,19,10,0,0,0,0,0,0,0,0,0,0 //MG_FIREBOLT#Fire Bolt# 23,20,10,0,0,0,0,0,0,0,0,0,0 //MG_LIGHTNINGBOLT#Lightning Bolt# 23,21,10,20,4,0,0,0,0,0,0,0,0 //MG_THUNDERSTORM#Thunderstorm# 23,22,10,0,0,0,0,0,0,0,0,0,0 //AL_DP#Divine Protection# 23,23,10,22,3,0,0,0,0,0,0,0,0 //AL_DEMONBANE#Demon Bane# 23,24,1,0,0,0,0,0,0,0,0,0,0 //AL_RUWACH#Ruwach# 23,25,1,27,4,0,0,0,0,0,0,0,0 //AL_PNEUMA#Pneuma# 23,26,2,24,1,0,0,0,0,0,0,0,0 //AL_TELEPORT#Teleport# 23,27,4,26,2,0,0,0,0,0,0,0,0 //AL_WARP#Warp Portal# 23,28,10,0,0,0,0,0,0,0,0,0,0 //AL_HEAL#Heal# 23,29,10,28,3,0,0,0,0,0,0,0,0 //AL_INCAGI#Increase AGI# 23,30,10,29,1,0,0,0,0,0,0,0,0 //AL_DECAGI#Decrease AGI# 23,31,1,0,0,0,0,0,0,0,0,0,0 //AL_HOLYWATER#Aqua Benedicta# 23,32,10,23,3,0,0,0,0,0,0,0,0 //AL_CRUCIS#Signum Crusis# 23,33,10,22,3,0,0,0,0,0,0,0,0 //AL_ANGELUS#Angelus# 23,34,10,22,5,0,0,0,0,0,0,0,0 //AL_BLESSING#Blessing# 23,35,1,28,2,0,0,0,0,0,0,0,0 //AL_CURE#Cure# 23,36,10,0,0,0,0,0,0,0,0,0,0 //MC_INCCARRY#Enlarge Weight Limit# 23,37,10,36,3,0,0,0,0,0,0,0,0 //MC_DISCOUNT#Discount# 23,38,10,37,3,0,0,0,0,0,0,0,0 //MC_OVERCHARGE#Overcharge# 23,39,10,36,5,0,0,0,0,0,0,0,0 //MC_PUSHCART#Pushcart# 23,40,1,0,0,0,0,0,0,0,0,0,0 //MC_IDENTIFY#Item Appraisal# 23,41,10,39,3,0,0,0,0,0,0,0,0 //MC_VENDING#Vending# 23,42,10,0,0,0,0,0,0,0,0,0,0 //MC_MAMMONITE#Mammonite# 23,43,10,0,0,0,0,0,0,0,0,0,0 //AC_OWL#Owl's Eye# 23,44,10,43,3,0,0,0,0,0,0,0,0 //AC_VULTURE#Vulture's Eye# 23,45,10,44,1,0,0,0,0,0,0,0,0 //AC_CONCENTRATION#Improve Concentration# 23,48,10,0,0,0,0,0,0,0,0,0,0 //TF_DOUBLE#Double Attack# 23,49,10,0,0,0,0,0,0,0,0,0,0 //TF_MISS#Improve Dodge# 23,50,10,0,0,0,0,0,0,0,0,0,0 //TF_STEAL#Steal# 23,51,10,50,5,0,0,0,0,0,0,0,0 //TF_HIDING#Hiding# 23,52,10,0,0,0,0,0,0,0,0,0,0 //TF_POISON#Envenom# 23,53,1,52,3,0,0,0,0,0,0,0,0 //TF_DETOXIFY#Detoxify# 23,410,1,0,0,0,0,0,0,0,0,0,0 //WE_CALLBABY#Call Baby# 23,681,1,0,0,0,0,0,0,0,0,0,0 //ALL_INCCARRY#Enlarge Weight Limit R# 23,2535,1,41,1,0,0,0,0,0,0,0,0 //ALL_BUYING_STORE#Open Buying Store# 23,89,10,0,0,0,0,0,0,0,0,0,0 // STORM GUST add this
  7. Here patch for version 17061, and not show any error, inclusive my dialog error . i am using 2012-04-10aRagexeRE. @TeamSpeakUser Sorry, i mistyped. fixed. ExtendedVendingSystem_1.8.1 r17061.patch
  8. Angel

    Custom cash shop

    I am using several currency, like bronze coins, plata, gold, Battle Badge. This mod is working fine in another revisions more old, but i will upgrade to rathena and i need this modification.
  9. Quitale el 127.0.0.1 , solo se coloca el nombre del dominio que creaste. No conecta a la base de datos porque al parecer no la has configuraro correctamente y para eso no necesitas el no-ip ya que se conecta a tu local, en uno de los errores que muestra el screenshot no encuentra la tabla login log, cargaste los logs.sql ?
  10. Is working in rathena 17053, but when i buy something give me a dialog message with some numbers and "NO MSG". i am using 2012-05-25aRagexeRE the packet are of the version. can someone help me to fix that message please? Regards [media=] [/media]__________________________________________________________________________ Edit: I think the problem is due to the packts... It's working fine with 2012-04-10 RagexeRE [ Packet : 0x0288,-1,cashshopbuy,4:8 ] in 2012-05-25aRagexeRE the packets has changed a 0x0288,-1,npcpointshopbuy,2:4:8:10. Someone has an idea how to fix it?
  11. La ip que te toma el no-ip es tu ip local, asi que no hay problema con lo del sql no es necesario configrar nada alli, puesto que tu sql esta en la ip local y se conecta a tu servidor., Para que se conecte la gente a tu server local, le debes colocar al clientinfo.xml el dominio de no-ip que creaste y ese pasarselo a la gente que quiera que se conecte, si su exe lee carpeta data solo ponganlo en la carpeta data, sino tienen que agregarlo al grf. Por ejemplo aqui "rathena.no-ip.info" viene siendo el dominio creado en no-ip. <?xml version="1.0" encoding="euc-kr" ?> <clientinfo> <servicetype>korea</servicetype> <servertype>sakray</servertype> <connection> <display>Ragnarok</display> <balloon>the balloon</balloon> <desc>description</desc> <address>rathena.no-ip.info</address> <port>6900</port> <version>31</version> <langtype>1</langtype> <registrationweb>flux.domain.com</registrationweb> <aid> <admin>2000001</admin> <admin>2000002</admin> </aid> <loading> <image>loadingscreen01.jpg</image> </loading> </connection> </clientinfo> Recuerda que el dominio creado en no-ip lo debes colocar en el emulador ( char_athena.conf y map_athena.conf ) como si fuera la ip, todos menos en los datos del sql ( inter_athena.conf) . // Login Server IP // The character server connects to the login server using this IP address. // NOTE: This is useful when you are running behind a firewall or are on // a machine with multiple interfaces. login_ip: rathena.no-ip.info // The character server listens on the interface with this IP address. // NOTE: This allows you to run multiple servers on multiple interfaces // while using the same ports for each server. //bind_ip: 127.0.0.1 // Login Server Port login_port: 6900 // Character Server IP // The IP address which clients will use to connect. // Set this to what your server's public IP address is. char_ip: rathena.no-ip.info // Character Server Port char_port: 6121
  12. Angel

    Custom cash shop

    Ok...thanks sir for your answer ___________________________________________________________________________________________________ Hello all ;D I need help with the code ( Custom Cash Shop ) by IND. Original patch: Custom Cash Shop I try to adapt the code to rAthena and to the compile don't show any error, but at buy in the shop it doesn't delete the item in players inventory ( Item Currency ). Video explanation: [media=] [/media]Iam using: rAthena 17053 Exe: 20120525a Packets Npc Demo Index: src/map/clif.c =================================================================== --- src/map/clif.c (revision 17053) +++ src/map/clif.c (working copy) @@ -14349,9 +14364,9 @@ WFIFOHEAD(fd,offset+nd->u.shop.count*11); WFIFOW(fd,0) = 0x287; WFIFOW(fd,2) = offset+nd->u.shop.count*11; - WFIFOL(fd,4) = sd->cashPoints; // Cash Points + WFIFOL(fd,4) = pc_readaccountreg(sd,"#CASHPOINTS"); // Cash Points #if PACKETVER >= 20070711 - WFIFOL(fd,8) = sd->kafraPoints; // Kafra Points + WFIFOL(fd,8) = pc_readaccountreg(sd,"#KAFRAPOINTS"); // Kafra Points #endif for( i = 0; i < nd->u.shop.count; i++ ) Index: src/map/npc.c =================================================================== --- src/map/npc.c (revision 17053) +++ src/map/npc.c (working copy) @@ -1427,15 +1427,100 @@ if( (double)nd->u.shop.shop_item[i].value * amount > INT_MAX ) { ShowWarning("npc_cashshop_buy: Item '%s' (%d) price overflow attempt!\n", item->name, nameid); - ShowDebug("(NPC:'%s' (%s,%d,%d), player:'%s' (%d/%d), value:%d, amount:%d)\n", - nd->exname, map[nd->bl.m].name, nd->bl.x, nd->bl.y, sd->status.name, sd->status.account_id, sd->status.char_id, nd->u.shop.shop_item[i].value, amount); + ShowDebug("(NPC:'%s' (%s,%d,%d), player:'%s' (%d/%d), value:%d, amount:%d)\n", nd->exname, map[nd->bl.m].name, nd->bl.x, nd->bl.y, sd->status.name, sd->status.account_id, sd->status.char_id, nd->u.shop.shop_item[i].value, amount); return 5; } price = nd->u.shop.shop_item[i].value * amount; if( points > price ) points = price; + + /*--------------------------- Ind Mod ---------------------------*/ + + if( stristr(nd->name,"ITMCur") ) {//Item Currency + int count=0,ind=0,c = 0, cid = pc_readreg(sd,add_str("@RRITMCur")); + for(c = 0; c < MAX_INVENTORY; c++) + if(sd->status.inventory[c].nameid == cid ) + count += sd->status.inventory[c].amount; + if( count != pc_readaccountreg( sd, "#CASHPOINTS" ) ) + return 6; + ind = pc_search_inventory(sd, cid); + if( ind < 0 )//because checking twice is safer... + return 6; + sd->cashPoints = count; + if( sd->cashPoints < price ) + return 6; + if( pc_delitem(sd, ind, price, 0, 0, LOG_TYPE_NPC) )//somehow it failed to delete... + return 6; + + sd->cashPoints -= price; + if( !pet_create_egg(sd, nameid) ) + { + struct item item_tmp; + memset(&item_tmp, 0, sizeof(struct item)); + item_tmp.nameid = nameid; + item_tmp.identify = 1; + + pc_additem(sd,&item_tmp, amount, LOG_TYPE_NPC); + + } + if(log_config.enable_logs&0x20) + log_pick_pc(sd, LOG_TYPE_SCRIPT, amount, NULL); + pc_setaccountreg(sd,"#CASHPOINTS",sd->cashPoints);//update shop~ + return 0; + } + if( stristr(nd->name,"CharCur") ) {//Char Reg Currency (from set REGNAME,1;) + const char* charReg = pc_readregstr(sd,add_str("@CharCurrrency$")); + int count = pc_readglobalreg(sd,charReg); + if( count != pc_readaccountreg( sd, "#CASHPOINTS" ) )//safecheck + return 6; + sd->cashPoints = count; + if( sd->cashPoints < price ) + return 6; + sd->cashPoints -= price; + pc_setglobalreg(sd,charReg,sd->cashPoints);//update... + if( !pet_create_egg(sd, nameid) )//give item... + { + struct item item_tmp; + memset(&item_tmp, 0, sizeof(struct item)); + item_tmp.nameid = nameid; + item_tmp.identify = 1; + + pc_additem(sd,&item_tmp, amount, LOG_TYPE_NPC); + } + if(log_config.enable_logs&0x20) + log_pick_pc(sd, LOG_TYPE_SCRIPT, amount, NULL); + pc_setaccountreg(sd,"#CASHPOINTS",sd->cashPoints);//update shop~ + return 0; + } + if( stristr(nd->name,"ACCCur") ) {//Account Reg Currency + const char* charReg = pc_readregstr(sd,add_str("@AccCurrrency$")); + int count = pc_readaccountreg(sd,charReg); + if( count != pc_readaccountreg( sd, "#CASHPOINTS" ) )//safecheck + return 6; + sd->cashPoints = count; + if( sd->cashPoints < price ) + return 6; + sd->cashPoints -= price; + pc_setaccountreg(sd,charReg,sd->cashPoints);//update... + if( !pet_create_egg(sd, nameid) )//give item... + { + struct item item_tmp; + memset(&item_tmp, 0, sizeof(struct item)); + item_tmp.nameid = nameid; + item_tmp.identify = 1; + + pc_additem(sd,&item_tmp, amount, LOG_TYPE_NPC); + } + if(log_config.enable_logs&0x20) + log_pick_pc(sd, LOG_TYPE_SCRIPT, amount, NULL); + pc_setaccountreg(sd,"#CASHPOINTS",sd->cashPoints);//update shop~ + return 0; + } + + + /*--------------------------- Ind Mod ---------------------------*/ if( (sd->kafraPoints < points) || (sd->cashPoints < price - points) ) return 6 Somebody help please.....
  13. Angel

    unknown item

    what exe are you using? Try of put that info in itemInfo.lub ( System/itemInfo.lub )
  14. No tengo experiencia con hamachi, pero si con No-ip el cual es mucho mas sencillo, te dejo un tuto que encontre en youtube para poder crear un host no-ip. Ya que tengas tu host por ejemplo : rathena-ro.no-ip.info, esta direccion es la que vas a colocar en tu emulador como ip ( login_ip:, char_ip: ) y tambien la colocas en tu clientinfo.xml, el cual puedes enviar a los miembros de tu staff para que puedan entrar en tu server local. Espero te ayude esta info, yo tengo al igual un server local junto con XAMPP y el servicio de no-ip, cualquier cosa te hecho la mano. Saludos. [media=]http://www.youtube.com/watch?v=B1zXswfESWs[/media]
  15. You can see in changeset 14400 : http://trac.rathena....t/14400/rathena Edit: src/common/mmo.h src/map/battle.c src/map/skill.c src/map/status.c Only revert back this, changing the green block for the red, then recompile and try. i hope to help you.
  16. Players using "emergency call" don't be affected for devotion skill, or while casting don't permit cast Devotion on them. Can someone help pls? Thanks.
  17. why dont try this mod? Its really excellent, easy and dont need restart for restrict items or skills in maps that are assigned http://rathena.org/board/topic/59578-mapflags-noitem-and-noskill2/
  18. Hi Legato,which exe are you using? patch does not show any error at compile, but when i buy of npc it's send me exe crash. its mi script npc: prontera,164,168,5 cashshop(#pvp_points) Pvp_Shop 83,502:5,503:1 Iam using exe version 2011-06-09aRagexeRE.exe and rAthena 16208. i think that the problem come from the packets (packet_db.txt) someone have the same problem and got fix it?
  19. Hello All. iam using Rathena 16208 and calciumkid-fluxcp-renewal-9463113 but i still some errors in mob_db, item_db i when i log in My Account. i really want fix "My Account" first for the users tnks. it gave me this error in all mentioned:
×
×
  • Create New...