Handled dynamic adding and removing of inventory items and syncing with menu systems.
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
#include "Crawler.h"
|
||||
#include "DEFINES.h"
|
||||
#include "Menu.h"
|
||||
#include "Item.h"
|
||||
|
||||
INCLUDE_MONSTER_LIST
|
||||
|
||||
@@ -13,6 +14,21 @@ void State_GameRun::OnUserUpdate(Crawler*game){
|
||||
if(game->encounterStarted&&game->totalBossEncounterMobs>0){
|
||||
game->encounterDuration+=game->GetElapsedTime();
|
||||
}
|
||||
|
||||
|
||||
if(game->GetKey(O).bPressed){
|
||||
Inventory::AddItem("Dummy Item 14",192);
|
||||
Inventory::AddItem("Dummy Item 15",35);
|
||||
Inventory::AddItem("Dummy Item 16",6);
|
||||
Inventory::AddItem("Dummy Item 17",3);
|
||||
Inventory::AddItem("Dummy Item 18",1);
|
||||
Inventory::AddItem("Dummy Item 19",8);
|
||||
Inventory::AddItem("Dummy Item 20",4);
|
||||
}
|
||||
if(game->GetKey(P).bPressed){
|
||||
Inventory::AddItem("Medium Mana Potion",1);
|
||||
}
|
||||
|
||||
game->HandleUserInput(game->GetElapsedTime());
|
||||
|
||||
if(game->GetKey(T).bPressed){
|
||||
|
||||
Reference in New Issue
Block a user