Jump to content

Insane Limits - Examples


Recommended Posts

Originally Posted by blademaster*:

 

hello guys,

 

I'm trying to get player.KillsRound to be sent to procon chat but instead im getting only total kills for the player from battlelog - something like "8959Round"

I have noticed that commands like: KdrRound, KpmRound, SpmRound, ScoreRound, KillsRound, DeathsRound, TimeRound - getting stats from battlelog instead of current round while : HeadshotsRound, TeamKillsRound, TeamDeathsRound, SuicidesRound - working as it should , returning correct results.

 

Same thing with "player.KillsTotal" - doesn't work while "player.HeadshotsTotal" - returning correct result.

 

Should be thankfull to get any hint on this - whether it's a bug or i'm doing something wrong.

 

 

many thanks

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Singh400*:

 

That code is okay. Personally, I'd make the yells be at least 10 seconds and also send chat with the first yell, particularly since the first 5 second yell might be missed by the player when they spawn. Some of that first yell is spent in the fade to black/fade-in time when a player spawns. They can't see the yell during that time.

For some reason the limit triggers for every first spawn on every new map/round per player (still private yell which is what I want). I did want it to replicate the old behaviour of only triggering for the first spawn on the first time spawning into the server.

 

The code has changed slightly from:-

 

Posted Image

 

To:-

Code:

double count = limit.Activations ( player.Name );

if (count == 1)
	{
		plugin.ServerCommand("admin.yell", "Welcome " + player.Name + " to the Hairy Haggis! Please type @haggis to see server commands", "15", "player", player.Name);
	}

return false;
I think I need to work in:-

Code:

( limit.ActivationsTotal ( player.Name ) == 1 )
But I can't quite get it.

 

Or perhaps if I start the code with:-

Code:

if (limit.Activations() > 1)
	return false;
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

Using it, mainly, because I am a noob and have no idea how to do that right :smile:

 

Will try the way you described.

 

 

That return error on compilation. Does not like "\". Same for

Code:

[\_!]+
If back slash removed - all compiled OK, but now sure it works properly.
Sorry, my mistake. I forgot the all important @ symbol. Here is corrected code:

 

Code:

rules_calls.Add(@"m26[\_!]+"); // followed by one or more question marks
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

For some reason the limit triggers for every first spawn on every new map/round per player (still private yell which is what I want). I did want it to replicate the old behaviour of only triggering for the first spawn on the first time spawning into the server.

 

The code has changed slightly from:-

 

Posted Image

 

To:-

Code:

double count = limit.Activations ( player.Name );

if (count == 1)
	{
		plugin.ServerCommand("admin.yell", "Welcome " + player.Name + " to the Hairy Haggis! Please type @haggis to see server commands", "15", "player", player.Name);
	}

return false;
I think I need to work in:-

Code:

( limit.ActivationsTotal ( player.Name ) == 1 )
But I can't quite get it.

 

Or perhaps if I start the code with:-

Code:

if (limit.Activations() > 1)
	return false;
Just change Activations to ActivationsTotal in your original code. Don't change anything else. Should look like this:

 

Code:

double count = limit.ActivationsTotal( player.Name );

if (count == 1)
	{
		plugin.ServerCommand("admin.yell", "Welcome " + player.Name + " to the Hairy Haggis! Please type @haggis to see server commands", "15", "player", player.Name);
	}

return false;
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

hello guys,

 

I'm trying to get player.KillsRound to be sent to procon chat but instead im getting only total kills for the player from battlelog - something like "8959Round"

I have noticed that commands like: KdrRound, KpmRound, SpmRound, ScoreRound, KillsRound, DeathsRound, TimeRound - getting stats from battlelog instead of current round while : HeadshotsRound, TeamKillsRound, TeamDeathsRound, SuicidesRound - working as it should , returning correct results.

 

Same thing with "player.KillsTotal" - doesn't work while "player.HeadshotsTotal" - returning correct result.

 

Should be thankfull to get any hint on this - whether it's a bug or i'm doing something wrong.

 

 

many thanks

That's strange. I looked at the Insane Limits code and I didn't see any obvious confusion of Battlelog stuff with current in-game stuff. It's all separated.

 

I'm a little unclear on what you mean by "command". Do you mean the in-game commands you type to get stats? Or do you mean limit code? If limit code, do you mean properties like player.SpmRound, or do you mean replacements, like plugin.R("player.SpmRound")?

 

