mirror of
https://github.com/GTA-ASM/SanAndreasUnity
synced 2024-11-26 05:50:18 +00:00
delete postprocessing script
This commit is contained in:
parent
ebaee83e71
commit
17db595e4c
2 changed files with 0 additions and 69 deletions
|
@ -1,57 +0,0 @@
|
|||
using System;
|
||||
using System.IO;
|
||||
using UnityEditor;
|
||||
using UnityEditor.Callbacks;
|
||||
using UnityEngine;
|
||||
|
||||
namespace SanAndreasUnity.Editor
|
||||
{
|
||||
public class Config : MonoBehaviour
|
||||
{
|
||||
[PostProcessBuild]
|
||||
public static void CopyConfig(BuildTarget target, string pathToBuiltProject)
|
||||
{
|
||||
if (!IsStandaloneTarget (target))
|
||||
return;
|
||||
|
||||
var destDir = Path.GetDirectoryName(pathToBuiltProject);
|
||||
|
||||
// copy config file
|
||||
|
||||
var dest = Path.Combine(destDir, Utilities.Config.FileName);
|
||||
File.Copy(Utilities.Config.FilePath, dest, true);
|
||||
|
||||
// copy Data folder
|
||||
|
||||
var dataDir = SanAndreasUnity.Utilities.Config.DataPath;
|
||||
|
||||
dest = Path.Combine(destDir, Path.GetFileNameWithoutExtension(pathToBuiltProject) + "_Data");
|
||||
|
||||
dest = Path.Combine(dest, "Data");
|
||||
|
||||
if (Directory.Exists(dest))
|
||||
{
|
||||
Directory.Delete(dest);
|
||||
}
|
||||
|
||||
FileUtil.CopyFileOrDirectory(dataDir, dest);
|
||||
}
|
||||
|
||||
private static bool IsStandaloneTarget (BuildTarget target)
|
||||
{
|
||||
switch (target)
|
||||
{
|
||||
case BuildTarget.StandaloneWindows:
|
||||
case BuildTarget.StandaloneWindows64:
|
||||
case BuildTarget.StandaloneLinux:
|
||||
case BuildTarget.StandaloneLinux64:
|
||||
case BuildTarget.StandaloneLinuxUniversal:
|
||||
case BuildTarget.StandaloneOSX:
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -1,12 +0,0 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 6837867a733aff54882619926d2e2ab8
|
||||
timeCreated: 1428171580
|
||||
licenseType: Pro
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Loading…
Reference in a new issue