So I figured out a bug that I kinda thought it existed but wasn't sure ... well yeah ... now I have narrowed it down and found it.
If you revive a hero when the hero is alive it will remove the heros items and basically reset the inventory to default.
Yeah interesting hey? Kind of like hiding the UI while hiding the UI causes the credit screen to pop up.
So I kinda knew items were disappearing in Tofu ... like I was sure I had items and then sometimes they would disappear. When I wrote in the rounds I was being lazy because I figured reviving an already alive hero wouldn't cause any problems, like instead of putting a check in I just wrote it ... well ... thats what I get.
Actually I am a dumbass ... turns out that it was an extra function I wrote that was removing all non hero units from the game to reset the round, things like mines, or left over summons etc ... which also removes items from inside the inventory ... so, after futher testing involving manually reviving heroes I actually discovered it was not as I first thought, and I then thought maybe it was pausing an already paused unit ... then after manually testing that I saw my function Remove Non-Hero Units() and disabled it, sure enough, the inventory stays ...
No comments plox. It was bound to happen one day.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
So I figured out a bug that I kinda thought it existed but wasn't sure ... well yeah ... now I have narrowed it down and found it.If you revive a hero when the hero is alive it will remove the heros items and basically reset the inventory to default.Yeah interesting hey? Kind of like hiding the UI while hiding the UI causes the credit screen to pop up.So I kinda knew items were disappearing in Tofu ... like I was sure I had items and then sometimes they would disappear. When I wrote in the rounds I was being lazy because I figured reviving an already alive hero wouldn't cause any problems, like instead of putting a check in I just wrote it ... well ... thats what I get.Nice find. Guess you gotta put that extra condition.
This is not a commentActually I am a dumbass ... turns out that it was an extra function I wrote that was removing all non hero units from the game to reset the round, things like mines, or left over summons etc ... which also removes items from inside the inventory ... so, after futher testing involving manually reviving heroes I actually discovered it was not as I first thought, and I then thought maybe it was pausing an already paused unit ... then after manually testing that I saw my function Remove Non-Hero Units() and disabled it, sure enough, the inventory stays ...
No comments plox. It was bound to happen one day.