- Added AActor::SetFriendPlayer() to make setting FriendPlayer cleaner to read when doing it with

a player_t pointer.

SVN r3681 (trunk)
This commit is contained in:
Randy Heit 2012-06-09 04:15:56 +00:00
commit 086d0a797e
8 changed files with 28 additions and 49 deletions

View file

@ -100,7 +100,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_Beacon)
{
rebel->Translation = owner->Translation;
}
rebel->FriendPlayer = owner->player != NULL ? BYTE(owner->player - players + 1) : 0;
rebel->SetFriendPlayer(owner->player);
// Set the rebel's target to whatever last hurt the player, so long as it's not
// one of the player's other rebels.
if (owner->target != NULL && !rebel->IsFriend (owner->target))