cloud167 Posted August 15, 2012 Group: Members Topic Count: 17 Topics Per Day: 0.00 Content Count: 31 Reputation: 0 Joined: 05/13/12 Last Seen: November 5, 2024 Share Posted August 15, 2012 A script that will detect a player if one of his stats exceeds 255, it will announce the player's name, it will tell the player that he have stats that go over the limit of 255 and will be DC-ed in 5 seconds. thank you in advance Quote Link to comment Share on other sites More sharing options...
Emistry Posted August 15, 2012 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2370 Joined: 10/28/11 Last Seen: Yesterday at 05:27 AM Share Posted August 15, 2012 try add this code for your script to check for( set .@i,13; .@i <= 18; set .@i,.@i + 1 ) if( readparam(.@i) > 255 ){ announce strcharinfo(0)+" have Exceeded Max Stats Limits.",0; message strcharinfo(0),"Disconnecting within 5 Seconds."; sleep2 5000; // resetstatus; atcommand "@kick "+strcharinfo(0); break; } end; Quote Link to comment Share on other sites More sharing options...
cloud167 Posted August 16, 2012 Group: Members Topic Count: 17 Topics Per Day: 0.00 Content Count: 31 Reputation: 0 Joined: 05/13/12 Last Seen: November 5, 2024 Author Share Posted August 16, 2012 umm, Sir Emistry, thank you for your quick reply, but can you add that it will look for unlegit characters every 30minutes or 1hour perhaps, I just thought of it because if someone exceeds the 255 stats, that script will only work on login right? so they might return the stats of the character to normal if they'll logout? Quote Link to comment Share on other sites More sharing options...
Emistry Posted August 16, 2012 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2370 Joined: 10/28/11 Last Seen: Yesterday at 05:27 AM Share Posted August 16, 2012 OnPCLoginEvent: while( 1 ){ //code.......... sleep2 ( 30 * 60000 ); } end; remove the end after the FOR-LOOP in above script. Quote Link to comment Share on other sites More sharing options...
cloud167 Posted August 16, 2012 Group: Members Topic Count: 17 Topics Per Day: 0.00 Content Count: 31 Reputation: 0 Joined: 05/13/12 Last Seen: November 5, 2024 Author Share Posted August 16, 2012 uhhh, so sir, it'll look like this, - script statlimiter -1,{ for( set .@i,13; .@i <= 18; set .@i,.@i + 1 ) if( readparam(.@i) > 255 ){ announce strcharinfo(0)+" have Exceeded Max Stats Limits.",0; message strcharinfo(0),"Disconnecting within 5 Seconds."; sleep2 5000; // resetstatus; atcommand "@kick "+strcharinfo(0); break;OnPCLoginEvent: while( 1 ){ //code.......... sleep2 ( 30 * 60000 ); } end; Quote Link to comment Share on other sites More sharing options...
Question
cloud167
A script that will detect a player if one of his stats exceeds 255, it will announce the player's name, it will tell the player that he have stats that go over the limit of 255 and will be DC-ed in 5 seconds. thank you in advance
Link to comment
Share on other sites
4 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.