Alexandria 53 Posted December 21, 2014 Hello there! I would like to set up my Reset NPC for 3 Reset for character. https://github.com/HerculesWS/Hercules/blob/master/npc/custom/resetnpc.txt Thank you in advance for your help! Quote Share this post Link to post Share on other sites
0 jaBote 438 Posted January 3, 2015 Maybe this untested NPC edit could help you do that? I took a different approach than Happy's because I think it's a bit cleaner this way: //===== Hercules Script ======================================//= Reset NPC//===== By: ==================================================//= Hercules Dev Team//===== Current Version: =====================================//= 1.3//===== Description: =========================================//= Resets skills, stats, or both.//===== Additional Comments: =================================//= 1.0 First Version//= 1.1 Optimized for the greater good. [Kisuka]//= 1.2 Cleaning [Euphy]//= 1.3 All statuses removed upon skill reset. [Euphy]//===== Custom Additions: ====================================//= 1.3a Custom reset limits. Modernized syntax [jaBote]//============================================================prontera,150,193,4 script Reset Girl 4_F_TELEPORTER,{ .@ResetStat = 5000; // Zeny for stat reset .@ResetSkill = 5000; // Zeny for skill reset .@ResetBoth = 9000; // Zeny for resetting both together .@MaxReset = 3; // Max amount of resets. Must be positive. mes "[Reset Girl]"; mes "I am the Reset Girl."; if (.@MaxReset) { mes "You can reset your character up to " + .@MaxReset + " times."; if (ResetCount >= .@MaxReset) { mes "Sorry, you've already used all of your available resets."; close; } mes "You've already used this service for " + ResetCount + " time(s)."; } mes "Reset Stats: "+ .@ResetStat +"z"; mes "Reset Skills: "+ .@ResetSkill +"z"; mes "Reset Both: "+ .@ResetBoth +"z"; mes "Please select the service you want:"; next; switch(select("^FF3355Reset Skills:Reset Stats:Reset Both^000000:Cancel")) { case 1: mes "[Reset Girl]"; if (Zeny < .@ResetSkill) { mes "Sorry, you don't have enough Zeny."; close; } if (.@MaxReset) ResetCount++; Zeny -= .@ResetSkill; sc_end SC_ALL; resetskill; mes "There you go!"; close; case 2: mes "[Reset Girl]"; if (Zeny < .@ResetStat) { mes "Sorry, you don't have enough Zeny."; close; } if (.@MaxReset) ResetCount++; Zeny -= .@ResetStat; resetstatus; mes "There you go!"; close; case 3: mes "[Reset Girl]"; if (Zeny < .@ResetBoth) { mes "Sorry, you don't have enough Zeny."; close; } if (.@MaxReset) ResetCount++; Zeny -= .@ResetBoth; sc_end SC_ALL; resetskill; resetstatus; mes "There you go!"; close; case 4: close; }} 3 Lilystar, tupe1387 and Alexandria reacted to this Quote Share this post Link to post Share on other sites
0 Happy 28 Posted December 23, 2014 (edited) you mean you want it to stop resetting after 3 resets? Assuming that's what you mean, feel free to test this one out: https://github.com/happyme9/AthenaScripts/blob/master/modification_requests/resetnpc_with_limit.txt Limit is currently set to 3 per char. Please test it carefully before implementing on your production/online server. Edited December 24, 2014 by Happy Quote Share this post Link to post Share on other sites
0 karazu 33 Posted December 24, 2014 3 resets per character the way I understand Quote Share this post Link to post Share on other sites
0 Alexandria 53 Posted December 24, 2014 you mean you want it to stop resetting after 3 resets? Assuming that's what you mean, feel free to test this one out: https://github.com/happyme9/AthenaScripts/blob/master/modification_requests/resetnpc_with_limit.txt Limit is currently set to 3 per char. Please test it carefully before implementing on your production/online server. Thank you but It does not work. You can reset more than 3 times per character. Can you also add a message at the beginning how many reset is remaining? mess "You can reset until 3 times."; mess "It is your numer '+numberreset+' of reset". next; Quote Share this post Link to post Share on other sites
0 Happy 28 Posted December 24, 2014 Please try the latest version https://github.com/happyme9/AthenaScripts/blob/master/modification_requests/resetnpc_with_limit.txt I added the msg thing as well. Quote Share this post Link to post Share on other sites
0 Alexandria 53 Posted December 25, 2014 Thank you! but it has a bug. When you cancel it by using the button cancel and you did not reset it, it counts as reset :/ Quote Share this post Link to post Share on other sites
0 Lilystar 42 Posted December 26, 2014 Talk of the reset NPC of limit three times?Isn't need to create a character variable data? It is a talk when it wants to maintain reset count data after the restart of the server. Sorry if I misunderstood it. 1 Alexandria reacted to this Quote Share this post Link to post Share on other sites
0 Alexandria 53 Posted December 26, 2014 Talk of the reset NPC of limit three times? Isn't need to create a character variable data? It is a talk when it wants to maintain reset count data after the restart of the server. Sorry if I misunderstood it. Yeah, 3 times per character Reset limit for 3 times Quote Share this post Link to post Share on other sites
0 Alexandria 53 Posted December 28, 2014 Any help? thank you Quote Share this post Link to post Share on other sites
0 Lilystar 42 Posted January 5, 2015 (edited) awesome. data is maintained after the restart. Edited January 5, 2015 by Lilystar Quote Share this post Link to post Share on other sites
0 Alexandria 53 Posted January 5, 2015 Thank you! Quote Share this post Link to post Share on other sites
0 jaBote 438 Posted January 6, 2015 awesome. data is maintained after the restart. That's how permanent char variables are supposed to behave . Thanks for testing! Quote Share this post Link to post Share on other sites
Hello there!
I would like to set up my Reset NPC for 3 Reset for character.
https://github.com/HerculesWS/Hercules/blob/master/npc/custom/resetnpc.txt
Thank you in advance for your help!
Share this post
Link to post
Share on other sites