Target filters now run for "@me" special target (bug 4000, r=pred).
This commit is contained in:
parent
e3e11d233c
commit
4fc378d3e2
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 sw=4 tw=99 noet :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2009 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -1168,10 +1168,18 @@ void PlayerManager::ProcessCommandTarget(cmd_target_info_t *info)
|
|||||||
|
|
||||||
if (strcmp(info->pattern, "@me") == 0 && info->admin != 0)
|
if (strcmp(info->pattern, "@me") == 0 && info->admin != 0)
|
||||||
{
|
{
|
||||||
info->targets[0] = info->admin;
|
info->reason = FilterCommandTarget(pAdmin, pAdmin, info->flags);
|
||||||
info->num_targets = 1;
|
if (info->reason == COMMAND_TARGET_VALID)
|
||||||
strncopy(info->target_name, pAdmin->GetName(), info->target_name_maxlength);
|
{
|
||||||
info->target_name_style = COMMAND_TARGETNAME_RAW;
|
info->targets[0] = info->admin;
|
||||||
|
info->num_targets = 1;
|
||||||
|
strncopy(info->target_name, pAdmin->GetName(), info->target_name_maxlength);
|
||||||
|
info->target_name_style = COMMAND_TARGETNAME_RAW;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
info->num_targets = 0;
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user