I'm curious, does it also apply to C2 tilemaps? We still have on-going projects developed on C2
I already know how to pin by using events, IID, loops, etc; my question was specifically about selecting an UID directly in the behavior script, but if that's not possible, then nevermind
Does anyone know if something like this would work for the Pin behavior?
We're looking for a way to automatically pin an instance to an UID when the instance is created in layout without requiring events by using a behavior property, a sort of equivalent of the child/parent tree system from C3, we thought it would be useful for menus and interfaces
Thanks in advance
Frames 1-4* as I used loopindex+1, but yes this one is made with the idea that there's as much frames that there's instances;
For a pool based on the total number of frames (still excluding frame 0), this does the job :
To be fair instance picking can be tricky in C2 and C3 so it's worth the head-scratching;
Btw I over-complicated it, you don't need a function or an array to achieve the shuffle, try this :
You can also try the self-calling function method, where you set up a function that will go through a random instance that hasn't been randomized, set its frame and move to the next instance
Example capx :
drive.google.com/file/d/1bS84qMrTWlIFO0Tqq3V5YLDGuLTvPWtS/view
Your welcome!
Alright I made an example capx, feel free to change the distance/speed values to fit your needs, but that should solve your problem (works with multiple enemies instances) :
drive.google.com/file/d/1F5L75Z0UjxcNAGX2NukdTzTFaiYE7p7O/view
No i mean, was it meant to activate a random enemy if many enemies are on screen?
Also, what's the Line of Sight distance you used?
And what about the "Pick at random" condition? What's the effect you're trying to achieve with it?
Also what's the Line of Sight reach?
So the enemy stays still, enters a short ALERT phase when detecting the player, then start moving toward them; Once close enough, if the player is not attacking already, the enemy will attack, did I get everything right?
Develop games in your browser. Powerful, performant & highly capable.
I see many issues in your events logic, can you describe me how your enemies are supposed to behave exactly? I'll make an example capx, that will be easier than writing an essay;
If possible link me your capx file, that'll be faster to edit
Member since 3 Apr, 2016