was the box duplication on the spiral level, the one with two boxes stuck on the right or one of the last 3?
i know the spiral one can kill the player if you enter and the one with two boxes on the right can duplicate but i havent experienced any bugs in the last 3, thanks
Viewing post in Parcel Puzzler jam comments
i store the level as a hashmap where the key is the coordinate and the value is a struct containing the top and bottom tile
the conveyor logic goes like this:
for each conveyor in the map, check if its possible for it to move, and whether you would need to push an object (like if theres a box after the conveyor and theres empty space after the box, so the box will get pushed by whats on the conveyor)
i store this as an array of moves, then for each move i perform it, by setting the object in the end coordinate to the one that was in the start coordinate, then removing the object from the start coordinate only if theres no moves in the array which point to the start coordinate, or if an object needs to be pushed i call the move() function i have which i use for moving the player
its most likely an issue with the pushing mechanic, now i feel stupid for making the objects part of the map instead of in an array, since i iterate over that entire hashmap many times per frame/move, if i maintain this game i will remake this system but i only had ~3.5 days to make the game since i started late
TLDR;
im a complete idiot and i used a hashmap to store all the objects on the map lol