Advertisement
kasru

Change Alpha Cutout

Feb 21st, 2013
2,039
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //****** Donations are greatly appreciated.  ******
  2. //****** You can donate directly to Jesse through paypal at  https://www.paypal.me/JEtzler   ******
  3.  
  4. var alpha : float = 0;
  5.  
  6. function Start () {
  7.  
  8.     ChangeAlpha();
  9. }
  10.  
  11.  
  12. function Update () {    
  13.    
  14. }
  15.  
  16.  
  17. function ChangeAlpha () {
  18.  
  19.     yield WaitForSeconds(5);
  20.  
  21.     for(i=1; i>0; i++) {
  22.  
  23.         yield WaitForSeconds(0.05);
  24.         alpha += 0.05;
  25.         renderer.material.SetFloat("_Cutoff", alpha);
  26.     }
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement