Esempio n. 1
0
        private void onItemAddedHook(On.Bag.orig_OnItemAddedToBag orig, Bag self, Item _item)
        {
            orig(self, _item);
            var itemToAdd = modifiedStuff.Find(x => x.item.UID == _item.UID);

            if (itemToAdd != null)
            {
                Debug.Log(itemToAdd.item.DisplayName);
                Debug.Log("Notifying Adding Item " + itemToAdd.item.DisplayName);
                Debug.Log("Item to add is not null");
                Debug.Log("Adding modified weapon to inventory and adding to json");
                JDBHelper.AddItemToDB(currentCharSave, itemToAdd);
            }
        }
 public void LoadItemDB()
 {
     JDBHelper.LoadItemDB();
 }
Esempio n. 3
0
 //Used for LoadingDB originally and Setting the Character Save Object
 private void playerSystemStartHook(On.PlayerSystem.orig_StartInit orig, PlayerSystem self)
 {
     orig(self);
     currentCharSave = JDBHelper.LoadItemDBSetCharacter(self.CharUID);
 }