#Collisions groups

1 messages · Page 1 of 1 (latest)

thin crag
#

I'm doing a two players obby and I'm setting collisions groups of some players, which is working fine, but I was wondering if there is a way to set a collision group of a part that only exist on the client side, I know you can only use collision groups on the server but can you use it on the client if it's on a client part?

#

The idea is that I want the two players to have collisions with some objects that are only made on their client's side, but other players can collide with those objects even if for them, they don't exist...

#

I thought of using run service to make the other player's characters (torso and head) uncollideable but I don't think this would be very slow devices friendly

#

I don't need a full script detailed, I just need an idea on how to make this work, like I said, I tried some things but none of them really worked...

#

ping me if you got an idea

spare reef
#

just make 2 copies of the part in both clients, and set its properties as you want

thin crag
#

The issue is that , when one of the player grabs the block, it works fine, but if there is another duo of players that are at the same place as the cube is for you, they will collide with it, altho for them they collide with nothing so they continue moving and it makes it hard to move the block when there are other players that are not in your duo

thin crag
buoyant heron
#

Can you send a vid example?

thin crag
#

sure

#

@buoyant heron let me record it, it will be a bit laggy perhaps as I need to simulate three players to show you my issue

#

the video file is too large 💀

#

how can I send it to you @buoyant heron ?

spare reef
#

use streamable

thin crag
#

wait I'm compressing the video

#

here you go

#

so the issue in this video is that the "player1" should not be able to collide with the "player3" and the "player2" block.

thin crag
#

@spare reef what you think ?

buoyant heron
#

Maybe

#

Turn off collision on all other players

#

Or make a collision group on the block that won’t collide with other players than the duo

Duo collision group(+block): "Duo"
OtherPlayers: "OtherPlayers"

Duo can’t collide with other players

thin crag
buoyant heron
# thin crag yea that is what I thought, but the issue is that the block dosen't exist on the...

Another idea:

make a folder (I’ll call it main for now)

When a duo is created, make a folder inside main named Plr1Name+Plr2Name.
Make the block inside the folder
A localscript will make that folder removed if you’re not a part of the duo
That way, the block exists on server but only that duo will have the block

Then, make a new collision group for the block and for the players (same one) and make it so the other duos group won’t collide with it
How to:
https://devforum.roblox.com/t/collision-groups-with-scripts/2152867/2

buoyant heron
thin crag
#

so that's a bit the same as using collisions groups, but it also works on client

#

I just didn't knew those nocollisionconstraint existed

buoyant heron
#

O

#

Ok 👍

thin crag
#

thank you for your help