diff --git a/src/deh_tables.c b/src/deh_tables.c index 23276e114..6a6203910 100644 --- a/src/deh_tables.c +++ b/src/deh_tables.c @@ -3325,12 +3325,6 @@ const char *const STATE_LIST[] = { // array length left dynamic for sanity testi // Item capsules "S_ITEMCAPSULE", - "S_ITEMCAPSULE_TOP_SIDE", - "S_ITEMCAPSULE_BOTTOM_SIDE_AIR", - "S_ITEMCAPSULE_BOTTOM_SIDE_GROUND", - //"S_ITEMCAPSULE_TOP", - //"S_ITEMCAPSULE_BOTTOM", - //"S_ITEMCAPSULE_INSIDE", // Signpost sparkles "S_SIGNSPARK1", diff --git a/src/info.c b/src/info.c index f43cd6a4e..c55fe1dbb 100644 --- a/src/info.c +++ b/src/info.c @@ -3888,13 +3888,7 @@ state_t states[NUMSTATES] = {SPR_NULL, FF_FULLBRIGHT, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMICON - {SPR_ICAP, FF_ADD|0, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE - {SPR_ICAP, FF_PAPERSPRITE|1, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE_TOP_SIDE - {SPR_ICAP, FF_VERTICALFLIP|FF_PAPERSPRITE|1, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE_BOTTOM_SIDE_AIR - {SPR_ICAP, FF_PAPERSPRITE|2, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE_BOTTOM_SIDE_GROUND - //{SPR_ICAP, FF_FLOORSPRITE|3, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE_TOP - //{SPR_ICAP, FF_FLOORSPRITE|4, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE_BOTTOM - //{SPR_ICAP, FF_FLOORSPRITE|5, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE_INSIDE + {SPR_NULL, FF_ADD|0, -1, {NULL}, 0, 0, S_NULL}, // S_ITEMCAPSULE {SPR_SGNS, FF_ADD|FF_FULLBRIGHT, 1, {NULL}, 0, 0, S_SIGNSPARK2}, // S_SIGNSPARK1 {SPR_SGNS, FF_ADD|FF_FULLBRIGHT|1, 1, {NULL}, 0, 0, S_SIGNSPARK3}, // S_SIGNSPARK2 @@ -22155,7 +22149,7 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] = S_NULL, // missilestate S_INVISIBLE, // deathstate S_NULL, // xdeathstate - sfx_itcaps, // deathsound + sfx_itpick, // deathsound 0, // speed 56*FRACUNIT, // radius 112*FRACUNIT, // height diff --git a/src/info.h b/src/info.h index ba7591ce7..f61891c06 100644 --- a/src/info.h +++ b/src/info.h @@ -4299,12 +4299,6 @@ typedef enum state // Item capsules S_ITEMCAPSULE, - S_ITEMCAPSULE_TOP_SIDE, - S_ITEMCAPSULE_BOTTOM_SIDE_AIR, - S_ITEMCAPSULE_BOTTOM_SIDE_GROUND, - //S_ITEMCAPSULE_TOP, - //S_ITEMCAPSULE_BOTTOM, - //S_ITEMCAPSULE_INSIDE, // Signpost sparkles S_SIGNSPARK1, diff --git a/src/p_inter.c b/src/p_inter.c index 0d3ff964f..fdd46408b 100644 --- a/src/p_inter.c +++ b/src/p_inter.c @@ -314,6 +314,13 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck) } S_StartSound(toucher, special->info->deathsound); + + if (special->tracer && !P_MobjWasRemoved(special->tracer)) + { + special->destscale = mapobjectscale>>4; + special->scalespeed <<= 1; + } + P_KillMobj(special, toucher, toucher, DMG_NORMAL); return; case MT_KARMAHITBOX: @@ -1429,58 +1436,11 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, UINT8 damaget else target->fuse = 40*TICRATE; - // burst effects - for (i = 0; i < 2; i++) - { - mobj_t *blast = P_SpawnMobjFromMobj(target, 0, 0, target->info->height >> 1, MT_BATTLEBUMPER_BLAST); - blast->angle = angle + i*ANGLE_90; - P_SetScale(blast, 2*blast->scale/3); - blast->destscale = 2*blast->scale; - } - - // dust effects - for (i = 0; i < 10; i++) - { - mobj_t *puff = P_SpawnMobjFromMobj( - target, - P_RandomRange(-spacing, spacing) * FRACUNIT, - P_RandomRange(-spacing, spacing) * FRACUNIT, - P_RandomRange(0, 4*spacing) * FRACUNIT, - MT_SPINDUST - ); - - P_SetScale(puff, (puff->destscale *= 2)); - puff->momz = puff->scale * P_MobjFlip(puff); - - P_Thrust(puff, R_PointToAngle2(target->x, target->y, puff->x, puff->y), 3*puff->scale); - if (attacker) - { - puff->momx += attacker->momx; - puff->momy += attacker->momy; - puff->momz += attacker->momz; - } - } - // remove inside item - if (target->tracer && !P_MobjWasRemoved(target->tracer)) - P_RemoveMobj(target->tracer); - - // bust capsule caps - while (part && !P_MobjWasRemoved(part)) + /*if (target->tracer && !P_MobjWasRemoved(target->tracer)) { - P_InstaThrust(part, part->angle + ANGLE_90, 6 * part->target->scale); - P_SetObjectMomZ(part, 6 * FRACUNIT, false); - part->fuse = TICRATE/2; - part->flags &= ~MF_NOGRAVITY; - - if (attacker) - { - part->momx += attacker->momx; - part->momy += attacker->momy; - part->momz += attacker->momz; - } - part = part->hnext; - } + P_RemoveMobj(target->tracer); + }*/ // give the player an item! if (source && source->player) @@ -1494,13 +1454,6 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, UINT8 damaget break; } - // special behavior for SPB capsules - if (target->threshold == KITEM_SPB) - { - K_ThrowKartItem(player, true, MT_SPB, 1, 0); - break; - } - if (target->threshold < 1 || target->threshold >= NUMKARTITEMS) // bruh moment prevention { player->itemtype = KITEM_SAD; diff --git a/src/p_mobj.c b/src/p_mobj.c index 1d8410a63..995d0ba1f 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -4106,6 +4106,13 @@ static void P_ItemCapsulePartThinker(mobj_t *mobj) target->y + P_ReturnThrustY(mobj, mobj->angle + ANGLE_90, mobj->radius), z); } + + if (mobj->scale <= mapobjectscale>>4) + { + P_RemoveMobj(mobj); + return; + } + } static void P_RefreshItemCapsuleParts(mobj_t *mobj) @@ -4120,34 +4127,7 @@ static void P_RefreshItemCapsuleParts(mobj_t *mobj) if (itemType < 1 || itemType >= NUMKARTITEMS) itemType = KITEM_SAD; - - // update invincibility properties - if (itemType == KITEM_INVINCIBILITY) - { - mobj->renderflags = (mobj->renderflags & ~RF_BRIGHTMASK) | RF_FULLBRIGHT; - mobj->colorized = true; - } - else - { - mobj->renderflags = (mobj->renderflags & ~RF_BRIGHTMASK) | RF_SEMIBRIGHT; - mobj->color = SKINCOLOR_NONE; - mobj->colorized = false; - } - - // update cap colors - if (itemType == KITEM_SUPERRING) - { - color = SKINCOLOR_GOLD; - newRenderFlags |= RF_SEMIBRIGHT; - } - else if (mobj->spawnpoint && (mobj->spawnpoint->args[2] & TMICF_INVERTTIMEATTACK)) - color = SKINCOLOR_SAPPHIRE; - else if (itemType == KITEM_SPB) - color = SKINCOLOR_JET; - else - color = SKINCOLOR_NONE; - - colorized = (color != SKINCOLOR_NONE); + part = mobj; while (!P_MobjWasRemoved(part->hnext)) { @@ -4241,16 +4221,6 @@ static void P_SpawnItemCapsuleParts(mobj_t *mobj) { UINT8 i; mobj_t *part; - fixed_t buttScale = 0; - statenum_t buttState = S_ITEMCAPSULE_BOTTOM_SIDE_AIR; - angle_t spin = ANGLE_MAX - ROTATIONSPEED; - - if (P_IsObjectOnGround(mobj)) - { - buttScale = 13*FRACUNIT/10; - buttState = S_ITEMCAPSULE_BOTTOM_SIDE_GROUND; - spin = 0; - } // inside item part = P_SpawnMobjFromMobj(mobj, 0, 0, 0, MT_ITEMCAPSULE_PART); @@ -4263,32 +4233,6 @@ static void P_SpawnItemCapsuleParts(mobj_t *mobj) part->eflags &= ~MFE_VERTICALFLIP; P_SetTarget(&mobj->tracer, part); // pointer to this item, so we can modify its sprite/frame - // capsule caps - part = mobj; - for (i = 0; i < CAPSULESIDES; i++) - { - // a bottom side - P_SetTarget(&part->hnext, P_SpawnMobjFromMobj(mobj, 0, 0, 0, MT_ITEMCAPSULE_PART)); - P_SetTarget(&part->hnext->hprev, part); - part = part->hnext; - P_SetTarget(&part->target, mobj); - P_SetMobjState(part, buttState); - part->angle = i * ANG_CAPSULE; - part->movedir = spin; // rotation speed - part->movefactor = 0; // z offset - part->extravalue1 = buttScale; // relative scale - - // a top side - P_SetTarget(&part->hnext, P_SpawnMobjFromMobj(mobj, 0, 0, 0, MT_ITEMCAPSULE_PART)); - P_SetTarget(&part->hnext->hprev, part); - part = part->hnext; - P_SetTarget(&part->target, mobj); - P_SetMobjState(part, S_ITEMCAPSULE_TOP_SIDE); - part->angle = i * ANG_CAPSULE; - part->movedir = spin; // rotation speed - part->movefactor = mobj->info->height - part->info->height; // z offset - } - P_RefreshItemCapsuleParts(mobj); } #undef CAPSULESIDES diff --git a/src/sounds.c b/src/sounds.c index 09d6f7c0b..bd8d66856 100644 --- a/src/sounds.c +++ b/src/sounds.c @@ -1098,9 +1098,6 @@ sfxinfo_t S_sfx[NUMSFX] = {"syfail", false, 96, 8, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // Funny sync failure {"itfree", false, 64, 0, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // :shitsfree: {"dbgsal", false, 255, 8, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // Debug notification - {"cock", false, 64, 0, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // Hammer cocks, bang bang - {"itcaps", false, 64, 16, -1, NULL, 0, -1, -1, LUMPERROR, "Item capsule"}, - {"kstart", false, 64, 16, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // Sonic Adventure shwing! {"typri1", false, 64, 16, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // SA2 boss typewriting 1 {"typri2", false, 64, 16, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // SA2 final boss-type typewriting {"eggspr", false, 64, 16, -1, NULL, 0, -1, -1, LUMPERROR, ""}, // Sonic Unleashed Trap Spring diff --git a/src/sounds.h b/src/sounds.h index e008608bd..64985a7f8 100644 --- a/src/sounds.h +++ b/src/sounds.h @@ -1162,9 +1162,6 @@ typedef enum sfx_syfail, sfx_itfree, sfx_dbgsal, - sfx_cock, - sfx_itcaps, - sfx_kstart, sfx_typri1, sfx_typri2, sfx_eggspr,