How do I display objects frame without associating events?

Get help using Construct 2

Post » Wed Jul 13, 2016 8:47 pm

I am wanting to have a menu that displays an image of game objects that can be found during game play.

An example would be a building that can be upgraded so it will have different frames. During game play the building will have reactions to other objects. I am wanting to add the image of the building on a menu. It needs to show the same frame as the game play building, but not have it adopt it's events and triggers associated with it.

Is there a way I can just grab a frame of an object and have it displayed in a 2nd location, so it doesn't have events or triggers associated with it? Is it possible to make a 2nd object and use the first objects animation frames, but it will still be it's own object and won't adopt "on created" events etc. Or do I have to make a 2nd duplicate object with the same Animations? I am not wanting to waste ticks that are not needed on the 2nd building image if possible.

This brings up another question. If I do an overlay on a layout as a menu, how do I prevent drag and drop items from interacting with what is below the menu overlay?
B
62
S
35
G
13
Posts: 230
Reputation: 12,402

Post » Wed Jul 13, 2016 9:29 pm

I would simply use one object with an instance variable to check for conditions. So for your building, add a boolean "DisplayOnly" true or false. Then for your events, add the DispayOnly=false to not affect the menu ones.
Mistakes were made.
B
51
S
25
G
107
Posts: 1,581
Reputation: 60,458

Post » Wed Jul 13, 2016 9:30 pm

Regarding the drag and drop on the menu, again you would just add a condition to your drag event to only include things on the relative layer.
Mistakes were made.
B
51
S
25
G
107
Posts: 1,581
Reputation: 60,458

Post » Wed Jul 13, 2016 9:39 pm

I realized this and was trying to remove the post. Windows updates started without asking and slowed my internet down so much I couldn't do anything... Thank you for your reply.
B
62
S
35
G
13
Posts: 230
Reputation: 12,402


Return to How do I....?

Who is online

Users browsing this forum: David181, dop2000 and 10 guests