Can you give me some example limit code, the value you get and the expected value? Maybe a screenshot of the Battlelog page to confirm that the numbers you get match the Battlelog stat?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by wraygun*:

 

Hi,

 

This might have been covered before, but I can't find any info on it. Is it possible to place limits on Jets? The reason I ask is, Jets are just so grossly over powered on RUSH maps that it is ruining our server. We would like a limit that tracks how many kills a pilot has gotten in a row and then auto kill them after so many kills. If anyone has any ideas it would be appreciated.

 

Thanks

 

Wray

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by DrRectalPain*:

 

Sorry, my mistake. I forgot the all important @ symbol.

Do not know if this right or not, but it works (compiles and react properly) either way

Code:

rules_calls.Add(@"m26[\_!]+");
or

Code:

rules_calls.Add("m26[_!]+");
The only thing is that if there is >1 match in one sentence, it returns >1.

Means, if chat message looks like "what about M26? Is M26 allowed_" or "what about M26? Is underslugging MASS allowed_" it displays what is set in

Code:

plugin.SendGlobalMessage(plugin.R("M26 MASS is not allowed in any setup"));
as many times as equal to match (in example case - twice).

 

Ia there any workaround? Thanks

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by blademaster*:

 

many thanks for reply PapaCharlie9,

 

here is an example on "Per-Weapon Headshots Percentage Kicker"

this code working as it should :

 

double kills = player[kill.Weapon].KillsRound;

double headshots = player[kill.Weapon].HeadshotsRound;

double headshots_percent = Math.Round((headshots / kills)*100.0, 2);

 

if (headshots_percent > 35 && kills > 15)

{

plugin.ConsoleWrite(plugin.R("%p_n% has " + headshots_percent + " headshots percent with "+ kill.Weapon + " after " + kills + " kills"));

return true;

}

 

return false;

 

but the time it's being activated I would like the information to be sent to procon chat, so in the ProConChat Action tab I have added the following line to limit1_procon_chat_text : ""activated Limit #%l_id% %l_n% -- %p_n% HeadShots: (player.HeadshotsRound) Kills: (player.KillsRound) "" - where player.HeadshotsRound returning correct value like HeadShots: (6) while Kills: (8959Round) returning total number of player kills from battlelog, and same happens with all the properties I described earlier.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by DrRectalPain*:

 

@PapaCharlie9 - is it possible to add the email notification (with email message body content includes vote starter, vote target, vote reason) when Vote Kick/Ban limit activated?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

Do not know if this right or not, but it works (compiles and react properly) either way

Code:

rules_calls.Add(@"m26[\_!]+");
or

Code:

rules_calls.Add("m26[_!]+");
The only thing is that if there is >1 match in one sentence, it returns >1.

Means, if chat message looks like "what about M26? Is M26 allowed_" or "what about M26? Is underslugging MASS allowed_" it displays what is set in

Code:

plugin.SendGlobalMessage(plugin.R("M26 MASS is not allowed in any setup"));
as many times as equal to match (in example case - twice).

 

Ia there any workaround? Thanks

Just add a return false; in the if statement, like this:

 

Code:

List<String> rules_calls = new List<String>();
	
	rules_calls.Add("m26");
	rules_calls.Add("mass");
	rules_calls.Add("dart");
	
	String[] chat_words = Regex.Split(player.LastChat, @"\s+");
	
	foreach(String chat_word in chat_words)
	    foreach(String rules_call in rules_calls)
		    if (Regex.Match(chat_word, "^"+rules_call+"$", RegexOptions.IgnoreCase).Success)
			{
                            plugin.ConsoleWarn(plugin.R("%p_n% mention M26 in chat"));
                            plugin.SendGlobalMessage(plugin.R("M26 MASS is not allowed in any setup"));
                            plugin.SendGlobalMessage(plugin.R("This is temporary untill the bug fix by EA"));
                            plugin.SendGlobalMessage(plugin.R("Do not be darted, or be banned"));
                            return false;
			}	

	return false;
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

Hi,

 

This might have been covered before, but I can't find any info on it. Is it possible to place limits on Jets? The reason I ask is, Jets are just so grossly over powered on RUSH maps that it is ruining our server. We would like a limit that tracks how many kills a pilot has gotten in a row and then auto kill them after so many kills. If anyone has any ideas it would be appreciated.

 

