Raised This Month: $ Target: $400
 0% 

[v2.5.2, March 19] Trouble in Terrorist Town mod


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
bitterness.
Junior Member
Join Date: Jan 2016
Old 01-07-2016 , 02:50   Re: [v2.5.2, March 19] Trouble in Terrorist Town mod
Reply With Quote #11

Hi GuskiS, first of all sorry for my "bad english".

Now, I downloaded the last version of this mod and install it on my server.
I have a problem with "ttt_warning_system.amxx". I set "bg" in "ttt_warnings_punishment" but the ban punishment doesn't work (kick, bad aim, remove karma do work).

PHP Code:
public plugin_init()
{
    
register_plugin("[TTT] Warning system"TTT_VERSIONTTT_AUTHOR);

    
cvar_warnings_special        my_register_cvar("ttt_warnings_special",        "2",    "Max warnings for killing Traitor or Detective wrongly, for example, Detective kills Detective. (Default: 2)");
    
cvar_warnings_innocent        my_register_cvar("ttt_warnings_innocent",        "3",    "Max warnings for killing Innocent wrongly. (Default: 3)");
    
cvar_warnings_continued        my_register_cvar("ttt_warnings_continued",    "3",    "Max continued warnings for killing wrongly, for example, kill wrongly Innocent, Detective, Innocent. (Default: 3)");
    
cvar_warnings_punishment    my_register_cvar("ttt_warnings_punishment",    "bg",    "Punishment types: a=kick, b=ban, c=remove karma, d=hp to 1, e=blind, f=bad aim, g=ban on low karma. (Default: cdf)");
    
cvar_warnings_bantime        my_register_cvar("ttt_warnings_bantime",        "30",    "Ban time if ttt_ar_warnings_punishment has B. (Default: 60)");
    
cvar_warnings_players        my_register_cvar("ttt_warnings_players",        "5",    "Minimum players to start warn them. (Default: 5)");
    
cvar_warnings_blind_time    my_register_cvar("ttt_warnings_blind_time",    "60",    "Blind time in seconds. (Default: 60)");
    
cvar_warnings_minkarma        my_register_cvar("ttt_warnings_minkarma",        "300",    "Ban if karma <= X. (Default: 300)"); 
PHP Code:
            server_cmd("amx_banip %d #%d TK:%s"get_pcvar_num(cvar_warnings_bantime), get_user_userid(killer), reason);
            
g_iWarnings[killer][WARN_BANNED] = true
PHP Code:
stock ban_user_lowkarma(id)
{
    new 
karma ttt_get_playerdata(idPD_KARMATEMP);
    if(
karma <= get_pcvar_num(cvar_warnings_minkarma))
    {
        
server_cmd("amx_banip %d #%d MIN_KARMA:%d"get_pcvar_num(cvar_warnings_bantime), get_user_userid(id), karma);
        
g_iWarnings[id][WARN_BANNED] = true;
    }

I don't know if it's something wrong in some lines, but those codes are default (not the first one).

Thanks.
bitterness. is offline
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:06.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode