Problem when Objects are not in the frame
User clicks
+Mouse pointer is not overlapping Object1
+Mouse pointer is not overlapping Object2
+Mouse pointer is not overlapping Object3
----> do something
doesn't work if all objects of type 1,2 and/or 3 are destroyed. Is this a bug? It's annoying to make several additional events to work around. After all, an object that doesn't exist can't be overlapped ;)
Re: Problem when Objects are not in the frame
Make sure you have the latest official patch, as this has been fixed.
Re: Problem when Objects are not in the frame
Re: Problem when Objects are not in the frame
I haven't tested this, but there may a workaround. How about assigning value to someplace when all objects of type one are destroyed, same for object 2 and 3. Say, you add 1 for counter 1, when object 1 is destroyed, 1 to counter 2 when all object 2 are destroyed, et etc.
Then you go:
User clicks
+counter 1=1
+counter 2=1
+counter 3=1
----> do something
Re: Problem when Objects are not in the frame
That's right, there are ways to workaround. But that also means more complicated, less efficient code.
Re: Problem when Objects are not in the frame
The workaround I saw was to keep an instance of each of the objects off-screen.
Re: Problem when Objects are not in the frame
You're really sure you're using the latest version? :)
I tested the events you wrote above and it works perfectly. This used to be a bug in previous versions.
Re: Problem when Objects are not in the frame
Quote:
Originally Posted by Popcorn
I tested the events you wrote above and it works perfectly.
Strange, you are right, these events really work:
User clicks
+Mouse pointer is not overlapping Object1
+Mouse pointer is not overlapping Object2
+Mouse pointer is not overlapping Object3
----> do something
BUT...
...I wrote this example, because it was the most simple way to describe the problem. In my case the mouse pointer is hidden and an Active Object is set to Xmouse/Ymouse. And I don't test the mouse pointer itself, only the "Active (Mouse)". Since this detail makes an important difference, here's the original code which definitely doesn't work:
User clicks
+Active (Mouse) is not overlapping Object1
+Active (Mouse) is not overlapping Object2
+Active (Mouse) is not overlapping Object3
----> do something
As a workaround, I put the Objects 1-3 in a group. I have a dummy object which is member of all groups. While this object exists outside of the visible area, this event works:
User clicks
+Active (Mouse) is not overlapping Group1
----> do something
Of course, this may cause confusion. You have to keep this problem in mind whenever checking for the number of group members. And you must not simply destroy group members leaving the screen, because you have to keep the dummy alive...it's really a source for self-made bugs which can be hard to track. Especially if you don't remember these details when making changes after some time has passed.
Re: Problem when Objects are not in the frame
The "Select Object" helps with keeping dummy members of qualifiers alive:
Qualifier is outside play area
+Select: Deselect First 1 "Dummy"
-Destroy Qualifier
Re: Problem when Objects are not in the frame
Cool option! But I don't like workarounds caused by workarounds, featuring 3rd party extensions which aren't part of an official Bonus Pack, at least ;)
Just encountered a similar problem, where AOs should be paralyzed while covered by some kind of stasis field, which forces me again to care about an unnecessary stasis object out of view.
I face this kind of problem frequently, while doing only some basic stuff, so I'm wondering if this may be fixed in the future?