Question about animated uv in unity

Hello , my question is i got a mesh ,and how can i only apply my texture from start to end one time without looping?
(like each time my particle spawn 1 mesh and the arrow texture scrolling uv from start to end with no looping or tiling)
it hard to learn shader graph etc.:tired_face:

1 Like

select the texture you use in unity, and then in inspector window you will see wrap mode, set it to Clamp then the texture will not loop anymore.
image

1 Like

how do i do in particle system. is not work with shader(only work with playmode)

how do you do it now?

Hello!

What I do to get it to only play once in a particle system is this:

First turn of looping in the particle system.

Afterwards I also set max paticle count to 1 and I create a burst in the emmision that also has a count of 1 and a rate over time of 0.

Hope this helps?

What will happen now is it will only play once, and if you wnat it to play again you need to restart the effect so to speak.

if i use clamp, when particle spawn mesh it doesnt show anything.
so i just regular repeat
the problem is everytime particle spawn the uv start position is not same.


Hey, you might want to check Unity’s Custom Vertex Stream, there’s some knowledge about it on the forum.
https://realtimevfx.com/t/unity-custom-vertex-stream-and-shadergraph-amplify-shader/9524
https://realtimevfx.com/t/unity-custom-stream-and-shaderforge/2300/3
Hope it helps and have a great day :smiley:

1 Like

Because it’s based on delta time on your shader, it’s like a clock from 0 to 1 that never stop.

you should use the custom vertex stream to manage this with a curve, there is a good topic here ! Unity - Custom Vertex Stream and Shadergraph/Amplify Shader

@Mursi @Neall
thank guys, i get the meaning , will try to understand custom vertex stream.
so much technical side to learn :no_mouth:

2 Likes


in the pic you can see at the same time the uv offset of each particle is the same because the offset of the texture is depends on the time not particle parameters
image
you can try Custom Data in particle system. You can get per-particle control using it.
image

ya understand, but i need take sometime to understand how to use custom data.
haha

this is a tut about how to use custom data. it’s using shader forge but the way to do it in ASE is amost the same. https://www.youtube.com/watch?v=3z534Zhb6_I&t=18s