Highly reusable C++ inventory system
- highly optimised (each slot updates individually when changed)
- interchangeable with different UI
- full C++ backend
- customisable slot number and rows
Picking up is handeled by the C++ inventory which fires an event for if a UI slot that needs updating. Dropping needs to be called by the player, in this case it is handled by clicking on the UI slot.
The layout of the inventory widget constructs itself at runtime to the maximum inventory size with a customisable number of coloumns.
The C++ backend is fully seperate from the frontend and provides useful events for anyone who wants to link it to a new UI.
Both the entire inventory component and items are made up of entirely C++