I want to after i attach the player. the timer will start then on timerup it will jail. please help the timer doesn't star eeergg!!"
Seasonia,151,109,4 script Police 852,{
Main:
cutin "ein_soldier",2;
mes "[ Police ]";
mes "Do you have a suspect botter?";
next;
switch(select("Yes:No")){
case 1:
mes "[ Police ]";
mes "Please input the name!";
input .@name$;
query_sql "SELECT `char_id` FROM `char` WHERE `name` = '"+.@name$+"'",.@charid;
if (!.@charid) { mes "The name is invalid."; next; goto Main; }
else set .@charid,0;
mes "[ Police ]";
mes "thx for reporting!";
close2;
cutin "",255;
attachrid( getcharid(3,.@name$) );
callfunc("propaganda",.@name$);
case 2:
mes "[ Police ]";
mes "Okay bye!";
close2;
cutin "",255;
end;
}
}
function script propaganda {
set .@ranbot,rand(1,5);
sc_start SC_BERSERK,10000000,1;
atcommand "@option 2";
cutin "ein_soldier",2;
initnpctimer;
if (.@ranbot == 1) {
mes "[ Police ]";
mes "What is your name!";
input .@Input$;
if( .@Input$ == strcharinfo(0) ){
mes "Correct.";
close2;
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
cutin "",255;
detachrid;
end;
} else {
mes "[ Police ]";
mes "Wrong!";
close2;
cutin "",255;
atcommand "@jail "+strcharinfo(0)+"";
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
detachrid;
end;
}
}
if (.@ranbot == 2) {
mes "[ Police ]";
mes "if ^0000FFA^000000 = 3, ^FF0000B^000000 = 7, ^008000C^000000 = 10";
mes "^0000FFA^000000 + ^008000C^000000 - ^FF0000B^000000 = ?";
input .@pwd;
if(.@pwd == "6"){
mes "[ Police ]";
mes "Correct!";
close2;
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
cutin "",255;
detachrid;
end;
} else {
mes "[ Police ]";
mes "Wrong!";
close2;
cutin "",255;
atcommand "@jail "+strcharinfo(0)+"";
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
detachrid;
end;
}
}
if (.@ranbot == 3) {
mes "[ Police ]";
mes "Type the Code given!";
set .@str$,"";
for(set .@i,0; .@i<10; set .@i,.@i+1)
set .@str$, .@str$+rand(9);
mes .@str$;
input .@i$;
if (.@i$ == .@str$){
mes "[ Police ]";
mes "Correct!";
close2;
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
cutin "",255;
detachrid;
end;
} else {
mes "[ Police ]";
mes "Wrong!";
close2;
cutin "",255;
atcommand "@jail "+strcharinfo(0)+"";
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
detachrid;
end;
}
}
if (.@ranbot == 4) {
mes "[ Police ]";
mes "What is the name of this RO?";
mes " Type the Word given:";
mes " ^0000FF Tykes Pogi ^000000";
input .@server$;
if(.@server$ == "Tykes Pogi"){
mes "[ Police ]";
mes "Correct!";
close2;
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
cutin "",255;
detachrid;
end;
} else {
mes "[ Police ]";
mes "Wrong!";
close2;
cutin "",255;
atcommand "@jail "+strcharinfo(0)+"";
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
detachrid;
end;
}
}
if (.@ranbot == 5) {
atcommand "@disguise 1063";
mes "[ Police ]";
mes "What kind of monster are you?";
mes "Clue : ";
mes " ^0000FFL_n_t_c^000000";
input .@poring$;
if(.@poring$ == "Lunatic"){
atcommand "@undisguise";
mes "[ Police ]";
mes "Correct!";
close2;
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
cutin "",255;
detachrid;
end;
} else {
atcommand "@undisguise";
mes "[ Police ]";
mes "Wrong!";
close2;
cutin "",255;
atcommand "@jail "+strcharinfo(0)+"";
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
detachrid;
end;
OnTimer0000:
announce "Timer Start's Now!", bc_self|#008000;
end;
OnTimer10000:
announce "Last 50 Seconds!!", bc_self|#008000;
end;
OnTimer30000:
announce "Last 30 Seconds!!", bc_self|#008000;
end;
OnTimer50000:
announce "Last 10 Seconds!!", bc_self|#008000;
end;
OnTimer55000:
announce "Last 5 Seconds!!", bc_self|#008000;
end;
OnTimer60000:
atcommand "@jail "+strcharinfo(0)+"";
atcommand "@option 0";
sc_end SC_BERSERK;
percentheal 100,100;
end;
}
}
}