mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2025-05-31 09:21:36 +00:00
- scriptified most of a_strifestuff.cpp.
This commit is contained in:
parent
caef5344b0
commit
edd8e51a69
15 changed files with 376 additions and 383 deletions
|
@ -6807,3 +6807,32 @@ DEFINE_ACTION_FUNCTION(AActor, A_SetTranslation)
|
|||
self->SetTranslation(trname);
|
||||
return 0;
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
//
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
DEFINE_ACTION_FUNCTION(AActor, A_CheckTerrain)
|
||||
{
|
||||
PARAM_SELF_PROLOGUE(AActor);
|
||||
|
||||
sector_t *sec = self->Sector;
|
||||
|
||||
if (self->Z() == sec->floorplane.ZatPoint(self) && sec->PortalBlocksMovement(sector_t::floor))
|
||||
{
|
||||
if (sec->special == Damage_InstantDeath)
|
||||
{
|
||||
P_DamageMobj(self, NULL, NULL, 999, NAME_InstantDeath);
|
||||
}
|
||||
else if (sec->special == Scroll_StrifeCurrent)
|
||||
{
|
||||
int anglespeed = tagManager.GetFirstSectorTag(sec) - 100;
|
||||
double speed = (anglespeed % 10) / 16.;
|
||||
DAngle an = (anglespeed / 10) * (360 / 8.);
|
||||
self->Thrust(an, speed);
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue