The Front
Today was a pretty slow day to get started. But once I got rolling it felt like a lot of things were coming together. Each new game that I start is saved in a separate slot. I've somewhat arbitrarily only given you 10,000 to work with. This may eventually change to just be however many your PC can manage. Just keep in mind that the UI I'll be designing might not be the most convenient when you've got far too many games running. Realistically I would think most people will only have one given all the collectibles and progress folks will have access to.
I've also updated the artifact system so that my serialization updates from yesterday...or two days ago...is even more efficient and convenient to use. This is good because a system really needs to be convenient or I'm likely to nuke it. A system that is both convenient AND good is always a nice surprise.
So this means that the next step we need to take is having continue work. Once I can click on any of my prior saves and load into them I'll know that I'm in a pretty good place. Obviously things like loading from Save A to Save D while actively in game might be a little messy. What we may end up doing is unloading the game scene, taking the player to some kind of loading scene, and then have it load up the same way each time.
I'm sure I'll miss something leading to data persisting between them, but if it isn't super bad that'll be fine. Those kind of goofs are fun for speed runs or challenge runs.
The Back
I'm a few days removed from my last work out but it was a real beast!
Stair Calves - Two Sets - Body Weight @ 31 Reps
Barbell Squat - Two Sets - 150 lbs @ 7 Reps
Seated Cable Row - Three Sets - 100 lbs @ 13 Reps
Bench Press - Three Sets - 105lbs @ 6 Reps
Barbell Curl - Two Sets - 55lbs @ 17 and 14 Reps Respectively.
Cable Triceps Pushdown (Rope) - 50lbs @ 11 Reps, and 40lbs @ 7 Reps respectively.
My biggest mistake here was those Cable Triceps, the list of exercises above IS the ideal order but I didn't do it in order. I misread my sheet and did 50 lb pushdowns which, as you might guess, is quite hard! It completely gassed my arms and when I double checked I realized my mistake. But at that point I still had curls and press to go. Talk about a grind. I managed it but only with a lot of grunting and perhaps a bit of praying to the iron gods.
I'm pretty happy overall with my performance and I really enjoy working out. I'll see if I can manage some more Phitness & Philosophy videos this year. If I can plan them properly they might not be the worst amount of effort. Perhaps I should just do more unedited long form videos. Its not like I'm trying to become the next big thing on YT. So the success, or lack thereof, really shouldn't be a limiting factor in what I want to do.
Just a matter of keeping a positive mindset and approaching things in a healthy way. Lets see if I can muster that.
I think going forward on these updates I'm going to split them into two sections. Think of it like a mullet, we'll have business in the front, for anyone that only cares about that, and personal in the back where its just the things going on in my life. If you don't care about one side, don't read it, and if you don't care about either side then you've just saved yourself some time!
The Front
It took a strange amount of heavy thinking but I've managed to update the save system to be a lot cleaner! Now we have the concept of a UtilitySaveData class, utilities are classes that are neither SOs or Monobehaviors and will handle various needs of other classes. This is hardly revolutionary but like all my other naming structures the important thing is having some level of consistency. It is the fact that these are neither MB nor SO that makes them a "utility" class. And that mentality in the future will help me manage what is what easily without a lot of hovering.
These new classes can be utilized as easily as:
var USD = new UtilitySaveData(_keyArtifact.Value, _saveIndexArtifact.Value, _objectToSave);
USD.SaveState();
and
var USD = new UtilitySaveData(_keyArtifact.Value, _saveIndexArtifact.Value, _objectToLoad);
USD.LoadState();
Simply generate a copy of the USD and give it a go! This will read from shared artifacts between the behaviors that are creating these classes and that results in us never losing sync between our savers and loaders. It also means they don't have to be one monolithic class. You might say "Well, Oafkad, why is your Utility a monolithic class?" To that I say, its been a long month.
But also its still a pretty defined operation that doesn't require a lot of different events and communications with the outside world. The same is not true of the behaviors that are saving and loading. Those have a lot of moving parts outside of themselves and I want them to be simple and contained.
Plus I think this utility is darn near feature complete for now. We'll see as I use it!
We've got our savers and loaders setup in the scene for the main menu. So the next time I'm developing I'll need to hook those up to their neighbors. The loading system will be what determines if continue is clickable (and indeed what you see after you click it). The saving will be called by the player submission request, and following that save succeeding we'll transfer into the introduction of the game.
It's been a long and slow road for a month or two here, but I can see some level of progress on the horizon.
The Back
I'm a little bummed that I don't have a lot of mental energy lately. Which itself kind of feeds back into the problem where you are constantly in recovery mode. This does mean that doing work outside of work gets harder and harder. That's especially bad because then I end up feeling more tightly bound to work as that's the source of my income, and thus the few freedoms you can manage as an adult. But the more that happens then the harder it is to shut off from work and the cycle repeats.
I'm hoping that as I get back into fitness this will become less and less of a problem. I can already tell that the muscle soreness from my last routine has given me a bit more pep in my mental step. That might sound weird, I know a lot of people don't like to be sore, but I generally like it when I know why it happened. Soreness tells me that I really gave it my all with whatever I was doing.
And yet I hate headaches, so perhaps not all soreness is equal.
I'm going to probably get back into posting on my YT channel soon. Not because I expect anyone to watch but because that also makes me feel better. We'll have raw videos of gameplay, development, and fitness. Like these front and back posts, if any of it appeals to you, please check it out, but if none of it does that's fine too. The internet is a dark and scary place, and if I'm not able to give you a bit of levity then that's fine. We all gotta find what works for us.
Maybe after tomorrows workout I'll include what I did in the backend of the update for the day.
Welp, you can officially click new game, pick a name, a birthday, and then move into the main game proper. This is great but it does raise a few things that I need to overhaul. The first is our saving and loading system. Currently it is using interfaces in a way that should literally be impossible in C#, how I got it to work I'm uncertain. But it is impossible to breakpoint which is very annoying.
This week we will update the saving and loading such that it is done properly and can be properly breakpointed. This will be very helpful and part of this will be creating checks for whether or not the loading data exists. You might be saying "Uh...how do you load at the moment if you don't know the state of the save data?" Well I DO know, but it is loaded immediately after checking.
This was perfectly fine for a few months of development but now I need to make it more robust. We will check if save data exists on open, if it does then turn on the continue button. From there you can select one of the save data that currently exists. And ah hah! That's another thing we need to validate, saving to different index values. Currently it only does a rolling save, so it'll save to spot 1, then 2, then 3, and roll around after it hits the limit.
But I want you to be able to pick a slot and always save to that slot until you pick a new one. Perhaps with "-1" being our autosave slot. We'll see.
Overall though, making some core progress. I'll also talk about how I solved the "state to state" communications in an upcoming post. It isn't super clever but it was a refreshing moment when I saw it work on the first try.
So I'm realizing today that I need to make the primary state machine of our system a system that exists outside of the primary scenes. It hit me like a ton of bricks when I was clicking on one of my main menu buttons and...nothing was happening. Well shoot, I thought, that's definitely unexpected! I've been using this system for years, how could it be failing now?
Well, when a tree falls in the wood and nobody has registered a listener, does it raise an event? The answer, at least in my system, is no. This isn't an insurmountable problem. What I can do tomorrow is create a class that I add to my fresh scenes, this will check to see if we've instantiated the state machine yet (and placed it in the do not destroy scene). Once this has happened we'll have our system setup and ready to rock for all other places.
This is a bit different from a singleton in that we won't actually have any static references to it. This is simply a system that exists in the ether and communicates back and forth with the rest of our game world through events and our scriptable objects. This is an exciting moment for me because it gives me a very direct thing to solve and given how fatigued I've been lately that'll be a welcome adventure! Once that is done we'll move onto the next game action I need which is spawning the player at a particular location and rotation. We'll need this for the introduction sequence.
While today was slow goings, I can happily say that I've started doing work again. The last few weeks of my life were extremely hectic with occasional workdays literally going from 8 in the morning until midnight. My brain and body were both drained, by the end of it I was just completely exhausted. I knew if I tried to work on the project at the same time that I'd not get anything even close to quality as a result.
So I took some time off, focused on getting work caught up and out of my way. With today being my first return back. Unfortunately coming off of going to bed at 1AM did not help for the return. But I've had a few days off from work and I'm feeling a lot better. Currently working through the slow process of improving our UI flow for new games. A few of the classes I made before I left weren't quite up to my ever progressing standards.
They've been tweaked a smidge and now I'll get even more utility out of them. Also I'm hoping to start posting videos of some kind more often going forward. I know this will remain my own little slice of the world off in the middle of nowhere but might as well deck it out with nice things.
If nothing else it gives me interesting logs to look back on in ten to twenty years. Hopefully I will be more positively surprised by them than I was when I saw my teenage ramblings as a twenty something. Some of it was genuinely interesting but also some of it was pretty wacky. Our own many evolutions over time are very interesting to me. So many different people in a single body. But not like that, unless you are into that, I am not one to judge.