Thanks

 

Wray

It is not possible, in general, to put any limits on any kind of vehicle, including jets.

 

That said, as long as you are willing to limit all vehicles, including the Mortar which counts as a vehicle, you can base a kill rate limit on "Death". All kills (other than TKs, suicides and collisions) made by vehicles are reported to PRoCon as "Death". So you can limit the kill rate for "Death" and get close to what you want.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

many thanks for reply PapaCharlie9,

 

here is an example on "Per-Weapon Headshots Percentage Kicker"

this code working as it should :

 

double kills = player[kill.Weapon].KillsRound;

double headshots = player[kill.Weapon].HeadshotsRound;

double headshots_percent = Math.Round((headshots / kills)*100.0, 2);

 

if (headshots_percent > 35 && kills > 15)

{

plugin.ConsoleWrite(plugin.R("%p_n% has " + headshots_percent + " headshots percent with "+ kill.Weapon + " after " + kills + " kills"));

return true;

}

 

return false;

 

but the time it's being activated I would like the information to be sent to procon chat, so in the ProConChat Action tab I have added the following line to limit1_procon_chat_text : ""activated Limit #%l_id% %l_n% -- %p_n% HeadShots: (player.HeadshotsRound) Kills: (player.KillsRound) "" - where player.HeadshotsRound returning correct value like HeadShots: (6) while Kills: (8959Round) returning total number of player kills from battlelog, and same happens with all the properties I described earlier.

That looks like a replacements bug in Insane Limits. You can work around the bug by not using replacements and using Code instead of an Action.

 

Disable the Action (set it to None) and modify the Code (first_check_) to this:

 

Code:

double kills = player[kill.Weapon].KillsRound;
double headshots = player[kill.Weapon].HeadshotsRound;
double headshots_percent = Math.Round((headshots / kills)*100.0, 2);

if (headshots_percent > 35 && kills > 15)
{
    plugin.ConsoleWrite(plugin.R("%p_n% has " + headshots_percent + " headshots percent with "+ kill.Weapon + " after " + kills + " kills"));
    String msg = plugin.R("activated Limit #%l_id% %l_n% -- %p_n% HeadShots: (") + player.HeadshotsRound + ") Kills: (" + player.KillsRound + ")";
    plugin.PRoConChat(msg);
}

return false;
That will only send messages to the log files, not to anyone in game. Is that what you intended?
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by wraygun*:

 

It is not possible, in general, to put any limits on any kind of vehicle, including jets.

 

That said, as long as you are willing to limit all vehicles, including the Mortar which counts as a vehicle, you can base a kill rate limit on "Death". All kills (other than TKs, suicides and collisions) made by vehicles are reported to PRoCon as "Death". So you can limit the kill rate for "Death" and get close to what you want.

Not ideal but worth a try. Trying to understand this plug-in makes me dizzy. If you could write such a limit it would be much appreciated. My guess is, it would only need to target 3 maps in Rush: Kharg, Caspian and Firestorm.

 

1. 10 kill limit? Could be adjustable.

2. Yell warning targeting player before limit is reached.

3. Yell to player on limit violation why he was auto killed.

4. Just on RUSH maps that have jets.

 

If this is possible our community would love to try it.

 

Thanks

 

Wray

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by blademaster*:

 

That looks like a replacements bug in Insane Limits. You can work around the bug by not using replacements and using Code instead of an Action.

 

Disable the Action (set it to None) and modify the Code (first_check_) to this:

 

Code:

double kills = player[kill.Weapon].KillsRound;
double headshots = player[kill.Weapon].HeadshotsRound;
double headshots_percent = Math.Round((headshots / kills)*100.0, 2);

if (headshots_percent > 35 && kills > 15)
{
    plugin.ConsoleWrite(plugin.R("%p_n% has " + headshots_percent + " headshots percent with "+ kill.Weapon + " after " + kills + " kills"));
    String msg = plugin.R("activated Limit #%l_id% %l_n% -- %p_n% HeadShots: (") + player.HeadshotsRound + ") Kills: (" + player.KillsRound + ")";
    plugin.PRoConChat(msg);
}

return false;
That will only send messages to the log files, not to anyone in game. Is that what you intended?
yes, I already did same by adding this to the code:

 

plugin.PRoConChat(plugin.R("activated Limit #%l_id% %l_n% -- %p_n% Headshots:(" + headshots + ") Kills:(" + kills + ") Percent:(" + headshots_percent + ")"));

 

thank you!

 

Is it possible to get accuracy per round for specific weapon or total accuracy for all the weapons ?

 

BTW PapaCharlie9 - is it any way to donate to you for your awesome community support ?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by )RAG()N*:

 

What if you want to setup a negative check ... like kick anyone that joins who is not from "US". In that case, you can do this:

 

Set limit to evaluate OnJoin, and set action to Kick

 

Set first_check to this Expression:

 

Code:

! Regex.Match(player.CountryCode, "(US)", RegexOptions.IgnoreCase).Success
I have been having a problem with this I have set it to only allow AU & NZ player to join, But I have seen some AU players get kicked by "Simple Country Kicker"

I'm thinking its a EA problem because I have tried another country kicker and it also kicks some Au players also.

 

What do you think..?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Mootart*:

 

I have been having a problem with this I have set it to only allow AU & NZ player to join, But I have seen some AU players get kicked by "Simple Country Kicker"

I'm thinking its a EA problem because I have tried another country kicker and it also kicks some Au players also.

 

What do you think..?

yeah me too other countries are being kick even they are not set on this country list.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Fl0ppyF*:

 

Not sure if it was requested allready, since I'm not able to monitor the forums that much at the moment. Can someone modify micovery's ...* Limit so it Yells the result instead of Say?

 

I only changed it so it gives out the result only one time. Tried to modify it myself a while ago with Papacharlie's ...*, but failed completely. I just have no clue at all when it comes to coding. :huh:

 

Here's my current code:

Code:

double count = limit.Activations();
    
    if (count > 1)
        return false;

    List<PlayerInfoInterface> players = new List<PlayerInfoInterface>();
    players.AddRange(team1.players);
    players.AddRange(team2.players);
    Dictionary<String, double> clan_stats = new Dictionary<String, double>();
    
    /* Collect clan statistics */
    foreach(PlayerInfoInterface player_info in players)
    {
        if(player_info.Tag.Length == 0)
            continue;
        
        if (!clan_stats.ContainsKey(player_info.Tag))
            clan_stats.Add(player_info.Tag, 0);
        
        clan_stats[player_info.Tag] += player_info.ScoreRound;
    }

    /* Find the best scoring clan */
    String best_clan = String.Empty;
    double best_score = 0;
    
    foreach(KeyValuePair<String, double> pair in clan_stats)
        if (pair.Value > best_score)
        {
             best_clan = pair.Key;
             best_score = pair.Value;
        }
    
    if (best_clan.Length > 0)
	{
		String message = "Top scoring clan this round is "+ best_clan + " with " + best_score + " points!";
                plugin.SendGlobalMessage(message); 
		plugin.ConsoleWrite(message);
        }   
    return false;
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Satanja*:

 

Suppose that you want to be tolerant and allow the server to fill up and only kick the high ranking players after a certain point. You can achieve this by combining the Simple Rank Limit with another Expression using the server's player count.

 

Set limit to evaluate OnJoin, and set action to Kick ...

 

Set first_check to this Expression:

 

Code:

(  player.Rank > 45   &&  server.PlayerCount > 30  )
This will allow the server to fill up to 30 players, and start kicking high ranking players only after the 31st player joins.
Maybe I'm misunderstanding what this one is supposed to do. But the way it worked when I tried it, is is allow 31 players on, then immediately kick everyone higher than rank 45, instead of just booting players when they try to join, resulting in kicking over 50% of the players at the same time, instead of "Onjoin"

 

If that just the way this works? I'd like it to just kick rank 45 when they join if theres more than 30 players, and leave the rank 45 players that has already joined. Then as they leave the server it would slowly trickle down to only below rank 45 instead of one massive kick of everyone rank 45 and risking killing the server population when everyone suddenly leaves.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Singh400*:

 

So I've got a Bad Word limit. It's has a range of bad words (like cunt, nigger, paki, cunt etc). What I wanted to do was split this into two tiers. Using any racist language will get your auto kicked, using offensive language (like cunt) will get you a warning on the first occasion, then a kick on the second occasion.

 

I think I've edited the code correctly, if someone could double check it for me that would be great.

 

Evaluation set to OnAnyChat

 

First_Check to this Code:-

Code:

