Author Topic: Changing Image in Simple texture using button  (Read 2890 times)

Sona

  • Guest
Changing Image in Simple texture using button
« on: February 05, 2013, 10:59:41 PM »
I have two image button(nextButton and previousButton), and a Simple Texture, While clicking on nextButton, next image should come on Simple Texture and  clicking on previousButton, previous image should come on Simple Texture. I cant able to change texture of Simple Texture. Please help to solve this issue.

Nicki

  • Global Moderator
  • Hero Member
  • *****
  • Thank You
  • -Given: 33
  • -Receive: 141
  • Posts: 1,768
    • View Profile
Re: Changing Image in Simple texture using button
« Reply #1 on: February 06, 2013, 05:04:14 AM »
  1. UITexture myUITexture;
  2. Texture myOtherTextureReference;
  3. myUITexture.mainTexture = myOtherTextureReference;

Sona

  • Guest
Re: Changing Image in Simple texture using button
« Reply #2 on: February 07, 2013, 07:01:54 AM »
@Mr.Nicki : Thank you. Its works fine. :)