Today was my first foray into the game development. I have a working prototype of my main game mechanic, the scheduler.
I wanted to create a drag and drop system. I'm allowing 16 hours of time from 9 am to midnight (7 hours of sleeping and 1 hour of day prep) to be customizable. I want tasks that you can do to be unlocked, with maybe around 10 different tasks in the beginning of the game.
Currently, I only have one task wired up. The 16 objects are on a grid, and when the task comes near one of the 16 hours, it will fade to 50% alpha, allowing you to see which hour your task is hovering over. If released, the hour will recognize it and bring the task to itself, and switch itself to invisible. At first I had the object destroyed, and a controller to detect to see if there were 16 hours in the frame, and create a prefab if it wasn't, but it was clunky and you could see it mess up, even if for one frame.
If the task is not inside the schedule, it will destroy itself, and another prefab will be created from it's original spawn point. If another task tries to go over a different task that isn't the default, then the default hour will destroy the other task object and bring in the new task.
It works very well, although the code is horrendous. Eventually I'll need to learn how to actually code, but for now it works. The "spawners" that create a new prefab of tasks when you pick one up to drag need to be organized on a vertical grid, so that they can detect how many will need to be available and sort themselves accordingly. I also wanted to be able to adjust the size of the tasks so that they occupy more than one hour, but I don't have an idea of how that can be possible with my current code, so it will need to be refactored. For now, it's functional, and I want to get it wired up!
As for the actual simulation, I have a simple "Beer Game" simulation working. You have to manage Red Cups, Lemons, and Sugar to sell to customers. Each one takes up varying amounts to make lemonade. One bag of sugar can create 22 cups, one crate of lemons 28. The lemons take up the majority of your space. Customers are random, with more coming on the weekend. Each day creates journal entries for you business, and I have 3 accounts wired up...inventory, cash, and retained earnings. If you purchase orders, it takes two days for it to arrive, so you have to balance all three inventories with limited cash and customers.
I want to implement spoilage, where lemons go bad in 4 days. I currently am not checking to see if we go over inventory space, need to code that in. I want to code in more customers for weekends and much less for weekdays.
I think once I've wired up the schedule system, I'll work on player stats and skills. Have different tasks adjust them. I think I want a task to unlock more recipes and industries. Tasks to network, and marketing. A way to clean out your garage to increase inventory space and storage. Some type of "brand name" system to affect customers. I honestly don't think this will be too difficult. I think the hardest coding was the scheduler, and the next will likely be a framework for detecting which company the player is interested in and having json files being read to see which inventory items are needed to produce and to display it automatically. I currently know nothing about JSON, so this will be a huge opportunity to increase my knowledge. It already looks like a hassle, so we'll see.
But currently working on a functional vertical slice of a lemonade selling game before implementing that! We will see how the week goes.