Jump to content

Emistry

Forum Moderator
  • Posts

    9,610
  • Joined

  • Days Won

    272

Everything posted by Emistry

  1. - script hourly_point_main -1,{ OnInit: .npc_name$ = strnpcinfo(3); bindatcmd "check",.npc_name$+"::OnAtcommand"; end; OnAtcommand: dispbottom "Accumulated "+#daily_minute_count; end; OnUpdate: if (checkvending()) { dispbottom "Hourly point stopped due to vending."; end; } #daily_minute_count++; deltimer .npc_name$+"::OnUpdate"; switch ( #daily_minute_count ) { default: break; case 60: // 60 minutes #CASHPOINT += 1; getitem 677,1; break; case 120: // 120 minutes #CASHPOINT += 1; getitem 677,1; break; case 180: // 180 minutes #CASHPOINT += 1; getitem 677,1; break; case 240: // 240 minutes #CASHPOINT += 1; getitem 677,1; break; case 300: // 300 minutes #CASHPOINT += 1; getitem 677,1; break; case 360: // 360 minutes #CASHPOINT += 1; getitem 677,1; break; case 420: // 420 minutes #CASHPOINT += 1; getitem 677,1; break; case 480: // 480 minutes #CASHPOINT += 1; getitem 677,1; #daily_minute_count = 0; // reset. break; } OnPCLoginEvent: addtimer ( 60 * 1000 ), .npc_name$+"::OnUpdate"; end; }
  2. EquipScript: | addtimer (60 * 1000), "Sample::OnUpdate"; UnEquipScript: | deltimer "Sample::OnUpdate"; - script Sample -1,{ OnUpdate: if (checkvending()) { dispbottom "Hourly Point stopped due to vending."; } else if (checkchatting()) { dispbottom "Hourly Point stopped due to chatroom."; } else if (checkidle() >= 60) { // idled for 60 seconds dispbottom "Hourly Point stopped due to idle."; } else { #hourly_point_duration++; if (#hourly_point_duration >= 60) { #hourly_point++; dispbottom "Hourly Point +1. Total "+#hourly_point+" Points."; } addtimer (60 * 1000), strnpcinfo(3)+"::OnSample"; } end; }
  3. - Id: 501 AegisName: Red_Potion Type: Healing Script: | callfunc("F_SignedItem", 501, IG_Taming); function script F_SignedItem { [email protected]_id = getarg(0, 0); [email protected] = getarg(1, 0); if ([email protected]_id && [email protected]) { getinventorylist; for ([email protected] = 0; [email protected] < @inventorylist_count; [email protected]++) { if (@inventorylist_id[[email protected]] == [email protected]_id && @inventorylist_card3[[email protected]] && @inventorylist_card4[[email protected]]) { [email protected]_cid = (@inventorylist_card3[[email protected]] | (@inventorylist_card4[[email protected]] << 0x10)); query_sql("SELECT `name` FROM `char` WHERE `char_id` = "[email protected]_cid, [email protected]_name$); [email protected]_name$ = getitemname([email protected]_id); if ([email protected]_name$ != "") [email protected]_name$ = [email protected]_name$+"'s " + [email protected]_name$; [email protected]_name$[[email protected]] = [email protected]_name$; [email protected]$ = [email protected]$ + [email protected]_name$; } [email protected]$ += ":"; } [email protected] = select([email protected]$) - 1; delitem2 @inventorylist_id[[email protected]],1,@inventorylist_identify[[email protected]],@inventorylist_refine[[email protected]],@inventorylist_attribute[[email protected]],@inventorylist_card1[[email protected]],@inventorylist_card2[[email protected]],@inventorylist_card3[[email protected]],@inventorylist_card4[[email protected]]; [email protected]_id = groupranditem([email protected]); getitem [email protected]_id, 1; announce "["+strcharinfo(0)+"] has obtained "+getitemname([email protected]_id)+" from ["[email protected]_name$[[email protected]]+"'s "+getitemname([email protected]_id)+"]!!!", bc_all; } return; } you can try something like this.
  4. you may still able to download some of the oldschool hexed clients from 2005 ~ 2010 here. https://web.archive.org/web/20170106031705/http://svn.games-service.net/
  5. if (getmapxy(@mapname$,@mapx,@mapy,0) == -1) goto L_Finish; change to if (getmapxy(@mapname$, @mapx, @mapy, BL_PC) == -1) goto L_Finish;
  6. - script atcmd_example -1,{ OnInit: bindatcmd "killcount", strnpcinfo(3) + "::OnAtcommand"; end; OnAtcommand: if (compare([email protected]_parameters$, "reset")) { #killcount_mob_id = 0; #killcount_amount = 0; dispbottom [email protected]_command$+" reset successfully."; } else if (getmonsterinfo(atoi([email protected]_parameters$), MOB_NAME) != "null") { [email protected]_mob_id = atoi([email protected]_parameters$); if ([email protected]_mob_id != #killcount_mob_id) { #killcount_mob_id = [email protected]_mob_id; #killcount_amount = 0; dispbottom [email protected]_command$+" will start count "+getmonsterinfo(#killcount_mob_id, MOB_NAME)+"."; } } else if (#killcount_mob_id) { dispbottom getmonsterinfo(#killcount_mob_id, MOB_NAME)+" Kill: "+F_InsertComma(#killcount_amount); } else { dispbottom [email protected]_command$+" failed. Usage: "[email protected]_command$+" <mob_id/reset>"; } end; OnNPCKillEvent: if (killedrid == #killcount_mob_id) { #killcount_amount++; dispbottom getmonsterinfo(#killcount_mob_id, MOB_NAME)+" Kill: "+F_InsertComma(#killcount_amount); } end; }
  7. if([email protected] > 3) { dispbottom "Sorry, only 3 IDs with same Unique ID are allowed on this map."; sleep2 500; dispbottom "Warping you back to Savepoint now..."; sleep2 1000; warp "SavePoint",0,0; }
  8. OnNPCKillEvent: if (getgmlevel() >= .gm ) end; // If gm = event wont happen if ( getmonsterinfo( killedrid, MOB_MVPEXP )) { for ([email protected] = 0; [email protected] < getarraysize(.t_maps$); [email protected]++) { if ( strcharinfo(3) == instance_mapname("06guild_01") ) end; if ( strcharinfo(3) == instance_mapname("force_1-1") ) end; if ( strcharinfo(3) == .t_maps$[[email protected]]) { if (rand(100) < .chance) getitem .s_rwd[0], .s_rwd[1]; announce "[ System ] : Player ["+ strcharinfo(0) +"] has killed "+ getmonsterinfo( killedrid, MOB_NAME ) +" alone at "+ strcharinfo(3), bc_all; MVPKills = MVPKills+1; dispbottom "---------------------------------------------------"; dispbottom "You killed a total of "+MVPKills+" MVP"+((MVPKills == 1)?"":"s")+"."; dispbottom "---------------------------------------------------"; end; } } end; }
  9. https://rathena.org/board/topic/105789-utility-sql-job-changer/
  10. 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.
  11. setarray [email protected]_item_list, 450086, 450087, 45088; if (inarray([email protected]_item_list, getequipid([email protected])) == -1) { emotion ET_OTL; mes "[Refine Master]"; mes "Oh, I'm sorry."; mes "This item is impossible to refine."; close; }
  12. atcommand "@petrename "[email protected]$; use this instead. if you are using the SQL method above, your char need to be disconnected from server before the SQL query is executed to update the server, otherwise your current character data will override the changes when it saved into database upon logout.
  13. set the max refine value to 9 instead of 10.
  14. open up the map using GRF Editor, then you can easily find out what files you are missing.
  15. i am sure you can find tons of guide to resolve your policy requirements by searching the internet. ex: https://ostechnix.com/fix-mysql-error-1819-hy000-your-password-does-not-satisfy-the-current-policy-requirements/ CREATE USER 'ragnarok'@'localhost' IDENTIFIED BY 'YOUR_PASSWORD'; GRANT ALL PRIVILEGES ON ragnarok.* to 'ragnarok'@'%' IDENTIFIED BY 'YOUR_PASSWORD'; the IDENTIFIED BY is refer for your password.
  16. 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); }
  17. your Event_LMS script only assign mapflag, doesn't support assigning extra parameter for mapflag. Hence it wont work with the way you doing it. setmapflag "sec_pri", MF_RESTRICTED, 2; setmapflag "06guild_01", MF_RESTRICTED, 2; or sec_pri mapflag restricted 2 06guild_01 mapflag restricted 2 these would work.
  18. 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
  19. try byako,83,154,4 script Who's Online Event 99,{ mes "[Who's Online Event]"; if (getgroupid() < 99) { mes "Only GM's are allowed to use this NPC."; } else { mes "Enable event?"; if (select("Yes", "No") == 1) { mes "Event started."; donpcevent strnpcinfo(3)+"::OnStart"; } } close; OnHour00: OnHour03: OnHour06: OnHour09: OnHour12: OnHour15: OnHour18: OnHour21: OnStart: do { query_sql "select `account_id`, `name` from `char` where online = 1 order by rand() limit 1", [email protected], [email protected]$; attachrid [email protected]; } while (checkvending() || getgroupid() >= 2 || inarray(.map$, strcharinfo(3)) == -1); announce strcharinfo(0) +" won 1 Lucky Pick Box in Exiled Lucky Pick", bc_all, 0x00FF00; getitem 50043,1; end; OnInit: setarray .map$, "prontera", "izlude", "payon"; end; }
  20. try - script Sample -1,{ OnInit: .max_limit = 1; setarray .castles$[0], "prtg_cas01","prtg_cas02","prtg_cas03","prtg_cas04","prtg_cas05", "payg_cas01","payg_cas02","payg_cas03","payg_cas04","payg_cas05", "gefg_cas01","gefg_cas02","gefg_cas03","gefg_cas04","gefg_cas05", "aldeg_cas01","aldeg_cas02","aldeg_cas03","aldeg_cas04","aldeg_cas05", "arug_cas01","arug_cas02","arug_cas03","arug_cas04","arug_cas05", "schg_cas01","schg_cas02","schg_cas03","schg_cas04","schg_cas05"; .castle_size = getarraysize(.castles$); for ([email protected] = 0; [email protected] < .castle_size; [email protected]++) setmapflag .castles$[[email protected]], mf_loadevent; end; OnPCLoadMapEvent: [email protected]$ = strcharinfo(3) if (inarray(.castles$, [email protected]$) != -1) { [email protected]_id = getcharid(2); if ([email protected]_id) { for ([email protected] = 0; [email protected] < .castle_size && [email protected]_count < .max_limit; [email protected]++) { if ([email protected]$ != .castles$[[email protected]] && [email protected]_id == getcastledata(.castles$[[email protected]], CD_GUILD_ID)) [email protected]_count++; } getguildmember [email protected], 1; getguildmember [email protected], 2; if ([email protected]_count >= .max_limit) { for ([email protected] = 0; [email protected] < [email protected]; [email protected]++) { if (isloggedin([email protected][[email protected]], [email protected][[email protected]])) { if (attachrid([email protected][[email protected]])) { if (strcharinfo(3) == [email protected]$) { dispbottom "There can only be "+.max_limit+" Knight per guild members inside a castle during woe."; warp "SavePoint", 0, 0; } detachrid; } } } } } } end; }
  21. https://rathena.org/board/topic/128705-woe-job-count-limit-updated/#comment-400262
  22. when you warp into the room, reset the initial count #count = 0; when they killed the Emperium, #count++; if (#count == 1) [email protected] = 11; else if (#count == 2) [email protected] = 10; query_sql("INSERT INTO `breaker_ladder` SET `char_id` = "+getcharid(0)+", `count` = 1 ON DUPLICATE KEY UPDATE `count` = `count` + "[email protected]);
  23. if (rand(100) < 10) { 10% } if (rand(100) < 20) { 20% }
  24. also can try this https://rathena.org/board/topic/124827-utility-analyzeitem-count-item-in-your-server/
×
×
  • Create New...

Important Information

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