Hello,
I use RFPS for my own game currently in progress and i need you'r help for footsteps fix.
I have a footsteps.cs script, on this script we are all surfaces (wood, stone, sand, water etc) and TAG in the which surfaces are assigned them (Surface dirt = Dirt Tag). Then the player walk on prefab with tag "wood" the footsteps/jump sound wood play.
The problem is with the ground, my ground is not flat, thus if I put the ground with " sand " TAG and I add smooth to plane collider for the forest so when the player will walk on a bump in bit or in a hole the sound "dirt" or "foliage" will not play.
I have two ideas to fix that :
1) Create a script which detects textures of the ground then I can add a tag has this texture so when the player walks on the sand texture the sound " sand " plays.
or
2) Create a zone which defines a surface, when players is in this zone sounds "sand" play.
How i can make it please ?
↧