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

Paintball VIP plugin request


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Grav3yardman
Member
Join Date: Oct 2021
Old 11-02-2021 , 12:40   Paintball VIP plugin request
Reply With Quote #1

Hi. I request paintball VIP plugin.That plugin should contain:
- Free defusers kit at roundstart.
- Free granades at roundstart(HE,2x FB,SG).
- 200HP and 100armor at roundstart.
- Lower gravity.
- VIP tag in scoreboard
- [VIP] Prefix with green chat
- Slot reservation
- Write /vips u will see VIP's online.
- Unlimited ammo
Vip should be given for example: amx_addvip "name/id" "pw(a password that a player would type in the console (setinfo _pw "pw")" "days (How many days)"

P.S I tried to make a plugin like this myself but without success

Last edited by Grav3yardman; 11-02-2021 at 12:42.
Grav3yardman is offline
SHIFT0
Senior Member
Join Date: Apr 2021
Location: Palestine
Old 11-02-2021 , 12:42   Re: Paintball VIP plugin request
Reply With Quote #2

https://forums.alliedmods.net/showthread.php?t=293017
https://forums.alliedmods.net/showthread.php?t=211627
Search next time

Last edited by SHIFT0; 11-02-2021 at 12:42.
SHIFT0 is offline
Grav3yardman
Member
Join Date: Oct 2021
Old 11-02-2021 , 12:44   Re: Paintball VIP plugin request
Reply With Quote #3

This is not the plugin I requested and what should I do with it?

Last edited by Grav3yardman; 11-02-2021 at 12:48.
Grav3yardman is offline
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 11-02-2021 , 12:57   Re: Paintball VIP plugin request
Reply With Quote #4

I will start working on this, don't expect this to be done anytime soon though.
__________________
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
Grav3yardman
Member
Join Date: Oct 2021
Old 11-02-2021 , 12:58   Re: Paintball VIP plugin request
Reply With Quote #5

Thank you very much
Grav3yardman is offline
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 11-02-2021 , 15:20   Re: Paintball VIP plugin request
Reply With Quote #6

This is what i have so far. Please keep in mind that i DO NOT have a test server, so all testing will have to be done by you.

Items from your list that are done so far:

- Free defusers kit at roundstart.
- Free granades at roundstart(HE,2x FB,SG).
- 200HP and 100armor at roundstart.
- VIP tag in scoreboard
- Unlimited Ammo
- lower gravity: amx_cvar pb_gravity
- Write /vips u will see VIP's online.
- Slot reservation.

PHP Code:
/* Sublime AMXX Editor v2.2 */

#include <amxmodx>
#include <cromchat>
// #include <amxmisc>
#include <cstrike>
// #include <engine>
// #include <fakemeta>
#include <hamsandwich>
#include <fun>
// #include <xs>
// #include <sqlx>

#pragma semicolon 1

#if AMXX_VERSION_NUM < 183
    
const MAX_PLAYERS 32;
    const 
MAX_NAME_LENGTH 32;
#endif

#define ADMIN_VIP ADMIN_LEVEL_H    

new const g_szVersion[] = "1.0.0";

new const 
g_iExcludedWeapons[] =
{
    
CSW_C4,
    
CSW_KNIFE,
    
CSW_HEGRENADE,
    
CSW_SMOKEGRENADE,
    
CSW_FLASHBANG
};

new 
g_szScoreAttribMsg;

new 
g_pGravity;
new 
g_pSlots;

public 
plugin_init()
{
    
register_plugin("Paintball VIP"g_szVersion"NapoleoN#");

    
register_clcmd("say /vips""showVipsOnline");

    
RegisterHam(Ham_Spawn"player""playerSpawnPost"1);

    
register_event("CurWeapon""currentWeapon""be""1=1");

    
register_logevent("roundStart"2"1=Round_Start");

    
g_szScoreAttribMsg get_user_msgid("ScoreAttrib");
    
register_message(g_szScoreAttribMsg"showVipScoreboard");

    
g_pGravity register_cvar("pb_gravity""700");
    
g_pSlots register_cvar("pb_slots""1");
}

public 
client_authorized(id)
{
    new 
iPlayerNum get_playersnum(1);
    new 
iPlayerLimit MAX_PLAYERS get_pcvar_num(g_pSlots);
    new 
iRegularPlayers iPlayerNum getVipsOnline();

    if(
iRegularPlayers iPlayerLimit)
    {
        new 
szMessage[100];
        
formatex(szMessagecharsmax(szMessage), "Kicked: slot reservation.");

        
message_begin(MSG_ONESVC_DISCONNECT,_id);
        
write_string(szMessage);
        
message_end();
    }
}

