Jump to content

Lord Ganja

Members
  • Content Count

    161
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Lord Ganja

  1. Can anyone help me modify this successenchant src. This source works like this: 'successenchant <equip location>,<enchant orb id>;' I need to work like this one: 'successenchant <equip location>,<card slot>,<enchant orb id>;' I'm bad at src mod so I can't do it on my own. Help please. Thanks in advance! BUILDIN(successenchant){ int i = -1, j, num, enchant, ep; TBL_PC *sd; num = script_getnum(st,2); // Equip Slot enchant = script_getnum(st,3); // Equip Enchant sd = script_rid2sd(st); if( sd == NULL || !itemdb_isenchant(enchant) ) return 0; if( num > 0 && num <= ARRAYLENGTH(script->equip) ) i = pc->checkequip(sd, script->equip[num - 1]); if( i < 0 ) return 0; if( !sd->inventory_data[i] || sd->inventory_data[i]->slot >= MAX_SLOTS ) return 0; // Cannot enchant an item with 4 slots. Enchant uses last slot. ep = sd->status.inventory[i].equip; logs->pick_pc(sd, LOG_TYPE_SCRIPT, -1, &sd->status.inventory[i],sd->inventory_data[i]); // By Official Info: Item will lose cards, refine and previus enchants. for( j = 0; j < MAX_SLOTS; j++ ) sd->status.inventory[i].card[j] = 0; sd->status.inventory[i].refine = 0; // -------------------------------------------------------------------- pc->unequipitem(sd,i,2); clif->delitem(sd,i,1,3); sd->status.inventory[i].card[MAX_SLOTS - 1] = enchant; logs->pick_pc(sd, LOG_TYPE_SCRIPT, 1, &sd->status.inventory[i],sd->inventory_data[i]); clif->additem(sd,i,1,0); pc->equipitem(sd,i,ep); clif->misceffect(&sd->bl,3); return 0;}
  2. Magandang hapon po. Tanong ko lang po baka meron sainyong may alam na nagooffer ng IT Short Courses. Yung mga good for 3 months lang. Siguro yung sa mga basic muna tapos pataas. Gusto ko din kasi matuto mag programming, web development, pag gawa ng mga codes kaso di kaya ng oras ko kapag sa university ako pumasok. Mejo may mga idea nadin akong konti sa mga basic, pero gusto ko iimprove yung skills ko. Meron din sana akong nakikitang online eh, kaso di ko alam kung talagang matututo ba ako sa online. Ayaw ko din kasi magsayang ng oras kung magbabasa ako ng mga di naman talaga kelangan matutunan. Salamat po!
  3. alright. Thanks for this. Is it a bit complicated to add one for boss only?
  4. Can anyone help me edit this warpgodelay to set timer when a player inflict or received damage from other players or boss monsters only. thanks!
  5. Anybody willing to help me about this? I successfully added custom jobs using Neo's Guide, but I still want to get rid of the warnings when compiling. srcmapitemdb.c(361): warning C4293: '<<' : shift count negative or too big, undefined behavior and as Neo, said So can anyone help me change 32bit into 64bit variable? Thanks in advance!
  6. Hi. Can anyone check this script? It's not working fine with me.. My only problem here is it doesn't kick the party member when the party member logged out. But if the party member changed map, the script is triggered. Does this script still continue to run even when the player logged out? Since I didnt put an 'end;' at OnPCLogoutEvent, it should continue run until OnPCStatCalcEvent right? But doesn't work for me. OnPCLogoutEvent: if( @insta_event ) .@logged = 1;OnPCStatCalcEvent: if( @insta_event ) { ..................................... Here's the full script: - script custom_event_checker -1,{OnPCLoadMapEvent:getmapxy(.@map$,.@x,.@y,0); if( .@map$ == "guild_vs2-2" || .@map$ == "ph_dun01" || .@map$ == "ph_dun02" || .@map$ == "ph_dun03" ) { if(getgmlevel() > 0 && getgmlevel() < 99) { atcommand "@storeall"; atcommand "@job novice"; atcommand "@adjgroup 30"; end; } else { atcommand "@autoloot 100"; @insta_event = 1; end; } } end;OnPCLogoutEvent: if( @insta_event ) .@logged = 1;OnPCStatCalcEvent: if( @insta_event ) { if ( strcharinfo(3) == "ph_dun01" && !.@logged || strcharinfo(3) != "ph_dun01" && .@logged || strcharinfo(3) == "ph_dun02" && !.@logged || strcharinfo(3) != "ph_dun02" && .@logged || strcharinfo(3) == "ph_dun03" && !.@logged || strcharinfo(3) != "ph_dun03" && .@logged || strcharinfo(3) == "guild_vs2-2" && !.@logged || strcharinfo(3) != "guild_vs2-2" && .@logged || getcharid(1) == 0 ) end; .@party_id = getcharid(1); if ( getcharid(0) != getpartyleader( .@party_id, 2 ) ) party_delmember(); else { .i = 0; if ( instance_check_party(.@party_id,2) == 0 ) party_destroy(.@party_id); else { addrid( 2, 0, .@party_id ); if( !.i && !.@party_id ) { .i = 1; party_changeleader getcharid(1), getcharid(0); } else if( .@party_id ) party_delmember(); } } @insta_event = 0; } end;}
  7. Does KA-Type(Kaite, Kaahi, Kaupe, Kaizel) skills can really be casted even without soullink? How do I make them like the previous one? If you cast KA-Type skills without soul link the caster will be stunned. I try to changed it at skill_db.txt. But whenever I make it a spirit skill(0x8), the skill level stays at level 1 only. from 465,9,6,16,0,0x1,0,7,1,yes,0,0,0,magic,0,0x20, SL_KAITE,Kaite to 465,9,6,16,0,0x1,0,7,1,yes,0,0x8,0,magic,0,0x20, SL_KAITE,Kaite Please just move this if I post it on the wrong section. Thanks in advance.
  8. Lol. Alright. Guess i'll have to wait anyways, thanks @@Dastgir EDIT: @@Neo, I'm having this client error now. I didn't even touch the PCImfs.lub file..
  9. src/map/map.h:MAPID_AKATSUKI = 0x11 Other 2 should be 0x12 and 0x13 Thank you! How about changing the variable from 32bit to 64bit?
  10. @@Dastgir Thanks for the response. Anyway can you help me fix those issues? I really don't have any idea how to change the variable from 32 bit to 64 bit.. And about the value 17, how to change it with 18/19?
  11. I'm having these errors while compiling. Any idea why? itemdb.c Line 358 //Custom JobsLine 359 if (jobmask & 1<<31)Line 360 bclass[0] |= 1<<MAPID_AKATSUIT;Line 361 if (jobmask & 1<<32)Line 362 bclass[0] |= 1<<MAPID_AKATSUKI;Line 363 if (jobmask & 1<<33)Line 364 bclass[0] |= 1<<MAPID_ANBU; ERROR: srcmapitemdb.c(361): warning C4293: '<<' : shift count negative or too big, undefined behaviorsrcmapitemdb.c(363): warning C4293: '<<' : shift count negative or too big, undefined behavior pc.c Line 6058 //Custom JobsLine 6059 case MAPID_AKATSUIT: return JOB_AKATSUIT;Line 6060 case MAPID_AKATSUKI: return JOB_AKATSUKI;Line 6061 case MAPID_ANBU: return JOB_ANBU; ERROR: srcmappc.c(6060): error C2196: case value '17' already usedsrcmappc.c(6061): error C2196: case value '17' already used
  12. Thanks for your replies. I had a project with him before. And it is successful, that's why i didn't think that it would happen this way. Guess that's just badluck for me, atleast for those newbie who could read this would learn how to properly negotiate with people.
  13. I just want to share something of my previous experience. So I talked to this guy named Kichi on this forums regarding some paid services. I had a successful transaction with him around year 2012. And last March 2015, I ask him again to do something for me for a paid service(a custom source code). Then I paid him last March 31,2015. Anyway before I paid him, he always reply from my msgs, but then after I paid him, I rarely got any of his replies. I know it's just $20, but the thing is his reputation. I trusted him coz we already had a successful transaction before, plus he was really a nice guy. I even posted a review from him HERE and somehow replied from someone who's giving him bad rep. Actually I ask him for a 2 source codes, and he gave me a price $50 for that codes (1 for $30 and the other for $20 plus a free fix of some outdated src). And after that, I told him that I was a bit short coz I had to pay my bills, so I told him that I will have to pay him with the $20 first, but he doesn't need to work with the $30 one if I haven't paid him yet. So our deal is like, I pay him $20 then give me that worth $20 code, and if I have already paid the $30 one, that's when he will start the other project. I don't know if that's why he isn't replying from my msgs, but he could have told me right? plus he already agreed with the $20 first, which is not really a problem coz the codes has a specific price. I really have a patience, but atleast he should have gave me any updates regarding the matter so I could understand and we can talk further. I somehow wanted to understand him, but everytime I dropped him a msg, he's always online but I haven't got any replies. HERE HE TOLD ME THAT HE WAS GOING TO START THE PROJECT THAT NIGHT APRIL 3,2015 THEN AFTER 3 DAYS, I ASKED HIM IF HE GOT ANY UPDATES. i THINK 3 DAYS IS ENOUGH TO MAKE THAT CODE COZ I THINK IT'S NOT REALLY COMPLICATED BUT THEN, I UNDERSTAND HIM COZ HE TOLD ME HE GOT BUSY WITH HIS REAL LIFE TASKS THEN AFTER ALMOST A WEEK, HE TOLD ME THAT HE WAS JUST BEGINNING WITH THE PROJECT AFTER THAT, I HAVEN'T GOT ANY UPDATES FROM HIM. HE'S ALWAYS ONLINE BUT I DON'T GET ANY REPLIES FROM HIM. HE WAS JUST IGNORING MY MESSAGES. UNTIL I FINALLY MADE MY OWN SOURCE CODE SIMILAR FROM WHAT I WAS ASKING FROM HIM. AND TOLD HIM THAT THE MONEY I SENT TO HIM WILL JUST BE USED FOR THE 3D LOGO. BUT INTIL NOW, I HAVEN'T GOT ANY MSGS FROM HIM.
  14. on script.c BUILDIN(getsealeditem) { int nameid,amount,get_count,i,flag = 0, offset = 0; struct item it; TBL_PC *sd; struct item_data *item_data; if( script_isstringtype(st, 2) ) { // "<item name>" const char *name = script_getstr(st, 2); if( (item_data = itemdb->search_name(name)) == NULL ) { ShowError("buildin_%s: Nonexistant item %s requested.n", script->getfuncname(st), name); return false; //No item created. } nameid=item_data->nameid; } else { // <item id> nameid = script_getnum(st, 2); //Violet Box, Blue Box, etc - random item pick if( nameid < 0 ) { nameid = -nameid; flag = 1; } if( nameid <= 0 || !(item_data = itemdb->exists(nameid)) ) { ShowError("buildin_%s: Nonexistant item %d requested.n", script->getfuncname(st), nameid); return false; //No item created. } } // <amount> if( (amount=script_getnum(st,3)) <= 0) return true; //return if amount <=0, skip the useles iteration memset(&it,0,sizeof(it)); it.nameid=nameid; if(!flag) it.identify=1; else it.identify=itemdb->isidentified2(item_data); if( !(it.equip&EQP_HEAD_TOP) || !(it.equip&EQP_ARMOR) || !(it.equip&EQP_HAND_L) || !(it.equip&EQP_HAND_R) || !(it.equip&EQP_GARMENT) || !(it.equip&EQP_SHOES) || !(it.equip&EQP_ACC_L) || !(it.equip&EQP_ACC_R) || !(it.equip&EQP_HEAD_MID) || !(it.equip&EQP_HEAD_LOW) ) { ShowError("script_getsealeditem: Cannot create this sealeditem, it only works for equipments."); return false; } if( script_hasdata(st,4+offset) ) sd=map->id2sd(script_getnum(st,4+offset)); // <Account ID> else sd=script->rid2sd(st); // Attached player if( sd == NULL ) // no target return true; //Check if it's stackable. if (!itemdb->isstackable(nameid)) get_count = 1; else get_count = amount; it.nameid = nameid; it.refine = 0; it.attribute = 0; it.card[0] = CARD0_CREATE; it.card[1] = 0; it.card[2] = GetWord(battle_config.reserved_sealed_id, 0); it.card[3] = GetWord(battle_config.reserved_sealed_id, 1); for (i = 0; i < amount; i += get_count) { // if not pet egg if (!pet->create_egg(sd, nameid)) { if ((flag = pc->additem(sd, &it, get_count, LOG_TYPE_SCRIPT))) { clif->additem(sd, 0, 0, flag); if( pc->candrop(sd,&it) ) map->addflooritem(&it,get_count,sd->bl.m,sd->bl.x,sd->bl.y,0,0,0,0); } } } return true;}-------------------------------------------------------------BUILDIN_DEF(getsealeditem,"vi?"), sample script: prontera,150,150,4 script testing 521,{getsealeditem 2383,1;end;} after clicking the debug occured.
  15. Even if I use this I got the same error. When I try to click the npc this one appears: [Debug]: Source (NPC): sealeditem at prontera (156,177) And when I stopped the server this one appears [Error]: script_getsealeditem: Cannot create this sealeditem, it only works for equipments.
  16. edit agit_main.txt npc/guild/agit_main.txt // Respawn the Emperium, and display new owners.sleep 500; // Slow down script execution slightly.if( agitcheck() ) donpcevent "Agit#"+strnpcinfo(2)+"::OnStartArena";sleep 7000;-announce "The [" + getcastlename(strnpcinfo(2)) + "] castle has been conquered by the [" + getguildname(.@GID) + "] guild.",bc_all|bc_woe;+announce "The [ " + getcastlename(strnpcinfo(2)) + " ] castle's emperium has been destroyed by [ "+strcharinfo(0)+" ] and conquered by the [ " + getguildname(.@GID) + " ] guild.",bc_all|bc_woe;end;
  17. All variables are stored at SQL(except scope , since it is erased quickly (as soon as script ends))There are 6 tables char_reg_num_db char_reg_str_db and 2-2 more for login and global variables. Gotcha! Thanks@@Dastgir
  18. @@Garr Thanks! anyway are permanent variables stored at sql?
  19. If it says 'passed', you can use it and try if it works.. AFAIK it also supports 20130807 clients. and if you think you already set all things correctly but errors occured like [info]: clif_parse: Disconnecting session #3 with unknown packet version (p:0x464d,l:19). try to generate another key.. just make sure that you always replace the packetkeys 1st to 3rd in packets.h with your new packetkeys always diff your client with your new packetkeys and also don't forget to recompile.
  20. As the title says, when does variable resets? Like, if we use '@' variable, it resets whenever the attached player logged out. How about the others? Thanks for those who can explain.
  21. edit mo sa db/pre-re/exp.txt
  22. I already tried that one, but won't work I think I still have to add or edit something from the whole script. But I don't know what and how.
  23. I currently created a new script command but it's not working well I'm not good on src modifcation This script is basically just a copy paste from getitem script and get some ideas from costume system but this one works differently. I need it to only work on equipments (armor,garment,shoes,accessory,weapon,shields and headgears) My problem here is whenever the script runs on this part below, it doesn't went through. It always returns the error even if the script im using is getsealeditem 2383,1; // 2383 is an armor if( !(it.equip&EQP_HEAD_TOP) || !(it.equip&EQP_ARMOR) || !(it.equip&EQP_HAND_L) || !(it.equip&EQP_HAND_R) || !(it.equip&EQP_GARMENT) || !(it.equip&EQP_SHOES) || !(it.equip&EQP_ACC_L) || !(it.equip&EQP_ACC_R) || !(it.equip&EQP_HEAD_MID) || !(it.equip&EQP_HEAD_LOW) ) { ShowError("script_getsealeditem: Cannot create this sealeditem, it only works for equipments."); return false; } This is the whole part script.c BUILDIN(getsealeditem) { int nameid,amount,get_count,i,flag = 0, offset = 0; struct item it; TBL_PC *sd; struct item_data *item_data; if( script_isstringtype(st, 2) ) { // "<item name>" const char *name = script_getstr(st, 2); if( (item_data = itemdb->search_name(name)) == NULL ) { ShowError("buildin_%s: Nonexistant item %s requested.n", script->getfuncname(st), name); return false; //No item created. } nameid=item_data->nameid; } else { // <item id> nameid = script_getnum(st, 2); //Violet Box, Blue Box, etc - random item pick if( nameid < 0 ) { nameid = -nameid; flag = 1; } if( nameid <= 0 || !(item_data = itemdb->exists(nameid)) ) { ShowError("buildin_%s: Nonexistant item %d requested.n", script->getfuncname(st), nameid); return false; //No item created. } } // <amount> if( (amount=script_getnum(st,3)) <= 0) return true; //return if amount <=0, skip the useles iteration memset(&it,0,sizeof(it)); it.nameid=nameid; if(!flag) it.identify=1; else it.identify=itemdb->isidentified2(item_data); if( !(it.equip&EQP_HEAD_TOP) || !(it.equip&EQP_ARMOR) || !(it.equip&EQP_HAND_L) || !(it.equip&EQP_HAND_R) || !(it.equip&EQP_GARMENT) || !(it.equip&EQP_SHOES) || !(it.equip&EQP_ACC_L) || !(it.equip&EQP_ACC_R) || !(it.equip&EQP_HEAD_MID) || !(it.equip&EQP_HEAD_LOW) ) { ShowError("script_getsealeditem: Cannot create this sealeditem, it only works for equipments."); return false; } if( script_hasdata(st,4+offset) ) sd=map->id2sd(script_getnum(st,4+offset)); // <Account ID> else sd=script->rid2sd(st); // Attached player if( sd == NULL ) // no target return true; //Check if it's stackable. if (!itemdb->isstackable(nameid)) get_count = 1; else get_count = amount; it.nameid = nameid; it.refine = 0; it.attribute = 0; it.card[0] = CARD0_CREATE; it.card[1] = 0; it.card[2] = GetWord(battle_config.reserved_sealed_id, 0); it.card[3] = GetWord(battle_config.reserved_sealed_id, 1); for (i = 0; i < amount; i += get_count) { // if not pet egg if (!pet->create_egg(sd, nameid)) { if ((flag = pc->additem(sd, &it, get_count, LOG_TYPE_SCRIPT))) { clif->additem(sd, 0, 0, flag); if( pc->candrop(sd,&it) ) map->addflooritem(&it,get_count,sd->bl.m,sd->bl.x,sd->bl.y,0,0,0,0); } } } return true;} Thanks in advance!
  24. What seems to be the problem with the fonts?
  25. Yes you can make your own custom packetkeys. However as @@Dastgir said, it shouldn't be a broken packetkey. You can try to use nkwz RO Toolkit to generate your own custom packet keys. but I don't know if hercules accepts packetkeys higher than 0x7FFFFFFF. coz rA only accepts 0x7FFFFFFF for maximum key value. Anyway if some problem occur regarding the packetkeys, you can just generate another custom packetkey until you got a working one. You can thank me by clicking
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.