Quantcast
Channel: Questions in topic: "javascripting"
Viewing all articles
Browse latest Browse all 105

Using the Texture Swap Animator js I found in the Wiki to create a gif like texture, only showing first frame and not playing through them all

$
0
0
Very new to coding so it might be something small I'm over looking or forgetting but just cant seem to be able to get this code to work for me, I apply it to a plane add in all my frames and when i hit play, it just shows the first frame as the texture and that's it. any help or advice would be very appriciated Using the TextureSwapAnimator.js : var frames : Texture2D[]; var framesPerSecond = 10.0; function Update () { var index : int = Time.time * framesPerSecond; index = index % frames.Length; renderer.material.mainTexture = frames[index]; }

Viewing all articles
Browse latest Browse all 105

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>