Esempio n. 1
0
        static void Awake(ref ItemDrop __instance)
        {
            var prefabName = __instance.GetPrefabName(__instance.gameObject.name);

            if (prefabName == "MushroomYellow")
            {
                if (__instance.m_itemData is TyrData)
                {
                    var tyrData = __instance.m_itemData as TyrData;

                    tyrData.Set("dye_color", 15190091, false);

                    return;
                }
            }

            /*var renderer = __instance.gameObject.GetComponentInChildren<MeshRenderer>();
             * renderer.material.SetColor("_EmissionColor", Utils.ToColor(tyrData.GetInt("dye_color")));*/
        }