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

[CSGO] Advanced Admin Commands


Post New Thread Reply   
 
Thread Tools Display Modes
Cruze
Veteran Member
Join Date: May 2017
Old 12-17-2018 , 07:01   Re: [CSGO] Advanced Admin Commands
Reply With Quote #141

Quote:
Originally Posted by hiiamu View Post
I'm looking to extract the sm_hp out of the plugin, it compiles fine by its self, but when I try to take out the parts of the code for the hp setting it will not compile. It gives error 147 on multiple lines and I do not know how to fix some of these(I am new to sourcepawn still). What do I do to fix these errors?
PHP Code:
#include <sourcemod>

#pragma semicolon 1
#pragma newdecls required

#define CMD_PREFIX            "[SM] "

public Plugin myinfo = {
    
name        "Set HP",
    
author      "Cruze",
    
description "",
    
version     "1.0",
    
url         ""
};

public 
void OnPluginStart()
{
    
RegAdminCmd("sm_hp",            CMD_Health,        ADMFLAG_KICK,        "Set the health for the targets");
    
RegAdminCmd("sm_health",        CMD_Health,        ADMFLAG_KICK,        "Set the health for the targets");
    
    
LoadTranslations("common.phrases");
    
LoadTranslations("advadmin.phrases");
}
public 
Action CMD_Health(int clientint args)
{
    if(!
IsClientValid(client) || !IsClientInGame(client))
    {
        return 
Plugin_Handled;
    }
    
    if(
args != 2)
    {
        
ReplyToCommand(client"%t""CMD_Health_Usage");
        return 
Plugin_Handled;
    }
    
    
char target_name[MAX_TARGET_LENGTH], buffer[512];
    
int target_list[MAXPLAYERS], target_count;
    
bool tn_is_ml;
    
    
GetCmdArg(1buffersizeof(buffer));
    if((
target_count ProcessTargetString(bufferclienttarget_listMAXPLAYERSCOMMAND_FILTER_ALIVEtarget_namesizeof(target_name), tn_is_ml)) <= 0)
    {
        
ReplyToTargetError(clienttarget_count);
        return 
Plugin_Handled;
    }
    
    
GetCmdArg(2buffersizeof(buffer));
    
int value StringToInt(buffer);
            
    for(
int i 0target_counti++)
    {
        if((
buffer[0] == '+') || (buffer[0] == '-'))
        {
            
value value GetEntProp(target_list[i], Prop_Data"m_iHealth");
        }
        
SetEntProp(target_list[i], Prop_Data"m_iHealth"value);
    }
    
    if(
tn_is_ml)
    {
        
ShowActivity2(clientCMD_PREFIX"%t""CMD_Health"target_namevalue);
        
LogActionEx(client"%t""CMD_Health"target_namevalue);
    }
    else
    {
        
ShowActivity2(clientCMD_PREFIX"%t""CMD_Health""_s"target_namevalue);
        
LogActionEx(client"%t""CMD_Health""_s"target_namevalue);
    }
    return 
Plugin_Handled;
}

stock char LogActionEx(int clientchar[] messageany ...)
{
    
char buffer[256];
    
SetGlobalTransTarget(LANG_SERVER);
    
VFormat(buffersizeof(buffer), message3);
    
LogMessage("%N: %s"clientbuffer);
}

bool IsClientValid(int client)
{
    return ((
client 0) && (client <= MaxClients));

__________________
Taking paid private requests! Contact me
Cruze is offline
YourDignity
Junior Member
Join Date: Sep 2018
Old 12-20-2018 , 11:21   Re: [CSGO] Advanced Admin Commands
Reply With Quote #142

when i try to give someone a weapon it crashes my server and when i try to swap someone to a different team it swaps them twice and they end up on the team they started on
YourDignity is offline
PeEzZ
Senior Member
Join Date: Jan 2014
Location: Hungary
Old 12-20-2018 , 13:23   Re: [CSGO] Advanced Admin Commands
Reply With Quote #143

What plugins are you using?
Type in your console:
sm plugins list
after this:
sm version
and
meta version
and copy here.
__________________
I MAKING MY PLUGINS/MAPS STILL, BUT I DON'T HAVE ENOUGH TIME, PLEASE STAND BY.
Sorry for my bad english, correct me if i'm wrong.
Magyarok írjanak PM-et ha fontos!

If you want, you can donate for me here
My plugins here / My maps here

Last edited by PeEzZ; 04-28-2019 at 06:06.
PeEzZ is offline
YourDignity
Junior Member
Join Date: Sep 2018
Old 12-20-2018 , 15:55   Re: [CSGO] Advanced Admin Commands
Reply With Quote #144

"[CSS/CS:GO] AbNeR ResetScore" (1.5fix) by AbNeR_CSS
"Admin File Reader" (1.9.0.6245) by AlliedModders LLC
"Admin Help" (1.9.0.6245) by AlliedModders LLC
"Admin Menu" (1.9.0.6245) by AlliedModders LLC
"[CSGO] Advanced Admin" (1.7.1) by PeEzZ
"Anti Untrusted" (1.0.0) by Voltz
"Anti-Flood" (1.9.0.6245) by AlliedModders LLC
"Basic Ban Commands" (1.9.0.6245) by AlliedModders LLC
"Basic Chat" (1.9.0.6245) by AlliedModders LLC
"Basic Comm Control" (1.9.0.6245) by AlliedModders LLC

SourceMod 1.9.0.6245, by AlliedModders LLC
mm version did not do anything

also it does this when i try to give a weapon: Ignoring unreasonable position (-1183548191070569175518806016.000000,-1089809.375000,-0.195303) from vphysics! (entity weapon_scar20)
Ignoring unreasonable position (-1183548191070569175518806016.000000,-1089809.375000,-6673.089844) from vphysics! (entity weapon_scar20)
Ignoring unreasonable position (-1183548191070569175518806016.000000,-1089809.375000,-16553.191406) from vphysics! (entity weapon_scar20)
Ignoring unreasonable position (-1183548191070569175518806016.000000,-1089809.375000,-26483.86132 from vphysics! (entity weapon_scar20)
Ignoring unreasonable position (-1183548191070569175518806016.000000,-1089809.375000,-36416.347656) from vphysics! (entity weapon_scar20)
Ignoring unreasonable position (-1183548191070569175518806016.000000,-1089809.375000,-46379.406250) from vphysics! (entity weapon_scar20)
THEN IT CRASHES THE SERVER

Last edited by YourDignity; 12-20-2018 at 16:07.
YourDignity is offline
PeEzZ
Senior Member
Join Date: Jan 2014
Location: Hungary
Old 12-21-2018 , 06:52   Re: [CSGO] Advanced Admin Commands
Reply With Quote #145

You need to download and install metamod:source
https://www.sourcemm.net/downloads.php?branch=stable
and try redownload and install the newest stable sm
https://www.sourcemod.net/downloads.php?branch=stable
__________________
I MAKING MY PLUGINS/MAPS STILL, BUT I DON'T HAVE ENOUGH TIME, PLEASE STAND BY.
Sorry for my bad english, correct me if i'm wrong.
Magyarok írjanak PM-et ha fontos!

If you want, you can donate for me here
My plugins here / My maps here
PeEzZ is offline
freak.exe_uLow
AlliedModders Donor
Join Date: Jul 2012
Location: Germany
Old 01-09-2019 , 17:46   Re: [CSGO] Advanced Admin Commands
Reply With Quote #146

@PeEzZ

i think i dont get access to the Advance Admin, i running your script on the server, but is doesn't show the extra menu.

freak.exe_uLow is offline
PeEzZ
Senior Member
Join Date: Jan 2014
Location: Hungary
Old 01-10-2019 , 01:38   Re: [CSGO] Advanced Admin Commands
Reply With Quote #147

Are you replaced the adminmenu_custom.cfg in your addons/sourcemod/configs ?
__________________
I MAKING MY PLUGINS/MAPS STILL, BUT I DON'T HAVE ENOUGH TIME, PLEASE STAND BY.
Sorry for my bad english, correct me if i'm wrong.
Magyarok írjanak PM-et ha fontos!

If you want, you can donate for me here
My plugins here / My maps here
PeEzZ is offline
Cruze
Veteran Member
Join Date: May 2017
Old 01-10-2019 , 01:39   Re: [CSGO] Advanced Admin Commands
Reply With Quote #148

Quote:
Originally Posted by freak.exe_uLow View Post
@PeEzZ

i think i dont get access to the Advance Admin, i running your script on the server, but is doesn't show the extra menu.

try restarting server
__________________
Taking paid private requests! Contact me
Cruze is offline
freak.exe_uLow
AlliedModders Donor
Join Date: Jul 2012
Location: Germany
Old 01-10-2019 , 04:24   Re: [CSGO] Advanced Admin Commands
Reply With Quote #149

Quote:
Originally Posted by PeEzZ View Post
Are you replaced the adminmenu_custom.cfg in your addons/sourcemod/configs ?
I updated the server with a new Sourcemod version, and have overwritten that, thanks, now it works And is it possible that it only with the flag "z" shows the extra menu?

Quote:
Originally Posted by Cruze View Post
try restarting server
really? xD and I am aware of that^^

Last edited by freak.exe_uLow; 01-10-2019 at 04:40.
freak.exe_uLow is offline
hoycieto
Senior Member
Join Date: Feb 2018
Old 02-12-2019 , 18:14   Re: [CSGO] Advanced Admin Commands
Reply With Quote #150

Will be added checking have player bomb and if his team is changing from TT to CT his bomb will be moved to another TT player?
hoycieto 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 17:22.


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