Raised This Month: $ Target: $400
 0% 

Edit plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
radussteam
Junior Member
Join Date: Sep 2014
Old 12-19-2014 , 06:19   Edit plugin
Reply With Quote #1

Hello

Please add:
Prefix: [V.I.P] on say
Prefix on boardscore [V.I.P]

Code:
#include <sourcemod> 
#include <sdktools> 

public Plugin:myinfo =  
{ 
    name = "Simple VIP plugin", 
    author = "ESK0", 
    description = "Simple VIP plugin for radussteam", 
    version = "1.0", 
    url = "www.cs.overcore.eu" 
} 

public OnPluginStart() 
{ 
    HookEvent("round_start", roundStart); 
} 
public Action:roundStart(Handle:event, const String:name[], bool:dontBroadcast) 
{ 
    for ( new client = 1 ; client <= MaxClients+1 ; client++){ 
        if (IsValidClient(client, true)){ 
            if (GetAdminFlag(GetUserAdmin(client), Admin_Custom1)){ 
                decl CurrentMoney; 
                CurrentMoney = GetEntProp(client, Prop_Send, "m_iAccount"); 
                SetEntProp(client, Prop_Send, "m_iAccount", CurrentMoney + 250); 
                GivePlayerItem(client, "weapon_hegrenade"); 
                GivePlayerItem(client, "weapon_smokegrenade"); 
                GivePlayerItem(client, "weapon_decoy"); 
                GivePlayerItem(client, "weapon_flashbang"); 
                GivePlayerItem(client, "weapon_molotov"); 
            } 
        } 
    } 
} 
stock bool:IsValidClient(client, bool:alive = false) 
{ 
    return (client >= 1 && client <= MaxClients && IsClientConnected(client) && IsClientInGame(client) && (alive == false || IsPlayerAlive(client))); 
}

Last edited by radussteam; 12-19-2014 at 06:35.
radussteam is offline
The1Speck
SourceMod Donor
Join Date: Oct 2014
Location: USA
Old 12-19-2014 , 16:16   Re: Edit plugin
Reply With Quote #2

Here's the scoreboard VIP addition.

PHP Code:
#include <sourcemod> 
#include <sdktools>
#include <cstrike>

public Plugin:myinfo =  

    
name "Simple VIP plugin"
    
author "ESK0"
    
description "Simple VIP plugin for radussteam"
    
version "1.0"
    
url "www.cs.overcore.eu" 


public 
OnPluginStart() 

    
HookEvent("round_start"roundStart); 

public 
Action:roundStart(Handle:event, const String:name[], bool:dontBroadcast

    for ( new 
client client <= MaxClients+client++){ 
        if (
IsValidClient(clienttrue)){ 
            if (
GetAdminFlag(GetUserAdmin(client), Admin_Custom1)){ 
                
decl CurrentMoney
                
CurrentMoney GetEntProp(clientProp_Send"m_iAccount"); 
                
SetEntProp(clientProp_Send"m_iAccount"CurrentMoney 250); 
                
GivePlayerItem(client"weapon_hegrenade"); 
                
GivePlayerItem(client"weapon_smokegrenade"); 
                
GivePlayerItem(client"weapon_decoy"); 
                
GivePlayerItem(client"weapon_flashbang"); 
                
GivePlayerItem(client"weapon_molotov"); 
                
                
CS_SetClientClanTag(client"[V.I.P]");
            } 
        } 
    } 

stock bool:IsValidClient(clientbool:alive false

    return (
client >= && client <= MaxClients && IsClientConnected(client) && IsClientInGame(client) && (alive == false || IsPlayerAlive(client))); 

__________________

Add me on Steam for personal inquiries or direct assistance.
The1Speck 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 05:20.


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