Jump to content

Emistry

Forum Moderator
  • Posts

    10018
  • Joined

  • Days Won

    408

Everything posted by Emistry

  1. for( set .@party,0; .@party < 2; set .@party,.@party + 1 ){ getpartymember .Team[0],1; for( set .@i,0; .@i < .No; set .@i,.@i + 1 ) warpchar .Map$,0,0,$@partymembercid[.@i]; } change into getpartymember .Team[0],1; for( set .@i,0; .@i < .No; set .@i,.@i + 1 ) warpchar .Map$,0,0,$@partymembercid[.@i]; // <-- edit the coordiate team 1 getpartymember .Team[1],1; for( set .@i,0; .@i < .No; set .@i,.@i + 1 ) warpchar .Map$,0,0,$@partymembercid[.@i]; // <-- edit the coordiate team 2
  2. you could use the timer to create this... playBGM("filename", 0); initnpctimer; OnTimer60000: // set according to your BGM duration playBGM("filename", 0); initnpctimer; end; start the timer when the BGM started, and repeat it once it end.
  3. try a different langtype and make sure your database use the correct encoding to save it.
  4. i dont think currently the emulator could support more than 23 characters.
  5. *bindatcmd "<command>","<NPC object name>::<event label>"{,<atcommand level>,<charcommand level>}; This command will bind a NPC event label to an atcommand. Upon execution of the atcommand, the user will invoke the NPC event label. Each atcommand is only allowed one binding. If you rebind, it will override the original binding. Note: The default level for atcommand is 0 while the default level for charcommand is 100. The following variables are set upon execution: .@atcmd_command$ = The name of the @command used. .@atcmd_parameters$[] = Array containing the given parameters, starting from an index of 0. .@atcmd_numparameters = The number of parameters defined. - script atcmd_example -1,{ OnInit: bindatcmd "mall",strnpcinfo(3) + "::OnAtcommand1"; bindatcmd "quest",strnpcinfo(3) + "::OnAtcommand2"; bindatcmd "dona",strnpcinfo(3) + "::OnAtcommand3"; end; OnAtcommand1: mes "You used "+.@atcmd_command$; close; OnAtcommand2: mes "You used "+.@atcmd_command$; close; OnAtcommand3: mes "You used "+.@atcmd_command$; close; }
  6. users = 100; // extra 100 fake players count
  7. check your lub file. data\luafiles514\lua files\emotion\emotionlist.lub
  8. prontera,155,181,5 script Sample 4_F_KAFRA1,{ getinventorylist(); if (@inventorylist_count > 0) { mes "Please remove all items from your inventory."; close; } CURRENT_CLASS = Class; jobchange Job_Novice; addtimer 5000, strnpcinfo(3)+"::OnUpdate"; warp "prontera", 0, 0; end; OnUpdate: if (strcharinfo(3) == "prontera") { addtimer 5000, strnpcinfo(3)+"::OnUpdate"; } else if (CURRENT_CLASS) { jobchange CURRENT_CLASS; CURRENT_CLASS = 0; } end; }
  9. 1. try this https://pastebin.com/raw/ZL6iPLsJ 2. change set CooldownQuest,gettimetick(2); into set CooldownQuest,gettime(8); change if(gettimetick(2) - CooldownQuest < (60 * 60 * 24)) { next; mes "[ Daily Quest ]"; mes "^FF0000Sorry you have to wait 24 Hours until you can do the Quest again!^000000"; close; } into if(CooldownQuest == gettime(8)) { next; mes "[ Daily Quest ]"; mes "^FF0000Sorry you have to wait 24 Hours until you can do the Quest again!^000000"; close; }
  10. perhaps you didnt apply the commits/source mod correctly? your emulator are calculating wrong average level ...
  11. conf/battle/monster.conf#L187-L192
  12. that's something that up to you to decide and figure out what and how ....
  13. if (.@chance >= .@passrate) { goto sureball_refine; } else { goto fail_refine; } change to if (rand(100) < .@passrate) { goto sureball_refine; } else { goto fail_refine; }
  14. there exists a SQL table named cashlog, maybe you could refer there ...
  15. prontera,150,150,3 script Beta Reward 100,{ mes "[ Beta Reward ]"; if(BaseLevel < 255) { mes "You don't have the required level for Beta Reward."; mes "Come back when you reached it - Base Level 255!"; } else if(getcharid(3) > 2000100) { mes "You're not eligible for rewards"; } else if(#cbtreward == 1) { mes "You already got your reward!"; } else if (#ONLINE_MINUTE < 500) { mes "You need to stay online for next "+(500 - #ONLINE_MINUTE)+" minutes to redeem the rewards!"; } else { getitembound 909,1,Bound_Account; // <-- should be bound if you don't want this to be abused. mes "Here's your reward!"; set #cbtreward,1; } close; OnUpdate: #ONLINE_MINUTE++; OnPCLoginEvent: if (!#cbtreward && #ONLINE_MINUTE < 500) { addtimer (60 * 1000), strnpcinfo(3)+"::OnUpdate"; } end; } try this
  16. - script Sample -1,{ OnInit: .map$ = "prontera"; setmapflag, .map$, mf_loadevent; end; OnPCLoadMapEvent: if (strcharinfo(3) == .map$) { if (getgroupid() <= 0) warp "SavePoint", 0, 0; } end; } using OnPCLoadMapEvent are more appropriate, it triggered everytime you teleport or enter the map.
  17. https://rathena.org/board/topic/114042-how-to-use-signboard/?do=findComment&comment=355449
  18. neko_isle,93,99,4 script PlayerOnline 512,{ query_sql "SELECT `name` , `class` FROM `char` WHERE `online` = '1'", .@name$, .@class; mes "-----------------------------------"; mes "Online Users: " + getusers(1); mes "-----------------------------------"; for( set .@a,0; .@a < getarraysize(.@name$); set .@a,.@a + 1) mes .@name$[.@a]+ " | Job: " +jobname(.@class[.@a]); mes "-----------------------------------"; close; OnInit: OnPCLoginEvent: OnPCLogoutEvent: delwaitingroom; waitingroom "Online Users: " + getusers(1), 0; end; } avoid loop ... use the PC login/logoff event instead.
  19. when you edited anything related with the source code, you need to recompile the server, not restart server, its different action.
  20. - script HHE -1,{ OnInit: set .DefaultBaseRates,getbattleflag("base_exp_rate"); set .DefaultJobRates,getbattleflag("job_exp_rate"); set .Access,80; // GM access lvl OnTimer3600000: // After 1 hour OnStop: stopnpctimer; set .Event,0; callsub(L_Start, .DefaultBaseRates, .DefaultJobRates); end; OnClock1000: OnClock1600: callsub(L_Start, (.DefaultBaseRates * 2), (.DefaultJobRates * 2)); // 2x end; OnWhisperGlobal: if (getgmlevel() < .Access) end; if (@whispervar0$ == "Start") { if (.Event == 1) { dispbottom "Event already started"; } else { dispbottom "Input New Base Rate"; input .@BaseExp; dispbottom "Input New Job Rate"; input .@JobExp; callsub(L_Start, .@BaseExp, .@JobExp); } end; } else if (@whispervar0$ == "Stop") { if (.Event == 1) { donpcevent strnpcinfo(3)+"::OnStop"; } else dispbottom "Event not started."; end; } end; L_Start: .@BaseExp = getarg(0, 1); .@JobExp = getarg(0, 1); if (.@BaseExp < 1) .@BaseExp = 1; if (.@JobExp < 1) .@JobExp = 1; setbattleflag "base_exp_rate",.@BaseExp*100; setbattleflag "job_exp_rate",.@JobExp*100; dispbottom "Event has been started."; initnpctimer; set .Event,1; announce "Happy Hour EXP: Floating rates event started. New rates: Base - "+(.@BaseExp / 100)+"x, Job - "+(.@JobExp / 100)+"x",0; return; }
  21. - script HHE -1,{ OnInit: set .DefaultBaseRates,getbattleflag("base_exp_rate"); set .DefaultJobRates,getbattleflag("job_exp_rate"); set .Access,80; // GM access lvl OnTimer3600000: // After 1 hour OnStop: stopnpctimer; set .Event,0; callsub(L_Start, .DefaultBaseRates, .DefaultJobRates); end; OnClock1000: OnClock1600: callsub(L_Start, 2, 2); // 2x end; OnWhisperGlobal: if (getgmlevel() < .Access) end; if (@whispervar0$ == "Start") { if (.Event == 1) { dispbottom "Event already started"; } else { dispbottom "Input New Base Rate"; input .@BaseExp; dispbottom "Input New Job Rate"; input .@JobExp; callsub(L_Start, .@BaseExp, .@JobExp); } end; } else if (@whispervar0$ == "Stop") { if (.Event == 1) { donpcevent strnpcinfo(3)+"::OnStop"; } else dispbottom "Event not started."; end; } end; L_Start: .@BaseExp = getarg(0, 1); .@JobExp = getarg(0, 1); if (.@BaseExp < 1) .@BaseExp = 1; if (.@JobExp < 1) .@JobExp = 1; setbattleflag "base_exp_rate",.@BaseExp*100; setbattleflag "job_exp_rate",.@JobExp*100; dispbottom "Event has been started."; initnpctimer; set .Event,1; announce "Happy Hour EXP: Floating rates event started. New rates: Base - "+.@BaseExp+"x, Job - "+.@JobExp+"x",0; return; } try
  22. pretty much self explained... MVP - extra MVP Item drops Card-Based - Card (item bonuses) that grant additional item drop upon killed monsters Treasure - Tresure Chest item drops
  23. OnTimer6000000: if (rand(1,6) == 1) { donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; } end; OnTimer6300000: if (rand(1,6) == 2) { donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; } end; OnTimer6600000: if (rand(1,6) == 3) { donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; } end; OnTimer6900000: if (rand(1,6) == 4) { donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; } end; OnTimer7200000: if (rand(1,6) == 5) { donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; } end; OnTimer7500000: if (rand(1,6) == 6) { donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; } end; OnTimer7800000: donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; end; change to OnTimer36000000: donpcevent "summon_boss_lt::OnSummon"; stopnpctimer; end;
  24. - script Sample -1,{ OnInit: setarray .@map_list$, "prtg_cas01", "gefg_cas01", "payg_cas01", "aldeg_cas01", "prtg_cas02", "gefg_cas02", "payg_cas02", "aldeg_cas02", "prtg_cas03", "gefg_cas03", "payg_cas03", "aldeg_cas03", "prtg_cas04", "gefg_cas04", "payg_cas04", "aldeg_cas04", "prtg_cas05", "gefg_cas05", "payg_cas05", "aldeg_cas05"; for (.@i = 0; .@i < .@size; .@i++) setmapflag .@map_list$[.@i], mf_loadevent; end; OnPCLoadMapEvent: if (getmercinfo(0) > 0 && getmapflag(strcharinfo(3), mf_gvg_castle)) { mes "Mercenary aren't allowed in woe."; sleep 3000; warp "SavePoint", 0, 0; } end; } for your warpers and other NPC, add these line. if (getmercinfo(0)) { mes "Mercenary aren't allowed in woe."; close; }
×
×
  • Create New...