Client side objects bug

So in my roblox game, i have a cube, and you need to push this cube on a pressure plate

This cube is also spawned by the client

The problem is, other people can push it somehow, they can’t see it nor touch it, but can somehow push it

How do i fix this?

1 Like

maybe remove collusion for other players

1 Like

i suppose i could create the object on the server, right now its spawned on the client

this might cause more lag tho but it depends on server size

i think i have a solution, i will try it and say if it works

my solution didnt work, bummer

what if my idea but other way round the players will have no collusion in cilent with the cube you push

how would i remove it for other players tho

Check out the documentation on CollisionGroups.

You can make the Part only collide with the Player it needs to by putting them in the same group.
It’s probably better to leave them client sided so others don’t interact with them or see them in any other way.

1 Like

Try make the cubes on the server, and make separate collision groups for each player, then assign that collision group to your cube.

The issue with that is (I think, it seems like OP wants them invisible to other players) they’d also have to make them invisible and CanCollide false for the other players.
Client sided would save a little bit of Server load. You could do checks to make sure that players aren’t using some cheat program to change gameplay on their client.

1 Like

i could try having a collision group on the rock, main client and other clients

then have the rock collide with main client and not other clients

by the way, the cube is only on the client, so it doesnt exist for other clients, but when they touch it on my screen, it still pushes it

Just add 1 collision group per player. Make it and their rock only collide with each other. I’m pretty sure you can script them to be added.

You’d probably have to delete that collision group if the player left the game to keep within your limit of collision groups.

would i create it on the client?
or would i create on server and set on client

YES IT WORKED! thank you so much!

2 Likes