Pick All / Create Bug

Bugs will be moved here once resolved.

Post » Tue Jun 28, 2016 1:00 pm

@Ashley Would it be possible to request a new type of top level event related to creation of objects that allows for picking? It would just be neat and allow an easy pedagogical way instead of figuring out workarounds or filing bugs. For a layman without any deeper understanding of the current event design it just doesn't make sense, and I bet not only me wasted countless of hours trying to figure out why it doesn't pick as 'In my mind' the objects should have been picked. I think people stumbling across this odd behaviour will continue to file this as a bug in the future as well.

First time I encountered this problem I instinctively went directly for the "on created" condition, and then functions as my first try to find a solution but this didn't help, so it had me scratching my head why, and joining the discussion here. Would there be any drawbacks to changing the "On created" condition to be a pure top level event?
Follow my progress on Twitter
or in this thread Archer Devlog
B
35
S
15
G
17
Posts: 944
Reputation: 12,210

Post » Tue Jun 28, 2016 2:01 pm

tunepunk wrote:Would it be possible to request a new type of top level event related to creation of objects that allows for picking? Would there be any drawbacks to changing the "On created" condition to be a pure top level event?

No, this does not solve the underlying problem. The engine cannot support potentially modifying the instance lists while it is using them, and so there can neither be a new kind of event, nor a special kind of trigger, that works around this.
Scirra Founder
B
387
S
230
G
87
Posts: 24,248
Reputation: 192,226

Post » Tue Jun 28, 2016 6:28 pm

@Ashley , if I understand correctly, the reason we can't pick newly created objects within nested subevents is because loops would attempt to reference indices that don't exist within the instance list (because the new objects aren't merged with it until top-level event)?
And if you wanted to reference an instance that isn't in the instance list, there'd need to be a way to know that it is in the new object list instead- and this is an engineering issue that would require a lot of work?

Edit: couldn't you give new objects a "would-be" index number, that corresponds to what their index would be when they get added to the instance list. And then when checking instance list, cycle through the would-be indices- if they are greater than the instance list length, then check the new object list instead?
B
41
S
19
G
65
Posts: 1,085
Reputation: 37,842

Post » Tue Jun 28, 2016 6:46 pm

"When you develop intricate processes that aren't just simple events like these examples, the order of every single step through the process matters- you can't afford to break away and assume it will work with everything else."

What if a user destroys that object in the same event? What if a user destroys some other instance in the same event?
What if it's created from a family? What if a user creates yet another instance in a subevent?
Image ImageImage
B
168
S
50
G
163
Posts: 8,220
Reputation: 105,059

Post » Tue Jun 28, 2016 6:53 pm

newt wrote:"When you develop intricate processes that aren't just simple events like these examples, the order of every single step through the process matters- you can't afford to break away and assume it will work with everything else."

What if a user destroys that object in the same event? What if a user destroys some other instance in the same event?
What if it's created from a family? What if a user creates yet another instance in a subevent?


If everything was accounted for, and objects that should be considered created are created and objects considered to be destroyed are destroyed, then that would be no problem. The logic would follow a consistent pattern and you would easily make sense of the events.
B
41
S
19
G
65
Posts: 1,085
Reputation: 37,842

Post » Tue Jun 28, 2016 7:37 pm

They do.
The logic is pick something, or somethings, and do something, or things to those objects.
Not and some other objects that weren't picked.
Picking at creation is a special case meant to make things easier, trying to exploit that even more is the issue.
Image ImageImage
B
168
S
50
G
163
Posts: 8,220
Reputation: 105,059

Post » Tue Jun 28, 2016 7:43 pm

It's not about exploiting anything, newt. It's about expecting some logic to work. If I want to pick everything that is created, I don't want to wait because it isn't fully available when I create it.
B
41
S
19
G
65
Posts: 1,085
Reputation: 37,842

Post » Tue Jun 28, 2016 8:11 pm

OK, ask Ashley if updating the sol every event, and sub event causes issues.
Ask him if he wants to add to add code to check if the sol needs to be updated every event.
Image ImageImage
B
168
S
50
G
163
Posts: 8,220
Reputation: 105,059

Post » Tue Jun 28, 2016 8:35 pm

He doesn't- he already state that.
There could be other ways though. Just because something is difficult to fix, doesn't mean it shouldn't be attempted.
B
41
S
19
G
65
Posts: 1,085
Reputation: 37,842

Post » Tue Jun 28, 2016 11:57 pm

Prominent wrote:And then when checking instance list, cycle through the would-be indices- if they are greater than the instance list length, then check the new object list instead?

This is also extra work that would add a great deal of complexity and degrade the performance of all projects, just for this corner case.
Scirra Founder
B
387
S
230
G
87
Posts: 24,248
Reputation: 192,226

PreviousNext

Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 1 guest