Jump to content

TheReturn

Members
  • Content Count

    14
  • Joined

  • Last visited


Reputation Activity

  1. Upvote
    TheReturn reacted to AnnieRuru in How to apply a diff file   
    getting tired of people keep sending me personal message -> how do I apply your koe patch
    after about 6 PMs or so I getting really fed up,
    only then I realize there is no guide to properly teach members how to apply a diff file, so here I make one for you guys
    First step
    A lot of people download hercules in .zip format. This is WRONG.

    instead, follow the proper guide and use tortoisegit (if you are using windows) to download your server
    This is the proper guide on how to install hercules

     
    Question: but I am using rathena, not hercules
    Answer: just change the link into rathena ones
    https://github.com/rathena/rathena/wiki/Install-on-Windows
     
     
    Second step
    after you get your proper server, the first thing you have to do is get rid of your current one
    this is the painful process, because you did not follow the guide
    but on the up side, you can always update your server every week just by Git pull
    which already mentioned in that installation topic guide
    Question: but every time I Git pull, it always ask to resolve conflicts
    Answer: that's the reason hercules community stop providing patch file and transition towards plugin system
    you should always keep your server up to date with the latest revision as we always add new features and bug fix
    nobody on the board like to give support on old emulator
    Question: but rathena doesn't have plugin system
    Answer: yes rathena doesn't support right now, but will be soon in the near future. rathena already slowly transition towards C++ format
     
     
    Third Step
    now you have a .diff file, download the file somewhere, right click on it

    then point the link towards your hercules installation folder
    Apply Patch Serial... Review/apply single patch... if either option doesn't work, try the other
     
     
    Disclaimer:
    I am windows user, so I never use Linux or Centos whatever,
    so this guide is purely meant for those keep bombard my PM box over and over
  2. Upvote
    TheReturn reacted to Habilis in [Event] Wheel of fortune   
    I've recently got a brilliant idea.
    Why not make my own version of a paid script, sold on rAthena
    and release it to Hercules for free!?

    (Not because I'm banned on rAthena )
     
    I need a peer review before releasing the whole package.
     
    @Myriad Did a nice Peer review of my terribel kode...
    If anyone else would like to contribute, feel free.
    Otherwise, it is soon to be released
     
     
    UPD : I reDrew the cutins, they don't look like stolen from rAthena

     

     
     
     
    1) configuration
    there are 2 arrays
        setarray .prize_id[1],-1,31024,31026,31008,31020,31017,31010,31016,0,31009;
        setarray .prize_qty[1],2,1,1,1,3,3,1,3,0,3;
     
    in prize_id
    if id is > 0, the prize is an item
    if id = 0 , the prize is NOTHING!
    if id = -1, the prizer is free spin (number of free spins set in qty array)
    in array  .prize_qty you setup the quantity won
     
     
    //===== Hercules Script ====================================== //= Wheel of Fortune //===== By =================================================== //= Habilis //= Edited by Myriad //===== Description ========================================== //= Wheel of fortune something. //============================================================ - script Wheel_of_Fortune FAKE_NPC ,{ OnInit: disablenpc("Wheel of Fortune#Main"); disablenpc("Hussein#WOF"); .EventName$ = "[Wheel Of Fortune]"; end; OnMinute39: OnStart: query_sql("DELETE FROM `acc_reg_num_db` WHERE `key`='#freewheelfortunespin';"); announce(sprintf("%s : The event will begin in 1 minute, near the center of Prontera.", .EventName$), bc_blue | bc_all); initnpctimer(); end; OnTimer60000: // 1 min enablenpc("Wheel of Fortune#Main"); enablenpc("Hussein#WOF"); announce(sprintf("%s : Come to Prontera and test your luck, everyone got some free spins!", .EventName$), bc_blue | bc_all); end; OnTimer1800000: // 30 mins announce(sprintf("%s : One more minute, do your last spin!", .EventName$), bc_blue | bc_all); end; OnTimer1860000: // 31 mins OnStop: disablenpc("Wheel of Fortune#Main"); disablenpc("Hussein#WOF"); end; } prontera,159,178,3 script Hussein#WOF 1_M_MERCHANT,{ doevent("Wheel of Fortune#Main::OnTalk"); end; } prontera,155,176,3 script Wheel of Fortune#Main 2_SLOT_MACHINE,{ OnTalk: if (#freewheelfortunespin == 0) #freewheelfortunespin = .Free_Spins; if (getd(.Event_Points_Variable$) < .Points_Cost && #freewheelfortunespin < 0) { mesf("[^0055FF ::: %s ::: ^000000]", .EventName$); mes("You are out of points"); mes("and have no more free"); mes("spins! Come back next"); mes("time for more."); close(); } .@mes$ = (#freewheelfortunespin > 0) ? sprintf(", but you, my friend, have %d free spin%s!", #freewheelfortunespin, (#freewheelfortunespin == 1) ? "" : "s") : "."; cutin("aca_salim02", 2); addtimer(1, sprintf("%s::OnEnd", strnpcinfo(NPC_NAME))); mesf("[^0055FF ::: %s ::: ^000000]", .EventName$); mes("Do you want to spin the wheel?"); mesf("It costs ^FF0000%d Event points^000000 to play%s", .Points_Cost, .@mes$); next(); callsub(S_Loop); S_Loop: .@val = getd(.Event_Points_Variable$); if (.@val < .Points_Cost && #freewheelfortunespin < 0) callsub(S_End); switch (select( (#freewheelfortunespin > 0) ? sprintf("Yes! Use free spin! (%d left)", #freewheelfortunespin) : "", (.@val > 0) ? sprintf("Yes! Use Event Points. (%d remaining)", .@val) : "", "No (Leave)" )) { case 1: callsub(S_Pay, 0); case 2: callsub(S_Pay, 1); default: callsub(S_End); } S_Pay: switch (getarg(0)) { // pay with free spin case 0: if (#freewheelfortunespin > 0) { if ((#freewheelfortunespin -= 1) < 1) #freewheelfortunespin = -1; callsub(S_Gamble); } else callsub(S_End); // Pay with points case 1: default: if ((.@val = getd(.Event_Points_Variable$)) >= .Points_Cost) { setd(.Event_Points_Variable$, (.@val -= .Points_Cost)); dispbottom(sprintf("%s : You now have %d event points.", .ServerName$, .@val)); callsub(S_Gamble); } else { cutin("aca_salim02", 2); mesf("[^0055FF ::: %s ::: ^000000]", .EventName$); mes("Awww, you don't have enough to gamble..."); mes(" "); mes("Have you ever heard?"); mes("'Money isn't all that matters' Got it?"); mes("Byeeeeeeeeeeeeee ;)"); callsub(S_End); } } S_Gamble: // Actual Gambling .@sector = rand(.Sector[0], .Sector[1]); .@displayCutin = (.@sector * 2) - 1; .@Speed = .Spin_Speed; for (.@i = 0; .@i < .nbTurns; .@i++) { .@b = .Cutin[0]; while (.@b <= .Cutin[1]) { cutin(sprintf("%s%d", .cutin$, .@b), 4); sleep2(.@Speed); .@b++; .@Speed++; } } .@b = .Cutin[0]; while (.@b < .@displayCutin) { cutin(sprintf("%s%d", .cutin$, .@b), 4); sleep2(.@Speed); .@b++; } cutin(sprintf("%s%d", .cutin$, .@b), 4); if (.prize_id[.@sector] == -1) { // Free spin if (.Sound_Effects) soundeffect("wheel_jackpot.wav", 0); announce(sprintf("[%s] : Wow, %d more Free spins!!!", .EventName$, .prize_qty[.@sector]), bc_blue | bc_self); #freewheelfortunespin = #freewheelfortunespin == -1 ? .prize_qty[.@sector] : #freewheelfortunespin + .prize_qty[.@sector]; } else if (.prize_id[.@sector] == 0) { // nothing if (.Sound_Effects) soundeffect("wheel_lost.wav", 0); announce(sprintf("[%s] : Awwww, No luck in gamble, more luck in love...", .EventName$), bc_blue | bc_self); } else { // item if (.Sound_Effects) soundeffect("wheel_won.wav", 0); announce(sprintf("[%s] : Enjoy your prize!!!", .EventName$), bc_blue | bc_self); getitem(.prize_id[.@sector], .prize_qty[.@sector]); } sleep2(1000); callsub(S_Loop); end; S_End: close2(); OnEnd: cutin("", 255); end; OnInit: .ServerName$ = "[Your boring server]"; .EventName$ = "Wheel Of Fortune"; .cutin$ = "WheelOfFortune_"; .Event_Points_Variable$ = "#LROEVENTPOINTS"; // The name of your event points variable setarray(.Sector, 1, 10); // Sector range setarray(.Cutin, 0, 19); // Cutin range .Spin_Speed = 50; // What is the base spin speed? (ms) .nbTurns = 2; .Points_Cost = 100; // How many 'points' does it cost for a spin? .Free_Spins = 1; // How many free spins does a player get? .Sound_Effects = true; // Enable sound effects? (true/false) setarray(.prize_id[1], -1, 31024, 31026, 31008, 31020, 31017, 31010, 31016, 0, 31009); setarray(.prize_qty[1], 2, 1, 1, 1, 3, 3, 1, 3, 0, 3); end; }  
  3. Upvote
    TheReturn reacted to AnnieRuru in noitem plugin   
    1.4
    plugin
    -- fix a rare bug if the user put multiple noitem on the same map, it spam non-sensible error
    ---- although this will overwrite the previous one without warning this time
  4. Upvote
    TheReturn reacted to luizragna in Custom Unit HP Bar System   
    Hello guys, i'm making a custom hp bar system for mob units.
    The command show the HP of the mob for all players in the map.
     
    I am using the cutin command, the problem is that I do not think so many files are necessary. In the case 1 image for each percentage of hp I would like your opnion and help to improve this system and make it lighter.
    Test yourselves :).
     
    HP Bar System:
    payon,147,229,4 script Test#HPbar 1_F_MARIA,{ if (.HP_Bar == 0) { .HP_Bar = 1; .mobGID = monster ("payon",148,226,"[T] HP Test",POPORING,1,strnpcinfo(0)+"::OnDie"); setunitdata .mobGID,UDT_MAXHP,4000; setunitdata .mobGID,UDT_HP,4000; .@count = getunits(BL_PC, .@units, false, "payon"); for (.@i = 0; .@i < .@count; .@i++) addtimer(0,strnpcinfo(0)+"::OnHPBar", .@units[.@i]); } end; OnDie: .HP_Bar = 0; end; OnHPBar: .U_MAXHP = getunitdata (.mobGID,UDT_MAXHP); while (.HP_Bar != 0) { .U_HP = getunitdata (.mobGID,UDT_HP); .P_HP = (.U_HP*100)/.U_MAXHP; cutin(""+.P_HP+"", 1); sleep2 100; } cutin("0", 1); sleep2 5000; //Delay to hide HP Bar cutin("", 255); end; }  







     
    Donwload of the data folder files: HP Bar System (2018-06-26).rar
  5. Upvote
    TheReturn got a reaction from AnnieRuru in Willing to pay for this agit defender script   
    you can check it out here:
     
  6. Upvote
    TheReturn got a reaction from Habilis in Agit Denfed Ranking   
    Its not a full release since you need to modify some stuff, it can get some improvements but works as intended.
    This script is only showing the ranking for Swanhild and Kriemhild as an example, if you wanna show more just change the code:
     
    switch( select("- Swanhild", "- Kriemhild.")) { case 1: set .@castleName$,"Swanhild"; break; case 2: set .@castleName$,"Kriemhild"; break; } Adding more cases and more options on the switch select.
    Install:
     Copy the agit_defend_ranking.txt to the custom folder and add it to scripts_custom.conf.
     Insert the SQL table to your server database
     replace the agit_main.txt to 'hercules\npc\woe-fe\' folder.

    obs* doest work for woe-se for now, I will update it if someone ask for it.
    agit_defend_ranking.txt
    agit_defend_stats.sql
    agit_main.txt
  7. Upvote
    TheReturn reacted to AnnieRuru in Russian Roulette   
    Download: 1.1
    script
    just join the event and then AFK there and wait for the luck ...
    the last one who has enough patience ... or you are just god damn lucky ... might win this event

     
  8. Upvote
    TheReturn reacted to AnnieRuru in Help Learning Instance and how it works. <3   
    similar topic appear in rathena forum
    prontera,155,180,0 script Test Instance 1_F_MARIA,{ if ( has_instance2("guild_vs2") >= 0 ) { // dispbottom has_instance2("guild_vs2") +" destroy"; instance_destroy has_instance2("guild_vs2"); } if ( ( .@ins = instance_create( "Test Instance", getcharid(CHAR_ID_ACCOUNT), IOT_CHAR ) ) < 0 ) { mes "error : "+ .@ins; close; } if ( !getstrlen( instance_attachmap( "guild_vs2", .@ins, true, ( getcharid(CHAR_ID_ACCOUNT) )+"INST" ) ) ) { mes "error : 5"; instance_destroy .@ins; close; } instance_set_timeout 3600, 15, .@ins; instance_init .@ins; warp has_instance("guild_vs2"), 49,49; end; } guild_vs2,49,49,5 script test dialog 1_F_MARIA,{ dispbottom strnpcinfo(NPC_MAP); mesf "%d monsters on this map", 'amount; next; select "Destroy"; instance_destroy; end; OnInstanceInit: monster has_instance("guild_vs2"), 49,49, "--ja--", PORING, 10, instance_npcname( strnpcinfo(NPC_NAME) )+"::OnMobDead"; 'amount = 10; end; OnMobDead: --'amount; if ( !'amount ) instance_announce -1, "all monster killed", bc_map; end; } few things noted for hercules ones
    1. hercules has more instance related script commands, but also make this more flexible to write once you learn them all
    a. hercules has *instance_attach script command, make sure this script command is added before trying do anything instance related in the register npc
    b. hercules has to emulate the map name with *instance_attachmap if the map name doesn't follow the syntax <number>@<5 string limit>
    2. hercules instance ID start from 0, rathena instance ID start from 1
    a. make sure the instance_announce is set to -1
    3. hercules seems cannot *instance_destroy inside the instance map itself ... has to rely on *instance_set_timeout of the timeout value
  9. Upvote
    TheReturn reacted to Cabrera in [Release] 2018 Clients translated tipbox   
    Hello everyone, I present to you a modified tip box which has been completely translated to English. 
    Tested on: 2018-04-04c RagexeRE and worked like a charm.
    In your System folder in Client side, replace your tipbox.lub with my translated tipbox i have attached below:
    tipbox.lub
    Then, Patch your client with whatever settings you want and then open the patched client in hexeditor ( I used XV132 for this)
    IMPORTANT NOTE : Make sure you hex a "patched" client. DO NOT do it on an unpatched client or else NEMO will show errors for random "recommended patches" that you select while patching it.
    Find the following and replace with hex for english translation : for checkbox: BD C3 C0 DB C7 D2 20 B6 A7 20 BF AD B1 E2 English translation: 53 61 76 65 20 54 69 70 3F 20 20 20 20 20 for close button : B4 DD B1 E2 English translation : 44 6F 6E 65 (korean translation of close has only 4 strings so I had to replace it with "Done" to match the string size -_-) OR go to your NEMO folder/patches/TranslateClient.txt and add this at the end of it then patch your clients: (Thanks to @Asheraf for telling me about this xD)
    M: Translate Tip box ------------------------------ F: BD C3 C0 DB C7 D2 20 B6 A7 20 BF AD B1 E2 R: 'Save Tip?' F: B4 DD B1 E2 R: 'Done' if you did everything as said, this will be your result :
    Old tip box:

    New translated tipbox:
     

     
    -- On a funny Note, I had no clue what the korean translation for the Check box was LOL so I just randomly translated it to "Save tip?" instead cuz it was a logical solution LMAO 
  10. Upvote
    TheReturn reacted to OmarAcero in Como traudizir as habilidades?   
    to edit the skill description you have to open this folder:
    data\luafiles514\lua files\skillinfoz\
    and look for the file skilldescript.lub
  11. Upvote
    TheReturn reacted to OmarAcero in Como traudizir as habilidades?   
    You can try editing this file:  skillinfolist.lub  ( SkillName: " Name skill " )
     
  12. Upvote
    TheReturn got a reaction from Idlaz in Disconnected from server after selecting the character   
    Is your client a ragexeRE subset? If is so you need to enable #define ENABLE_PACKETVER_RE on mmo.h.
  13. Upvote
    TheReturn reacted to bWolfie in [Guide] Mapcache Generation 2018   
    As of Release v2018.03.13, the method to generate mapcache for Hercules has changed. A lot of people. myself included, were confused as to how it works. In this thread, I will do my best to explain the new way to generate your cache. This guide is intended to help people using the old system, not to aid new people (i.e. never generated mapcache before), so if you are new, some of it may seem like alien talk.
    Old (your source predates [is older than] Feb 18, 2018)
    In the old system, there were two ways to generate mapcache
    You could run the mapcache executable in Hercules root folder. Or use a program such as WeeMapCache to edit in your required mapcache. These two methods would generate or alter your required mapcache located in db/[pre-re or re]/map_cache.dat. However, they are no longer supported.
    New (your source is using Release v2018.03.13 or newer)
    The new system involves the use of the new 'mapcache' plugin to generate files. Some quick points:
    db/[pre-re or re]/map_cache.dat has been dropped (no longer supported). In its place are individual .mcache files for every map located in maps/[pre-re or re]/ Mapcache executable has been removed. Replaced with the mapcache plugin (src/plugins/mapcache.c). How to generate the mapcache?
    Same as before, check conf/map/maps.conf and db/map_index.txt have all the maps you want to cache. Your maps need to exist somewhere in your repository! There are two ways for the plugin to find them:
    a. Place all your maps, including resnametable.txt, inside the data folder of your Hercules repo. I.e. Hercules/data/prontera.gat/gnd/gnd/rsw (note: I forget if all three files are needed).
    b. OR Configure your conf/grf-files.txt to tell it where to find your GRF(s) which contains your maps. Build the mapcache plugin. On linux, this can be done by running the following command:
    make plugin.mapcache
    If using MSVC, compile as you would any other plugin. Execute plugin. This can be done using the following command:
    ./map-server --load-plugin mapcache [param]
    In windows, just remove the './' and run the commands in your command prompt. The params:
    The first thing you should do is run
    ./map-server --load-plugin mapcache --help
    A list of usable parameters will appear. Here are the ones you need to know for mapcache:
    [Info]:   --convert-old-mapcache         Converts an old db/pre-re/map_cache.dat file to the new format. [Mapcache] [Info]:   --rebuild-mapcache             Rebuilds the entire mapcache folder (maps/pre-re/), using db/map_index.txt as index. [Mapcache] [Info]:   --map <name>                   Rebuilds an individual map's cache into maps/pre-re/ (usage: --map <map_name_without_extension>). [Mapcache] [Info]:   --fix-md5                      Updates the checksum for the files in maps/pre-re/, using db/map_index.txt as index (see PR #1981). [Mapcache] ./map-server --load-plugin mapcache --convert-old-mapcache
    Rebuild all the .mcache files using your old db/[pre-re or re]map_cache.dat file.
    NOTE: You should only run this command when you have an old map_cache.dat file you need to convert.
    ./map-server --load-plugin mapcache --rebuild-mapcache
    Rebuild all the .mcache files using your map files specified in step 2 of generation.
    NOTE: You should only run this command in special circumstances. This erases ALL the existing mapcache and rebuilds it with whatever files you provide it. If you don't have the required files, the build will fail and you will be left with missing mapcache files, meaning you won't be able to access those particular maps.
    ./map-server --load-plugin mapcache --map <name>
    Rebuild the .mcache file for the map name you specify. E.g. if you replace <name> with prontera, the maps/[pre-re or re]/prontera.mcache file will be rebuilt.
    NOTE: This is the best command to run, as it only caches a single map at a time.
    ./map-server --load-plugin mapcache --fix-md5
    I don't know what checksum is for.
    The End
    Feel free to ask for help here. I'll try to answer questions re: mapcache if possible. And if you think anything needs correcting or added, let me know.
    Hope this helps!
×
×
  • Create New...

Important Information

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