Jump to content


Content Moderator
  • Posts

  • Joined

  • Last visited

  • Days Won


sader1992 last won the day on December 23 2021

sader1992 had the most liked content!

About sader1992

  • Birthday 11/16/1991

Profile Information

  • Gender
  • Location
  • Server
    DEV On : ArenaRO , DigitalRO
  • Github: sader1992
  • Discord: sader1992#3562
  • Interests
    rAthena , C# , C++ , PHP , MMO , Anime , Microsoft , Science , Cooking , Math

Contact Methods

Recent Profile Visitors

14,909 profile views


  • Ill
  • Currently Feeling Ill

sader1992's Achievements

  1. create a timer , something like this OnInstanceInit://Runs once the instance is created. 'map_gld_dun01$ = instance_mapname("gld_dun01");//save this map name inside the instance 'npc_instance_main_body$ = instance_npcname(strnpcinfo(3));//save this npc name inside the instance monster('map_gld_dun01$,32,36,"--en--",1002,1,'npc_instance_main_body$ + "::OnPoringKilled"); initnpctimer('npc_instance_main_body$); stopnpctimer('npc_instance_main_body$); end; OnPoringKilled: startnpctimer('npc_instance_main_body$); end; OnTimer600000://after 10 minute monster('map_gld_dun01$,32,36,"--en--",1002,1,'npc_instance_main_body$ + "::OnPoringKilled"); setnpctimer(0,'npc_instance_main_body$); stopnpctimer('npc_instance_main_body$); end; or maybe put a sleep delay OnInstanceInit://Runs once the instance is created. 'map_gld_dun01$ = instance_mapname("gld_dun01");//save this map name inside the instance 'npc_instance_main_body$ = instance_npcname(strnpcinfo(3));//save this npc name inside the instance monster('map_gld_dun01$,32,36,"--en--",1002,1,'npc_instance_main_body$ + "::OnPoringKilled"); end; OnPoringKilled: detachrid;//de attach the player from the event. sleep(600000);//sleep for 10 minutes monster('map_gld_dun01$,32,36,"--en--",1002,1,'npc_instance_main_body$ + "::OnPoringKilled"); end;
  2. OnInit: bindatcmd "reset_count",strnpcinfo(3) + "::OnAtcommand"; end; OnAtcommand: mes "Reset Count: " + RESET_COUNT; end;
  3. close2 doesn't detach the player , use close or end for the reset times , you are already saving that in RESET_COUNT so you can do something like mes "Reset Count: " + RESET_COUNT;
  4. You need to create the instance body in a new npc with the instance map you can check the instances commands in https://github.com/rathena/rathena/blob/0aa5e93397d3ddfe7a559747b09c16b055da8b24/doc/script_commands.txt#L9248 and instances events in https://github.com/rathena/rathena/blob/0aa5e93397d3ddfe7a559747b09c16b055da8b24/doc/script_commands.txt#L903 so for example you want to spawn 1 poring when the instance starts and respawn it again everytime id die would be like gld_dun01,0,0,0 script #instance_main_body 444,{ end; OnInstanceInit://Runs once the instance is created. 'instance_id = instance_id();//save the instance id 'map_gld_dun01$ = instance_mapname("gld_dun01");//save this map name inside the instance 'npc_instance_main_body$ = instance_npcname(strnpcinfo(3));//save this npc name inside the instance //^ 'var is instance variable , you can call it from any script in that instance. //spawn the monster with a death event monster('map_gld_dun01$,32,36,"--en--",1002,1,'npc_instance_main_body$ + "::OnPoringKilled"); end; OnPoringKilled: //announce that the poring is killed inside all the instance's maps instance_announce('instance_id,"The poring is killed!",0); //spawn the monster again after it's dead. monster('map_gld_dun01$,32,36,"--en--",1002,1,'npc_instance_main_body$ + "::OnPoringKilled"); end; } and to destroy the instance from outside you need to provide the instance id this should work change instance_destroy; to instance_destroy(instance_id(IM_PARTY)); ^this will destroy the party instance that hooked to the player (it's not a good idea to do that without a lot of other checks like party leader , or the instance is the instance you want to destroy not another instance etc)
  5. what about the other token ? does it work ? or everything doesn't work ? and try @resurrect command while the character is dead , this command is the same as pushing the revive button. I think this might be from the client diff.
  6. they should work by default , any item inside the group IG_TOKEN_OF_SIEGFRIED you can find this group in db folder in the item_misc.txt file depending on your server mode re or pre-re folder after the yml update it's in here pre-re https://github.com/rathena/rathena/blob/a251c3743c26f4042548e6cc3fb896503120b322/db/pre-re/item_group_db.yml#L5475 or re https://github.com/rathena/rathena/blob/a251c3743c26f4042548e6cc3fb896503120b322/db/re/item_group_db.yml#L19553
  7. You are sure that the .ladder_statues[[email protected] +1] is the npc id ? and [email protected]$[[email protected]] is M or F of the player ? the code above is correct however m = 1 not 0 and f = 0 use this setunitdata(.ladder_statues[[email protected]+1],UNPC_SEX,(([email protected]$[[email protected]] == "M")?1:0)); if your rAthena is too old (years old), make sure long ago the F or M was on the account not character, in that case you can take the gender from the login table, however I think the line above will fix the issue you are having. you can use debugmes([email protected]$[[email protected]]); to see if the variable is valid (make sure it's F or M)
  8. the only thing that I can suspect of is SC_ Something is a bad way to call a function or a label or a npc maybe try to rename the labels and functions ? specifically "SC_MOVEARM" "SC_ARMS" "SC_DISPARM" because I didn't check but maybe the server is translating it to a SC_ variables like SC_STUN and other variables to make it more readable I suggest to name the functions F_WhatEverYouWant , and labels as an event like OnWhatEverYouWant , NPCs rename them to WhatEverYouWant just don't use a prefix of a variables at the start not sure if this would fix the problem, but I don't see any problem in the script code from the error you are getting , this is my only conclusion.
  9. Are you sure that the errors you provided is from the script you provided ? not an edited version ?
  10. did I mislead you by giving you the link for the official documents? or telling you that you are using the incorrect variable types and it will lead to bugs in the script ? or by the example that I included with the correct variable usage ? well , there still a problem in the script that I mentioned before , maybe it's your chance to reach version 99 in your script.
  11. again you need to know why you are using a type of variable , you don't have to stick to one variable type , you should use what the script needs, check my old reply for more info looking at your script you should use .var + [email protected] + [email protected] and there is no "debuglog" command and "serarray" is misspelled you should not use oninit or npc variables in a function here I just fixed all the above without editing the script getItemByMapFunction v10 - Experimentell - Extended Debugging.txt
  12. what I meant is the other variables too, if the variable is only used inside the npc , you should use npc variable , also you might get problems when editing the npc and reload only that npc because [email protected] is global the function will return if any of the chances failed , (setarray [email protected]_chance[0],1,1,1000;) [try getting the 3rd item from the 3rd map with this chance] also there is no need for the function if it will only be called once. with other mistakes in the script ,you can check it if you test the script (I rarely test my scripts when replying to a post , so that's understandable xD) the debug messages are too much but that's my opinion with optimization this is the result - script GetItemByMap -1,{ OnNPCKillEvent: if(([email protected] = inarray(.maps$,strcharinfo(3))) == -1) end; if(rand(1000) <= .item_chance[[email protected]]) getitem(.items[[email protected]],.item_amounts[[email protected]]); end; OnInit: setarray .maps$[0],"prontera","alberta","izlude"; setarray .items[0],501,4012,512; setarray .item_amounts[0],100,1,5; setarray .item_chance[0],1000,500,800;//Chance begins by 0.1 percentage. 1 = 0.1 and 1000 = 100 percent end; } this optimized script doesn't support inputting the same map twice , you can edit it to do so if you want that
  13. https://github.com/rathena/rathena/blob/bdf568979dd53702494d3a6b3b9d35054c44594a/doc/script_commands.txt#L432
  • Create New...

Important Information

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