WIP: Lootbot Rush
-
Nice drop shadow!
-
A VIP WIP, Yay! ;-) I am very excited, to see you doing another one, I am still learning a lot from Super Mega Arena Blaster, it started with the title font shadow, title wave animation and I will look at it again, when I need to manage multiple enemies. And now, I already see shadowed 2D sprites, particle gun in action and hear about auto-generated levels. 😂
-
Wow. amazing! random levels really interests me, I bet it's hard as hell to do though.
-
I love that jumping/sliding off the walls. This is cool stuff.
-
New stuff: Air boosting and level transitions! It only supports one level at a time, so I'm basically taking a screenshot of the previous level, creating the next level, and then I can draw them both during the transition.
@SteveZX81 It's pretty basic, I can go through the algorithm quick. This is actually the first time I've ever done any procedural generation, and it's really fun!
Room setup:
- Start with a grid where every square is occupied
- Make an empty list of rooms
- For each of N rooms with initial size W and H:
- Choose a semi-random room_w / room_h for the room based on W and H
- Choose x and y for the room, making sure x + room_w and y + room_h don't go off the edges of the map
- If the chosen rectangle doesn't overlap an existing room, go back to step 4 (ignore if this is the first room)
- Mark the grid squares defined by the room as unoccupied
- Reduce available room W and H by 1 for next room (with some minimum)
Platform setup:
- For each of N flat platforms with initial width W:
- Choose a start/end x location and y location for it such that it fits in the map area
- Check to make sure there are no occupied tiles around each of the endpoints. If there are, go back to step 2
- Mark the grid squares defined by the platform as occupied
- Reduce available platform W by 1 (with some minimum)
After that, an entrance and exit are placed by checking for the leftmost open tile and the rightmost open tile and then clearing tiles until we're off the map. For this game, entrances can only be on the left and exits can only be on the right.
Some more checks happen at this point to make sure there's no solid walls horizontally or vertically through the whole map (although there shouldn't be, theoretically). If there are, the map is discarded and we try again.
There's no pathfinding check for whether or not a level is completable. I wanted to do a simple check, but doing it recursively (like a flood-fill) hits a F4NS recursion limit. I could do it with A* pathfinding but I'm not sure if it's actually needed, so I'll cross that bridge when I come to it. It seems like it's all pretty completable so far because the player has good movement abilities.
Collision between the level and objects is done exclusively with sprites, and I can go over how that works in another post.
-
Incredible work!
@Willpowered said in WIP: Lootbot Rush:
There's no pathfinding check for whether or not a level is completable. I wanted to do a simple check, but doing it recursively (like a flood-fill) hits a F4NS recursion limit.
Yes, I hit the same limit trying to implement a flood-fill in my drawing program. I was able to fix it by avoiding recursion using a simple array of vectors as a stack of places to visit. Turns out you can sometimes hit the limit in my file system program if you copy/paste a folder with really really deep sub-directories.
-
-
@Willpowered nice one! Looks fantastic!
-
Amazing work! I love the look and wow, you're making the rest of us look really shabby.. haha Well done, keep it up!
-
I love everyone's creations! Some of you have done stuff that I wouldn't even know where to start on.
Here's the latest progress:
A life bar has been added! You lose life constantly over time, and if you collect loot it replenishes your life. Keys and locked doors have also been added.
If you take damage while you're holding a key, you lose it and have to re-collect it. There can be up to 3 keys/locked doors per level, and you can hold 3 keys at a time.
Next I'm probably going to look at adding some real enemies to blast! -
This is looking incredible. The character reminds me of Ristar, and (strange thing to pick up on) I really like the way the key follows you
-
So cool and polished looking Will. Congratulations, amazing work! These additions are super xciting
-
-
Very happy to hear that you are continuing this! It looks amazing and very fun!