Suggestion Dummy Object

New releases and general discussions.

Post » Sat May 16, 2009 8:18 pm

Just a thought I had. Since we're always using dummy sprites for this and that, wouldn't it be good to have and object that was just for that purpose?
I know it might be a bit redundant, but it might be a lot quicker if we could have some special options in the preferences tab.
For example if it was placed in a container it would have the ability to mimic its container object.
You could have the ability to set its position, image, angle, size, animation, etc based on the "master" object, all in the preferences tab.

Something like if image was unchecked, but position, and angle were, the dummy would always set its position, and angle to the master sprite, but it would have 0 opacity. Then its size would remain the same as well.
Image Image
B
161
S
48
G
91
Posts: 7,359
Reputation: 67,273

Post » Mon May 18, 2009 3:36 pm

It's too redundant, sprites are enough i find. It doesnt take that long to set up events anyways, and imo i would not use it.
B
25
S
3
G
6
Posts: 1,197
Reputation: 5,620

Post » Mon May 18, 2009 5:10 pm

If everything else that was in the same container as the object with dummy behaviour, per dummy object, was aligned properly according to size and angle and everything at runtime on demand, that would be neat. But the uses here are become somewhat limited; it is probably best to simply event script these things as needed.

For this sort of object arrangement, it would be useful if there were a "This," or "picked object," etc to use in equations - instead of Object.X, operate more vaguely on the object that is currently being placed. Then an event could run through each object in a family, and set each of them up the same - that is, instead of setting the width, height, angle etc of objectA, objectB and objectC individually per dummy, to be able to, as it runs through each dummy object, also run through objectA, B and C as a family and orient each, with the same few events.

If there is already some way to do it, using containers or something, that would be cool. I keep reading that things done to one object in a container are done to all other objects in that container, but does this also include positioning, scaling and rotation? Maybe I have just not tested this thoroughly enough, hmm...
B
4
S
2
G
6
Posts: 161
Reputation: 2,597

Post » Mon May 18, 2009 6:05 pm

Objects in containers can have actions individually applied to them, such as being set to separate positions and angles. Conditions, on the other hand, pick the entire container whenever one object in the container is picked.
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,630

Post » Mon May 18, 2009 7:33 pm

As I said, yes it is a bit redundant, its meant to simplify, and speed things up.
While it could have all the display attributes of its master, it would not mimic any of the behaviors of the master.
For example, currently you can not change the size of any object using the physics behavior, so one way around this is to use a dummy sprite.
Image Image
B
161
S
48
G
91
Posts: 7,359
Reputation: 67,273

Post » Wed May 20, 2009 11:31 pm

I started using boxes as dummies, but then found out they are very limited. They don't even rotate their collision boxes. Which could be a bug. Which I will report.


Yes.


Sprites are more useful, but you wind up wasting VRAM on them. A dummy object would be awesome if it had everything sprite has and you could draw an icon on it... and it would be a Sprite, essentially.
So... just group them in a family and hide them on startup. Use a tiny pow2 texture (32x32 for example).
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Thu May 21, 2009 7:24 am

Why not just use 2x2? That'll use as much VRAM as a tiny peck of sand uses up space on your courtyard.
B
62
S
21
G
12
Posts: 1,910
Reputation: 13,155


Return to Construct Classic Discussion

Who is online

Users browsing this forum: No registered users and 1 guest