Пример #1
0
 private void saveAsFile()
 {
     _currentPath = EditorUtility.SaveFilePanel(string.Empty, string.IsNullOrEmpty(_currentPath) ? Application.streamingAssetsPath : _currentPath, "New Card", "thcd");
     if (!string.IsNullOrEmpty(_currentPath))
     {
         CardFileHelper.writeToFile(_currentPath, _card);
     }
 }
Пример #2
0
 private void saveFile()
 {
     if (!string.IsNullOrEmpty(_currentPath))
     {
         CardFileHelper.writeToFile(_currentPath, _card);
     }
     else
     {
         saveAsFile();
     }
 }