- scriptified Heretic's wizard.

This commit is contained in:
Christoph Oelckers 2016-11-11 23:32:13 +01:00
commit 14a9c13113
7 changed files with 135 additions and 102 deletions

View file

@ -6041,6 +6041,13 @@ static double GetDefaultSpeed(PClassActor *type)
return GetDefaultByType(type)->Speed;
}
DEFINE_ACTION_FUNCTION(AActor, GetDefaultSpeed)
{
PARAM_PROLOGUE;
PARAM_CLASS(type, AActor);
ACTION_RETURN_FLOAT(GetDefaultSpeed(type));
}
//---------------------------------------------------------------------------
//
// FUNC P_SpawnMissile
@ -6283,6 +6290,19 @@ AActor *P_SpawnMissileAngleZSpeed (AActor *source, double z,
return (!checkspawn || P_CheckMissileSpawn(mo, source->radius)) ? mo : NULL;
}
DEFINE_ACTION_FUNCTION(AActor, SpawnMissileAngleZSpeed)
{
PARAM_SELF_PROLOGUE(AActor);
PARAM_FLOAT(z);
PARAM_CLASS(type, AActor);
PARAM_ANGLE(angle);
PARAM_FLOAT(vz);
PARAM_FLOAT(speed);
PARAM_OBJECT_DEF(owner, AActor);
PARAM_BOOL_DEF(checkspawn);
ACTION_RETURN_OBJECT(P_SpawnMissileAngleZSpeed(self, z, type, angle, vz, speed, owner, checkspawn));
}
/*
================
=
@ -6879,6 +6899,13 @@ DEFINE_ACTION_FUNCTION(AActor, GetDefaultByType)
ACTION_RETURN_OBJECT(GetDefaultByType(cls));
}
DEFINE_ACTION_FUNCTION(AActor, GetBobOffset)
{
PARAM_SELF_PROLOGUE(AActor);
PARAM_FLOAT_DEF(frac);
ACTION_RETURN_FLOAT(self->GetBobOffset(frac));
}
// This combines all 3 variations of the internal function
DEFINE_ACTION_FUNCTION(AActor, VelFromAngle)
{