Unique gamemode, used to play there.
also server gets more joyful in high playercounts
also server gets more joyful in high playercounts
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Show posts MenuKey_WIN <- BindKey(true, 0x5B, 0, 0); // Better add this at onScriptLoad();
Evaders <- [];
class PlayerStats {
Knocked = false;
AFK = false;
}
function onPlayerActionChange(player, old, new) {
if(new == 42 || new == 43){
// 42 = Knocked | 43 = Standing up
for(local i = 0; i < GetPlayers(); i++) {
local pl = FindPlayer(i);
if(pl && pl.Pos.Distance(player.Pos) < 27 && player.Team != plr.Team) {
// Shotgun range is 24meters I guess, so adding +3 meters is better if player flew away when knocked (abit)
return stats[player.ID].Knocked = true;
}
}
}
else if(new != 43 && new != 42){return stats[player.ID].Knocked=false;}
}
function onKeyDown(player, key) {
if(key == Key_WIN){
if(stats[player.ID].Knocked){
stats[ player.ID ].AFK = true; // 0 delay with Keys
Evaders.append(player.UID);
Message("[#FFF000]"+player.Name+" [#FF0000]has been banned for [#FFA540]Death evasion");
player.Kick();
}
}
function onPlayerPart(player, reason){
if((player.Away || stats[ player.ID ].AFK) && (stats[ player.ID ].Knocked)) {
Message("[#FFF000]"+player.Name+" [#FF0000]has been banned for [#FFA540]Death evasion");
Evaders.append(player.UID);
}
}
function onPlayerJoin(player){
foreach(val in Evaders) {
if(val == player.UID) player.Kick();
}
else return;
/*
OR YOU CAN TRY THIS
if(Evaders.find(player.UID) != null) player.Kick();
I guess this is better than 1st method
*/
}
Key_WIN <- BindKey(true, 0x5B, 0, 0); // Better add this at onScriptLoad();
Evaders <- [];
class PlayerStats {
Knocked = false;
AFK = false;
}
function onPlayerActionChange(player, old, new) {
if(new == 42 || new == 43){
// 42 = Knocked | 43 = Standing up
for(local i = 0; i < GetPlayers(); i++) {
local pl = FindPlayer(i);
if(pl && pl.Pos.Distance(player.Pos) < 27 && player.Team != plr.Team) {
// Shotgun range is 24meters I guess, so adding +3 meters is better if player flew away when knocked (abit)
return stats[player.ID].Knocked = true;
}
}
}
else if(new != 43 && new != 42){return stats[player.ID].Knocked=false;}
}
function onKeyDown(player, key) {
if(key == Key_WIN){
if(stats[player.ID].Knocked){
stats[ player.ID ].AFK = true; // 0 delay with Keys
Evaders.append(player.UID);
Message("[#FFF000]"+player.Name+" [#FF0000]has been banned for [#FFA540]Death evasion");
player.Kick();
}
}
function onPlayerPart(player, reason){
if((player.Away || stats[ player.ID ].AFK) && (stats[ player.ID ].Knocked)) {
Message("[#FFF000]"+player.Name+" [#FF0000]has been banned for [#FFA540]Death evasion");
Evaders.append(player.UID);
}
}
function onPlayerJoin(player){
foreach(val in Evaders) {
if(val == player.UID) player.Kick();
}
else return;
/*
OR YOU CAN TRY THIS
if(Evaders.find(player.UID) != null) player.Kick();
I guess this is better than 1st method
*/
}