Raised This Month: $51 Target: $400
 12% 

VIP Plugin v5.4.5


Post New Thread Reply   
 
Thread Tools Display Modes
Unkolix
Veteran Member
Join Date: Sep 2012
Old 04-18-2013 , 07:46   Re: VIP Plugin v5.3.9
Reply With Quote #31

Quote:
Originally Posted by alicx View Post
vip flag is the flag "H" of the Admin
Wrong. It's flag "t", level H.
Unkolix is offline
hix
Member
Join Date: Apr 2013
Old 04-18-2013 , 11:46   Re: VIP Plugin v5.3.9
Reply With Quote #32

can you add prefix [vip] in future ?
hix is offline
Unkolix
Veteran Member
Join Date: Sep 2012
Old 04-18-2013 , 12:23   Re: VIP Plugin v5.3.9
Reply With Quote #33

Quote:
Originally Posted by hix View Post
can you add prefix [vip] in future ?
I might, but I've broken my right hand finger today, won't be to active on this for a week or two...
Unkolix is offline
Unkolix
Veteran Member
Join Date: Sep 2012
Old 04-28-2013 , 16:36   Re: VIP Plugin v5.4.0
Reply With Quote #34

VIP Plugin v5.4.0
  • v5.4.0 - If files awpmapnames.ini and mapnames.ini are missing, they are automatically created.
  • v5.3.9 - MotD improvement, no need for other .txt files. Example taken from: souvikdas95
Unkolix is offline
alicx
BANNED
Join Date: Mar 2013
Location: Tunisia
Old 04-29-2013 , 08:21   Re: VIP Plugin v5.4.0
Reply With Quote #35

why do you don't show vip like this:



This code can help you
PHP Code:
#include <amxmodx>

#define g_Buffer 1536



new Array:g_Arraybool:g_Vip[33];

new const 
g_Langcmd[][]={"say /vips","say_team /vips"};

public 
plugin_init(){
    
register_plugin("Mtod Show vip""1.0""Alicx");
    
g_Array=ArrayCreate(64,32);
    for(new 
i;i<sizeof g_Langcmd;i++){
        
register_clcmd(g_Langcmd[i], "ShowVips");
    }
}
public 
client_authorized(id){
    if(
get_user_flags(id) & 524288 == 524288){
        
client_authorized_vip(id);
    }
}
public 
client_authorized_vip(id){
    
g_Vip[id]=true;
    new 
g_Name[64];
    
get_user_name(id,g_Name,charsmax(g_Name));
    
    new 
g_Size ArraySize(g_Array);
    new 
szName[64];
    
    for(new 
0g_Sizei++){
        
ArrayGetString(g_ArrayiszNamecharsmax(szName));
        
        if(
equal(g_NameszName)){
            return 
0;
        }
    }
    
ArrayPushString(g_Array,g_Name);
    
    return 
PLUGIN_CONTINUE;
}
public 
client_disconnect(id){
    if(
g_Vip[id]){
        
client_disconnect_vip(id);
    }
}
public 
client_disconnect_vip(id){
    
g_Vip[id]=false;
    new 
Name[64];
    
get_user_name(id,Name,charsmax(Name));
    
    new 
g_Size ArraySize(g_Array);
    new 
g_Name[64];
    
    for(new 
0g_Sizei++){
        
ArrayGetString(g_Arrayig_Namecharsmax(g_Name));
        
        if(
equal(g_Name,Name)){
            
ArrayDeleteItem(g_Array,i);
            break;
        }
    }
}
public 
ShowVips(id){
    
ShowVipsMotd(id);
    return 
PLUGIN_CONTINUE;
}
public 
ShowVipsMotd(id){
    new 
Data[g_Buffer],Len,g_Name[64];
    
    
Len formatex(Data[Len], g_Buffer Len"<html><body bgcolor=Black><br>");
    
Len += formatex(Data[Len], g_Buffer Len"<center><table frame=^"border^" width=^"600^" cellspacing=^"0^" bordercolor=#4A4344 style=^"color:#56A5EC;text-align:center;^">");
    
Len += formatex(Data[Len], g_BufferLen"<tr><td><b>#</b></td><td><b>Nick</b></td></td></tr>");
    
    new 
g_Size=ArraySize(g_Array);
    
    for(new 
0g_Sizei++){
        
ArrayGetString(g_Arrayig_Namecharsmax(g_Name));
        
        
Len += formatex(Data[Len], g_Buffer Len"<tr>");
        
Len += formatex(Data[Len], g_Buffer Len"<td><font color=Red>%d</font></td>"1);
        
Len += formatex(Data[Len], g_Buffer Len"<td>%s</td>"g_Name);
        
Len += formatex(Data[Len], g_Buffer Len"</tr>");
    }
    
Len += formatex(Data[Len],g_Buffer Len,"</center></body></html>");
    
    
show_motd(idData"Vips Online [By Alicx]");
}
public 
client_infochanged(id){
    if(
g_Vip[id]){
        new 
szName[64];
        
get_user_info(id,"name",szName,charsmax(szName));
        
        new 
Name[64];
        
get_user_name(id,Name,charsmax(Name));
        
        if(!
equal(szName,Name)){
            
ArrayPushString(g_Array,szName);
            
            new 
g_Size=ArraySize(g_Array);
            new 
g_Name[64];
            for(new 
0g_Sizei++){
                
ArrayGetString(g_Arrayig_Namecharsmax(g_Name));
                
                if(
equal(g_Name,Name)){
                    
ArrayDeleteItem(g_Array,i);
                    break;
                }
            }
        }
    }
}
public 
plugin_end(){
    
ArrayDestroy(g_Array);
}
public 
amxbans_admin_connect(id){
    
client_authorized(id);

and if possible add a cvar to choose how to display vip online :
show_vip # (if 0 don't show/ if 1 show on print / if 2 show on mtod)

Last edited by alicx; 04-29-2013 at 08:31.
alicx is offline
Send a message via MSN to alicx Send a message via Skype™ to alicx
Old 04-29-2013, 08:24
alicx
This message has been deleted by ConnorMcLeod. Reason: Read rules https://forums.alliedmods.net/misc.php?do=showrules
Old 04-29-2013, 08:26
alicx
This message has been deleted by ConnorMcLeod. Reason: Read rules https://forums.alliedmods.net/misc.php?do=showrules
Old 04-29-2013, 08:27
alicx
This message has been deleted by ConnorMcLeod. Reason: Read rules https://forums.alliedmods.net/misc.php?do=showrules
Unkolix
Veteran Member
Join Date: Sep 2012
Old 04-29-2013 , 11:10   Re: VIP Plugin v5.4.4
Reply With Quote #36

Thanks alicx. You helped me a lot, but your motd picture looks different from mine motd...
I didn't add anything except the motd thingy, with a new cvar, gonna try adding the VIP prefix later. The other ideas are useless I believe...

VIP Plugin v5.4.4
  • v5.4.4 - A new cvar to control how to show online vip list. vip_list 0/1/2. off/chat/motd. Thanks to alicx
  • v5.4.3 - Edited all cvars, vip_ prefix added. color_msg now changes /vips colors and vip info color.
  • v5.4.2 - Added a cvar for vip price show: vip_price "price"
  • v5.4.1 - Renewed amx_contactinfo cvar, now it will be shown when player types /vips and in want vip MotD.
Unkolix is offline
alicx
BANNED
Join Date: Mar 2013
Location: Tunisia
Old 04-29-2013 , 11:19   Re: VIP Plugin v5.4.4
Reply With Quote #37

no problem
if you need any thing just tell me and i will help you if i can ;)
alicx is offline
Send a message via MSN to alicx Send a message via Skype™ to alicx
Unkolix
Veteran Member
Join Date: Sep 2012
Old 04-29-2013 , 11:51   Re: VIP Plugin v5.4.4
Reply With Quote #38

Quote:
Originally Posted by alicx View Post
no problem
if you need any thing just tell me and i will help you if i can ;)
I believe you could try to download this plugin and edit the /vips to show in a MotD and see how does it show for you... Because for me, it's in a very strange way, the inside the square, there's no lines...
Unkolix is offline
alicx
BANNED
Join Date: Mar 2013
Location: Tunisia
Old 04-29-2013 , 11:52   Re: VIP Plugin v5.4.4
Reply With Quote #39

hey unkolix i there is a mistake in the translation of french correct it:
PHP Code:
CHOSE_M4A1 Vous venez de remporter un M4A1 avec Deagle!
CHOSE_AK47 Vous venez de remporter un AK47 avec Deagle!
CHOSE_AWP Vous venez de remporter un AWP avec Deagle

PHP Code:
CHOSE_M4A1 Vous venez de recevoir un M4A1 avec Deagle!
CHOSE_AK47 Vous venez de recevoir un AK47 avec Deagle!
CHOSE_AWP Vous venez de recevoir un AWP avec Deagle
alicx is offline
Send a message via MSN to alicx Send a message via Skype™ to alicx
Old 04-29-2013, 13:11
alicx
This message has been deleted by ConnorMcLeod. Reason: Read rules https://forums.alliedmods.net/misc.php?do=showrules
Unkolix
Veteran Member
Join Date: Sep 2012
Old 04-29-2013 , 13:14   Re: VIP Plugin v5.4.4
Reply With Quote #40

Lol... VIP's already have 70% of their time on the server 16000$...
But still, I might add this if you will tell me default values that you get without this code.
Unkolix is offline
Reply



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 08:18.


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