Jump to content

sader1992

Content Moderator
  • Posts

    1678
  • Joined

  • Last visited

  • Days Won

    72

Everything posted by sader1992

  1. sader1992

    Web Hosting

    read the logs in both your server and your web server.
  2. the clone command return the monster gid so you can just save the gid and check for it like .PlayerOneClone = clone("prontera",155,155,"NpcName::OnEvent",1); .PlayerTwoClone = clone("prontera",145,145,"NpcName::OnEvent",2); end; OnEventOne: if(!unitexists(.PlayerOneClone)){ //player one clone is dead } if(!unitexists(.PlayerTwoClone)){ //player two clone is dead } end; also the event name, you can just use different event name for each clone like clone("prontera",155,155,"NpcName::OnEventOne",1); clone("prontera",145,145,"NpcName::OnEventTwo",2); end; OnEventOne: //player one clone is dead end; OnEventTwo: //player two clone is dead end; here a long example : let's clone everyone in prontera , than we check every time one of the mobs are dead we output a debugmes for the char id of the player (i didn't test it , i just wrote it as an example , i don't know even if it will work but technically it should work) getmapunits(BL_NPC,"prontera",.@AID); for(.@i=0;.@i<getarraysize(.@AID);.@i++){ .@s = getarraysize(.charList); .charList[.@s] = convertpcinfo(.@AID[.@i],CPC_CHAR); .mobList[.@s] = clone("prontera",155,155,"NpcName::OnEvent",.charList[.@s]); } end; OnEvent: for(.@i=0;.@i<getarraysize(.mobList);.@i++){ if(.mobList[.@i] && !unitexists(.mobList[.@i])){ //the monster has been found. //we save it. .@charID = .charList[.@i]; .@mobID = .mobList[.@i]; //we delete it from the array. deletearray .charList[.@i],1; deletearray .mobList[.@i],1; //we break out. break; } } //now we have the here .@charID = the player id , .@mobID = the monster gid debugmes "" + .@charID; debugmes "" + .@mobID;
  3. this check for the items if (countitem(715) < 3 || countitem(938) < 20) { copy/paste as much as you want && = and || = or and this delete the items, also copy/paste delitem 715,3; delitem 938,20; for zeny if(zeny < 10000){ mes "you don't have 10kz"; close; } zeny -= 10000; add it before the item check
  4. if you are planing to use the unique id more in the future , i would suggest using this the script would look like this prontera,0,0,0 script rewards 444,{ mes "something"; if(!gepard_int_get("freebies")){ gepard_int_set("freebies",1); mes "here is the rewards"; getitem 502,1; }else{ mes "you already got the freebies rewards"; } close; }
  5. as far as i know , skills have their own animation not like normal attack or multi hit attack
  6. https://github.com/rathena/rathena/pull/4454
  7. check out your mapcache.dat in the server search for how to update your mapcache
  8. i don't understand, what is the question ?
  9. i would suggest you upload your job_basehpsp and job_db1 from your prere|re folder , and make sure that those files in the import folder are empty
  10. the guild id as i told you , you put a guild that owned by you (the gm) so your guild will be the new owner , so when the woe start , non of the guild in the server would own that guild and they will fight for it as like no one own it means if you don't have a guild in your gm account , just create one , and put in it's id
  11. - script reset_castle_data -1,{ OnFri2130: //on Friday 9:30 PM , edit this to what you want. .@castle$ = ""; //input the guild castle name (map name like "gefg_cas01"). .@guildID = 0; //if the script didn't work , try to change this to a guild id owned by you. for(.@i = (CD_NONE+1); .@i < (CD_MAX-1); .@i++){ if(.@i == CD_GUILD_ID){ setcastledata .@castle$,.@i,.@guildID; }else{ setcastledata .@castle$,.@i,0; } } end; }
  12. i would really suggest you join browedit discord and for faster support for these things https://discord.gg/ma7BkG ofc still hopefully someone would reply with a fix here too.
  13. do not use commands like @refresh or something to deattach from the npc while doing/testing quest that include when the script stop your movement / disabled your actions the main reason from this update https://github.com/rathena/rathena/pull/4043 is to prevent this kind of behavior make sure there is nothing to break your interaction with the script , maybe src edit , or something else. in this quest you need to wait for the npc to finish talking ,than you will get the close button to continue your way, if you didn't wait , you will get an error.
  14. try this - script reset_castle_data -1,{ OnFri2130: //on Friday 9:30 PM , edit this to what you want. .@castle$ = ""; //input the guild castle name (map name like "gefg_cas01"). .@guildID = 0; //if the script didn't work , try to change this to a guild id owned by you. for(.@i = CD_NONE; .@i < CD_MAX; .@i++){ if(.@i == CD_GUILD_ID){ setcastledata .@castle$,.@i,.@guildID; }else{ setcastledata .@castle$,.@i,0; } } end; }
  15. because you blindly editing the script --------------------------------------- *getitembound <item id>,<amount>,<bound type>{,<account ID>}; *getitembound "<item name>",<amount>,<bound type>{,<account ID>}; This command behaves identically to 'getitem', but the items created will be bound to the target character as specified by the bound type. All items created in this manner cannot be dropped, sold, vended, auctioned, or mailed, and in some cases cannot be traded or stored. Valid bound types are: Bound_Account : Account Bound item Bound_Guild : Guild Bound item Bound_Party : Party Bound item Bound_Char : Character Bound item ---------------------------------------
  16. both scripts have the same source , but they are not the same.
  17. it could be useful for who don't have FluxCP but i would really suggest using FluxCP instead
  18. FluxCP/config/application.php LINE 54
  19. try - script mvp_announce -1,{ OnInit: setarray .mobid, 1002, 1001; setarray .map$, "prt_fild08", "prontera"; end; OnNPCKillEvent: if((.@index = inarray(.mobid[0], killedrid )) != -1){ if ( strcharinfo(3) == .map$[.@index] ) { announce "["+ strcharinfo(0) +"] ha matado "+ getmonsterinfo( killedrid, MOB_NAME ) +" en el mapa "+ strcharinfo(3) +".", bc_all; } } }
  20. if (.@index != -1 && strcharinfo(3) == .map$[.@index] ) {
  21. i would suggest using this https://github.com/rathena/rathena/blob/master/npc/custom/etc/autopot.txt no need for src edit
  22. https://github.com/rathena/rathena/blob/9124d5600f2b4a99bbfa6e5b54131d18dfe8ac48/doc/item_group.txt#L41 make clean server
  23. i didn't read the full topic , so i would answer only this question , i don't know if any other question is asked if you mean like this it can be done like this - script ::NPC_UNIQUE_NAME8765643433 444,13,13,{ end; OnInit: hideonnpc strnpcinfo(3); end; OnTouch: specialeffect 696,SELF; end; } prontera,160,127,4 duplicate(NPC_UNIQUE_NAME8765643433) #no1 444,13,13 prontera,160,129,4 duplicate(NPC_UNIQUE_NAME8765643433) #no2 444,13,13 prontera,160,131,4 duplicate(NPC_UNIQUE_NAME8765643433) #no3 444,13,13 prontera,160,133,4 duplicate(NPC_UNIQUE_NAME8765643433) #no4 444,13,13 prontera,160,135,4 duplicate(NPC_UNIQUE_NAME8765643433) #no5 444,13,13 prontera,160,137,4 duplicate(NPC_UNIQUE_NAME8765643433) #no6 444,13,13 prontera,160,139,4 duplicate(NPC_UNIQUE_NAME8765643433) #no7 444,13,13 prontera,160,141,4 duplicate(NPC_UNIQUE_NAME8765643433) #no8 444,13,13 prontera,160,143,4 duplicate(NPC_UNIQUE_NAME8765643433) #no9 444,13,13 prontera,151,127,4 duplicate(NPC_UNIQUE_NAME8765643433) #no11 444,13,13 prontera,151,129,4 duplicate(NPC_UNIQUE_NAME8765643433) #no12 444,13,13 prontera,151,131,4 duplicate(NPC_UNIQUE_NAME8765643433) #no13 444,13,13 prontera,151,133,4 duplicate(NPC_UNIQUE_NAME8765643433) #no14 444,13,13 prontera,151,135,4 duplicate(NPC_UNIQUE_NAME8765643433) #no15 444,13,13 prontera,151,137,4 duplicate(NPC_UNIQUE_NAME8765643433) #no16 444,13,13 prontera,151,139,4 duplicate(NPC_UNIQUE_NAME8765643433) #no17 444,13,13 prontera,151,141,4 duplicate(NPC_UNIQUE_NAME8765643433) #no18 444,13,13 prontera,151,143,4 duplicate(NPC_UNIQUE_NAME8765643433) #no19 444,13,13
  24. sader1992

    @whosell

    try this /*========================================== * @whosell - List who is vending the item (amount, price, and location). * revamped by VoidLess, original by zephyrus_cr *------------------------------------------*/ ACMD_FUNC(whosell) { char item_name[100]; int item_id = 0, j, count = 0, sat_num = 0; int s_type = 1; // search bitmask: 0-name,1-id, 2-card, 4-refine int refine = 0,card_id = 0; bool flag = 1; // place dot on the minimap? struct map_session_data* pl_sd; struct s_mapiterator* iter; unsigned int MinPrice = battle_config.vending_max_value, MaxPrice = 0; struct item_data *item_data; static char atcmd_output[CHAT_SIZE_MAX]; if (!*message) { clif_displaymessage(fd, "Use: @whosell <item_id> or @whosell <name>"); return -1; } if (sscanf(message, "+%d %d[%d]", &refine, &item_id, &card_id) == 3){ s_type = 1+2+4; } else if (sscanf(message, "+%d %d", &refine, &item_id) == 2){ s_type = 1+4; } else if (sscanf(message, "+%d [%d]", &refine, &card_id) == 2){ s_type = 2+4; } else if (sscanf(message, "%d[%d]", &item_id, &card_id) == 2){ s_type = 1+2; } else if (sscanf(message, "[%d]", &card_id) == 1){ s_type = 2; } else if (sscanf(message, "+%d", &refine) == 1){ s_type = 4; } else if (sscanf(message, "%d", &item_id) == 1 && item_id == atoi(message)){ s_type = 1; } else if (sscanf(message, "%99[^\n]", item_name) == 1){ s_type = 1; if ((item_data = itemdb_searchname(item_name)) == NULL){ clif_displaymessage(fd, "Not found item with this name"); return -1; } item_id = item_data->nameid; } else { clif_displaymessage(fd, "Use: @whosell <item_id> or @whosell <name>"); return -1; } //check card if(s_type & 2 && ((item_data = itemdb_exists(card_id)) == NULL || item_data->type != IT_CARD)){ clif_displaymessage(fd, "Not found a card with than ID"); return -1; } //check item if(s_type & 1 && (item_data = itemdb_exists(item_id)) == NULL){ clif_displaymessage(fd, "Not found an item with than ID"); return -1; } //check refine if(s_type & 4){ if (refine<0 || refine>10){ clif_displaymessage(fd, "Refine out of bounds: 0 - 10"); return -1; } /*if(item_data->type != IT_WEAPON && item_data->type != IT_ARMOR){ clif_displaymessage(fd, "Use refine only with weapon or armor"); return -1; }*/ } iter = mapit_getallusers(); for (pl_sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); pl_sd = (TBL_PC*)mapit_next(iter)) { if (pl_sd->vender_id ) { // check if player is vending for (j = 0; j < pl_sd->vend_num; j++) { if ((item_data = itemdb_exists(pl_sd->cart.u.items_cart[pl_sd->vending[j].index].nameid)) == NULL) continue; if(s_type & 1 && pl_sd->cart.u.items_cart[pl_sd->vending[j].index].nameid != item_id) continue; if(s_type & 2 && ((item_data->type != IT_ARMOR && item_data->type != IT_WEAPON) || (pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[0] != card_id && pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[1] != card_id && pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[2] != card_id && pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[3] != card_id))) continue; if(s_type & 4 && ((item_data->type != IT_ARMOR && item_data->type != IT_WEAPON) || pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine != refine)) continue; if(item_data->type == IT_ARMOR) snprintf(atcmd_output, CHAT_SIZE_MAX, "+%d %s[%d] | Price %ud | Amount %d | %s[%d,%d] | %s",pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine ,item_data->jname ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[0] ,pl_sd->vending[j].value ,pl_sd->vending[j].amount ,mapindex_id2name(pl_sd->mapindex) ,pl_sd->bl.x,pl_sd->bl.y ,pl_sd->message); else if(item_data->type == IT_WEAPON) snprintf(atcmd_output, CHAT_SIZE_MAX, "+%d %s[%d,%d,%d,%d] | Price %ud | Amount %d | %s[%d,%d] | %s",pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine ,item_data->jname ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[0] ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[1] ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[2] ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[3] ,pl_sd->vending[j].value ,pl_sd->vending[j].amount ,mapindex_id2name(pl_sd->mapindex) ,pl_sd->bl.x,pl_sd->bl.y ,pl_sd->message); else snprintf(atcmd_output, CHAT_SIZE_MAX, "%s | Price %ud | Amount %d | %s[%d,%d] | %s",item_data->jname ,pl_sd->vending[j].value ,pl_sd->vending[j].amount ,mapindex_id2name(pl_sd->mapindex) ,pl_sd->bl.x, pl_sd->bl.y ,pl_sd->message); if(pl_sd->vending[j].value < MinPrice) MinPrice = pl_sd->vending[j].value; if(pl_sd->vending[j].value > MaxPrice) MaxPrice = pl_sd->vending[j].value; clif_displaymessage(fd, atcmd_output); count++; flag = 1; } if (flag && pl_sd->mapindex == sd->mapindex) { clif_viewpoint(sd, 1, 1, pl_sd->bl.x, pl_sd->bl.y, ++sat_num, 0xFFFFFF); flag = 0; } } } mapit_free(iter); if(count > 0) { snprintf(atcmd_output, CHAT_SIZE_MAX, "================== Found %d entries. ==================", count, MinPrice, MaxPrice); clif_displaymessage(fd, atcmd_output); } else clif_displaymessage(fd, "Nobody is selling it now."); return 0; }
×
×
  • Create New...