mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-11 07:12:02 +00:00
- added a Buddha powerup
This commit is contained in:
parent
a19620968d
commit
313245dd77
3 changed files with 49 additions and 0 deletions
|
@ -1396,6 +1396,42 @@ void APowerFrightener::EndEffect ()
|
|||
Owner->player->cheats &= ~CF_FRIGHTENING;
|
||||
}
|
||||
|
||||
// Buddha Powerup --------------------------------
|
||||
|
||||
IMPLEMENT_CLASS (APowerBuddha)
|
||||
|
||||
//===========================================================================
|
||||
//
|
||||
// APowerBuddha :: InitEffect
|
||||
//
|
||||
//===========================================================================
|
||||
|
||||
void APowerBuddha::InitEffect ()
|
||||
{
|
||||
Super::InitEffect();
|
||||
|
||||
if (Owner== NULL || Owner->player == NULL)
|
||||
return;
|
||||
|
||||
Owner->player->cheats |= CF_FRIGHTENING;
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
//
|
||||
// APowerBuddha :: EndEffect
|
||||
//
|
||||
//===========================================================================
|
||||
|
||||
void APowerBuddha::EndEffect ()
|
||||
{
|
||||
Super::EndEffect();
|
||||
|
||||
if (Owner== NULL || Owner->player == NULL)
|
||||
return;
|
||||
|
||||
Owner->player->cheats &= ~CF_FRIGHTENING;
|
||||
}
|
||||
|
||||
// Scanner powerup ----------------------------------------------------------
|
||||
|
||||
IMPLEMENT_CLASS (APowerScanner)
|
||||
|
|
|
@ -184,6 +184,14 @@ protected:
|
|||
void EndEffect ();
|
||||
};
|
||||
|
||||
class APowerBuddha : public APowerup
|
||||
{
|
||||
DECLARE_CLASS (APowerBuddha, APowerup)
|
||||
protected:
|
||||
void InitEffect ();
|
||||
void EndEffect ();
|
||||
};
|
||||
|
||||
class APowerTimeFreezer : public APowerup
|
||||
{
|
||||
DECLARE_CLASS( APowerTimeFreezer, APowerup )
|
||||
|
|
|
@ -271,6 +271,11 @@ ACTOR PowerFrightener : Powerup native
|
|||
Powerup.Duration -60
|
||||
}
|
||||
|
||||
ACTOR PowerBuddha : Powerup native
|
||||
{
|
||||
Powerup.Duration -60
|
||||
}
|
||||
|
||||
ACTOR PowerScanner : Powerup native
|
||||
{
|
||||
Powerup.Duration -80
|
||||
|
|
Loading…
Reference in a new issue