Jump to content

sader1992

Content Moderator
  • Posts

    1691
  • Joined

  • Last visited

  • Days Won

    77

Everything posted by sader1992

  1. 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 ---------------------------------------
  2. both scripts have the same source , but they are not the same.
  3. it could be useful for who don't have FluxCP but i would really suggest using FluxCP instead
  4. FluxCP/config/application.php LINE 54
  5. 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; } } }
  6. if (.@index != -1 && strcharinfo(3) == .map$[.@index] ) {
  7. i would suggest using this https://github.com/rathena/rathena/blob/master/npc/custom/etc/autopot.txt no need for src edit
  8. https://github.com/rathena/rathena/blob/9124d5600f2b4a99bbfa6e5b54131d18dfe8ac48/doc/item_group.txt#L41 make clean server
  9. 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
  10. 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; }
  11. well , it's better to say what is the problem even if you don't get an error
  12. copy your rAthena folder from your host , and read any guide on how to install rAthena offline , and use your folder instead from git for the sql , you can export it from your online database , and use it offline there is no real short answer to that , you just need to follow a guide using your pre-made files and databases
  13. why up ? it's a problem from 2014 do you have the same problem ?
  14. you need to add information on the topic don't take it so personally , but there is no different between your topic or something like (create a topic titled "server error" and the body is "read the title") you are free to open a new topic with full information about what the errors/your setting are
  15. GroupID,ItemID,Rate{,Amount,Random,isAnnounced,Duration,GUID,isBound,isNamed} doc: https://github.com/rathena/rathena/blob/master/doc/item_group.txt ref: https://github.com/rathena/rathena/blob/master/db/pre-re/item_giftbox.txt
  16. there is no fully functioning C# read/write grf library as i am aware i would suggest you start from that searching for one or making one , if you could do this , the rest would be easy this might help you https://github.com/arminherling/GRF
  17. please stay cool and don't go off-topic stay on the topic or we would be forced to lock this post if you found your answer , please mark it as an answer and if you have another question , open a new topic with that question if it's a personal question , you can ask the person in the private messages if he agree to contact you (i am talking about all who are moving off-topic)
  18. try this prontera,0,0,0 script daily_warper 444,{ if(LASTENTERTIME > gettimetick(2)){ mes "you can enter once every 24hr"; mes "come back after " + gettimestr("%Y-%m/%d %H:%M:%S",21,LASTENTERTIME); end; } LASTENTERTIME = gettimetick(2) + (60*60*24); warp "payon",0,0; end; }
  19. technically this script wont work i would suggest to not use .@var with addrid command
  20. - script MvP_Kill -1,{ OnNPCKillEvent: .@checkmvp = compare(.MvPID$,""+killedrid); if( .@checkmvp ) { if( !.Chance || (.Chance && .Chance > rand(10000)) ) if(.limit > .limit_drop){ getitem .Reward, 1; .limit_drop++; } } end; OnClock0000: .limit_drop = 0; end; OnInit: .limit = 100; //100 drop per day .Chance = 1000; // 1000 = 10%, 0 = turn off chance drop mode, 100% drop .MvPID$ = "1511,1734,1492,1647,1785,1630,1399,1039,1874,"+ "1251,2068,1272,1719,1046,1389,1112,1115,1957,1418,1871,1252,1768,"+ "1086,1688,1646,1373,1147,1059,1150,1956,2022,1087,"+ "1190,1038,1157,1159,1502,1623,1650,1583,"+ "1708,1312,1751,1685,1648,1917,1658"; // MvP Ids .Reward = 7227; // Reward Item ID end; }
  21. i uploaded a new version , so it's in the approval process it will be available soon
  22. make sure the packet version is current make sure the ports are open make sure the ip of each program like this conf/import/char_conf.txt login_ip: 127.0.0.1 char_ip: public_ip conf/import/map_conf.txt char_ip: 127.0.0.1 map_ip: public_ip make sure to check your clientinfo xml file check your subnet config and
  23. unfortunately , i can't understand the script above try this , no need for the functions i linked above prontera,0,0,0 script qqqqqq 444,{ //to prevent spamming sql requests >>>> //this will reset on the user login, but no problem with that if(!@reward_for_first_50) @reward_for_first_50 = true; else{ mes "didn't you talk to me like a moment ago ?"; end; } //<<<<<<<<<<<<<<<<<<<<<<<<<<<< query_logsql("SELECT `ip`,`unique_id` FROM `reward_for_first_50` ", .@ip$, .@unique_id$); for(.@i=0;.@i<getarraysize(.@ip$);.@i++){ if(getcharip() == .@ip$[.@i]) .@got = true; } for(.@i=0;.@i<getarraysize(.@unique_id$);.@i++){ if(get_unique_id() == .@unique_id$[.@i]) .@got = true; } if(!.@got){ if($REWARDS1 < 50){ //the rewards here! //------------ getitem 502,1; //------------ query_logsql("INSERT INTO `reward_for_first_50` (`ip`,`unique_id`) VALUES ('" + getcharip() + "','" + get_unique_id() + "')"); $REWARDS1++; mes "you got the reward"; end; } mes "you missed the reward";//50 player already got the reward end; } mes "you already got the reward"; end; OnInit: query_logsql("CREATE TABLE IF NOT EXISTS `reward_for_first_50` (`ip` varchar(100) NOT NULL default '',`unique_id` INT( 11 ) UNSIGNED NOT NULL DEFAULT '0') ENGINE=MyISAM"); end; } but i would suggest that you remove the npc when you are done with it. i am not sure what this npc does but at least the first 2 lines are like this - script VIP GRATIS -1,{ OnTouch: if(gepard_int_get("newbie_reward")) end; //the player already have newbie_reward true , so end the script here. gepard_int_set("newbie_reward",true); //the player does not have newbie_reward true , so set it to true and move on with the script. query_sql "UPDATE `login` SET `diasvip` = `diasvip`+'1', `level` = '1' WHERE `account_id` = '"+getcharid(3)+"'"; dispbottom "Você acaba de ganhar vip grátis."; end; }
×
×
  • Create New...