Quick replace objects in events?

Discussion and feedback on Construct 2

Post » Tue Mar 12, 2013 6:03 pm

I'm not thinking this is possible, but maybe I'm wrong. If it isn't possible, it definitely would be a nice feature.

Anyway... is there a way to quickly replace an object in code with another one? For example, say I have two sprites, and in my code I have just:

"On start of layout - Object 1 Destroy"

Now... I want to copy/paste this destroy action and change the second action to Object 2 Destroy...

To do this currently, I have to double click the action, go in and go back to the objects, change it to Object 2, and then click through the menus until it's done. But what if I have a piece of code that utilizes Object 2 already?

Wouldn't it be easier if I could like alt+click on the Object 2 icon in another piece of code, and then drag/drop it on the Object 1 icon for the Destroy event, and it would automatically update to Object 2?

Is something like this possible and I just don't know the shortcut for it?
B
7
S
2
G
3
Posts: 28
Reputation: 2,260

Post » Tue Mar 12, 2013 6:11 pm

Double click on the object name doesn't do this for you already?
B
49
S
11
G
10
Posts: 1,833
Reputation: 14,428

Post » Tue Mar 12, 2013 6:23 pm

Not sure what you mean
B
7
S
2
G
3
Posts: 28
Reputation: 2,260

Post » Tue Mar 12, 2013 6:29 pm

What I'm saying is to replace say... a "set object 1 x position" event with a "set object 2 x position" event, I need to left click a total of 8 times, through multiple menus.

The solution I'm requesting could be done in a single drag and drop. It would save a ton of time. Especially on large projects where you might have to look through 50 objects to find the one you want to change to.

Even better would be to drag an object from the Objects panel directly on top of an object icon in the event sheet to replace it.Konidias2013-03-12 18:29:34
B
7
S
2
G
3
Posts: 28
Reputation: 2,260

Post » Tue Mar 12, 2013 6:31 pm

Ah I see, never really thought of it as those 8 clicks only take me a couple seconds. Sounds useful though for scenarios where you need to do a lot of events. Some type of find/replace across events would be nice too...
B
49
S
11
G
10
Posts: 1,833
Reputation: 14,428

Post » Tue Mar 12, 2013 7:03 pm

Yeah... lately I've needed to do it a lot, across a dozen actions at a time, and it can really just be annoying and time consuming. A quicker method would be extremely appreciated.
B
7
S
2
G
3
Posts: 28
Reputation: 2,260

Post » Wed Mar 13, 2013 2:38 am

It may be on the todo list
B
20
S
5
G
8
Posts: 325
Reputation: 6,473

Post » Wed Mar 13, 2013 2:28 pm

It is already on the todo list. Hopefully will turn up soon!
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600

Post » Thu Mar 14, 2013 3:35 am

@Konidias @BluePhaze @lemo

Hi guys, I made this short tutorial, hope it works for you.How to replace objects in events

@Ashley I know nothing about programming, but wouldn't it work something like the "search and replace" function like the one in text editors?

Image
B
42
S
11
G
5
Posts: 269
Reputation: 10,890

Post » Thu Mar 14, 2013 4:03 am

@danuyos That was what I proposed above some type of search and replace option
B
49
S
11
G
10
Posts: 1,833
Reputation: 14,428

Next

Return to Construct 2 General

Who is online

Users browsing this forum: zenox98 and 15 guests