Devlog - Inventory UI - Douglas Strange
I have been having difficulties with my inventory UI. What I thought was going to be maybe a week project has taken almost two extra days’ worth of time. I did not foresee running into the issue of my blank item slots being listed as full, null being valid data for a sprite, slots sometimes not persisting in the manager, and other minor issues due to reminding or learning C#’s eccentricities.
The way I managed to locate the problem is quite simple. Instead of trying to fix all the problems at once I diagnosed the three problems: the inventory, the inventory manager, and the item slots and broke them down into what they should be doing for my purpose. So far, the largest of problems occurred when the manager attempts to add an item to a slot. Repeatedly I was given errors that empty slots could not be found or the data passed was invalid. This had a lot to do with two different persons working on the inventory. Our gameplay programmer set up the internals so they could test their pickups, and I adopted it before realizing that the data they used was incomplete compared to what I needed; which meant I had to completely rethink how I wanted to create the inventory UI for display purposes.
To solve my problems, I have decided on the simple solution of breaking down the programming methods into blocks to figure out how the logic failed. I believe that part of the problem was checking all the slots in my item slots array. For the fix I check all the slots regardless and in doing so found my empty slots when cleaning up the editor. As it turns out the slots had not been inserted into the inventory manager on the editor side. Once doing so the array became properly populated and my inventory manager performed its designated task as intended.
Assuming all goes well the inventory UI should be completed by the end of my work session tonight. Right now I just have to fix an error where the sprites are not updating and then I need to adjust the code to work with the inventory rather than as a separate component.
Get Noble Roots
Noble Roots
Status | In development |
Authors | PentaCogStudios, Tyrano, shawn0173, ADiscount4U, TarrellC246 |
Genre | Simulation |
Tags | Fantasy, Farming |
More posts
- Devlog - Hot Bar/Inventory UI - Douglas Strange2 days ago
- Devlog - Inventory UI/Display10 days ago
- Devlog - Inventory UI/Particle System - Douglas Strange14 days ago
- Devlog - Inventory - Douglas Strange21 days ago
- Devlog - 10/24/24 - Transition Script28 days ago
- Devlog - Douglas Strange -10/24/2428 days ago
- DevLog - Tarrell Charles - 10/24/2024 - Combination input cheat code / Input sys...28 days ago
- Devlog - Tyler Linton -10/24/2428 days ago
- Devlog - Shawn Newlin - 10/24/24 - Tool Selection UI28 days ago
Leave a comment
Log in with itch.io to leave a comment.