Player Assembly Interaction

Is there any way to prevent player’s masses from interacting with physics assemblies. I am currently trying to make a vehicle system using roblox’s physics constraints and don’t want players jumping around to mess with the vehicles physics.

CollisionGroups are what you’re after.

Use the scripting context within the tutorial as necessary, or do it manually with the group editor to play around with it.
Hope this helps.

Let me correct/clarify my problem. I need the players to act as if they are massless when they collide with parts of the vehicles physics assemblies. For example, if a player were to sit on a seat on the vehicle, the vehicle’s suspension should not sag.

That does clarify quite a bit.
When I made my own chassis system I ran into this same issue, and the only way I was able to rectify the issue was to stiffen my chassis (was necessary for higher speeds anyways) or use a script to force every character to a massless state.
(2.8 assembly mass is the lowest you can achieve before experiencing odd Humanoid behavior)

Otherwise, I’m not sure how else to solve this other than just making your chassis stiffer or making the issues massless.

Edit: Sorry, that was the old script (issues with CharacterAppearanceLoaded:Wait())

local Players = game:GetService("Players")

local function MakeMassless(Char)
	for _, Obj in Char:GetDescendants() do
		if Obj:IsA("BasePart") then
			pcall(function() Obj.Massless = true end)
		end
	end
end

for _, V in Players:GetPlayers() do
	V.CharacterAdded:Connect(function(Char)
		local Counter = 0
		repeat task.wait(1/30) Counter+=1 until V:HasAppearanceLoaded() or Counter > 30*5 -- Still works when roblox is failing to load characterappearance or it loads rapidly
		MakeMassless(Char)
	end)
end

Players.PlayerAdded:Connect(function(Player)
	Player.CharacterAdded:Connect(function(Char)
		local Counter = 0
		repeat task.wait(1/30) Counter+=1 until Player:HasAppearanceLoaded() or Counter > 30*5
		MakeMassless(Char)
	end)
end)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.