Making a character break Spikes?

Sir Thoksalot

What the thok
I'm working on a Super Knuckles wad and I want to have Knuckles break spikes when he walks into them. How would I go about doing this?
 
Try doing something similar to how Boost Mode (Dash Mode with SF_MACHINE flag) or the Metal Sonic race object do it.
 
Knuckles has a super form so a Super Knuckles mod isn't needed. But if it's similar to Almost Super Sonic, then go ahead.
 
Knuckles has a super form so a Super Knuckles mod isn't needed.
It has sprites and I wanted to add a bit of Lua to it, I have a GIF right here.
Sprite-SuperKnucklesIdle.gif
 
You could do a MobjCollide or MobjMoveCollide hook between the spike and player object, where the spike is killed if the player object is super and is using the "knuckles" skin.
 
I'm working on a Super Knuckles wad and I want to have Knuckles break spikes when he walks into them. How would I go about doing this?
Lua:
addHook("MobjCollide", function(spike, pluto)
    if not (pluto.player and pluto.skin == "knuckles")
        return nil
    if (pluto.z > spike.z+spike.height)
    or (spike.z > pluto.z+pluto.height)
        return nil
    else
        spike.health = 0
        S_StartSound(pluto, spike.info.deathsound)
        P_KillMobj(spike, pluto, pluto)
        return false
    end
end, MT_SPIKE)
Here's a modified spike breaker code used for my pluto mod that has been slightly modified to fit your needs. Hope this helps!
 

Who is viewing this thread (Total: 1, Members: 0, Guests: 1)

Back
Top