private static void Postfix(uGUI_CraftingMenu __instance, uGUI_CraftNode sender) { ITreeActionReceiver client = uGUI_CraftingMenuReflector.GetClient(__instance); bool interactable = uGUI_CraftingMenuReflector.GetInteractable(__instance); if (client != null && interactable && __instance.ActionAvailable(sender) || Object.op_Equality((Object)sender.get_icon(), (Object)null)) { return; } float num = 1f + Random.Range(-0.2f, 0.2f); sender.get_icon().PunchScale(5f, 0.5f, num, 0.0f); }
private static void Postfix(uGUI_CraftingMenu __instance, uGUI_CraftingMenu.Node sender) { bool client = __instance.client != null; bool interactable = __instance.interactable; if (!client || !interactable || !__instance.ActionAvailable(sender)) { if (sender.icon == null) { return; } float duration = 1f + UnityEngine.Random.Range(-0.2f, 0.2f); sender.icon.PunchScale(5f, 0.5f, duration, 0f); } }
private static void Postfix(uGUI_CraftingMenu __instance, uGUI_CraftNode sender) { var client = __instance.client; var interactable = __instance.interactable; if (client == null || !interactable || !__instance.ActionAvailable(sender)) { if (sender.icon == null) { return; } var duration = 1 + Random.Range(-0.2f, 0.2f); sender.icon.PunchScale(5, 0.5f, duration, 0); } }