Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How can I make a player "Hidden"?

Asked by 5 years ago

I want to make a script where when a part is being touched, the player is hidden from NPC's until they are no longer touching the part. I also need the PathFinding script to reset when the brick is being touched. (The Pathfinder script was deleted because it was glitched on the R15 avatar)

(The part is the Brick)

I only know how I can make a OnTouched script.


local torso = game.Players.zboi082007.Torso -- I dont really know how do do this part -- local bandit = game.ReplicatedStorage.Bandit local path = bandit.path script.Parent.Touched:Connect(function() bandit.path = ??? -- neither this ---
0
Also, I need to say that I have random scripts half English and half Japanese in my game. zboi082007 270 — 5y
0
Okay - don't rely on Touched for this it is a bad idea. Use raycasting instead. A single ray existing for the purpose of detecting whether or not the player is touching some object is very inexpensive and a step up from the Touched event. SummerEquinox 643 — 5y
0
Well how would I make the script? zboi082007 270 — 5y

Answer this question