local function removeairwalk(p)
	if p.mo and p.mo.valid
	and (p.mo.state == S_PLAY_STND or p.mo.state == S_PLAY_WALK or p.mo.state == S_PLAY_RUN or p.mo.state == S_PLAY_DASH)
	and not P_IsObjectOnGround(p.mo)
	and not (p.powers[pw_carry] == CR_ROLLOUT)
	and not (p.powers[pw_carry] == CR_MINECART)
	and not (p.powers[pw_carry] == CR_NIGHTSMODE)
		p.mo.state = S_PLAY_FALL
	end
end

addHook("PlayerThink", removeairwalk)