List<String> racisms = new List<String>();
	racisms.Add("nigger");
	racisms.Add("niggers");
	racisms.Add("paki");
	racisms.Add("pakis");
	racisms.Add("nigga");
	racisms.Add("niggas");
	racisms.Add("jew");
	racisms.Add("jews");

String[] chatwords = Regex.Split(player.LastChat, @"\s+");
    
foreach(String chatword in chatwords) 
{
	foreach(String racism in racisms)
	{
		if (Regex.Match(chatword, "^"+racism+"$", RegexOptions.IgnoreCase).Success)
		{
			plugin.SendGlobalMessage(plugin.R("%p_n% was auto-kicked for using the term "+racism+"!"));
			plugin.KickPlayerWithMessage(player.Name, plugin.R("[Auto-Admin] Racist Language"));
			plugin.ConsoleWarn(plugin.R("%p_n% used the word: " +racism+""));
			plugin.Log("Logs/InsaneLimits_BWD.log", plugin.R("%date% %time% %p_n% "+racism+""));
			return true;
			
		}
	}
}

List<String> swears = new List<String>();
	swears.Add("cunt");
	swears.Add("cunts");

String[] chat_words = Regex.Split(player.LastChat, @"\s+");
    
foreach(String chat_word in chat_words) 
{
	foreach(String swear in swears)
	{
		if (Regex.Match(chat_word, "^"+swear+"$", RegexOptions.IgnoreCase).Success)
		{
			plugin.SendGlobalMessage(plugin.R("%p_n% please stop using the term "+swear+"! This is your only warning!"));
			plugin.ConsoleWarn(plugin.R("%p_n% used the word: " +swear+""));
			plugin.Log("Logs/InsaneLimits_BWD.log", plugin.R("%date% %time% %p_n% "+swear+""));
			return true;
			
		}
	}
}
Second_Check to Code:-

Code:

double count = limit.Activations ( player.Name );

if (count == 2)
{
	plugin.KickPlayerWithMessage(player.Name, plugin.R("[Auto-Admin] Bad Language"));
	plugin.SendGlobalMessage(plugin.R("%p_n% was kicked for using a prohibited word!"));
	plugin.ConsoleWarn(plugin.R("%p_n% was kicked for using a prohibited word!"));
}

return false;
Thanks :smile:
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Jaythegreat1*:

 

I modified the shownextmap example to give someone our teamspeak info, is there a way to have it send the message to the specific player, or yell the message to the player?

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Singh400*:

 

I modified the shownextmap example to give someone our teamspeak info, is there a way to have it send the message to the specific player, or yell the message to the player?

Sure...

 

Set the limit Evaluation on OnAnyChat.

 

Set the First_Check to this Expression:-

Code:

player.LastChat.StartsWith("@teamspeak")
Set the Second_Check to this Code:-

Code:

// Edit rules here
List<String> Rules = new List<String>();
	Rules.Add("Address: ###YOUR ADDRESS HERE###");
	Rules.Add("Port: ###YOUR PORT HERE###");
	Rules.Add("Password: ###YOUR PASSWORD HERE###");

// Try not to add more Rules.Add because it won't fit in the chat box.

plugin.ConsoleWrite(plugin.R("%p_n% wants to know TeamSpeak details"));
    foreach(string Rule in Rules)
        plugin.SendSquadMessage(player.TeamId, player.SquadId, Rule);

return false;
I don't know if R21 now supports Private Player Say or not. But if it does it could be easily modded to do a Private Player Say.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by Hutchew*:

 

I'm assuming Version 0.0.0.8 Insane Limits and your Expression was (player.Kdr > 4.0), but change that to whatever you have or want. Make sure your admin_tag custom list is set to CASE SENSITIVE.

 

Set limit to evaluate OnJoin, and Action to Tweet. We will do the say in Code in second_check.

 

Set first_check to this Code (NOTE: first_check is now CODE, not EXPRESSION)

 

Code:

if (plugin.isInList(player.Tag, "admin_tag")) return false;

if (player.Kdr > 4.0) return true;  // Use whatever other Expression you want here

return false;
Set second_check to this Code

 

Code:

