Sallycantdance Posted November 8, 2023 Group: Members Topic Count: 224 Topics Per Day: 0.14 Content Count: 796 Reputation: 12 Joined: 12/04/20 Last Seen: Tuesday at 02:01 PM Share Posted November 8, 2023 hello how to fix this Quote - script HATEFFECT -1,{ OnHatEffect: if(getgmlevel()>= 0){ input .@number; if (.@number < 1) end; if (.@number >= 726) end; for(.@i = 1; .@i < 725; ++.@i) hateffect .@i,false; hateffect .@number,true; end; } OnInit: bindatcmd "efc",strnpcinfo(3)+"::OnHatEffect"; end; } [Error]: script:run_script_main: infinity loop ! [Debug]: Source (NPC): HATEFFECT (invisible/not on a map) Quote Link to comment Share on other sites More sharing options...
0 Winterfox Posted November 8, 2023 Group: Members Topic Count: 1 Topics Per Day: 0.00 Content Count: 245 Reputation: 92 Joined: 06/30/18 Last Seen: November 27, 2024 Share Posted November 8, 2023 *freeloop({<toggle>}) Toggling this to enabled (1) allows the script instance to bypass the infinite loop protection, allowing your script to loop as much as it may need. Disabling (0) will warn you if an infinite loop is detected. The command will return the state of freeloop for the attached script, even if no argument is provided. Example: freeloop(1); // enable script to loop freely // be careful with what you do here for ( .@i = 0; .@i < .@bigloop; .@i++ ) { dothis; // will sleep the script for 1ms when detect an infinity loop to // let rAthena do what it needs to do (socket, timer, process, etc.) } freeloop(0); // disable freeloop for ( .@i = 0; .@i < .@bigloop; .@i++ ) { dothis; // throw an infinity loop error } 1 Quote Link to comment Share on other sites More sharing options...
0 Sallycantdance Posted November 9, 2023 Group: Members Topic Count: 224 Topics Per Day: 0.14 Content Count: 796 Reputation: 12 Joined: 12/04/20 Last Seen: Tuesday at 02:01 PM Author Share Posted November 9, 2023 6 hours ago, Winterfox said: *freeloop({<toggle>}) Toggling this to enabled (1) allows the script instance to bypass the infinite loop protection, allowing your script to loop as much as it may need. Disabling (0) will warn you if an infinite loop is detected. The command will return the state of freeloop for the attached script, even if no argument is provided. Example: freeloop(1); // enable script to loop freely // be careful with what you do here for ( .@i = 0; .@i < .@bigloop; .@i++ ) { dothis; // will sleep the script for 1ms when detect an infinity loop to // let rAthena do what it needs to do (socket, timer, process, etc.) } freeloop(0); // disable freeloop for ( .@i = 0; .@i < .@bigloop; .@i++ ) { dothis; // throw an infinity loop error } thank you again XD Quote Link to comment Share on other sites More sharing options...
Question
Sallycantdance
hello how to fix this
[Error]: script:run_script_main: infinity loop !
[Debug]: Source (NPC): HATEFFECT (invisible/not on a map)
Link to comment
Share on other sites
2 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.