Bummer! This is just a preview. You need to be signed in with a Basic account to view the entire video.
Animating Material Offsets8:30 with Nick Pettit
The offset of a material determines where it should start and where it should end on the 3D model. Animating the material offset over time can create the illusion of slow movement, like moving lava.
Material - This section of the Unity documentation details the
Materialclass, which exposes all properties of a material.
Material.SetTextureOffset() - The
Material.SetTextureOffset()method takes a property name as a string and a Vector2 that can offset the X and Y coordinates of the property. Generally
Material.SetTextureOffset()is used with the
"_MainTex"property to offset the entire material over time.
- Materials in Unity - Project Files - This is a zip file that contains the Unity project for this course. Download the file, unzip it, and then in your file browser (Finder on OS X and Exporer on Windows) navigate to Materials in Unity > Assets > _Scenes. Finally, choose the scene you'd like to open.
You need to sign up for Treehouse in order to download course files.Sign up