Exemplo n.º 1
0
    public void UpdateDisplayName()
    {
        string dName = hexType.ToString() + ": " + gridPos.ToString();



        if (hexAttribute != null)
        {
            dName = dName.Replace("HexTile_", "☰ ");
            if (hexAttribute.GetType() == typeof(MenuButtonElementAttribute))
            {
                MenuButtonElementAttribute yeet = hexAttribute as MenuButtonElementAttribute;
                hexAttributeInfo = yeet.GetType() + ": " + yeet.commandToCall;
            }
            else
            {
                hexAttributeInfo = hexAttribute.GetType().ToString();
            }



            // Debug.Log(hexAttribute);
        }
        else
        {
            dName            = dName.Replace("HexTile_", "♥ ");
            hexAttributeInfo = null;
        }

        displayName = dName;
    }
Exemplo n.º 2
0
    private void ShowLayout_MenuButtonAttribute()
    {
        if (attribute == null)
        {
            return;
        }
        MenuButtonElementAttribute digitAttribute = (MenuButtonElementAttribute)attribute;

        digitAttribute.commandToCall = (Command)EditorGUILayout.EnumPopup("Button Command", digitAttribute.commandToCall);
    }