public 
showVipsOnline(id)
{
    new 
szMainBuffer[128], szTempBuffer[34], szVipName[MAX_NAME_LENGTH], iVipCountiVipIndex;

    
formatex(szMainBuffercharsmax(szMainBuffer), "^3[VIP's] Online:^4 ");

    if(
getVipsOnline())
    {
        new 
iPlayers[MAX_PLAYERS], iPlayerCount;
        
get_players(iPlayersiPlayerCount"ch");

        for(new 
iiPlayerCounti++)
        {
            
iVipIndex iPlayers[i];
            if(!
isPlayerVip(iVipIndex))
            {
                continue;
            }

            
iVipCount++;

            
get_user_name(iVipIndexszVipNamecharsmax(szVipName));
            
formatex(szTempBuffercharsmax(szTempBuffer), "%s%s"szVipNameiVipCount == "." ", ");
            
add(szMainBuffercharsmax(szMainBuffer), szTempBuffer);
        }
    }

    else 
    {
        
add(szMainBuffercharsmax(szMainBuffer), "There are no vip's online!");
    }

    
ColorChat(idTEAM_COLOR"%s"szMainBuffer);
}

public 
playerSpawnPost(id)
{
    if(!
is_user_alive(id) || !isPlayerVip(id))
    {
        return;
    }

    
message_begin(MSG_ALLg_szScoreAttribMsg);
    
write_byte(id);
    
write_byte((1<<2));
    
message_end();
}

public 
currentWeapon(id)
{
    if(!
is_user_alive(id) || !isPlayerVip(id))
    {
        return;
    }

    new 
iWeapon read_data(2);
    static const 
m_pActiveItem 373;

    for(new 
isizeof(g_iExcludedWeapons); i++)
    {

        if(
iWeapon == g_iExcludedWeapons[i])
        {
            break;
        }

        
cs_set_weapon_ammo(get_pdata_cbase(idm_pActiveItem), 10);
    }
}

public 
roundStart()
{
    new 
iPlayers[MAX_PLAYERS], iPlayerCountiVipIndex;
    
get_players(iPlayersiPlayerCount"ach");

    new 
Float:iOriginalGravity 800.0;
    new 
Float:iLowerGravity get_pcvar_float(g_pGravity) / iOriginalGravity;

    for(new 
iiPlayerCounti++) 
    {
        
iVipIndex iPlayers[i];

        if(!
isPlayerVip(iVipIndex))
        {
            continue;
        }

        
give_item(iVipIndex"weapon_hegrenade");
        
give_item(iVipIndex"weapon_flashbang");
        
give_item(iVipIndex"weapon_smokegrenade");

        
cs_set_user_bpammo(iVipIndexCSW_FLASHBANG2);

        
set_user_health(iVipIndex200);
        
set_user_armor(iVipIndex100);


        
set_user_gravity(iVipIndexiLowerGravity);
    }

    
get_players(iPlayersiPlayerCount"aceh""CT");

    for(new 
iiPlayerCounti++)
    {
        
iVipIndex iPlayers[i];

        if(!
isPlayerVip(iVipIndex))
        {
            continue;
        }

        
give_item(iVipIndex"item_thighpack");
    }
}

public 
showVipScoreboard(const iMsg, const iType, const iDest)
{
    static 
id;
    
id get_msg_arg_int(1);

    if(
isPlayerVip(id) && !get_msg_arg_int(2))
    {
        
set_msg_arg_int(2ARG_BYTE, (<< 2));
    }
}

getVipsOnline()
{
    new 
iPlayers[MAX_PLAYERS], iPlayerCountiVipCountiVipIndex;
    
get_players(iPlayersiPlayerCount"chi");

    for(new 
iiPlayerCounti++)
    {
        
iVipIndex iPlayers[i];
        if(!
isPlayerVip(iVipIndex))
        {
            continue;
        }

        
iVipCount++;
    }

    return 
iVipCount;
}

bool:isPlayerVip(id)
{
    return (
get_user_flags(id) & ADMIN_VIP) ? true false;

__________________

Last edited by Napoleon_be; 11-03-2021 at 18:47.
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
Grav3yardman
Member
Join Date: Oct 2021
Old 11-03-2021 , 06:16   Re: Paintball VIP plugin request
Reply With Quote #7

I tested this plugin on my server and it has a few bugs:
1.No VIp tag in scoreboard
2.No perfix
3.When I type / vips shows me only "No online vips" (but I am vip)
4.No unlimited ammo
5.Whoever enters the server has a VIP
5.There is no command to give VIP to others ( how many days,everyone who has a VIP has their own password)
Example: amx_addvip "name/id" "pw" "how many days"

Last edited by Grav3yardman; 11-03-2021 at 06:18.
Grav3yardman is offline
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 11-03-2021 , 06:21   Re: Paintball VIP plugin request
Reply With Quote #8

I stated in my previous post which parts are done. Point 5 is not one of them. Please show me some debug logs at least if u have some.

I've changed the VIP flag to ADMIN_LEVEL_H (flag "t"). Please try again.

Previous flag was set to ADMIN_ADMIN ("y") which is most likely never used.
__________________

Last edited by Napoleon_be; 11-03-2021 at 06:24.
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
Grav3yardman
Member
Join Date: Oct 2021
Old 11-03-2021 , 06:26   Re: Paintball VIP plugin request
Reply With Quote #9

I dont have debug logs.
Grav3yardman is offline
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 11-03-2021 , 06:28   Re: Paintball VIP plugin request
Reply With Quote #10

Quote:
Originally Posted by Grav3yardman View Post
I dont have debug logs.
Do u read everything that i type? Test again and get back to me.
__________________
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
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 18:52.


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