IMPORTANT: Press ‘Edit Code’ before playing because ANY subsequent time you load the game up after the first time, entering portals crash the game.
With that out of the way, here’s the link to my game!
Controls are explained in-game, so read signs carefully! You have all the abilites from the start, but entering portals helps you learn how to use the abilities, as well as giving you health.
Here's a devlog about how I made the merge ability.
While coding this game, it took a very long time to implement the “merge” mechanic (kind of taken from Ultrahand in ToTK) and another many hours after that to figure out how to detach objects in a way that made sense. At first, I wanted “real” physics where objects could rotate freely, and also with no overlaps. I quickly figured out this was not feasible in Arcade due to lack of documentation and performance. When I first started, I had many ideas like sorting objects into “pairs” that were connected to each other, but this would quickly get messy and unmanagable. After trying sereral ideas including stupid ones like in a frame moving all sprites overlapping each other the same amount (which would be incredibly difficult and flawed because objects would “pick up” other objects along the way when they moved), I figured that a neatly-sorted array of objects with each object storing data that they are a certain number of pixels relative to another “main object” would work. Eventually, I made it so that objects sorted themselves neatly into arrays of arrays and “un-sorted” themselves easily as well. I figured out pretty quickly how to sync up the movement of objects connected (thanks to order of events in sprite utils), but figuring out how to sort merged objects into neat arrays was a lot more difficult. For a good portion of development, I didn’t have what I call “shifting” implemented, so in order to pick up a set of objects, you HAD to click on the last-connected object to a group (the “main object”). Also, collision was weird because only one object “officially” had collision. For a while, the merge ability couldn’t be canceled and you had to select an object and put it down again. At one point in development, gravity was universal to the last moved set of objects, so all sets of objects fell at that rate. Around this time, I also made it so that all connected objects had collision. When I finally did implement proper gravity, I also had to write a lot of code to prevent “clipping,” where if an object moves more than 4 pixels in a frame it can clip into walls. Also (as somewhat mentioned earlier), breaking objects apart was one of the last things implemented, almost as complicated as putting them together. Finally, I made it so that rotating objects could only be done when they were not connected to other objects. I now have a pretty flexible physics engine with the ability to fairly easily add new objects. The other mechanics were fairly easy, not much that I hadn’t done before.
If you’re ever low on health and don’t want to try killing enemies, just sleep in the bed at your house!