OnSendCommand
Usage
- Return a non-null value to override default behavior
Example Autogenerated
csharp
private void OnSendCommand( Connection cn, string strCommand, Object[] args )
{
Puts( "OnSendCommand works!" );
}
csharp
private void OnSendCommand( List`1 cn, string strCommand, Object[] args )
{
Puts( "OnSendCommand works!" );
}
Location
- ConsoleNetwork::SendClientCommand(Network.Connection cn, string strCommand, System.Object[] args)
- ConsoleNetwork::SendClientCommand(System.Collections.Generic.List`1<Network.Connection> cn, string strCommand, System.Object[] args)
csharp
//---
{
if (!Net.sv.IsConnected())
{
return;
}
if (Interface.CallHook("OnSendCommand", cn, strCommand, args) != null)
{
return;
}
NetWrite expr_28 = Net.sv.StartWrite();
expr_28.PacketID(Message.Type.ConsoleCommand);
//---
csharp
//---
{
if (!Net.sv.IsConnected())
{
return;
}
if (Interface.CallHook("OnSendCommand", cn, strCommand, args) != null)
{
return;
}
NetWrite expr_28 = Net.sv.StartWrite();
expr_28.PacketID(Message.Type.ConsoleCommand);
//---