- finished conversion of most of g_doom.
Only things left here are accesses to AActor::ceilingz and radius in A_PainShootSkull, plus scaleX and scaleY in the ScriptedMarine sprite setting code. Most is still using wrapper functions around the fixed point versions.
This commit is contained in:
parent
a4f5846c7c
commit
5875e91f39
17 changed files with 214 additions and 81 deletions
|
|
@ -13,7 +13,7 @@
|
|||
// PIT_VileCheck
|
||||
// Detect a corpse that could be raised.
|
||||
//
|
||||
void A_Fire(AActor *self, int height);
|
||||
void A_Fire(AActor *self, double height);
|
||||
|
||||
|
||||
//
|
||||
|
|
@ -50,13 +50,13 @@ DEFINE_ACTION_FUNCTION(AActor, A_FireCrackle)
|
|||
DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_Fire)
|
||||
{
|
||||
PARAM_ACTION_PROLOGUE;
|
||||
PARAM_FIXED_OPT(height) { height = 0; }
|
||||
PARAM_FLOAT_OPT(height) { height = 0; }
|
||||
|
||||
A_Fire(self, height);
|
||||
return 0;
|
||||
}
|
||||
|
||||
void A_Fire(AActor *self, int height)
|
||||
void A_Fire(AActor *self, double height)
|
||||
{
|
||||
AActor *dest;
|
||||
|
||||
|
|
@ -116,7 +116,7 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_VileAttack)
|
|||
PARAM_INT_OPT (dmg) { dmg = 20; }
|
||||
PARAM_INT_OPT (blastdmg) { blastdmg = 70; }
|
||||
PARAM_INT_OPT (blastrad) { blastrad = 70; }
|
||||
PARAM_FIXED_OPT (thrust) { thrust = FRACUNIT; }
|
||||
PARAM_FLOAT_OPT (thrust) { thrust = 1; }
|
||||
PARAM_NAME_OPT (dmgtype) { dmgtype = NAME_Fire; }
|
||||
PARAM_INT_OPT (flags) { flags = 0; }
|
||||
|
||||
|
|
@ -154,7 +154,7 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_VileAttack)
|
|||
}
|
||||
if (!(target->flags7 & MF7_DONTTHRUST))
|
||||
{
|
||||
target->Vel.Z = FIXED2FLOAT(Scale(thrust, 1000, target->Mass));
|
||||
target->Vel.Z = thrust * 1000 / MAX(1, target->Mass);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue