I'm working on a wonder weapon that does something upon impact but I only want it to do it on certain textures. For example if I shoot a brick texture nothing happens but If I shoot a specifically made texture such as "custom1" then the weapon impact will work. Right now it works on every surface type which is not what I want. Is there a way to get what surface or texture is being shot? Or maybe another way to force it to only work on certain textures?
I'm working on a wonder weapon that does something upon impact but I only want it to do it on certain textures. For example if I shoot a brick texture nothing happens but If I shoot a specifically made texture such as "custom1" then the weapon impact will work. Right now it works on every surface type which is not what I want. Is there a way to get what surface or texture is being shot? Or maybe another way to force it to only work on certain textures?
Thanks, Whippy
There is a way of getting what surface is shot. I'm not sure if there is a way to get what texture is shot, but this is how you do surface:
As you can see, one of the things you can check when doing bullettrace is the surface type that was hit (in this example it checking if trace["surfacetype"] is not water). I don't think you can check for textures specifically, but you can make the one texture you want to accept hits something like snow (or anything) in asset manager and then not use that texture type anywhere else in your map.
As you can see, one of the things you can check when doing bullettrace is the surface type that was hit (in this example it checking if trace["surfacetype"] is not water). I don't think you can check for textures specifically, but you can make the one texture you want to accept hits something like snow (or anything) in asset manager and then not use that texture type anywhere else in your map.
Thanks man! I'll let you know what happens and if i get it working.
I'm not sure exactly how I want it to work. I'm thinking of excluding certain surfaces like AwesomePieMan said and then it will work almost everywhere in my map that I need it to. Sorry I can't elaborate but I'ts a wonder weapon I'd like to keep secret.