Page 10 of 11 FirstFirst ... 891011 LastLast
Results 91 to 100 of 104
  1. #91
    Senior Member
    Join Date
    Apr 2012
    Location
    Manhester UK
    Posts
    169
    I did what you asked but the limit doesnt seem to work, no errors are reported either.

    Here is what i have

    limited virtualmode false

    limit enabled.
    first check expression
    Code:
    ! Regex.Match(kill.Weapon, @"(U_A91|U_ACR|U_AEK971|U_AK12|U_AK5C|U_AKU12|U_AMR2|U_AMR2_CQB|U_AMR2_MED|U_AR160|U_ASVAL|U_AWS|U_Bulldog|U_CBJ-MS|U_CS-LR4|U_CS5|U_CZ805|U_CZ75|U_DesertEagle|U_Defib|EODBot|U_F2000|U_FAMAS|U_Flashbang|U_FN57|U_FY-JS|U_G36C|U_GalilACE|U_GalilACE23|U_GalilACE52|U_GalilACE53|U_Glock18|U_GOL|U_Grenade_RGO|U_HK45C|U_JNG90|U_JS2|U_L85A2|U_L96A1|U_LSAT|U_M16A4|U_M1911|U_M200|U_M240|U_M249|U_M39EBR|U_M40A5|U_M416|U_M4A1|U_M60E4|U_M67|U_M82A3|U_M82A3_CQB|U_M82A3_MED|U_M9|U_M93R|U_M98B|U_MagpulPDR|U_Medkit|U_MG4|U_MK11|U_MP7|U_MP412Rex|U_MP443|U_MTAR21|U_MPX|U_MX4|U_P226|U_P90|U_Pecheneg|U_PortableMedicpack|U_PP2000|U_QBB95|U_QBU88|U_QBZ951|U_QSZ92|U_Repairtool|U_RFB|U_RPK12|U_RPK-74|U_SAR21|U_SCAR-H|U_SCAR-HSV|U_Scorpion|U_Scout|U_SG553LB|U_SKS|U_SR2|U_SR338|U_SRS|U_SteyrAug|U_SV98|U_SVD12|U_SW40|U_Taurus44|U_Type88|U_Type95B|U_Ultimax|U_UMP9|U_UMP45|U_Unica6|U_V4|Melee|Suicide|SoldierCollision|DamageArea|Death|)", RegexOptions.IgnoreCase).Success
    second check code

    Code:
       double count = limit.Activations(player.Name);
    	
    	if (count == 1)
    	{
    	    plugin.KillPlayer(player.Name);
    	    plugin.SendPlayerMessage(player.Name, plugin.R ("%p_n%, this weapon is not allowed on this server, do not use %w_n% again! Next time kick"));
    	}
    	
    	else if (count == 2)
    	{
                plugin.KickPlayerWithMessage(player.Name, plugin.R("%p_n%, kicked you for using %w_n% on This server"));
                plugin.PRoConChat(plugin.R("%p_n% has been kicked for using %w_n%"));
    	}
    
     return false;

  2. #92
    Remove the final | after Death, that might cause a problem.

    How do you know it does not work? What weapon did you test with?
    Don't send me private messages (PMs) unless you really need privacy, like your game server password. If you just have a question or need help, post in one of the threads. It's extra work for me to answer questions and give help in private messages and no one else gets the benefit of the answer.

  3. #93
    What is the Phantom Bow code for Insane Limits 0.2.17.0?
    After three days searching, alas i've found nothing but the old regix code stuff.
    Please help.

    I am running the script for Bow/Pistol/Knife. Knife and Pistol seem to work fine. But it still kills you on bow shots.

    In the line:

    if (!isPistolsOnly || kill.Category == "Handgun" || kill.Category == "Melee" || kill.Category == "Knife" || kill.Category == "Phantom") return false;

    I have tried; Phantom, Bow, Phantom Bow, dlSHTR. Is my syntax incorrect?
    Last edited by Random_Digits; 16-04-2015 at 16:50.

  4. #94
    Member
    Join Date
    Dec 2010
    Location
    Portland, OR USA
    Posts
    49
    I know, old thread, but
    I'm simply trying to have a BF4 server where only the melee (knife) can be used, killing first offense, kicking the second (want to change to a ban once the code is working).
    I'm currently trying the following, and it's not enforcing at all, even though it's compiling with no errors:
    Eval: OnKill, action: None
    1st check: expression:
    Code:
    ! Regex.Match(kill.Weapon, @"(Melee|Suicide|SoldierCollision|DamageArea|Death)", RegexOptions.IgnoreCase).Success
    2nd check: Code
    Code:
    double count = limit.Activations(player.Name);    
        if (count == 1)
        {
            plugin.KillPlayer(player.Name);
            plugin.SendPlayerMessage(player.Name, plugin.R ("%p_n%, this is a melee only server, do not use %w_n% again! Next time kick"));
        }
        
        else if (count == 2)
        {
                plugin.KickPlayerWithMessage(player.Name, plugin.R("%p_n%, kicked you for using %w_n% on melee only server"));
                plugin.PRoConChat(plugin.R("%p_n% has been kicked."));
        }
    
    
     return false;
    Trying to figure out where I'm going wrong. I do have use_direct_fetch set to false and use_slow_weapon_stats set to True.
    Anyone see something amiss?
    Thank you so very much for all you do and your help.
    Last edited by BizSAR; 08-06-2018 at 06:25.
    ~BizSAR
    EVGA/PDXLAN game server admin

  5. #95
    The code looks valid. Perhaps it's not correctly enabled? Or you have virtual mode on for the limit?
    ____

  6. #96
    Member
    Join Date
    Dec 2010
    Location
    Portland, OR USA
    Posts
    49
    Thanks for the response!
    virtual_mode is false and limit_1_state is Enabled.
    Capture.PNG
    ~BizSAR
    EVGA/PDXLAN game server admin

  7. #97
    Senior Member
    Join Date
    Apr 2013
    Location
    Russia
    Posts
    246
    If "Melee" used as "kill.Weapon" condition then it checks a face-to-face attack (without animation).
    You need to add weapon "U_Knife" to condition.
    Or use "kill.Category" but in this case the defibrillator and repairtool will also be allowed.

    1)
    Code:
    ! Regex.Match(kill.Weapon, @"(U_Knife|Melee|Suicide|SoldierCollision|DamageArea|Death)", RegexOptions.IgnoreCase).Success
    2)
    Code:
    (!Regex.Match(kill.Weapon, @"(Death)", RegexOptions.IgnoreCase).Success && !Regex.Match(kill.Category, @"(Melee|Suicide)", RegexOptions.IgnoreCase).Success)
    Last edited by Chilace; 11-06-2018 at 02:53.

  8. #98
    Member
    Join Date
    Dec 2010
    Location
    Portland, OR USA
    Posts
    49
    Thank you!!
    Just one more Q: How would I change the second check code to kick on first offense, ban for 120 minutes on the second?
    ~BizSAR
    EVGA/PDXLAN game server admin

  9. #99
    Quote Originally Posted by BizSAR View Post
    Thank you!!
    Just one more Q: How would I change the second check code to kick on first offense, ban for 120 minutes on the second?
    Thinking about why you want to do something is very important.
    I believe kicking on first offense is an overly strict rule and doesn't give new players a chance to come back from a mistake.
    ____

  10. #100
    Member
    Join Date
    Dec 2010
    Location
    Portland, OR USA
    Posts
    49
    Well, normally yes, but it is for a short, fun little contest we're doing for PDXLAN on a private server. Long story short, it's 10 people able to use any weapons (whitelisted) vs. 54 that can only use knives.
    On a public server, I certainly don't set the punishments that way.
    ~BizSAR
    EVGA/PDXLAN game server admin

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •