Advertisement
Gayngel

Untitled

Jan 23rd, 2015
607
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. //This script changes texture on a timer. Change the float of llSetTimerEvent to increase or decrease the time between texture changes.
  2.  
  3. ChangeTexture ()
  4. {
  5. llSetPrimitiveParams ([ PRIM_TEXTURE, ALL_SIDES,llGetInventoryName (INVENTORY_TEXTURE, (integer) llFrand (llGetInventoryNumber (INVENTORY_TEXTURE))), <1.0, 1.0, 0.0>, <0.0, 0.0, 0.0>, 0.0 ]);
  6. }
  7. default
  8. {
  9. state_entry ()
  10. {
  11. llAllowInventoryDrop (TRUE);
  12. llSetTimerEvent (20.0);
  13. ChangeTexture ();
  14. }
  15. timer ()
  16. {
  17. ChangeTexture ();
  18. }
  19. touch_start (integer touches)
  20. {
  21. ChangeTexture ();
  22. }
  23. changed (integer Change)
  24. {
  25. if (Change & (CHANGED_ALLOWED_DROP | CHANGED_INVENTORY))
  26. ChangeTexture ();
  27. }
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement