[SOLVED NOT A BUG] (inverted) Cursor/Touch is object from a group

This is something that took me awhile to understand. Unfortunately, the documentation is lacking.

Instead of inverting cursor is on put it inside a NOT condition. It sounds the same but it’s not.

Gdevelop doesn’t work in a strict true or false with instances instead it picks the matching objects and triggers the action if the instances are greater than 0 .

So, inverted cursor is on with 4 instances will always return something unless as you said, you stack them and none of the objectsdon’t have the cursor over them.

When you invert a condition, you’re inverting the condition but when you use a NOT you invert the result.

If the cursor is over 1 of 4 instances

cursor is on triggers & picks 1 object

Inverted cursor is on triggers & picks 3 objects

[NOT] cursor is on it would pick 1 and trigger but the not inverts it so it doesn’t trigger

If the cursor is not on any object
[NOT] cursor is on wouldn’t pick anything bc there’s nothing to pick. It would normally not trigger the action but the [NOT] inverts the result and triggers the conditions but without anything picked.

I hope I made some sense.

5 Likes