How can i make parts be semi-transparent when a player is behind them?

I’m sorry if you I’m asking for spoon-fed code, but I don’t know where to start nor I’d implement this feature so any help would be appreciated!

I want it so whenever you have a wall that’s higher than the player, it becomes semi-transparent and you can see through the part.

Thank you!
(again I’m sorry if I need spoon-fed code)

2 Likes

You can set property of StartPlayer called DevCameraOcclusionMode to Invisicam.

if you don’t like this apporach and looking for more control over what becomes transparent, u can use BindToRenderStep() with priority lower than camera and raycasting, raycasting from camera’s cframe to character’s cframe, if u hit something just make it transparent, black list it and continue casting ray until it hits character.

I dunno if I did something wrong with the property but the DevCameraOcclusionMode isn’t working

if u are using custom camera script then it might not work. Try implementing the second apporach I suggested, into your custom camera script.

I’ll try! thank you for the help

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