Exemplo n.º 1
0
 protected virtual void ParseEffectTarget(AdvColumnName columnName)
 {
     this.targetName = base.ParseCell <string>(columnName);
     if (!ParserUtil.TryParaseEnum <AdvEffectManager.TargetType>(this.targetName, out this.targetType))
     {
         this.targetType = AdvEffectManager.TargetType.Default;
     }
 }
Exemplo n.º 2
0
 public bool TryParse(string name, string type, string fileType)
 {
     this.key = name;
     if (!ParserUtil.TryParaseEnum <ParamType>(type, out this.type))
     {
         Debug.LogError(type + " is not ParamType");
         return(false);
     }
     if (string.IsNullOrEmpty(fileType))
     {
         this.fileType = FileType.Default;
     }
     else if (!ParserUtil.TryParaseEnum <FileType>(fileType, out this.fileType))
     {
         Debug.LogError(fileType + " is not FileType");
         return(false);
     }
     return(true);
 }
Exemplo n.º 3
0
        /// <summary>
        /// 宴用のカスタムインポート設定を強制するSpriteアセットかチェック
        /// </summary>
        public TextureType ParseCustomImportTextureType(AssetImporter importer)
        {
            string assetPath = importer.assetPath;

            foreach (Object folderAsset in CustomInportSpriteFolders)
            {
                string floderPath = AssetDatabase.GetAssetPath(folderAsset);
                if (assetPath.StartsWith(floderPath))
                {
                    string      name = System.IO.Path.GetFileName(floderPath);
                    TextureType type;
                    if (ParserUtil.TryParaseEnum <TextureType>(name, out type))
                    {
                        return(type);
                    }
                    return(TextureType.Unknown);
                }
            }
            return(TextureType.Unknown);
        }
Exemplo n.º 4
0
 protected virtual void ParseWait(AdvColumnName columnName)
 {
     if (base.IsEmptyCell(columnName))
     {
         base.WaitType = AdvCommandWaitType.ThisAndAdd;
     }
     else
     {
         AdvCommandWaitType type;
         if (!ParserUtil.TryParaseEnum <AdvCommandWaitType>(base.ParseCell <string>(columnName), out type))
         {
             base.WaitType = AdvCommandWaitType.NoWait;
             Debug.LogError(base.ToErrorString("UNKNOWN WaitType"));
         }
         else
         {
             base.WaitType = type;
         }
     }
 }
Exemplo n.º 5
0
 //ウェイトタイプを解析
 protected virtual void ParseWait(AdvColumnName columnName)
 {
     //第6引数でウェイトタイプの設定
     if (IsEmptyCell(columnName))
     {
         //設定なしの場合
         this.WaitType = AdvCommandWaitType.Default;
     }
     else
     {
         string             waitString = ParseCell <string>(columnName);
         AdvCommandWaitType waitType;
         if (!ParserUtil.TryParaseEnum <AdvCommandWaitType>(waitString, out waitType))
         {
             //何のタイプか不明
             this.WaitType = AdvCommandWaitType.NoWait;
             Debug.LogError(ToErrorString("UNKNOWN WaitType"));
         }
         else
         {
             this.WaitType = waitType;
         }
     }
 }