Caves and The Underground
Set up a Teleporter in the Underground to take you to the Caves. This will eventually be changed to only take you to specific floors, and to other places??
1906
Added some particles to make it look a bit more magical
1908
Some more particles, in the centre to give a bit of depth
1909
Tried to add some green to the particles but I messed up the # to $ conversion XD
Kinda like the purple though
1910
The green ended up not being very noticeable, I think sticking to my palette might be a mistake with particles.
1911
For some reason when I used pixel particles they came out all blurry, so I tried using a sprite of a single pixel and that gave me nice crisp ones of the actual shape. Not sure it's best for this though?
1912
Realised I could use part of my Teleporter animation as a second particle, makes it a bit more dynamic!
1913
Added some glowing circle particles to add to my sprite animation
1914
Made them shrink and grow depending on the phase of the Teleporting.
1915
Added a menu to the Teleporter so I can do testing of different location options, and added a second tileset to make it obvious.
1916
Started work on a Cave tileset and the Autotiler for it. I wish I could have used the Autotiler for my Buildable Walls, or the one for Roofing/Soil/Snow etc, but they aren't compatible because of the need to draw an extra top bit. It also seemed what I'd set up for the Underground walls wasn't sufficient for the Cave ones, so I had to start from scratch and add more options.
1917
1918
Matched the Room background colour to the Wall voids, to save on excessive tiles.
1919
Started on a new tileset for the Underground, not really happy with the brick walls so I think I'll start again, but it has the all the shape options that the Caves have so they can use the same Autotiler.
Also figured out how to add Wall Mining with the tile system, and even added a nice cloud particle when you do it!
1920
Made them mineable with Ka-bombs too, only specific walls can be mined, but I gave a chance of the newly exposed walls to be mineable too!
1921
Found some issues with this system though, it was possible to make Walls you can't reach be mineable which is obviously not fun!
1922
I fixed that issue, but I still wasn't entirely happy with it, I think a new system is in order.
1923
New system work out! On room generation I look for a random wall that's next to open space, then snake out from it turning Walls into Ore Walls! This is much better! I can control how long they are too!
1924
Added some more overlay tiles to show that the walls contain things, had some issues with depth. Fortunately I'd worked this out when doing the wall tiles originally. Seems you can actually place multiple tiles on the same depth which I wasn't sure should be possible.
1925
Increased the amount that spawn, picked random starting walls and reduced the vein length.
1926
I thought I could use my existing Rock Spawn code from the Island for Caves but..urm there was issues. So a rewrite was needed. Both locations use the same code :D
1927
Fixed the Lighting System, it wasn't being set to the correct value when going between floors, causing it to slowly fade to the correct value. Also added a light flash to Ka-bombs, really like how it shrinks but I'm not sure it's realistic X'D.
1928
Realised Explosions weren't actually hitting as many tiles as they should have been (off by 1 error) so a minor rework of that was in order. Need to adjust the light flash to match the explosion size too.
1929
Added the Pathfinding Collision Grid for the Caves and Underground so the Creatures I eventually add wont walk through walls. Have to go though all my code now and add in a room check to make sure it's using the correct collision grid, had a few occations where I'd drop my Axe in the Caves and it'd go SPLOOSH because I was at the coordinates of Island Water.
Odd bug at the end where Bombs chain destroyed a wall?? Maybe the "for loops" are going the wrong way?
1930
Reworked the Ore Vein system and Tile data to be able to handle multiple Ore types. Unfortunately I had to add a whole other tileset for the different Ores, so I'm going to need one for each unless I figure out how to use the palette shifter on things at different depths (each tile on a different Y coord is depthed different).
Tested out a system to cause walls to chain react, it works but the way it happens instantaneous doesn't feel quite right.
1931
Started testing out a way of having traps and stuff underground. Turns out my Build System is totally viable for use underground, I can even pre-connect Buttons to things. It does need a rewrite to stop things happening repeatedly though, Doors shouldn't flap like that just because you're standing on the Button.
1933
1934
Added Spiked Gates! And reworked the Button Menu. You can now set things to only be triggered a certain number of times, so I can have one way traps...
1935
Got VERY basic Underground Ruin rooms set up.
I can have different designs and assign buttons randomly to Devices like Spiked Gates and have random loot in Chests!
I should be able to make puzzles by connecting a Device to more than one Button and more than once.
Thinking like pressing a button makes some gates go up and others down, so you need to press them in the correct order.
1936
Showing off the RNG
1937
1938
Reworked explosive walls. Instead of just doing checks for walls that can explode nearby they drop an invisible bomb. So now they chain with a delay, much more satisfying!
1941
Added Mushrooms and Grass to the Cave Gen. Mushroom Soup incoming!!
1942
Added Ceramic Pots. I think these will work nicely in the Underground, rather than the Caves.
Planning on having small items drop from these.
1943
Added Barrels for the Caves, think I'll redraw them a bit though. They look a bit too bright for being underground, and the lid looks more like a hole because of the vertical lines on it.
Also added a Item object for Gobloons, so now you can get Currency as a loot drop!
1944
Realised Items could get stuck in Walls, so added some unstick code to them, but it doesn't work with thrown Items, will have to add the check to the throw system.
1945
Out of the Caves for a moment, started updating the Water-based systems to instead of requiring a Shoreline Object, they would check the correct room's grid data for Water.
But found that at somepoint I completely broke how Rafts are shown :/
1946
Didn't take long to fix, and I even added a little bit of code to draw the underwater part as transparent so it looks better than ever!
1947
Finished swapping the Water stuff over to the Grid System, now the grid check flips when you go Rafting making it so you can't walk into water or Raft on land. This was a long overdue update. (you've been able to Raft on land for probably 2 months at this point X'D)
1949
Updated Fishing to use the same Grid System, now you'll be able to fish underground if you can find water! Watering Cans and Empty Bottles are also updated to use the same system.
1950
Back to underground stuff!
Reworked Cave Generation. Here's a gif of the smallest cave size, they get bigger the deeper you go.
Unless there's a special reason, every floor will have an [Up Stairs] to return to the surface and a [Down Stairs] to go deeper.
1951
Added a path check to make sure you can always get from the entrance of a cave to the exit! If not, move the exit somewhere else!
Important to do this BEFORE adding rocks, since they'd block the path.
But SIGH. The path check code worked, It keps trying till it was able to path the entrance to the exit, but urgh big inaccessible room!
Wait, this room shape shouldn't be possible, since it starts the floor gen from the same xy each loop.
1952
Huh, where's the exit? Where's the entrance?!
BUT HOW!?!? Something is going wrong with the Room Gen. I think it's stepping too far each loop? It should always place floor tiles when it moves, never allowing for sealed off areas.
1953
Fixed it, but I'm not sure if it's the best solution. The Floor Gen now always moves 1 tiles each time, but it chooses to create either 1x1 or 2x2 tiles, it also randomly picks to fill in all of those 2x2 or not, which gives less straight lines in cave shafts. I'm probably not going to add curves to caves so that'll have to do (anything other than full squares will be a pain for collisions).
Also added to the Cave Gen, a minimum distance check between entrance and exit, and a room gen retry if a condition fails too many times. Not sure if it's best to have lots of attempts then try a new room, or just a few attempts then try a new room. Will need a bunch of testing to figure out which is quicker.
1954
And that's pretty much it for the month, got a bunch of miscellaneous lesser fixes and changes below.
Bug Fixes and small Changes
-General Code clean up
-Fixed a delay between Ka-bombs exploding/Tools colliding and walls being destroyed. Forgot to set the attack animation to the final frame so it's instant.
-Changed that again, setting the attack animations to the first frame broke Tools
-Fixed Merchant UI so the Selector Box ends up in the correct place.
-Fixed Merchant UI so it displays the correct Item description text.
-Fixed Merchant UI so Selector Box stays on the correct line when on another page.
-Fixed Player not facing Merchant when Interacting.
-Fixed Player facing the wrong way when using Stairs to go up from Caves.
-Fixed Trees being able to be planted over(under) Grass.
-Changed tile grid checks to be map dependant so it no longer checks the Island's grid when you're underground. No more water slashes in solid underground!
-Changed how Fishing gets the Fish type, no longer needing to keep the whole array in memory the entire time.
-Changed Planting Trees code from being nested inside the Tool Order code, this was left over from ages back.
-Changed Cave Up Stairs to take you to the Underground instead of to the previous floor (avoiding cheesy grinding)
-Changed Teleporters to only spawn if you entered the room by one or if the Cave Floor is divisible by 10.
-Changed activation of Stairs that don't lead to or from the Surface. Using stairs in Caves requires a button press, will add a prompt to confirm you want to leave the current floor.
-Moved Teleporter particle clean up to the Surface Object that contains the Particle System to ensure particles are correctly destroyed on room end.
-Moved code for drawing interaction elements (fishing/mining etc) to the surface objects draw code so it's always draw on top of everything.
-Removed access to the Build Menu when not on the Surface.
-Stopped the ability to use Terraforming and Weather Potions when not on the Surface.
-Added an override to make the first Cave floor be smaller and have less content than other floors to avoid cheesy grinding.
-Added option to make Doors lockable, currently only openable by Button press.
-Added HUD data to show current Cave Floor.
Thank you all so very much for your constant support, it truly means the world to me, and I honestly couldn't do it without you.
I hope you all have a fantastic April, please stay safe and look after yourselves out there!
7 comments