// Send chat only to players whose tag matches admin_tag list
List<PlayerInfoInterface> admins = new List<PlayerInfoInterface>();
foreach (PlayerInfoInterface p in team1.players) {
    if (plugin.isInList(p.Tag, "admin_tag")) admins.Add(p);
}
foreach (PlayerInfoInterface p in team2.players) {
    if (plugin.isInList(p.Tag, "admin_tag")) admins.Add(p);
}
foreach (PlayerInfoInterface p in team3.players) {
    if (plugin.isInList(p.Tag, "admin_tag")) admins.Add(p);
}
foreach (PlayerInfoInterface p in team4.players) {
    if (plugin.isInList(p.Tag, "admin_tag")) admins.Add(p);
}

String msg = plugin.R("player.FullName joining with KDR player.Kdr > 4.0"); // Set this message to whatever you want

if (admins.Count > 0) foreach (PlayerInfoInterface a in admins) {
    plugin.ServerCommand("admin.say", msg, "player", a.Name);
}
return true;
That's perfect, works like a champ, Papacharlie. Thanks very much!

 

Is there any way to add a player to the whitelist with an in-game command? Don't really want our admins mucking about in the plugins.

 

Hutchew

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

Not ideal but worth a try. Trying to understand this plug-in makes me dizzy. If you could write such a limit it would be much appreciated. My guess is, it would only need to target 3 maps in Rush: Kharg, Caspian and Firestorm.

 

1. 10 kill limit? Could be adjustable.

2. Yell warning targeting player before limit is reached.

3. Yell to player on limit violation why he was auto killed.

4. Just on RUSH maps that have jets.

 

If this is possible our community would love to try it.

 

Thanks

 

Wray

Here ya go. Let me know if it works okay:

 

Insane Limits V0.8/R1: Vehicle Kill Rate Limit*

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

Is it possible to get accuracy per round for specific weapon or total accuracy for all the weapons ?

 

BTW PapaCharlie9 - is it any way to donate to you for your awesome community support ?

No, sorry, accuracy is not reported by the game server. Only Battlelog Accuracy is available.

 

No donation is necessary, but if you insist, you can donate to my clan. Go to http://bf2legionclan.com and click on the PAYPAL Donation button at the upper left.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

yeah me too other countries are being kick even they are not set on this country list.

Yeah, the country code is really only a guess based on the player's IP address. Battlelog can easily guess wrong.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

Not sure if it was requested allready, since I'm not able to monitor the forums that much at the moment. Can someone modify micovery's ...* Limit so it Yells the result instead of Say?

 

I only changed it so it gives out the result only one time. Tried to modify it myself a while ago with Papacharlie's ...*, but failed completely. I just have no clue at all when it comes to coding. :huh:

You just have to add one line :smile:

 

Code:

double count = limit.Activations();
    
    if (count > 1)
        return false;

    List<PlayerInfoInterface> players = new List<PlayerInfoInterface>();
    players.AddRange(team1.players);
    players.AddRange(team2.players);
    Dictionary<String, double> clan_stats = new Dictionary<String, double>();
    
    /* Collect clan statistics */
    foreach(PlayerInfoInterface player_info in players)
    {
        if(player_info.Tag.Length == 0)
            continue;
        
        if (!clan_stats.ContainsKey(player_info.Tag))
            clan_stats.Add(player_info.Tag, 0);
        
        clan_stats[player_info.Tag] += player_info.ScoreRound;
    }

    /* Find the best scoring clan */
    String best_clan = String.Empty;
    double best_score = 0;
    
    foreach(KeyValuePair<String, double> pair in clan_stats)
        if (pair.Value > best_score)
        {
             best_clan = pair.Key;
             best_score = pair.Value;
        }
    
    if (best_clan.Length > 0)
	{
		String message = "Top scoring clan this round is "+ best_clan + " with " + best_score + " points!";
                plugin.SendGlobalMessage(message); 
                [b]plugin.ServerCommand("admin.yell", message, "30"); [/b]
		plugin.ConsoleWrite(message);
        }   
    return false;
I made it show for 30 seconds but you can change that.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

Maybe I'm misunderstanding what this one is supposed to do. But the way it worked when I tried it, is is allow 31 players on, then immediately kick everyone higher than rank 45, instead of just booting players when they try to join, resulting in kicking over 50% of the players at the same time, instead of "Onjoin"

 

If that just the way this works? I'd like it to just kick rank 45 when they join if theres more than 30 players, and leave the rank 45 players that has already joined. Then as they leave the server it would slowly trickle down to only below rank 45 instead of one massive kick of everyone rank 45 and risking killing the server population when everyone suddenly leaves.

