mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2025-02-06 16:31:26 +00:00
* Slightly more papersprite stability!
* Slightly more sane Minecraft item scaling!
This commit is contained in:
parent
d13e999c99
commit
baf50a1dbf
4 changed files with 6 additions and 9 deletions
|
@ -3008,7 +3008,7 @@ void K_DropItems(player_t *player)
|
||||||
if (player->mo && player->kartstuff[k_itemamount])
|
if (player->mo && player->kartstuff[k_itemamount])
|
||||||
{
|
{
|
||||||
mobj_t *drop = P_SpawnMobj(player->mo->x, player->mo->y, player->mo->z + player->mo->height/2, MT_FLOATINGITEM);
|
mobj_t *drop = P_SpawnMobj(player->mo->x, player->mo->y, player->mo->z + player->mo->height/2, MT_FLOATINGITEM);
|
||||||
P_SetScale(drop, drop->scale>>5);
|
P_SetScale(drop, drop->scale>>4);
|
||||||
drop->destscale = (3*drop->destscale)/2;;
|
drop->destscale = (3*drop->destscale)/2;;
|
||||||
|
|
||||||
drop->angle = player->mo->angle + ANGLE_90;
|
drop->angle = player->mo->angle + ANGLE_90;
|
||||||
|
|
|
@ -445,7 +445,7 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||||
|
|
||||||
P_SetTarget(&special->tracer, toucher);
|
P_SetTarget(&special->tracer, toucher);
|
||||||
special->flags2 |= MF2_NIGHTSPULL;
|
special->flags2 |= MF2_NIGHTSPULL;
|
||||||
special->destscale = mapheaderinfo[gamemap-1]->mobj_scale>>5;
|
special->destscale = mapheaderinfo[gamemap-1]->mobj_scale>>4;
|
||||||
special->scalespeed <<= 1;
|
special->scalespeed <<= 1;
|
||||||
|
|
||||||
special->flags &= ~MF_SPECIAL;
|
special->flags &= ~MF_SPECIAL;
|
||||||
|
|
|
@ -8031,7 +8031,7 @@ void P_MobjThinker(mobj_t *mobj)
|
||||||
if (mobj->flags2 & MF2_NIGHTSPULL)
|
if (mobj->flags2 & MF2_NIGHTSPULL)
|
||||||
{
|
{
|
||||||
if (!mobj->tracer || !mobj->tracer->health
|
if (!mobj->tracer || !mobj->tracer->health
|
||||||
|| mobj->scale <= mapheaderinfo[gamemap-1]->mobj_scale>>5)
|
|| mobj->scale <= mapheaderinfo[gamemap-1]->mobj_scale>>4)
|
||||||
{
|
{
|
||||||
P_RemoveMobj(mobj);
|
P_RemoveMobj(mobj);
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -1266,7 +1266,6 @@ static void R_ProjectSprite(mobj_t *thing)
|
||||||
if (papersprite)
|
if (papersprite)
|
||||||
{
|
{
|
||||||
fixed_t yscale2, cosmul, sinmul, tz2;
|
fixed_t yscale2, cosmul, sinmul, tz2;
|
||||||
INT32 range;
|
|
||||||
|
|
||||||
if (ang >= ANGLE_180)
|
if (ang >= ANGLE_180)
|
||||||
{
|
{
|
||||||
|
@ -1296,12 +1295,10 @@ static void R_ProjectSprite(mobj_t *thing)
|
||||||
if (max(tz, tz2) < FixedMul(MINZ, this_scale)) // non-papersprite clipping is handled earlier
|
if (max(tz, tz2) < FixedMul(MINZ, this_scale)) // non-papersprite clipping is handled earlier
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (x2 > x1)
|
if (x2 <= x1)
|
||||||
range = (x2 - x1);
|
return;
|
||||||
else
|
|
||||||
range = 1;
|
|
||||||
|
|
||||||
scalestep = (yscale2 - yscale)/range;
|
scalestep = (yscale2 - yscale)/(x2 - x1);
|
||||||
|
|
||||||
// The following two are alternate sorting methods which might be more applicable in some circumstances. TODO - maybe enable via MF2?
|
// The following two are alternate sorting methods which might be more applicable in some circumstances. TODO - maybe enable via MF2?
|
||||||
// sortscale = max(yscale, yscale2);
|
// sortscale = max(yscale, yscale2);
|
||||||
|
|
Loading…
Reference in a new issue