Raised This Month: $32 Target: $400
 8% 

Help About simple vip plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Ali0mer
Senior Member
Join Date: Jan 2016
Location: Iraq
Old 12-21-2018 , 14:37   Help About simple vip plugin
Reply With Quote #1

Hello Guys,

I need help to create a .ini file for vip in this plugin
Like users.ini different file where i can add vip for players

Code Below please help me!

Code:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#include <zombieplague> 
#include <hamsandwich>


#define ADMIN_FLAG ADMIN_LEVEL_H

enum
{
    SCOREATTRIB_ARG_PLAYERID = 1,
    SCOREATTRIB_ARG_FLAGS
};

enum ( <<= 1 )
{
    SCOREATTRIB_FLAG_NONE = 0,
    SCOREATTRIB_FLAG_DEAD = 1,
    SCOREATTRIB_FLAG_BOMB,
    SCOREATTRIB_FLAG_VIP
};

new g_iStartHealth, g_iStartArmor

public plugin_init()
{
    register_plugin("Simple VIP", "0.1", "Alliedmodder")
    
    RegisterHam(Ham_Spawn, "player", "OnPlayerSpawnPost", 1)
    RegisterHam(Ham_Killed, "player", "OnPlayerKilled")

    g_iStartHealth = register_cvar("sv_start_HP", "150")
    g_iStartArmor = register_cvar("sv_start_armor", "100")
    
    register_message( get_user_msgid( "ScoreAttrib" ), "MessageScoreAttrib" );
}

public OnPlayerSpawnPost(id)
{
    if(is_user_alive(id) && get_user_flags(id) & ADMIN_FLAG)
    {
        set_pev(id, pev_health, get_pcvar_float(g_iStartHealth))
        set_pev(id, pev_armorvalue, get_pcvar_float(g_iStartArmor))
    }
}

public OnPlayerKilled(victim, attacker)
{
    if(!is_user_alive(attacker) || victim == attacker)
        return
}


public MessageScoreAttrib( iMsgId, iDest, iReceiver )
{
        new iPlayer = get_msg_arg_int( SCOREATTRIB_ARG_PLAYERID );
        
        if( access( iPlayer, ADMIN_FLAG ) )
        {
            set_msg_arg_int( SCOREATTRIB_ARG_FLAGS, ARG_BYTE, SCOREATTRIB_FLAG_VIP );
        }
}
Ali0mer is offline
Send a message via Skype™ to Ali0mer
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 12-21-2018 , 15:49   Re: Help About simple vip plugin
Reply With Quote #2

What's the issue with adding the VIP flag in users.ini?
What's the point of using a separate file for something that is already doable with default AMXX?
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Ali0mer
Senior Member
Join Date: Jan 2016
Location: Iraq
Old 12-22-2018 , 01:59   Re: Help About simple vip plugin
Reply With Quote #3

Hii oci

If you say I don’t need a separate file
Then can you help me adding a model into this plugin? Model for vip
Ali0mer is offline
Send a message via Skype™ to Ali0mer
Natsheh
Veteran Member
Join Date: Sep 2012
Old 12-22-2018 , 03:33   Re: Help About simple vip plugin
Reply With Quote #4

If you wait a bit i will release a vip system with alot of features + amxbans vip settings.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !

Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
Ali0mer
Senior Member
Join Date: Jan 2016
Location: Iraq
Old 12-22-2018 , 06:54   Re: Help About simple vip plugin
Reply With Quote #5

I just want a Smiple plugin not with a lot of features
Thats why i use this plugin in first post!

But my problem is i need to Add a model in it
Ali0mer is offline
Send a message via Skype™ to Ali0mer
Natsheh
Veteran Member
Join Date: Sep 2012
Old 12-22-2018 , 07:48   Re: Help About simple vip plugin
Reply With Quote #6

My problem is i cant release something redundant.
If you don't want to be patient you can wait for others to help or look up for tutorials and fix it yourself.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !


Last edited by Natsheh; 12-22-2018 at 07:50.
Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 12-22-2018 , 08:36   Re: Help About simple vip plugin
Reply With Quote #7

Then go ahead and add it. This is the scripting help section, so you script by yourself.
How is creating an .ini file going to help with the model?...
__________________

Last edited by OciXCrom; 12-22-2018 at 08:37.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Nutu_
AlliedModders Donor
Join Date: Mar 2016
Location: Germany
Old 12-22-2018 , 09:15   Re: Help About simple vip plugin
Reply With Quote #8

you can add another plugin for VIP Model, no need to merge
__________________
a simple act of caring creates an endless ripple.
Nutu_ is offline
Ali0mer
Senior Member
Join Date: Jan 2016
Location: Iraq
Old 12-22-2018 , 14:29   Re: Help About simple vip plugin
Reply With Quote #9

Quote:
Originally Posted by OciXCrom View Post
Then go ahead and add it. This is the scripting help section, so you script by yourself.
How is creating an .ini file going to help with the model?...
You are useless
Just talking not helping if you can’t help then you don’t need to reply on my topic
Ali0mer is offline
Send a message via Skype™ to Ali0mer
Ali0mer
Senior Member
Join Date: Jan 2016
Location: Iraq
Old 12-22-2018 , 14:30   Re: Help About simple vip plugin
Reply With Quote #10

Quote:
Originally Posted by Nutu_ View Post
you can add another plugin for VIP Model, no need to merge
Thank you my friend
Ali0mer is offline
Send a message via Skype™ to Ali0mer
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 17:11.


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