Stole the magical any: tag from sourcemod

This commit is contained in:
Steve Dudenhoeffer
2007-04-24 13:36:36 +00:00
parent 8e1f54465d
commit ea912f794c
3 changed files with 9 additions and 2 deletions

View File

@ -284,12 +284,13 @@ static void (*unopers[])(void) = { lneg, neg, user_inc, user_dec };
SC_FUNC int matchtag(int formaltag,int actualtag,int allowcoerce)
{
if (formaltag!=actualtag) {
if (formaltag!=actualtag && formaltag!=pc_anytag) {
/* if the formal tag is zero and the actual tag is not "fixed", the actual
* tag is "coerced" to zero
*/
if (!allowcoerce || formaltag!=0 || (actualtag & FIXEDTAG)!=0)
return FALSE;
return FALSE;
} /* if */
return TRUE;
}