コード例 #1
0
 public static void Init(JewelScriptable jewel)
 {
     if (window != null)
     {
         window.ShowNotification(new GUIContent("please close this template editor \n before editing template"));
         window.Repaint();
         return;
     }
     template                 = jewel;
     window                   = ScriptableObject.CreateInstance <JewelTemplate>();
     window.position          = new Rect(Screen.width / 2, Screen.height / 2, 400, 500);
     window.titleContent.text = "Jewel Editor";
     window.ShowUtility();
 }
コード例 #2
0
ファイル: Jewels.cs プロジェクト: Tapaka/match3
    public Sprite GetJewelSprite(JewelScriptable.Type type)
    {
        JewelScriptable jewel = list.Find(j => j.type == type);

        return(jewel == null ? null : Resources.Load <Sprite>(jewel.spritePath));
    }
コード例 #3
0
ファイル: Jewels.cs プロジェクト: Tapaka/match3
 internal void Remove(JewelScriptable item)
 {
     list.Remove(item);
 }