About Store Forum Documentation Contact



Post Reply 
Multiple object with the same image in Gui Editor.
Author Message
mih Offline
Member

Post: #1
Multiple object with the same image in Gui Editor.
Hi I have a problem with objects[Image type] that have the same image.
All of them have different names, but the same image, all set in Gui Editor.
I load them in the code like that:
Code:
        gfx_submarine_1 = &gameGUI.getImage("gfx_submarine_1");
        gfx_submarine_2 = &gameGUI.getImage("gfx_submarine_2");
but when I change the image in for example gfx_submarine_2, all images that had the same source image change.
Code:
    if(e_submarineHits[0]==true &&
       e_submarineHits[1]==true &&
       e_submarineHits[2]==true)
    {
        gfx_submarine_2->image->load("Gfx/light_off.gfx");
    }
So is there a way to do It in that way ? or do I have to assign to all Image type objects in Gui Editor, source image with different names ?
03-21-2010 12:27 PM
Find all posts by this user Quote this message in a reply
Esenthel Online
Administrator

Post: #2
RE: Multiple object with the same image in Gui Editor.
gfx_submarine_2->image=Images("Gfx/light_off.gfx");
03-21-2010 03:50 PM
Find all posts by this user Quote this message in a reply
mih Offline
Member

Post: #3
RE: Multiple object with the same image in Gui Editor.
Thanks It's working now, my bad wink
03-21-2010 07:56 PM
Find all posts by this user Quote this message in a reply
Post Reply