Uh, did you by any chance set the limit to evaluate OnSpawn instead OnKill? Or OnInterval? Or OnIntervalPlayer? Pretty much if you set it to anything other than OnJoin, you'd get a lot of players kicked unintentionally. If you did set it to OnJoin, it should only kick joiners.

 

Also, what version of Insane Limits are you using? Older versions used to process OnJoin on the eval thread, which could potentially execute on every player instead of on the one joining only. I don't think Verison 0.8 does that anymore, though.

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

So I've got a Bad Word limit. It's has a range of bad words (like cunt, nigger, paki, cunt etc). What I wanted to do was split this into two tiers. Using any racist language will get your auto kicked, using offensive language (like cunt) will get you a warning on the first occasion, then a kick on the second occasion.

 

I think I've edited the code correctly, if someone could double check it for me that would be great.

 

Evaluation set to OnAnyChat

 

First_Check to this Code:-

Code:

List<String> racisms = new List<String>();
	racisms.Add("nigger");
	racisms.Add("niggers");
	racisms.Add("paki");
	racisms.Add("pakis");
	racisms.Add("nigga");
	racisms.Add("niggas");
	racisms.Add("jew");
	racisms.Add("jews");

String[] chatwords = Regex.Split(player.LastChat, @"\s+");
    
foreach(String chatword in chatwords) 
{
	foreach(String racism in racisms)
	{
		if (Regex.Match(chatword, "^"+racism+"$", RegexOptions.IgnoreCase).Success)
		{
			plugin.SendGlobalMessage(plugin.R("%p_n% was auto-kicked for using the term "+racism+"!"));
			plugin.KickPlayerWithMessage(player.Name, plugin.R("[Auto-Admin] Racist Language"));
			plugin.ConsoleWarn(plugin.R("%p_n% used the word: " +racism+""));
			plugin.Log("Logs/InsaneLimits_BWD.log", plugin.R("%date% %time% %p_n% "+racism+""));
			return true;
			
		}
	}
}

List<String> swears = new List<String>();
	swears.Add("cunt");
	swears.Add("cunts");

String[] chat_words = Regex.Split(player.LastChat, @"\s+");
    
foreach(String chat_word in chat_words) 
{
	foreach(String swear in swears)
	{
		if (Regex.Match(chat_word, "^"+swear+"$", RegexOptions.IgnoreCase).Success)
		{
			plugin.SendGlobalMessage(plugin.R("%p_n% please stop using the term "+swear+"! This is your only warning!"));
			plugin.ConsoleWarn(plugin.R("%p_n% used the word: " +swear+""));
			plugin.Log("Logs/InsaneLimits_BWD.log", plugin.R("%date% %time% %p_n% "+swear+""));
			return true;
			
		}
	}
}
Second_Check to Code:-

Code:

double count = limit.Activations ( player.Name );

if (count == 2)
{
	plugin.KickPlayerWithMessage(player.Name, plugin.R("[Auto-Admin] Bad Language"));
	plugin.SendGlobalMessage(plugin.R("%p_n% was kicked for using a prohibited word!"));
	plugin.ConsoleWarn(plugin.R("%p_n% was kicked for using a prohibited word!"));
}

return false;
Thanks :smile:
That's not quite right. In the case of a racist word, they get kicked and if they come back and do it again, they will get kicked twice, once in first_check and again in second_check.

 

I think it would be better to just write two separate limits. Alternatively, write the entire limit in second_check and just set first_check to Expression (true).

* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by PapaCharlie9*:

 

That's perfect, works like a champ, Papacharlie. Thanks very much!

 

Is there any way to add a player to the whitelist with an in-game command? Don't really want our admins mucking about in the plugins.

 

Hutchew

Unfortunately, no. It's supposed to work, but it's bugged.
* Restored post. It could be that the author is no longer active.
Link to comment

Originally Posted by DeviousDevil*:

 

Is there a way to have the Excessive Kill Rate Kicker (which I changed values and made it a excessive kill rate banner) to be able to put the banned persons guid into your ban list page? Because it banned 2 people for the stand in spawn and kill everyone hack today but it doesnt list them anywhere as being banned.. I used PBban.

* Restored post. It could be that the author is no longer active.
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.




  • Our picks

    • Game Server Hosting:

      We're happy to announce that EZRCON will branch out into the game server provider scene. This is a big step for us so please having patience if something doesn't go right in this area. Now, what makes us different compared to other providers? Well, we're going with the idea of having a scaleable server hosting and providing more control in how you set up your server. For example, in Minecraft, you have the ability to control how many CPU cores you wish your server to have access to, how much RAM you want to use, how much disk space you want to use. This type of control can't be offered in a single service package so you're able to configure a custom package the way you want it.

      You can see all the available games here. Currently, we have the following games available.

      Valheim (From $1.50 USD)


      Rust (From $3.20 USD)


      Minecraft (Basic) (From $4.00 USD)


      Call of Duty 4X (From $7.00 USD)


      OpenTTD (From $4.00 USD)


      Squad (From $9.00 USD)


      Insurgency: Sandstorm (From $6.40 USD)


      Changes to US-East:

      Starting in January 2022, we will be moving to a different provider that has better support, better infrastructure, and better connectivity. We've noticed that the connection/routes to this location are not ideal and it's been hard getting support to correct this. Our contract for our two servers ends in March/April respectively. If you currently have servers in this location you will be migrated over to the new provider. We'll have more details when the time comes closer to January. The new location for this change will be based out of Atlanta, GA. If you have any questions/concerns please open a ticket and we'll do our best to answer them.
      • 5 replies
    • Hello All,

      I wanted to give an update to how EZRCON is doing. As of today we have 56 active customers using the services offered. I'm glad its doing so well and it hasn't been 1 year yet. To those that have services with EZRCON, I hope the service is doing well and if not please let us know so that we can improve it where possible. We've done quite a few changes behind the scenes to improve the performance hopefully. 

      We'll be launching a new location for hosting procon layers in either Los Angeles, USA or Chicago, IL. Still being decided on where the placement should be but these two locations are not set in stone yet. We would like to get feedback on where we should have a new location for hosting the Procon Layers, which you can do by replying to this topic. A poll will be created where people can vote on which location they would like to see.

      We're also looking for some suggestions on what else you would like to see for hosting provider options. So please let us know your thoughts on this matter.
      • 4 replies
    • Added ability to disable the new API check for player country info


      Updated GeoIP database file


      Removed usage sending stats


      Added EZRCON ad banner



      If you are upgrading then you may need to add these two lines to your existing installation in the file procon.cfg. To enable these options just change False to True.

      procon.private.options.UseGeoIpFileOnly False
      procon.private.options.BlockRssFeedNews False



       
      • 2 replies
    • I wanted I let you know that I am starting to build out the foundation for the hosting services that I talked about here. The pricing model I was originally going for wasn't going to be suitable for how I want to build it. So instead I decided to offer each service as it's own product instead of a package deal. In the future, hopefully, I will be able to do this and offer discounts to those that choose it.

      Here is how the pricing is laid out for each service as well as information about each. This is as of 7/12/2020.

      Single MySQL database (up to 30 GB) is $10 USD per month.



      If you go over the 30 GB usage for the database then each additional gigabyte is charged at $0.10 USD each billing cycle. If you're under 30GB you don't need to worry about this.


      Databases are replicated across 3 zones (regions) for redundancy. One (1) on the east coast of the USA, One (1) in Frankfurt, and One (1) in Singapore. Depending on the demand, this would grow to more regions.


      Databases will also be backed up daily and retained for 7 days.




      Procon Layer will be $2 USD per month.


      Each layer will only allow one (1) game server connection. The reason behind this is for performance.


      Each layer will also come with all available plugins installed by default. This is to help facilitate faster deployments and get you up and running quickly.


      Each layer will automatically restart if Procon crashes. 


      Each layer will also automatically restart daily at midnight to make sure it stays in tip-top shape.


      Custom plugins can be installed by submitting a support ticket.




      Battlefield Admin Control Panel (BFACP) will be $5 USD per month


      As I am still working on building version 3 of the software, I will be installing the last version I did. Once I complete version 3 it will automatically be upgraded for you.





      All these services will be managed by me so you don't have to worry about the technical side of things to get up and going.

      If you would like to see how much it would cost for the services, I made a calculator that you can use. It can be found here https://ezrcon.com/calculator.html

       
      • 11 replies
    • I have pushed out a new minor release which updates the geodata pull (flags in the playerlisting). This should be way more accurate now. As always, please let me know if any problems show up.

       
      • 9 replies
×
×
  • Create New...

Important Information

Please review our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.