Exemplo n.º 1
0
 private void SetNotificationItemHook(GenericNotification.orig_SetItem orig, RoR2.UI.GenericNotification self, ItemDef itemDef)
 {
     //self.descriptionText.token = itemDef.descriptionToken;
     orig(self, itemDef);
     if (itemDef.itemIndex == catalogIndex)
     {
         self.descriptionText.token = dynamicPickupText;
     }
 }
Exemplo n.º 2
0
        private static void SetNotificationItemHook(GenericNotification.orig_SetItem orig,
                                                    RoR2.UI.GenericNotification self,
                                                    ItemDef itemDef)
        {
            orig(self, itemDef);

            if (ItemStatsMod.DetailedPickupDescriptions.Value)
            {
                self.descriptionText.token = itemDef.descriptionToken;
            }
        }
 private void GenericNotification_SetEquipment(GenericNotification.orig_SetEquipment orig, RoR2.UI.GenericNotification self, EquipmentDef equipmentDef)
 {
     orig(self, equipmentDef);
     if (equipmentDef.equipmentIndex == catalogIndex)
     {
         var LocalUserList  = LocalUserManager.readOnlyLocalUsersList;
         var localUser      = LocalUserList[0];
         var inventoryCount = localUser.cachedBody.inventory.GetItemCount(SpiceTally);
         var index          = Mathf.Min(inventoryCount, SpiceDescArray.Length - 1);
         self.descriptionText.token = SpiceDescArray[index];
     }
 }