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

Vip connect plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Solaris15
Junior Member
Join Date: Jun 2019
Location: Romania
Old 07-09-2019 , 06:06   Vip connect plugin
Reply With Quote #1

Hello, I have a source from a plugin, but when I try to compile it I have errors.
The sourcecode is :
PHP code
PHP Code:
#include <sourcemod>
#include <cstrike>

public Plugin:myinfo =
{
    
name "vipconnect",
    
description "-",
    
author "-",
    
version "0.0.3",
    
url ""
};

public 
OnPluginStart()
{
    
CreateConVar("sm_admin_conmsg_version""0.0.3""Admin Connect MSG Version"8512false0.0false0.0);
    
HookEvent("player_disconnect"PlayerDisconnect_EventEventHookMode:0);
    
HookEvent("player_connect_full"PlayerFullConnect_EventEventHookMode:0);
    
RegAdminCmd("sm_fakeentrance"Command_FakeEntrance16384""""0);
    
RegAdminCmd("sm_fakeexit"Command_FakeExit16384""""0);
    return 
}

public 
Action:PlayerDisconnect_Event(Handle:eventString:name[], bool:dontBroadcast)
{
    new 
client GetClientOfUserId(GetEventInt(event"userid"0));
    new 
AdminId:id GetUserAdmin(client);
    if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:14AdmAccessMode:1))
    {
        new 
String:name1[32];
        
GetClientName(clientname132);
        
PrintToChatAll("%s Warning! \x07★ Founder ★ \x04%s\x01 has disconnected from the server !""★ \x04[JailBreak]\x01"name1);
        
PrintToServer("Founder %s a iesit de pe server!"name1);
    }
    else
    {
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:7AdmAccessMode:1))
        {
            new 
String:name1[32];
            
GetClientName(clientname132);
            
PrintToChatAll("%s Warning! \x07★ Owner ★ \x04%s\x01 has disconnected from the server !""★ \x04[JailBreak]\x01"name1);
            
PrintToServer("Owner %s a iesit de pe server!"name1);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:10AdmAccessMode:1) && GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name1[32];
            
GetClientName(clientname132);
            
PrintToChatAll("%s Warning! \x07★ Mod + VIP ★ \x04%s\x01 has disconnected from the server !""★ \x04[JailBreak]\x01"name1);
            
PrintToServer("Mod + VIP %s a iesit de pe server!"name1);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:3AdmAccessMode:1) && GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name1[32];
            
GetClientName(clientname132);
            
PrintToChatAll("%s Warning! \x07★ Admin + VIP ★ \x04%s\x01 has disconnected from the server !""★ \x04[JailBreak]\x01"name1);
            
PrintToServer("Admin + VIP %s a iesit de pe server!"name1);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:5AdmAccessMode:1) && GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name1[32];
            
GetClientName(clientname132);
            
PrintToChatAll("%s Warning! \x07★ Helper + VIP ★ \x04%s\x01 has disconnected from the server !""★ \x04[JailBreak]\x01"name1);
            
PrintToServer("Helper + VIP %s a iesit de pe server!"name1);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name1[32];
            
GetClientName(clientname132);
            
PrintToChatAll("%s Warning! \x07★ VIP ★ \x04%s\x01 has disconnected from the server !""★ \x04[JailBreak]\x01"name1);
            
PrintToServer("VIP %s a iesit de pe server!"name1);
        }
    }
    
SetEventBroadcast(eventtrue);
    return 
Action:0;
}

public 
Action:PlayerFullConnect_Event(Handle:eventString:name[], bool:dontBroadcast)
{
    new 
client GetClientOfUserId(GetEventInt(event"userid"0));
    new 
AdminId:id GetUserAdmin(client);
    if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:14AdmAccessMode:1))
    {
        new 
String:name2[32];
        
GetClientName(clientname232);
        
PrintToChatAll("%s Warning! \x07★ Founder ★ \x04%s\x01 has connected on the server !""★ \x04[JailBreak]\x01"name2);
        
PrintToServer("Founder %s a intrat pe server!"name2);
    }
    else
    {
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:7AdmAccessMode:1))
        {
            new 
String:name2[32];
            
GetClientName(clientname232);
            
PrintToChatAll("%s Warning! \x07★ Owner ★ \x04%s\x01 has connected on the server !""★ \x04[JailBreak]\x01"name2);
            
PrintToServer("Owner %s a intrat pe server!"name2);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:10AdmAccessMode:1) && GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name2[32];
            
GetClientName(clientname232);
            
PrintToChatAll("%s Warning! \x07★ Mod + VIP ★ \x04%s\x01 has connected on the server !""★ \x04[JailBreak]\x01"name2);
            
PrintToServer("Mod + VIP %s a intrat pe server!"name2);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:3AdmAccessMode:1) && GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name2[32];
            
GetClientName(clientname232);
            
PrintToChatAll("%s Warning! \x07★ Admin + VIP ★ \x04%s\x01 has connected on the server !""★ \x04[JailBreak]\x01"name2);
            
PrintToServer("Admin + VIP %s a intrat pe server!"name2);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:5AdmAccessMode:1) && GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name2[32];
            
GetClientName(clientname232);
            
PrintToChatAll("%s Warning! \x07★ Helper + VIP ★ \x04%s\x01 has connected on the server !""★ \x04[JailBreak]\x01"name2);
            
PrintToServer("Helper + VIP %s a intrat pe server!"name2);
        }
        if (
id != AdminId:-&& GetAdminFlag(idAdminFlag:20AdmAccessMode:1))
        {
            new 
String:name2[32];
            
GetClientName(clientname232);
            
PrintToChatAll("%s Warning! \x07★ VIP ★ \x04%s\x01 has connected on the server !""★ \x04[JailBreak]\x01"name2);
            
PrintToServer("VIP %s a intrat pe server!"name2);
                        return 
Action:0;
        }
    }
    
}

public 
Action:Command_FakeEntrance(clientargs)
{
    if (
args != 3)
    {
        
ReplyToCommand(client"★ \x04[JailBreak] \x01Usage: \x07sm_fakeentrance \x02<grad> \x04<nume>");
        return 
Action:3;
    }
    new 
String:arg1[128];
    
GetCmdArg(1arg1128);
    new 
String:arg2[128];
    
GetCmdArg(2arg2128);
    
PrintToChatAll("★ \x04[JailBreak] \x01Warning! \x07★ %s ★ \x04%s\x01 has connected on the server!"arg1arg2);
    return 
Action:0;
}

public 
Action:Command_FakeExit(clientargs)
{
    if (
args != 3)
    {
        
ReplyToCommand(client"★ \x04[JailBreak] \x01Usage: \x07sm_fakeentrance \x02<grad> \x04<nume>");
        return 
Action:3;
    }
    new 
String:arg1[128];
    
GetCmdArg(1arg1128);
    new 
String:arg2[128];
    
GetCmdArg(2arg2128);
    
PrintToChatAll("★ \x04[JailBreak] \x01★ \x07%s \x01★ \x02%s\x10 has disconnected from the server !"arg1arg2);
    return 
Action:0;
    } 
And the compile errors:
PHP Code:
//// vipconnect.sp
//
// D:\SERVER\steamapps\common\Counter-Strike Global Offensive Beta - Dedicated Server\csgo\addons\sourcemod\scripting\vipconnect.sp(1) : error 010: invalid function or declaration
// D:\SERVER\steamapps\common\Counter-Strike Global Offensive Beta - Dedicated Server\csgo\addons\sourcemod\scripting\vipconnect.sp(127) : warning 209: function "PlayerFullConnect_Event" should return a value
//
// 1 Error.
//
// Compilation Time: 0.23 sec
// ----------------------------------------

Press enter to exit ... 

Last edited by Solaris15; 07-09-2019 at 06:09.
Solaris15 is offline
farawayf
Senior Member
Join Date: Jan 2019
Old 07-09-2019 , 06:58   Re: Vip connect plugin
Reply With Quote #2

decompiled source. you need to clean the code first
farawayf is offline
kratoss1812
Senior Member
Join Date: May 2018
Location: Romānia
Old 07-09-2019 , 07:19   Re: Vip connect plugin
Reply With Quote #3

Hello! I can help you. Add me on steam.
__________________
kratoss1812 is offline
I am inevitable
Member
Join Date: May 2019
Location: 0xA6DA34
Old 07-09-2019 , 08:27   Re: Vip connect plugin
Reply With Quote #4

Btw, that's not php.

Spoiler
__________________
I do make plugins upon requests, so hit me up on discord if you're interested: Stefan Milivojevic#5311
I am inevitable is offline
Solaris15
Junior Member
Join Date: Jun 2019
Location: Romania
Old 07-09-2019 , 09:57   Re: Vip connect plugin
Reply With Quote #5

Te-am adaugat pe steam kratoss.
Solaris15 is offline
Reply


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 11:05.


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