LocalScript affects the ServerSide, How?

Hi all,

I’m trying to remove the hitbox on the character locally so the player’s mouse does not interfere with it (when aiming with mouse or mobile touch). Here’s the local script in StarterCharacterScripts.

local hitbox = character:WaitForChild("BiggerHitbox")
game.Debris:AddItem(hitbox, 1)

Now after testing on studio I can see on the ServerSide that the hitbox has completely vanished from the character. How do I remove it only on the client side?

Thanks in advance!

Not sure why that happens, but you could set the hitboxes’ .CanQuery to false, should remove mouse collision

1 Like

It doesn’t solve the issue for me, it just makes the player invincible since the weapons I use require mouse hit

Set Mouse.TargetFilter to the player character could work perhaps, unless you’re already using TargetFilter for something else.

UPDATE: I set the CanQuery to false THROUGH the localscript so it’s only applied to the player’s own character and it works.

thank you for the solution!

Roblox replicate any deletion of any instance in the Character. Yeah, that replication behavior sucks.

1 Like