Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- - script Sample -1,{
- function GetString;
- OnPCLoginEvent:
- if( checkidle() >= 300 ){
- mes "You have been AFK for "+checkidle()+" seconds.";
- }else{
- set .@String$,GetString( 15,rand(5,10) );
- mes "Input the ^FF0000RED COLOUR^000000 part";
- mes "^0000FF"+GetString( 15,rand(5,10) )+"^FF0000"+.@String$+"^0000FF"+GetString( 15,rand(3,10) )+"^000000";
- input .@Input$;
- if( .@Input$ != .@String$ ){
- mes "Wrong..";
- sleep2 3000;
- atcommand "@kick "+strcharinfo(0);
- }else if( @online ){
- mes "Online for 30 minutes ..gain prize.";
- getitem 14003, 1;
- getitem 673, 1;
- getitem 29003, 1;
- }else{
- @online = 1;
- }
- }
- addtimer ( 30 * 60000 ),strnpcinfo(0)+"::OnPCLoginEvent";
- close;
- function GetString {
- if( getarg(0) & 1 ) setarray .@List$[ getarraysize( .@List$ ) ],"1","2","3","4","5","6","7","8","9";
- if( getarg(0) & 2 ) setarray .@List$[ getarraysize( .@List$ ) ],"A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z";
- if( getarg(0) & 4 ) setarray .@List$[ getarraysize( .@List$ ) ],"a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z";
- if( getarg(0) & 8 ) setarray .@List$[ getarraysize( .@List$ ) ],"!","@","#","$","%","^","&","*","(",")","-","=","/","+";
- set .@Str$,"";
- while( getstrlen( .@Str$ ) < getarg(1) )
- set .@Str$,.@Str$ + .@List$[ rand( getarraysize( .@List$ ) ) ];
- return .@Str$;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment