Jump to content

Emistry

Forum Moderator
  • Posts

    9,610
  • Joined

  • Days Won

    272

Community Answers

  1. Emistry's post in Enchanced itemshower was marked as the answer   
    bindatcmd "shower",strnpcinfo(3)+"::OnShower", 99;
  2. Emistry's post in MVPRespown was marked as the answer   
    [email protected]$ = "prontera"; ex: always spawn on prontera.
  3. Emistry's post in Quest Shop with +10 Weapon / EQs was marked as the answer   
    sell it as a custom item box.
    add the item box into the quest shop
    add the script that give refined item into the item_db
  4. Emistry's post in H> Last Man Standing was marked as the answer   
    change all 
    getmapxy([email protected]$,[email protected],[email protected],0); into
    getmapxy([email protected]$,[email protected],[email protected],BL_PC); always read the latest rAthena changelog after you updated the server revisions.
  5. Emistry's post in how to save higher value to Table rank was marked as the answer   
    total kill count per session?
    when you warp into the room, reset the initial count
    @total_emperium_count = 0; when they killed the Emperium,
    @total_emperium_count++; if (@total_emperium_count > #count) { #count = @total_emperium_count; query_sql("INSERT INTO `breaker_ladder` SET `char_id` = "+getcharid(0)+", `count` = 1 ON DUPLICATE KEY UPDATE `count` = "+#count); }  
  6. Emistry's post in Pots Converter random stuck was marked as the answer   
    vip_lounge,157,139,4 script Potion Converter 100,{ mes "Hi! I can convert your potions to your choice."; mes "Select which item you want to exchange."; next; switch(select("Segen White Potion 2x->Segen Blue Potion 1x:Segen Blue Potion 2x->Segen White Potion 1x:Siege White Potion 2x->Siege Blue Potion1x:Siege Blue Potion2x->Siege White Potion1x:Close")) { case 1: mes "How much?"; input [email protected], 1, 30000; if(countitem(11503) >= [email protected]) { delitem 11503, [email protected]; getitem 11504, [email protected]/2; } else if (([email protected]) > 50){ mes "Hmmmm... it seems you are overweight"; } else if(countitem(11503) < [email protected]) { mes "Sorry You don't have the required item!"; } break; case 2: mes "How much?"; input [email protected], 1, 30000; if(countitem(11504) >= [email protected]) { delitem 11504, [email protected]; getitem 11503, [email protected]/2; } else if (([email protected]) > 50){ mes "Hmmmm... it seems you are overweight"; } else if(countitem(11504) < [email protected]) { mes "Sorry You don't have the required item!"; } break; case 3: mes "How much?"; input [email protected], 1, 30000; if(countitem(32007) >= [email protected]) { delitem 32007, [email protected]; getitem 32008, [email protected]/2; } else if (([email protected]) > 50){ mes "Hmmmm... it seems you are overweight"; } else if(countitem(32007) < [email protected]) { mes "Sorry You don't have the required item!"; } break; case 4: mes "How much?"; input [email protected], 1, 30000; if(countitem(32008) >= [email protected]) { delitem 32008, [email protected]; getitem 32007, [email protected]/2; } else if (([email protected]) > 50){ mes "Hmmmm... it seems you are overweight"; } else if(countitem(32008) < [email protected]) { mes "Sorry You don't have the required item!"; } default: break; } close; OnInit: waitingroom "Convert pots here",0; end; } just add a default minimum value to the input or add a checking to validate the minimum input amount.
  7. Emistry's post in How to add IP Checker on this script was marked as the answer   
    offtopic:
    tbh, everyone is relying too much on the 3rd party tools data without realize that getitembound or bounded/untradeble items would have been your perfect solution to prevent any abusive behavior to redeem the rewards.
  8. Emistry's post in Fenugreek announcer was marked as the answer   
    prontera,155,181,5 script Sample 757,{ announce "Sample message", bc_all; end; }  
  9. Emistry's post in bg_monster not working was marked as the answer   
    your groups id are different than the value that stored in the variable
    [email protected]_id1  
  10. Emistry's post in How can fix Access denied for user 'ragnarok'@'localhost' (using password: YES) was marked as the answer   
    make sure you are connecting using the correct username/password.
    and granted access to the database.
    CREATE USER 'ragnarok'@'localhost' IDENTIFIED BY 'ragnarok'; GRANT ALL PRIVILEGES ON ragnarok.* to 'ragnarok'@'%' IDENTIFIED BY 'ragnarok'; https://github.com/rathena/rathena/wiki/Install-MySQL
  11. Emistry's post in Bard healing npc. was marked as the answer   
    the skill required a source target that use the skill, I dont think the NPC can actually cast the skill for you to display the effect.
    However, you can still create a similar result by duplicating some NPC which will display and hold the effect, since the effect required a immobile npc object to stick to it.
    prontera,150,180,4 script Bard 51,14,14,{ end; OnInit: .range = 5; .hp_healing_rate = 3; .sp_healing_rate = 3; getmapxy(.npc_map$, .npc_x, .npc_y, BL_NPC); initnpctimer; [email protected]_count = 0; for ([email protected] = (.npc_x - .range); [email protected] <= (.npc_x + .range); [email protected] += 2) { for ([email protected] = (.npc_y - .range); [email protected] <= (.npc_y + .range); [email protected] += 2) { [email protected]_count++; movenpc "Bard#effect_" + [email protected]_count, [email protected], [email protected]; } } end; OnTouch_: donpcevent "::OnIdunActivate"; playBGMall "57",.npc_map$,(.npc_x - .range),(.npc_y - .range),(.npc_x + .range),(.npc_y + .range); // Don't Cry Baby end; OnTimer3000: initnpctimer; areapercentheal .npc_map$,(.npc_x - .range),(.npc_y - .range),(.npc_x + .range),(.npc_y + .range), .hp_healing_rate, .sp_healing_rate; addrid(4, 0, (.npc_x - .range),(.npc_y - .range),(.npc_x + .range),(.npc_y + .range)); if (Hp < MaxHp) { [email protected] = ((MaxHp * 100) / .hp_healing_rate); skilleffect "AL_HEAL", [email protected]; } end; } - script Bard#effect -1,{ end; OnIdunActivate: misceffect EF_BOTTOM_APPLEIDUN; end; } // add more if you enlarge the effect area. prontera,1,1,4 duplicate(Bard#effect) Bard#effect_1 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_2 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_3 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_4 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_5 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_6 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_7 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_8 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_9 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_10 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_11 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_12 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_13 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_14 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_15 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_16 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_17 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_18 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_19 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_20 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_21 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_22 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_23 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_24 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_25 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_26 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_27 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_28 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_29 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_30 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_31 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_32 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_33 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_34 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_35 139 prontera,1,1,4 duplicate(Bard#effect) Bard#effect_36 139 https://imgur.com/aWiDtTb

  12. Emistry's post in Hunting Mission Need to Add Zeny reward to 500K was marked as the answer   
    change
    [email protected] = #Mission_Count * .Quests * [email protected][[email protected]] * .Modifier[2]; to
    [email protected] = 500000;  
  13. Emistry's post in level and class check on freebies script was marked as the answer   
    try
    prontera,244,55,4 script Freebies 718,{ while (.rewardable_jobs[[email protected]] != Class && [email protected] < .rewardable_jobs_size) [email protected]++; if ([email protected] >= .rewardable_jobs_size) { mes "Your job class aren't eligible."; } else if (BaseLevel < .max_base || JobLevel < .max_job) { mes "Required "+.max_base+"/"+.max_job+"."; } else if (#Freebies) { mes "You have claimed the Reward already."; } else { #Freebies = 1; mes "Welcome to MyServerNameHere, Here are your start items!"; mes "You only get this once for each account!"; getitembound 31957,2,1; } close; OnInit: .max_base = 99; .max_job = 50; setarray .rewardable_jobs, Job_Knight, Job_Alchemist, Job_Assassin, Job_Bard, Job_Blacksmith, Job_Crusader, Job_Dancer, Job_Hunter, Job_Monk, Job_Priest, Job_Rogue, Job_Sage, Job_Wizard; .rewardable_jobs_size = getarraysize(.rewardable_jobs); end;  
  14. Emistry's post in Script that make you big when transformed was marked as the answer   
    autobonus "{ callfunc "F_BlackKingBar"; }",500,10000,BF_WEAPON; function script F_BlackKingBar { atcommand "@effect 123456"; // TODO: change to enlarge effect. sleep2 10000; atcommand "@effect 123456"; // TODO: repeat to end the effect. end; } i don't remember which effect allow user to growth in size. find the id and change it.
  15. Emistry's post in Event that occurs randomly twice a day was marked as the answer   
    OnInit: OnHour00: .rand_time_1 = rand(0, 11); .rand_time_2 = rand(12, 23); OnMinute00: if (gettime(DT_HOUR) == .rand_time_1 || gettime(DT_HOUR) == .rand_time_2) { // scripts. } end;  
  16. Emistry's post in Event to Trigger Two Times in Random Times was marked as the answer   
    OnInit: OnHour00: .rand_time_1 = rand(0, 11); .rand_time_2 = rand(12, 23); OnMinute00: if (gettime(DT_HOUR) == .rand_time_1 || gettime(DT_HOUR) == .rand_time_2) { // scripts. } end;  
  17. Emistry's post in loadevent mapflag event its not listed on the map list was marked as the answer   
    you have other NPC script that added the loadevent mapflag at payon map.
    all OnPCLoadMapEvent script should add extra map checking to avoid it trigger unnecessary event which come from other NPC scripts.
    It is a global event which will trigger all NPC that has this event label.
  18. Emistry's post in How do I change this script so it shows a dispbottom if the player has a particular variable? was marked as the answer   
    you can try something like this.
    - script #mvp_kill -1,{ OnInit: setarray .p_rwd, 607,1; // Party reward <item>,<amount> setarray .s_rwd, 607,1; // Solo reward <item>,<amount> .chance = 50; // Drop rate chances % // .gm = 10; // Prevents gm level and above to trigger the event // MVP Map list setarray .t_maps$[0],"moc_pryd06","lhz_dun03","gld2_prt","abbey02","ayo_dun02","lhz_dun04","ra_fild02","xmas_fild01","dic_dun02","beach_dun","iz_dun05","tur_dun04","lhz_dun02","jupe_core","moc_fild22","anthell02","odin_tem03","gon_dun03","gef_fild02","thana_boss","gef_fild10","ein_dun02","gef_fild14","moc_pryd04","dew_dun01","in_sphinx5","niflheim","moc_fild17","xmas_dun02","ice_dun03","kh_dun02","treasure02","moc_prydn2","pay_dun04","ra_san05","mosk_dun03","ama_dun03","thor_v03","gef_dun01","mjolnir_04","abyss_03","dic_dun03","prt_sewb4","pay_fild11","gef_dun02","gl_chyard","ra_fild03","ra_fild04","ve_fild01","ve_fild02","lou_dun03","prt_maze03","bra_dun02"; .t_maps_size = getarraysize(.t_maps$); end; OnNPCKillEvent: //if (getgmlevel() >= .gm) end; // If gm = event wont happen if (strcharinfo(3) == instance_mapname("06guild_01") || strcharinfo(3) == instance_mapname("force_1-1")) end; if (getmonsterinfo(killedrid, MOB_MVPEXP)) { for ([email protected] = 0; [email protected] < .t_maps_size; [email protected]++) { if (strcharinfo(3) == .t_maps$[[email protected]]) { if (getcharid(1)) { getpartymember getcharid(1), 1; getpartymember getcharid(1), 2; for ([email protected] = 0; [email protected] < [email protected]; [email protected]++) { if (isloggedin([email protected][[email protected]], [email protected][[email protected]])) { [email protected][[email protected]] = [email protected][[email protected]]; [email protected]++; } } if (rand(100) < .chance) getitem .p_rwd[0], .p_rwd[1], [email protected][ rand([email protected]) ]; [email protected]_message$ = "[ System ] : Player ["+ strcharinfo(0) +"] of party ["+ strcharinfo(1) +"] has killed "+ getmonsterinfo(killedrid, MOB_NAME) +" at "+ strcharinfo(3); } else { if (rand(100) < .chance) getitem .s_rwd[0], .s_rwd[1]; [email protected]_message$ = "[ System ] : Player ["+ strcharinfo(0) +"] has killed "+ getmonsterinfo(killedrid, MOB_NAME) +" alone at "+ strcharinfo(3); } MVPKills = MVPKills+1; dispbottom "---------------------------------------------------"; dispbottom "You killed a total of "+MVPKills+" MVP"+((MVPKills == 1)?"":"s")+"."; dispbottom "---------------------------------------------------"; } } addrid(0); if (#mvpon) { dispbottom [email protected]_message$; } } end; } or
    - script #mvp_kill -1,{ OnInit: setarray .p_rwd, 607,1; // Party reward <item>,<amount> setarray .s_rwd, 607,1; // Solo reward <item>,<amount> .chance = 50; // Drop rate chances % // .gm = 10; // Prevents gm level and above to trigger the event // MVP Map list setarray .t_maps$[0],"moc_pryd06","lhz_dun03","gld2_prt","abbey02","ayo_dun02","lhz_dun04","ra_fild02","xmas_fild01","dic_dun02","beach_dun","iz_dun05","tur_dun04","lhz_dun02","jupe_core","moc_fild22","anthell02","odin_tem03","gon_dun03","gef_fild02","thana_boss","gef_fild10","ein_dun02","gef_fild14","moc_pryd04","dew_dun01","in_sphinx5","niflheim","moc_fild17","xmas_dun02","ice_dun03","kh_dun02","treasure02","moc_prydn2","pay_dun04","ra_san05","mosk_dun03","ama_dun03","thor_v03","gef_dun01","mjolnir_04","abyss_03","dic_dun03","prt_sewb4","pay_fild11","gef_dun02","gl_chyard","ra_fild03","ra_fild04","ve_fild01","ve_fild02","lou_dun03","prt_maze03","bra_dun02"; end; OnNPCKillEvent: //if (getgmlevel() >= .gm) end; // If gm = event wont happen if (strcharinfo(3) == instance_mapname("06guild_01") || strcharinfo(3) == instance_mapname("force_1-1")) end; if (getmonsterinfo(killedrid, MOB_MVPEXP)) { if (inarray(.t_maps$, strcharinfo(3)) != -1) { [email protected]_id = getcharid(1); if ([email protected]_id) { getpartymember [email protected]_id, 1; getpartymember [email protected]_id, 2; for ([email protected] = 0; [email protected] < [email protected]; [email protected]++) { if (isloggedin([email protected][[email protected]], [email protected][[email protected]])) { [email protected][[email protected]] = [email protected][[email protected]]; [email protected]++; } } if (rand(100) < .chance) getitem .p_rwd[0], .p_rwd[1], [email protected][ rand([email protected]) ]; [email protected]_message$ = "[ System ] : Player ["+ strcharinfo(0) +"] of party ["+ strcharinfo(1) +"] has killed "+ getmonsterinfo(killedrid, MOB_NAME) +" at "+ strcharinfo(3); } else { if (rand(100) < .chance) getitem .s_rwd[0], .s_rwd[1]; [email protected]_message$ = "[ System ] : Player ["+ strcharinfo(0) +"] has killed "+ getmonsterinfo(killedrid, MOB_NAME) +" alone at "+ strcharinfo(3); } MVPKills = MVPKills+1; dispbottom "---------------------------------------------------"; dispbottom "You killed a total of "+MVPKills+" MVP"+((MVPKills == 1)?"":"s")+"."; dispbottom "---------------------------------------------------"; addrid(2, 0, [email protected]_id); if (#mvpon) { dispbottom [email protected]_message$; } } } end; }  
  19. Emistry's post in making the NPC hide after woe and unhide 30mins before woe was marked as the answer   
    you can try this.
    - script SupplyTrigger -1,{ OnInit: OnSat1930: OnSun1930: OnAgitEnd: OnAgitEnd2: if (gettime(DT_HOUR) == 19 && gettime(DT_MINUTE) >= 30) { hideoffnpc "Guild Supply#1"; hideoffnpc "Supply#2"; hideoffnpc "Guild Supply#3"; // hideoffnpc "Guild Supply#4"; } else { hideonnpc "Guild Supply#1"; hideonnpc "Supply#2"; hideonnpc "Guild Supply#3"; // hideonnpc "Guild Supply#4"; } end; } as long as the time is between 07:30PM to 07:59PM, the NPC will be enabled.
  20. Emistry's post in SQL Database was marked as the answer   
    your setting isn't configured correctly. conf\inter_athena.conf
    // MySQL Login server login_server_ip: 127.0.0.1 login_server_port: 3306 login_server_id: ragnarok login_server_pw: ragnarok login_server_db: ragnarok login_codepage: login_case_sensitive: no ipban_db_ip: 127.0.0.1 ipban_db_port: 3306 ipban_db_id: ragnarok ipban_db_pw: ragnarok ipban_db_db: ragnarok ipban_codepage: // MySQL Character server char_server_ip: 127.0.0.1 char_server_port: 3306 char_server_id: ragnarok char_server_pw: ragnarok char_server_db: ragnarok // MySQL Map Server map_server_ip: 127.0.0.1 map_server_port: 3306 map_server_id: ragnarok map_server_pw: ragnarok map_server_db: ragnarok // MySQL Log Database log_db_ip: 127.0.0.1 log_db_port: 3306 log_db_id: ragnarok log_db_pw: ragnarok log_db_db: ragnarok log_codepage: log_login_db: loginlog  
  21. Emistry's post in Question about @inventorylist_card[]. was marked as the answer   
    you can also use this to search for the card in a user inventory
    *checkequipedcard(<card id>) This function will return 1 if the card specified by its item ID number is inserted into any equipment they have in their inventory, currently equipped or not.  
  22. Emistry's post in @memo without having Warp skill was marked as the answer   
    https://github.com/rathena/rathena/blob/master/src/map/pc.cpp#L6300-L6305
  23. Emistry's post in Yggdrasil delay was marked as the answer   
    https://github.com/rathena/rathena/blob/master/db/re/item_db_usable.yml#L1154
    remove the delay
  24. Emistry's post in Antibot with problems please help me was marked as the answer   
    when your character are muted, it cant use command or chat.
    try replace the atcommand with these
    sc_start SC_MUTE, 10800000, 0; sc_end SC_MUTE;  
    if you want a better approach, then use the setpcblock instead.
    *setpcblock <type>,<state>{,<account ID>}; *getpcblock {<account ID>}; 'setpcblock' command prevents/allows the player from doing the given <type> of action according to the <state> during the player session (note: @reloadscript removes all <type> except PCBLOCK_IMMUNE). The <type> values are bit-masks, multiples of <type> can be added to change the player action. The action is blocked when the <state> is true, while false allows the action again. 'getpcblock' command return the bit-mask value of the currently enabled block flags. Available <type>: PCBLOCK_MOVE Prevent the player from moving. PCBLOCK_ATTACK Prevent the player from attacking. PCBLOCK_SKILL Prevent the player from using skills/itemskills. PCBLOCK_USEITEM Prevent the player from using usable items. PCBLOCK_CHAT Prevent the player from sending global/guild/party/whisper messages. PCBLOCK_IMMUNE Prevent the player from being hit by monsters. PCBLOCK_SITSTAND Prevent the player from sitting/standing. PCBLOCK_COMMANDS Prevent the player from using atcommands/charcommands. PCBLOCK_NPCCLICK Prevent the player from clicking/touching any NPC/shop/warp. PCBLOCK_EMOTION Prevent the player from using emotions. PCBLOCK_NPC Simulate NPC interaction. Useful for NPC with no mes window. Sum of PCBLOCK_MOVE|PCBLOCK_SKILL|PCBLOCK_USEITEM|PCBLOCK_COMMANDS|PCBLOCK_NPCCLICK. PCBLOCK_ALL Sum of all the flags. Examples: // Make the attached player invulnerable to monster (same as @monsterignore) setpcblock PCBLOCK_IMMUNE, true; // Prevents the attached player from attacking and using skills setpcblock PCBLOCK_ATTACK|PCBLOCK_SKILL, true; // Re-enables attack, skills and item use setpcblock PCBLOCK_ATTACK|PCBLOCK_SKILL|PCBLOCK_USEITEM, false; // getpcblock related checks if (getpcblock() & PCBLOCK_IMMUNE) mes "You are invulnerable!"; if (getpcblock() & (PCBLOCK_MOVE|PCBLOCK_SITSTAND)) mes "You can't walk or sit."; if ((getpcblock() & (PCBLOCK_ATTACK|PCBLOCK_SKILL)) == 0) mes "You can attack and use skills."; if (getpcblock() & PCBLOCK_CHAT) mes "You can't chat.";  
  25. Emistry's post in Warp/Flywing Debuff was marked as the answer   
    https://rathena.org/board/topic/74160-remove-buff-from-gospel-when-enter-a-map/
×
×
  • Create New...

Important Information

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