Thought I had everything set up so I could just easily add new Building Types..nah so many fiddly bits needed changing. So I redid it all!
Re-coded anything that was hard coded to look for building ID's to be much more robust, should be much easier now to add new Buildings.
2114
Instead of having to go through all the code and add the new building ID to the if statement, I've added a script isBuilding, when I add a new Building Type I just need to add the typeID to that and all the checks will get updated!
Also added scr_GetBuildingSize, which will grab the size of the array used for that building type and use it for the default size values, so as long as there's a default shape all the code will have the correct values!
Also;
Added new Building, the Dormitory!
A place for Goblins without a House to sleep. Has no other benefits though.
This might be too many beds for default though? You can expand the Dorm to add more Beds.
2135
Gave Dormitories their own Furniture list separate from Houses.
I've also changed it so the Destroy Furniture (mislabelled as Destroy Structure here) uses the new buildingPart variable instead of being hardcoded to check for specific things like Bed/Stone Ovens/Building Plaques etc.
2157
Wanted to update the SaveFile to store Goblins sleeping in beds, but realised that Savefiles weren't storing Goblins sitting on Stools anymore. So! Reworked that!
2115
I asked what kind of Decorations people would like, one request was more plant options so I added smaller Benches, and made it so you can add Plant Pot type Objects to them.
Because the sizes don't match you can't place them on the old Benches, so I might rework it so Benches have slots? Depends how much work it will be to adjust the collision checks.
I wonder if I should make Tables into Benches?
2116
Added them to Houses, along with some new Wall Decorations; Wreaths, made from various plants.
Wasn't really happy with the Glass Jar I drew for Bench Plants, so I used the Pot sprite from the Underground.
2117
Reworked how the Save System gets Building Types/SubTypes so Bench Plant Pots are Saved.
Also added added Fishtanks to the Save System.
2119
Started reworking the Fishtank Menu, since I have a System in place to add items from your Inventory I've connected that so you no longer add them by interacting with the Fishtank while holding the fish as your current item.
2120
While I was at it, also added the Inventory interface to Fishing so you can add Bait to your line.
2121
The heck!? How that Cactus get in there???
2122
Urgh...what? How the heck did I break Fish!???
2123
Fixed it, started working on improving the UI, decided to make it like the rest of the UI instead of just having the Fishtank floating in the middle of the screen...but somehow broke Fish again...
Turns out it was how I reworked the Saving Fishtanks. I forgot that you can't have static values for things if you're going to add new assets. So I've set them up a lookup array like I have for Recipes.
2124
That's better! New UI and menu options working!
2125
Now that's done, back to Fishing. Updated the UI!
2131
Added the ability to change the Angle of your throw, limited it's range so you can only launch the line infront of you, also removed the automatic Power.
2132
Increased the speed at which you change the Angle/Power, and added a basic UI.
2133
Better Power/Angle UI. I wasn't going to include it but my brain didn't like how pushing the up key increases power even when facing downwards, hopefully this will help.
2153
Seems I need to rework how Items are thrown. They don't always land where they should because the bounce amount is calculated as they're moving.
2136
This is better for Fishing, but it breaks the Player Throwing held Items.
2137
Did a full rework of Throwing, the number of bounces is now fully reliant on the distance the Item will move, previously there was a max of 3 bounces and I was using the Throw distance to reduce that by 1 based on an arbitrary value.
They're landing in the right place, and it works with Throwing too, but diagonal Fishing seems to move way too fast? Gonna tweak the speed values a bit!
2138
It broke how Items fell out of Trees too, so I've reworked that. Might still be a bit fast, but they look right again.
2139
Well, at least I got this done today!
Lots of screwing about with maths, but now I have the Fishing Lure flying through the air when you cast it!
Additional things I could do;
-Sync up the Lure bobbing with the players rod movement.
-Sync up the Lure's animation so it initially sinks when it hits the water.
-Add a splash animation as it hits the water.
2156
Decided I should update the NPC Emote system so it can be used with the Player. It's nice to have things standardised but also this should let me do better cutscenes!
2126
Further updated the Emote system so I can chain Emotes together, replacing the variable as a single emote to be an array.
2127
Seems to be working well! Need to change the condition that draws the arms though...getting double arms.
2128
It had to be done, I've had this dang song stuck in my head since it aired.
2129
Oh no it's spreading!
2130
In honour of hitting 666 followers on Threads I decided to add Lightning to the Weather Systems.
2141
Might have went overboard with the triggering...
2142
Still too frequent, but I've made them extend all the way to the cloud...now thinking I should lower those?
2143
Less frequent and better blending.
2144
Trying better lightning effect, works during the day too but doesn't really look as good.
2145
Added some ball lightning to the ends. Couldn't find my old code for it but turned out I could just use the same code I was for the main lightning.
2146
Decided to change nighttime to be less black and more blue, I think it looks better?
2149
2150
Made Storm Clouds darker, split cloud and rain particles into separate systems so I could layer them correctly, also reduce cloud height.
I'm toying with the idea of Lightning spawning a fish item if it hits water, but that could be overpowered, also items over water are destroyed if not near the player...
2155
Bug Fixes and small Changes
-Fixed buffer size around the Control Orb stopping you resizing a Building back to its original size.
-Fixed Resizing Cafe Walls into Stools.
-Fixed Resizing Cafe Walls that destroy Stools removing them from the AI Grid.
-Fixed Cafe Door count error causing gap in wall when resizing.
-Fixed drawing offsets in Build Menu/Placing Menu.
-Fixed a mistake when destroying Farms/Orchards, I didn't include the for loop X'D
-Fixed the loading of Shelf Tops not returning the correct object ID and not loading the rest of the data for the Top.
-Fixed infinite loop with NPC Reactions?
-Fixed NPC's constantly triggering buttons on step.
-Fixed a bug where game would crash if cycling Build options when build position was over a Seat.
-Remove some variables from all Building Objects that make the Interaction indicator work, weren't needed. Instead there's just the one in the the Surface object.
-Cleaned up interaction with Building Code.
-Fixed pathfinding for the Goblin Parade, they no longer get stuck if there's something in the way of the path's corner points!
-Fixed graphical font issue.
Probably a bunch of other small things I've forgotten. I really need to get back to writing this as I go instead of leaving it till the end of the month T_T
Thank you all so much for your support, you are all so incredibly kind and it really helps me out as well as meaning the world to me.
I hope you all have an amazing month!
Please look after yourselves and keep being awesome!
10 comments