Asset - Extension Instance Flags - bit flag based instance filtering

YellowAfterlife

ᴏɴʟɪɴᴇ ᴍᴜʟᴛɪᴘʟᴀʏᴇʀ
Forum Staff
Moderator
upload_2019-4-9_12-17-56.png

Quick links:
Documentation · itch.io page (has the demo project!) · GM Marketplace page · Source code
Versions: GameMaker: Studio (1.4.1804+ only), GameMaker Studio 2
Platforms: All of them
Price: Free
page1-demo.png page2-docs.png

Historically GameMaker instances only had a single flag ("soild"), which was mutually exclusive with filtering instances by their type/parent, but, with introduction of collision list functions, we can do better, allowing to filter by type AND an arbitrary set of flags.

So, for instance, you can check whether your character is standing on a slippery solid block, or whether that block is jump-through, or find the nearest airborne target in a tower defense game, or many other uses.

See the demo project for an example!

GMS1 notes: When importing the extension alone, subsequently import the "collision_list_funcs" extension from its included files.

GMS2 notes: If using the demo, remove the "collision_list_funcs" extension after importing the project - it is only used to workaround an issue with GMS1.
 
Last edited:
I

immortalx

Guest
I just had a play with the demo and it's fantastic! The way the demo is set-up, is like the equivalent of tile-collisions but with instances.
Now that we are able to set the starting frame of an instance in the room, I just had this idea: A single object with subimages for the arrows and solid block, set with image_speed = 0. Then a check in the create event which will determine the flags according to the image_index of the instance.
Thanks for another fantastic extension YAL!
 

YellowAfterlife

ᴏɴʟɪɴᴇ ᴍᴜʟᴛɪᴘʟᴀʏᴇʀ
Forum Staff
Moderator
Great idea! Thanks for releasing it for free.

Marketplace link not working...yet?
Fixed - this is a valid link,
Code:
https://marketplace.yoyogames.com/assets/8113/_
but this isn't:
Code:
https://marketplace.yoyogames.com/assets/8113/
I just had a play with the demo and it's fantastic! The way the demo is set-up, is like the equivalent of tile-collisions but with instances.
Now that we are able to set the starting frame of an instance in the room, I just had this idea: A single object with subimages for the arrows and solid block, set with image_speed = 0. Then a check in the create event which will determine the flags according to the image_index of the instance.
Thanks for another fantastic extension YAL!
Thank you! I hope that people will find many good uses for it.
 
Top