attempted merge at 1.77 back into trunk... Oh MY GOD

This commit is contained in:
David Anderson
2007-03-09 03:04:40 +00:00
parent 7adc49c541
commit 71065a65dd
90 changed files with 16915 additions and 1824 deletions

View File

@@ -310,3 +310,19 @@ stock constraint_offset(low, high, seed, offset)
return 0; // Makes the compiler happy -_-
}
/* Returns true if the user has ANY of the provided flags
* false if they have none
*/
stock has_flag(id, const flags[])
{
return (get_user_flags(id) & read_flags(flags));
}
/* Returns true if the user has ALL of the provided flags
* false otherwise
*/
stock has_all_flags(id, const flags[])
{
new FlagsNumber=read_flags(flags);
return ((get_user_flags(id) & FlagsNumber)==FlagsNumber);
}