plugins/include/basecomm.inc
author Nicholas Hastings <skamonkey@gmail.com>
Fri Mar 22 23:07:17 2013 -0400 (2013-03-22)
changeset 3868 1f5d92297fd1
parent 3645 80c9ae186971
permissions -rw-r--r--
Added Dota 2 gamedata for SDKHooks.
skamonkey@3340
     1
/**
skamonkey@3340
     2
 * vim: set ts=4 :
skamonkey@3340
     3
 * =============================================================================
skamonkey@3340
     4
 * SourceMod (C)2004-2011 AlliedModders LLC.  All rights reserved.
skamonkey@3340
     5
 * =============================================================================
skamonkey@3340
     6
 *
skamonkey@3340
     7
 * This file is part of the SourceMod/SourcePawn SDK.
skamonkey@3340
     8
 *
skamonkey@3340
     9
 * This program is free software; you can redistribute it and/or modify it under
skamonkey@3340
    10
 * the terms of the GNU General Public License, version 3.0, as published by the
skamonkey@3340
    11
 * Free Software Foundation.
skamonkey@3340
    12
 * 
skamonkey@3340
    13
 * This program is distributed in the hope that it will be useful, but WITHOUT
skamonkey@3340
    14
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
skamonkey@3340
    15
 * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
skamonkey@3340
    16
 * details.
skamonkey@3340
    17
 *
skamonkey@3340
    18
 * You should have received a copy of the GNU General Public License along with
skamonkey@3340
    19
 * this program.  If not, see <http://www.gnu.org/licenses/>.
skamonkey@3340
    20
 *
skamonkey@3340
    21
 * As a special exception, AlliedModders LLC gives you permission to link the
skamonkey@3340
    22
 * code of this program (as well as its derivative works) to "Half-Life 2," the
skamonkey@3340
    23
 * "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
skamonkey@3340
    24
 * by the Valve Corporation.  You must obey the GNU General Public License in
skamonkey@3340
    25
 * all respects for all other code used.  Additionally, AlliedModders LLC grants
skamonkey@3340
    26
 * this exception to all derivative works.  AlliedModders LLC defines further
skamonkey@3340
    27
 * exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
skamonkey@3340
    28
 * or <http://www.sourcemod.net/license.php>.
skamonkey@3340
    29
 *
skamonkey@3340
    30
 * Version: $Id$
skamonkey@3340
    31
 */
skamonkey@3340
    32
 
skamonkey@3340
    33
#if defined _basecomm_included
skamonkey@3340
    34
 #endinput
skamonkey@3340
    35
#endif
skamonkey@3340
    36
#define _basecomm_included
skamonkey@3340
    37
skamonkey@3340
    38
/**
drifter01620@3645
    39
 * Called when a client is muted or unmuted
drifter01620@3645
    40
 * 
drifter01620@3645
    41
 * @param	client		Client index
drifter01620@3645
    42
 * @param	muteState	True if client was muted, false otherwise
drifter01620@3645
    43
 */
drifter01620@3645
    44
 forward BaseComm_OnClientMute(client, bool:muteState);
drifter01620@3645
    45
 
drifter01620@3645
    46
 /**
drifter01620@3645
    47
 * Called when a client is gagged or ungagged
drifter01620@3645
    48
 * 
drifter01620@3645
    49
 * @param	client		Client index
drifter01620@3645
    50
 * @param	gagState	True if client was gaged, false otherwise
drifter01620@3645
    51
 */
drifter01620@3645
    52
 forward BaseComm_OnClientGag(client, bool:gagState);
drifter01620@3645
    53
 
drifter01620@3645
    54
/**
skamonkey@3340
    55
 * Returns whether or not a client is gagged
skamonkey@3340
    56
 *
skamonkey@3340
    57
 * @param client		Client index.
skamonkey@3340
    58
 * @return				True if client is gagged, false otherwise.
skamonkey@3340
    59
 */
skamonkey@3340
    60
native bool:BaseComm_IsClientGagged(client);
skamonkey@3340
    61
skamonkey@3340
    62
/**
skamonkey@3340
    63
 * Returns whether or not a client is muted
skamonkey@3340
    64
 *
skamonkey@3340
    65
 * @param client		Client index.
skamonkey@3340
    66
 * @return				True if client is muted, false otherwise.
skamonkey@3340
    67
 */
skamonkey@3340
    68
native bool:BaseComm_IsClientMuted(client);
skamonkey@3340
    69
skamonkey@3340
    70
/**
skamonkey@3340
    71
 * Sets a client's gag state
skamonkey@3340
    72
 *
skamonkey@3340
    73
 * @param client		Client index.
skamonkey@3340
    74
 * @param gagState		True to gag client, false to ungag.
skamonkey@3340
    75
 * @return				True if this caused a change in gag state, false otherwise.
skamonkey@3340
    76
 */
skamonkey@3340
    77
native bool:BaseComm_SetClientGag(client, bool:gagState);
skamonkey@3340
    78
skamonkey@3340
    79
/**
skamonkey@3340
    80
 * Sets a client's mute state
skamonkey@3340
    81
 *
skamonkey@3340
    82
 * @param client		Client index.
skamonkey@3340
    83
 * @param muteState		True to mute client, false to unmute.
skamonkey@3340
    84
 * @return				True if this caused a change in mute state, false otherwise.
skamonkey@3340
    85
 */
skamonkey@3340
    86
native bool:BaseComm_SetClientMute(client, bool:muteState);
skamonkey@3340
    87
skamonkey@3340
    88
/* DO NOT EDIT BELOW THIS LINE */
skamonkey@3340
    89
skamonkey@3340
    90
public SharedPlugin:__pl_basecomm = 
skamonkey@3340
    91
{
skamonkey@3340
    92
	name = "basecomm",
skamonkey@3340
    93
	file = "basecomm.smx",
skamonkey@3340
    94
#if defined REQUIRE_PLUGIN
skamonkey@3340
    95
	required = 1,
skamonkey@3340
    96
#else
skamonkey@3340
    97
	required = 0,
skamonkey@3340
    98
#endif
skamonkey@3340
    99
};
skamonkey@3340
   100
skamonkey@3340
   101
#if !defined REQUIRE_PLUGIN
skamonkey@3340
   102
public __pl_basecomm_SetNTVOptional()
skamonkey@3340
   103
{
skamonkey@3340
   104
	MarkNativeAsOptional("BaseComm_IsClientGagged");
skamonkey@3340
   105
	MarkNativeAsOptional("BaseComm_IsClientMuted");
skamonkey@3340
   106
	MarkNativeAsOptional("BaseComm_SetClientGag");
skamonkey@3340
   107
	MarkNativeAsOptional("BaseComm_SetClientMute");
skamonkey@3340
   108
}
skamonkey@3340
   109
#endif