Let he who has not sinned cast the first stone.
I am not confident of the code.
This is part_shader_logic code I touched.
There is a tutorial on custom perks here, just look for it. In that tutorial it walks you through making your own custom perk shaders, just follow that part. Its really easy and its the same process no matter what you're using the shaders for - jumpscares, perk shaders, parts etc.