Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

a platform you can jump-thru from the bottom, but cant fall through, is this possible?

I want to make a platform you can jump-thru from the bottom, but cant fall through, like in New Super Mario Bros Wii, and I've been trying some scripts and collisions for around 3 hours, and I just would like to know if this is possible without changing the players position or something along that, I've also done some researching on this, and I haven't found a solution to this yet. any help would help a lot.

3 comments

0

Can you show the part of New Super Mario Bros Wii that shows exactly that?

0

Though I am not sure if this would work, you could try using a one-sided mesh.

0

is it a singleplayer game?

1 answer

If you're doing SinglePlayer you won't need to create a new 'CollisionZone' for each player, but the CollisionZone will just be an invisible part that represents the collisionbounds for multiplayer so that all players get the same view, but have their own interaction with it, allowing multiple players to jump through it at once.

--Assumes each platform creates a new 'CollisionZone' for each player added to the game
local function setCanCollide(collisionZone, collisionZonePlayer)
	--If the player is touching it, leave it at it's current CanCollide
	for i,v in pairs(collisionZone:GetTouchingParts()) do
		if v:IsDescendantOf(collisionZonePlayer.Character) then
			return collisionZone.CanCollide
		end
	end
	--Otherwise, the player is either above or below, and set CanCollide appropriately
	return collisionZonePlayer.Character.WorldPivot.Position.Y > collisionZone.Position.Y
end

3 comments

0

^ And then if you want the player to be able to fall through when they hit the down arrow or something, you just set CanCollide = false for that player's collisionZone, and it should maintain the new CanCollide as they fall through it.

0

It is impossible to make the player's character's limbs since they have the Humanoid instance.

0

Any model that has the Humanoid instance inside, it is impossible to turn off the collisions of every parts that is a child of that model.

This discussion is preserved as it was. New answers, comments, and votes are closed.