diff --git a/Assets/Plugins/NAudio.meta b/Assets/Plugins/NAudio.meta new file mode 100644 index 0000000..ce5bb9d --- /dev/null +++ b/Assets/Plugins/NAudio.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2658fe7276645e2458423f92943ea27d +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/NAudio.dll b/Assets/Plugins/NAudio/NAudio.dll similarity index 100% rename from Assets/Plugins/NAudio.dll rename to Assets/Plugins/NAudio/NAudio.dll diff --git a/Assets/Plugins/NAudio.dll.meta b/Assets/Plugins/NAudio/NAudio.dll.meta similarity index 100% rename from Assets/Plugins/NAudio.dll.meta rename to Assets/Plugins/NAudio/NAudio.dll.meta diff --git a/Assets/Plugins/StandaloneFileBrowser.meta b/Assets/Plugins/StandaloneFileBrowser.meta new file mode 100644 index 0000000..fbb92ac --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 57e25b4a578dba94c9353f4633b20549 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/IStandaloneFileBrowser.cs b/Assets/Plugins/StandaloneFileBrowser/IStandaloneFileBrowser.cs new file mode 100644 index 0000000..19c089d --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/IStandaloneFileBrowser.cs @@ -0,0 +1,13 @@ +using System; + +namespace SFB { + public interface IStandaloneFileBrowser { + string[] OpenFilePanel(string title, string directory, ExtensionFilter[] extensions, bool multiselect); + string[] OpenFolderPanel(string title, string directory, bool multiselect); + string SaveFilePanel(string title, string directory, string defaultName, ExtensionFilter[] extensions); + + void OpenFilePanelAsync(string title, string directory, ExtensionFilter[] extensions, bool multiselect, Action cb); + void OpenFolderPanelAsync(string title, string directory, bool multiselect, Action cb); + void SaveFilePanelAsync(string title, string directory, string defaultName, ExtensionFilter[] extensions, Action cb); + } +} diff --git a/Assets/Plugins/StandaloneFileBrowser/IStandaloneFileBrowser.cs.meta b/Assets/Plugins/StandaloneFileBrowser/IStandaloneFileBrowser.cs.meta new file mode 100644 index 0000000..297c5e8 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/IStandaloneFileBrowser.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 7609f7b6787a54496aa41a3053fcc76a +timeCreated: 1483902788 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins.meta new file mode 100644 index 0000000..365e9b2 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ddc4e7b83981f244ba9a26b88c18cb67 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux.meta new file mode 100644 index 0000000..12e971a --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: 82666e520ab4d4cf08bebbb8059cd6f4 +folderAsset: yes +timeCreated: 1538224809 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64.meta new file mode 100644 index 0000000..7f52bde --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64.meta @@ -0,0 +1,10 @@ +fileFormatVersion: 2 +guid: bd198408642944765b9305bd99404136 +folderAsset: yes +timeCreated: 1538230728 +licenseType: Free +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64/libStandaloneFileBrowser.so b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64/libStandaloneFileBrowser.so new file mode 100644 index 0000000..344084e Binary files /dev/null and b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64/libStandaloneFileBrowser.so differ diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64/libStandaloneFileBrowser.so.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64/libStandaloneFileBrowser.so.meta new file mode 100644 index 0000000..f925612 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/Linux/x86_64/libStandaloneFileBrowser.so.meta @@ -0,0 +1,126 @@ +fileFormatVersion: 2 +guid: b8c465928f1784a3fac8dc3766f7201c +timeCreated: 1538230728 +licenseType: Free +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + '': Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux: 1 + Exclude Linux64: 0 + Exclude LinuxUniversal: 0 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude SamsungTV: 1 + Exclude Tizen: 1 + Exclude WebGL: 1 + Exclude Win: 0 + Exclude Win64: 0 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + CPU: x86_64 + DefaultValueInitialized: true + OS: Linux + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Samsung TV: SamsungTV + second: + enabled: 0 + settings: + STV_MODEL: STANDARD_15 + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux64 + second: + enabled: 1 + settings: + CPU: x86_64 + - first: + Standalone: LinuxUniversal + second: + enabled: 1 + settings: + CPU: x86_64 + - first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/Ookii.Dialogs.dll b/Assets/Plugins/StandaloneFileBrowser/Plugins/Ookii.Dialogs.dll new file mode 100644 index 0000000..a5164a5 Binary files /dev/null and b/Assets/Plugins/StandaloneFileBrowser/Plugins/Ookii.Dialogs.dll differ diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/Ookii.Dialogs.dll.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/Ookii.Dialogs.dll.meta new file mode 100644 index 0000000..ae7d573 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/Ookii.Dialogs.dll.meta @@ -0,0 +1,130 @@ +fileFormatVersion: 2 +guid: e60958662eed5413d86143a0a69b731e +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 0 + Exclude Win64: 0 + Exclude iOS: 1 + - first: + : Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + DefaultValueInitialized: true + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle.meta new file mode 100644 index 0000000..c7bdac6 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle.meta @@ -0,0 +1,40 @@ +fileFormatVersion: 2 +guid: 110fdfb459db4fc448a2ccd37e200fa4 +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + DefaultValueInitialized: true + - first: + Standalone: OSXIntel + second: + enabled: 1 + settings: {} + - first: + Standalone: OSXIntel64 + second: + enabled: 1 + settings: {} + - first: + Standalone: OSXUniversal + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents.meta new file mode 100644 index 0000000..37ed2fc --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 996ea0b0fb9804844ba9595686ee3e7a +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/Info.plist b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/Info.plist new file mode 100644 index 0000000..52c479c --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/Info.plist @@ -0,0 +1,46 @@ + + + + + BuildMachineOSBuild + 18A391 + CFBundleDevelopmentRegion + English + CFBundleExecutable + StandaloneFileBrowser + CFBundleIdentifier + com.gkngkc.sfb + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + StandaloneFileBrowser + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleSupportedPlatforms + + MacOSX + + CFBundleVersion + 1.0 + CSResourcesFileMapped + + DTCompiler + com.apple.compilers.llvm.clang.1_0 + DTPlatformBuild + 10A255 + DTPlatformVersion + GM + DTSDKBuild + 18A384 + DTSDKName + macosx10.14 + DTXcode + 1000 + DTXcodeBuild + 10A255 + + diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/Info.plist.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/Info.plist.meta new file mode 100644 index 0000000..22c9f90 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/Info.plist.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ce685769797f44046afa3e567860c94c +timeCreated: 1505756861 +licenseType: Pro +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS.meta new file mode 100644 index 0000000..bd2d540 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a5a66f5db020f344c9327188aec2c060 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS/StandaloneFileBrowser b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS/StandaloneFileBrowser new file mode 100644 index 0000000..caf2b68 Binary files /dev/null and b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS/StandaloneFileBrowser differ diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS/StandaloneFileBrowser.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS/StandaloneFileBrowser.meta new file mode 100644 index 0000000..a298a74 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.bundle/Contents/MacOS/StandaloneFileBrowser.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ddf122e0e89124ce78aacfeecb3ec554 +timeCreated: 1508179371 +licenseType: Pro +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib new file mode 100644 index 0000000..1198f38 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib @@ -0,0 +1,90 @@ +var StandaloneFileBrowserWebGLPlugin = { + // Open file. + // gameObjectNamePtr: Unique GameObject name. Required for calling back unity with SendMessage. + // methodNamePtr: Callback method name on given GameObject. + // filter: Filter files. Example filters: + // Match all image files: "image/*" + // Match all video files: "video/*" + // Match all audio files: "audio/*" + // Custom: ".plist, .xml, .yaml" + // multiselect: Allows multiple file selection + UploadFile: function(gameObjectNamePtr, methodNamePtr, filterPtr, multiselect) { + gameObjectName = Pointer_stringify(gameObjectNamePtr); + methodName = Pointer_stringify(methodNamePtr); + filter = Pointer_stringify(filterPtr); + + // Delete if element exist + var fileInput = document.getElementById(gameObjectName) + if (fileInput) { + document.body.removeChild(fileInput); + } + + fileInput = document.createElement('input'); + fileInput.setAttribute('id', gameObjectName); + fileInput.setAttribute('type', 'file'); + fileInput.setAttribute('style','display:none;'); + fileInput.setAttribute('style','visibility:hidden;'); + if (multiselect) { + fileInput.setAttribute('multiple', ''); + } + if (filter) { + fileInput.setAttribute('accept', filter); + } + fileInput.onclick = function (event) { + // File dialog opened + this.value = null; + }; + fileInput.onchange = function (event) { + // multiselect works + var urls = []; + for (var i = 0; i < event.target.files.length; i++) { + urls.push(URL.createObjectURL(event.target.files[i])); + } + // File selected + SendMessage(gameObjectName, methodName, urls.join()); + + // Remove after file selected + document.body.removeChild(fileInput); + } + document.body.appendChild(fileInput); + + document.onmouseup = function() { + fileInput.click(); + document.onmouseup = null; + } + }, + + // Save file + // DownloadFile method does not open SaveFileDialog like standalone builds, its just allows user to download file + // gameObjectNamePtr: Unique GameObject name. Required for calling back unity with SendMessage. + // methodNamePtr: Callback method name on given GameObject. + // filenamePtr: Filename with extension + // byteArray: byte[] + // byteArraySize: byte[].Length + DownloadFile: function(gameObjectNamePtr, methodNamePtr, filenamePtr, byteArray, byteArraySize) { + gameObjectName = Pointer_stringify(gameObjectNamePtr); + methodName = Pointer_stringify(methodNamePtr); + filename = Pointer_stringify(filenamePtr); + + var bytes = new Uint8Array(byteArraySize); + for (var i = 0; i < byteArraySize; i++) { + bytes[i] = HEAPU8[byteArray + i]; + } + + var downloader = window.document.createElement('a'); + downloader.setAttribute('id', gameObjectName); + downloader.href = window.URL.createObjectURL(new Blob([bytes], { type: 'application/octet-stream' })); + downloader.download = filename; + document.body.appendChild(downloader); + + document.onmouseup = function() { + downloader.click(); + document.body.removeChild(downloader); + document.onmouseup = null; + + SendMessage(gameObjectName, methodName); + } + } +}; + +mergeInto(LibraryManager.library, StandaloneFileBrowserWebGLPlugin); \ No newline at end of file diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib.meta new file mode 100644 index 0000000..9ba582b --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/StandaloneFileBrowser.jslib.meta @@ -0,0 +1,96 @@ +fileFormatVersion: 2 +guid: 265aaf20a6d564e0fb00a9c4a7a9c300 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + isPreloaded: 0 + isOverridable: 0 + platformData: + - first: + '': Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: WebGL + second: + enabled: 1 + settings: {} + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: x86_64 + - first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/System.Windows.Forms.dll b/Assets/Plugins/StandaloneFileBrowser/Plugins/System.Windows.Forms.dll new file mode 100644 index 0000000..f6d8475 Binary files /dev/null and b/Assets/Plugins/StandaloneFileBrowser/Plugins/System.Windows.Forms.dll differ diff --git a/Assets/Plugins/StandaloneFileBrowser/Plugins/System.Windows.Forms.dll.meta b/Assets/Plugins/StandaloneFileBrowser/Plugins/System.Windows.Forms.dll.meta new file mode 100644 index 0000000..5416966 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/Plugins/System.Windows.Forms.dll.meta @@ -0,0 +1,130 @@ +fileFormatVersion: 2 +guid: 7d459a96865cc4aaab657012c6dc4833 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 0 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux: 1 + Exclude Linux64: 1 + Exclude LinuxUniversal: 1 + Exclude OSXIntel: 1 + Exclude OSXIntel64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 0 + Exclude Win64: 0 + Exclude iOS: 1 + - first: + : Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + OS: AnyOS + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + DefaultValueInitialized: true + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Linux + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: LinuxUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXIntel64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 0 + settings: + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowser.cs b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowser.cs new file mode 100644 index 0000000..ac2ca5f --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowser.cs @@ -0,0 +1,153 @@ +using System; + +namespace SFB { + public struct ExtensionFilter { + public string Name; + public string[] Extensions; + + public ExtensionFilter(string filterName, params string[] filterExtensions) { + Name = filterName; + Extensions = filterExtensions; + } + } + + public class StandaloneFileBrowser { + private static IStandaloneFileBrowser _platformWrapper = null; + + static StandaloneFileBrowser() { +#if UNITY_STANDALONE_OSX + _platformWrapper = new StandaloneFileBrowserMac(); +#elif UNITY_STANDALONE_WIN + _platformWrapper = new StandaloneFileBrowserWindows(); +#elif UNITY_STANDALONE_LINUX + _platformWrapper = new StandaloneFileBrowserLinux(); +#elif UNITY_EDITOR + _platformWrapper = new StandaloneFileBrowserEditor(); +#endif + } + + /// + /// Native open file dialog + /// + /// Dialog title + /// Root directory + /// Allowed extension + /// Allow multiple file selection + /// Returns array of chosen paths. Zero length array when cancelled + public static string[] OpenFilePanel(string title, string directory, string extension, bool multiselect) { + var extensions = string.IsNullOrEmpty(extension) ? null : new [] { new ExtensionFilter("", extension) }; + return OpenFilePanel(title, directory, extensions, multiselect); + } + + /// + /// Native open file dialog + /// + /// Dialog title + /// Root directory + /// List of extension filters. Filter Example: new ExtensionFilter("Image Files", "jpg", "png") + /// Allow multiple file selection + /// Returns array of chosen paths. Zero length array when cancelled + public static string[] OpenFilePanel(string title, string directory, ExtensionFilter[] extensions, bool multiselect) { + return _platformWrapper.OpenFilePanel(title, directory, extensions, multiselect); + } + + /// + /// Native open file dialog async + /// + /// Dialog title + /// Root directory + /// Allowed extension + /// Allow multiple file selection + /// Callback") + public static void OpenFilePanelAsync(string title, string directory, string extension, bool multiselect, Action cb) { + var extensions = string.IsNullOrEmpty(extension) ? null : new [] { new ExtensionFilter("", extension) }; + OpenFilePanelAsync(title, directory, extensions, multiselect, cb); + } + + /// + /// Native open file dialog async + /// + /// Dialog title + /// Root directory + /// List of extension filters. Filter Example: new ExtensionFilter("Image Files", "jpg", "png") + /// Allow multiple file selection + /// Callback") + public static void OpenFilePanelAsync(string title, string directory, ExtensionFilter[] extensions, bool multiselect, Action cb) { + _platformWrapper.OpenFilePanelAsync(title, directory, extensions, multiselect, cb); + } + + /// + /// Native open folder dialog + /// NOTE: Multiple folder selection doesn't supported on Windows + /// + /// + /// Root directory + /// + /// Returns array of chosen paths. Zero length array when cancelled + public static string[] OpenFolderPanel(string title, string directory, bool multiselect) { + return _platformWrapper.OpenFolderPanel(title, directory, multiselect); + } + + /// + /// Native open folder dialog async + /// NOTE: Multiple folder selection doesn't supported on Windows + /// + /// + /// Root directory + /// + /// Callback") + public static void OpenFolderPanelAsync(string title, string directory, bool multiselect, Action cb) { + _platformWrapper.OpenFolderPanelAsync(title, directory, multiselect, cb); + } + + /// + /// Native save file dialog + /// + /// Dialog title + /// Root directory + /// Default file name + /// File extension + /// Returns chosen path. Empty string when cancelled + public static string SaveFilePanel(string title, string directory, string defaultName , string extension) { + var extensions = string.IsNullOrEmpty(extension) ? null : new [] { new ExtensionFilter("", extension) }; + return SaveFilePanel(title, directory, defaultName, extensions); + } + + /// + /// Native save file dialog + /// + /// Dialog title + /// Root directory + /// Default file name + /// List of extension filters. Filter Example: new ExtensionFilter("Image Files", "jpg", "png") + /// Returns chosen path. Empty string when cancelled + public static string SaveFilePanel(string title, string directory, string defaultName, ExtensionFilter[] extensions) { + return _platformWrapper.SaveFilePanel(title, directory, defaultName, extensions); + } + + /// + /// Native save file dialog async + /// + /// Dialog title + /// Root directory + /// Default file name + /// File extension + /// Callback") + public static void SaveFilePanelAsync(string title, string directory, string defaultName , string extension, Action cb) { + var extensions = string.IsNullOrEmpty(extension) ? null : new [] { new ExtensionFilter("", extension) }; + SaveFilePanelAsync(title, directory, defaultName, extensions, cb); + } + + /// + /// Native save file dialog async + /// + /// Dialog title + /// Root directory + /// Default file name + /// List of extension filters. Filter Example: new ExtensionFilter("Image Files", "jpg", "png") + /// Callback") + public static void SaveFilePanelAsync(string title, string directory, string defaultName, ExtensionFilter[] extensions, Action cb) { + _platformWrapper.SaveFilePanelAsync(title, directory, defaultName, extensions, cb); + } + } +} \ No newline at end of file diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowser.cs.meta b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowser.cs.meta new file mode 100644 index 0000000..8ea7258 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowser.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 3c708be74128e4ced9b79eaaf80e8443 +timeCreated: 1483902788 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserEditor.cs b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserEditor.cs new file mode 100644 index 0000000..f07d3c0 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserEditor.cs @@ -0,0 +1,56 @@ +#if UNITY_EDITOR + +using System; +using UnityEditor; + +namespace SFB { + public class StandaloneFileBrowserEditor : IStandaloneFileBrowser { + public string[] OpenFilePanel(string title, string directory, ExtensionFilter[] extensions, bool multiselect) { + string path = ""; + + if (extensions == null) { + path = EditorUtility.OpenFilePanel(title, directory, ""); + } + else { + path = EditorUtility.OpenFilePanelWithFilters(title, directory, GetFilterFromFileExtensionList(extensions)); + } + + return string.IsNullOrEmpty(path) ? new string[0] : new[] { path }; + } + + public void OpenFilePanelAsync(string title, string directory, ExtensionFilter[] extensions, bool multiselect, Action cb) { + cb.Invoke(OpenFilePanel(title, directory, extensions, multiselect)); + } + + public string[] OpenFolderPanel(string title, string directory, bool multiselect) { + var path = EditorUtility.OpenFolderPanel(title, directory, ""); + return string.IsNullOrEmpty(path) ? new string[0] : new[] {path}; + } + + public void OpenFolderPanelAsync(string title, string directory, bool multiselect, Action cb) { + cb.Invoke(OpenFolderPanel(title, directory, multiselect)); + } + + public string SaveFilePanel(string title, string directory, string defaultName, ExtensionFilter[] extensions) { + var ext = extensions != null ? extensions[0].Extensions[0] : ""; + var name = string.IsNullOrEmpty(ext) ? defaultName : defaultName + "." + ext; + return EditorUtility.SaveFilePanel(title, directory, name, ext); + } + + public void SaveFilePanelAsync(string title, string directory, string defaultName, ExtensionFilter[] extensions, Action cb) { + cb.Invoke(SaveFilePanel(title, directory, defaultName, extensions)); + } + + // EditorUtility.OpenFilePanelWithFilters extension filter format + private static string[] GetFilterFromFileExtensionList(ExtensionFilter[] extensions) { + var filters = new string[extensions.Length * 2]; + for (int i = 0; i < extensions.Length; i++) { + filters[(i * 2)] = extensions[i].Name; + filters[(i * 2) + 1] = string.Join(",", extensions[i].Extensions); + } + return filters; + } + } +} + +#endif diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserEditor.cs.meta b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserEditor.cs.meta new file mode 100644 index 0000000..c0c3b52 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserEditor.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 2650af8de2cda46b99b1bc7cf5d30ca5 +timeCreated: 1483902788 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserLinux.cs b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserLinux.cs new file mode 100644 index 0000000..ba27ec0 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserLinux.cs @@ -0,0 +1,115 @@ +#if UNITY_STANDALONE_LINUX + +using System; +using System.IO; +using System.Runtime.InteropServices; +using UnityEngine; + +namespace SFB { + + public class StandaloneFileBrowserLinux : IStandaloneFileBrowser { + + private static Action _openFileCb; + private static Action _openFolderCb; + private static Action _saveFileCb; + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + public delegate void AsyncCallback(string path); + + [DllImport("StandaloneFileBrowser")] + private static extern void DialogInit(); + [DllImport("StandaloneFileBrowser")] + private static extern IntPtr DialogOpenFilePanel(string title, string directory, string extension, bool multiselect); + [DllImport("StandaloneFileBrowser")] + private static extern void DialogOpenFilePanelAsync(string title, string directory, string extension, bool multiselect, AsyncCallback callback); + [DllImport("StandaloneFileBrowser")] + private static extern IntPtr DialogOpenFolderPanel(string title, string directory, bool multiselect); + [DllImport("StandaloneFileBrowser")] + private static extern void DialogOpenFolderPanelAsync(string title, string directory, bool multiselect, AsyncCallback callback); + [DllImport("StandaloneFileBrowser")] + private static extern IntPtr DialogSaveFilePanel(string title, string directory, string defaultName, string extension); + [DllImport("StandaloneFileBrowser")] + private static extern void DialogSaveFilePanelAsync(string title, string directory, string defaultName, string extension, AsyncCallback callback); + + public StandaloneFileBrowserLinux() + { + DialogInit(); + } + + public string[] OpenFilePanel(string title, string directory, ExtensionFilter[] extensions, bool multiselect) { + var paths = Marshal.PtrToStringAnsi(DialogOpenFilePanel( + title, + directory, + GetFilterFromFileExtensionList(extensions), + multiselect)); + return paths.Split((char)28); + } + + public void OpenFilePanelAsync(string title, string directory, ExtensionFilter[] extensions, bool multiselect, Action cb) { + _openFileCb = cb; + DialogOpenFilePanelAsync( + title, + directory, + GetFilterFromFileExtensionList(extensions), + multiselect, + (string result) => { _openFileCb.Invoke(result.Split((char)28)); }); + } + + public string[] OpenFolderPanel(string title, string directory, bool multiselect) { + var paths = Marshal.PtrToStringAnsi(DialogOpenFolderPanel( + title, + directory, + multiselect)); + return paths.Split((char)28); + } + + public void OpenFolderPanelAsync(string title, string directory, bool multiselect, Action cb) { + _openFolderCb = cb; + DialogOpenFolderPanelAsync( + title, + directory, + multiselect, + (string result) => { _openFolderCb.Invoke(result.Split((char)28)); }); + } + + public string SaveFilePanel(string title, string directory, string defaultName, ExtensionFilter[] extensions) { + return Marshal.PtrToStringAnsi(DialogSaveFilePanel( + title, + directory, + defaultName, + GetFilterFromFileExtensionList(extensions))); + } + + public void SaveFilePanelAsync(string title, string directory, string defaultName, ExtensionFilter[] extensions, Action cb) { + _saveFileCb = cb; + DialogSaveFilePanelAsync( + title, + directory, + defaultName, + GetFilterFromFileExtensionList(extensions), + (string result) => { _saveFileCb.Invoke(result); }); + } + + private static string GetFilterFromFileExtensionList(ExtensionFilter[] extensions) { + if (extensions == null) { + return ""; + } + + var filterString = ""; + foreach (var filter in extensions) { + filterString += filter.Name + ";"; + + foreach (var ext in filter.Extensions) { + filterString += ext + ","; + } + + filterString = filterString.Remove(filterString.Length - 1); + filterString += "|"; + } + filterString = filterString.Remove(filterString.Length - 1); + return filterString; + } + } +} + +#endif \ No newline at end of file diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserLinux.cs.meta b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserLinux.cs.meta new file mode 100644 index 0000000..e8bfba1 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserLinux.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 5d3a668018554b8a89c3fe12de72b60c +timeCreated: 1538067919 \ No newline at end of file diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserMac.cs b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserMac.cs new file mode 100644 index 0000000..ad9d023 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserMac.cs @@ -0,0 +1,119 @@ +#if UNITY_STANDALONE_OSX + +using System; +using System.Runtime.InteropServices; + +namespace SFB { + public class StandaloneFileBrowserMac : IStandaloneFileBrowser { + private static Action _openFileCb; + private static Action _openFolderCb; + private static Action _saveFileCb; + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + public delegate void AsyncCallback(string path); + + [AOT.MonoPInvokeCallback(typeof(AsyncCallback))] + private static void openFileCb(string result) { + _openFileCb.Invoke(result.Split((char)28)); + } + + [AOT.MonoPInvokeCallback(typeof(AsyncCallback))] + private static void openFolderCb(string result) { + _openFolderCb.Invoke(result.Split((char)28)); + } + + [AOT.MonoPInvokeCallback(typeof(AsyncCallback))] + private static void saveFileCb(string result) { + _saveFileCb.Invoke(result); + } + + [DllImport("StandaloneFileBrowser")] + private static extern IntPtr DialogOpenFilePanel(string title, string directory, string extension, bool multiselect); + [DllImport("StandaloneFileBrowser")] + private static extern void DialogOpenFilePanelAsync(string title, string directory, string extension, bool multiselect, AsyncCallback callback); + [DllImport("StandaloneFileBrowser")] + private static extern IntPtr DialogOpenFolderPanel(string title, string directory, bool multiselect); + [DllImport("StandaloneFileBrowser")] + private static extern void DialogOpenFolderPanelAsync(string title, string directory, bool multiselect, AsyncCallback callback); + [DllImport("StandaloneFileBrowser")] + private static extern IntPtr DialogSaveFilePanel(string title, string directory, string defaultName, string extension); + [DllImport("StandaloneFileBrowser")] + private static extern void DialogSaveFilePanelAsync(string title, string directory, string defaultName, string extension, AsyncCallback callback); + + public string[] OpenFilePanel(string title, string directory, ExtensionFilter[] extensions, bool multiselect) { + var paths = Marshal.PtrToStringAnsi(DialogOpenFilePanel( + title, + directory, + GetFilterFromFileExtensionList(extensions), + multiselect)); + return paths.Split((char)28); + } + + public void OpenFilePanelAsync(string title, string directory, ExtensionFilter[] extensions, bool multiselect, Action cb) { + _openFileCb = cb; + DialogOpenFilePanelAsync( + title, + directory, + GetFilterFromFileExtensionList(extensions), + multiselect, + openFileCb); + } + + public string[] OpenFolderPanel(string title, string directory, bool multiselect) { + var paths = Marshal.PtrToStringAnsi(DialogOpenFolderPanel( + title, + directory, + multiselect)); + return paths.Split((char)28); + } + + public void OpenFolderPanelAsync(string title, string directory, bool multiselect, Action cb) { + _openFolderCb = cb; + DialogOpenFolderPanelAsync( + title, + directory, + multiselect, + openFolderCb); + } + + public string SaveFilePanel(string title, string directory, string defaultName, ExtensionFilter[] extensions) { + return Marshal.PtrToStringAnsi(DialogSaveFilePanel( + title, + directory, + defaultName, + GetFilterFromFileExtensionList(extensions))); + } + + public void SaveFilePanelAsync(string title, string directory, string defaultName, ExtensionFilter[] extensions, Action cb) { + _saveFileCb = cb; + DialogSaveFilePanelAsync( + title, + directory, + defaultName, + GetFilterFromFileExtensionList(extensions), + saveFileCb); + } + + private static string GetFilterFromFileExtensionList(ExtensionFilter[] extensions) { + if (extensions == null) { + return ""; + } + + var filterString = ""; + foreach (var filter in extensions) { + filterString += filter.Name + ";"; + + foreach (var ext in filter.Extensions) { + filterString += ext + ","; + } + + filterString = filterString.Remove(filterString.Length - 1); + filterString += "|"; + } + filterString = filterString.Remove(filterString.Length - 1); + return filterString; + } + } +} + +#endif \ No newline at end of file diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserMac.cs.meta b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserMac.cs.meta new file mode 100644 index 0000000..4a2ffc3 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserMac.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: bcb49ddb0ed5644fda9c3b055cafa27a +timeCreated: 1483902788 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserWindows.cs b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserWindows.cs new file mode 100644 index 0000000..2bdb8c2 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserWindows.cs @@ -0,0 +1,137 @@ +#if UNITY_STANDALONE_WIN + +using System; +using System.IO; +using System.Windows.Forms; +using System.Runtime.InteropServices; +using Ookii.Dialogs; + +namespace SFB { + // For fullscreen support + // - WindowWrapper class and GetActiveWindow() are required for modal file dialog. + // - "PlayerSettings/Visible In Background" should be enabled, otherwise when file dialog opened app window minimizes automatically. + + public class WindowWrapper : IWin32Window { + private IntPtr _hwnd; + public WindowWrapper(IntPtr handle) { _hwnd = handle; } + public IntPtr Handle { get { return _hwnd; } } + } + + public class StandaloneFileBrowserWindows : IStandaloneFileBrowser { + [DllImport("user32.dll")] + private static extern IntPtr GetActiveWindow(); + + public string[] OpenFilePanel(string title, string directory, ExtensionFilter[] extensions, bool multiselect) { + var fd = new VistaOpenFileDialog(); + fd.Title = title; + if (extensions != null) { + fd.Filter = GetFilterFromFileExtensionList(extensions); + fd.FilterIndex = 1; + } + else { + fd.Filter = string.Empty; + } + fd.Multiselect = multiselect; + if (!string.IsNullOrEmpty(directory)) { + fd.FileName = GetDirectoryPath(directory); + } + var res = fd.ShowDialog(new WindowWrapper(GetActiveWindow())); + var filenames = res == DialogResult.OK ? fd.FileNames : new string[0]; + fd.Dispose(); + return filenames; + } + + public void OpenFilePanelAsync(string title, string directory, ExtensionFilter[] extensions, bool multiselect, Action cb) { + cb.Invoke(OpenFilePanel(title, directory, extensions, multiselect)); + } + + public string[] OpenFolderPanel(string title, string directory, bool multiselect) { + var fd = new VistaFolderBrowserDialog(); + fd.Description = title; + if (!string.IsNullOrEmpty(directory)) { + fd.SelectedPath = GetDirectoryPath(directory); + } + var res = fd.ShowDialog(new WindowWrapper(GetActiveWindow())); + var filenames = res == DialogResult.OK ? new []{ fd.SelectedPath } : new string[0]; + fd.Dispose(); + return filenames; + } + + public void OpenFolderPanelAsync(string title, string directory, bool multiselect, Action cb) { + cb.Invoke(OpenFolderPanel(title, directory, multiselect)); + } + + public string SaveFilePanel(string title, string directory, string defaultName, ExtensionFilter[] extensions) { + var fd = new VistaSaveFileDialog(); + fd.Title = title; + + var finalFilename = ""; + + if (!string.IsNullOrEmpty(directory)) { + finalFilename = GetDirectoryPath(directory); + } + + if (!string.IsNullOrEmpty(defaultName)) { + finalFilename += defaultName; + } + + fd.FileName = finalFilename; + if (extensions != null) { + fd.Filter = GetFilterFromFileExtensionList(extensions); + fd.FilterIndex = 1; + fd.DefaultExt = extensions[0].Extensions[0]; + fd.AddExtension = true; + } + else { + fd.DefaultExt = string.Empty; + fd.Filter = string.Empty; + fd.AddExtension = false; + } + var res = fd.ShowDialog(new WindowWrapper(GetActiveWindow())); + var filename = res == DialogResult.OK ? fd.FileName : ""; + fd.Dispose(); + return filename; + } + + public void SaveFilePanelAsync(string title, string directory, string defaultName, ExtensionFilter[] extensions, Action cb) { + cb.Invoke(SaveFilePanel(title, directory, defaultName, extensions)); + } + + // .NET Framework FileDialog Filter format + // https://msdn.microsoft.com/en-us/library/microsoft.win32.filedialog.filter + private static string GetFilterFromFileExtensionList(ExtensionFilter[] extensions) { + var filterString = ""; + foreach (var filter in extensions) { + filterString += filter.Name + "("; + + foreach (var ext in filter.Extensions) { + filterString += "*." + ext + ","; + } + + filterString = filterString.Remove(filterString.Length - 1); + filterString += ") |"; + + foreach (var ext in filter.Extensions) { + filterString += "*." + ext + "; "; + } + + filterString += "|"; + } + filterString = filterString.Remove(filterString.Length - 1); + return filterString; + } + + private static string GetDirectoryPath(string directory) { + var directoryPath = Path.GetFullPath(directory); + if (!directoryPath.EndsWith("\\")) { + directoryPath += "\\"; + } + if (Path.GetPathRoot(directoryPath) == directoryPath) { + return directory; + } + return Path.GetDirectoryName(directoryPath) + Path.DirectorySeparatorChar; + } + } +} + +#endif \ No newline at end of file diff --git a/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserWindows.cs.meta b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserWindows.cs.meta new file mode 100644 index 0000000..00f5617 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandaloneFileBrowserWindows.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: 194e247414a78461d83ae606c1b96917 +timeCreated: 1483902788 +licenseType: Pro +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Plugins/StandaloneFileBrowser/StandalongFileBrowser.runtime.asmdef b/Assets/Plugins/StandaloneFileBrowser/StandalongFileBrowser.runtime.asmdef new file mode 100644 index 0000000..d54326a --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandalongFileBrowser.runtime.asmdef @@ -0,0 +1,14 @@ +{ + "name": "StandalongFileBrowser.runtime", + "rootNamespace": "", + "references": [], + "includePlatforms": [], + "excludePlatforms": [], + "allowUnsafeCode": false, + "overrideReferences": false, + "precompiledReferences": [], + "autoReferenced": true, + "defineConstraints": [], + "versionDefines": [], + "noEngineReferences": false +} \ No newline at end of file diff --git a/Assets/Plugins/StandaloneFileBrowser/StandalongFileBrowser.runtime.asmdef.meta b/Assets/Plugins/StandaloneFileBrowser/StandalongFileBrowser.runtime.asmdef.meta new file mode 100644 index 0000000..55e8e92 --- /dev/null +++ b/Assets/Plugins/StandaloneFileBrowser/StandalongFileBrowser.runtime.asmdef.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 145e2572884581c48a08acf566c1a1d6 +AssemblyDefinitionImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scenes/Version2.unity b/Assets/Scenes/Version2.unity index a2fcd53..d601f0b 100644 --- a/Assets/Scenes/Version2.unity +++ b/Assets/Scenes/Version2.unity @@ -2136,14 +2136,16 @@ RectTransform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - {fileID: 844924682} + - {fileID: 2122030934} - {fileID: 2073237536} + - {fileID: 1226114733} m_Father: {fileID: 1704906816} m_RootOrder: 17 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1} - m_AnchoredPosition: {x: 141.5, y: -1071.7834} - m_SizeDelta: {x: 283, y: 100} + m_AnchoredPosition: {x: 141.5, y: -609.6035} + m_SizeDelta: {x: 283, y: 200} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &93905315 MonoBehaviour: @@ -2167,7 +2169,7 @@ MonoBehaviour: m_ChildForceExpandWidth: 1 m_ChildForceExpandHeight: 1 m_ChildControlWidth: 1 - m_ChildControlHeight: 1 + m_ChildControlHeight: 0 m_ChildScaleWidth: 0 m_ChildScaleHeight: 0 m_ReverseArrangement: 0 @@ -2209,6 +2211,81 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 93905313} m_CullTransparentMesh: 1 +--- !u!1 &105646722 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 105646723} + - component: {fileID: 105646725} + - component: {fileID: 105646724} + m_Layer: 5 + m_Name: Item Checkmark + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &105646723 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 105646722} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1851638710} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0.5} + m_AnchorMax: {x: 0, y: 0.5} + m_AnchoredPosition: {x: 10, y: 0} + m_SizeDelta: {x: 20, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &105646724 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 105646722} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10901, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &105646725 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 105646722} + m_CullTransparentMesh: 1 --- !u!1 &114362110 GameObject: m_ObjectHideFlags: 0 @@ -2393,7 +2470,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 0, g: 0, b: 0, a: 1} + m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 @@ -4176,6 +4253,7 @@ RectTransform: - {fileID: 523631780} - {fileID: 1453791884} - {fileID: 1584955489} + - {fileID: 566097865} m_Father: {fileID: 1300114664} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} @@ -5470,6 +5548,42 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 275760635} m_CullTransparentMesh: 1 +--- !u!1 &279726707 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 279726708} + m_Layer: 5 + m_Name: Sliding Area + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &279726708 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 279726707} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1883289381} + m_Father: {fileID: 793890128} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -20, y: -20} + m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &280814817 GameObject: m_ObjectHideFlags: 0 @@ -7050,6 +7164,85 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 365084184} m_CullTransparentMesh: 1 +--- !u!1 &370099769 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 370099770} + - component: {fileID: 370099772} + - component: {fileID: 370099771} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &370099770 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 370099769} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1199042429} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &370099771 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 370099769} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} + m_FontSize: 25 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 1 + m_MaxSize: 40 + m_Alignment: 4 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 0 + m_LineSpacing: 1 + m_Text: Change DataPath +--- !u!222 &370099772 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 370099769} + m_CullTransparentMesh: 1 --- !u!1 &375034546 GameObject: m_ObjectHideFlags: 0 @@ -12401,6 +12594,51 @@ MonoBehaviour: m_EditorClassIdentifier: m_HorizontalFit: 0 m_VerticalFit: 2 +--- !u!1 &566097864 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 566097865} + - component: {fileID: 566097866} + m_Layer: 5 + m_Name: Message + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &566097865 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 566097864} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1890798835} + m_Father: {fileID: 242004464} + m_RootOrder: 10 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &566097866 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 566097864} + m_CullTransparentMesh: 1 --- !u!1 &570264419 GameObject: m_ObjectHideFlags: 0 @@ -13254,6 +13492,96 @@ MonoBehaviour: m_PersistentCalls: m_Calls: [] m_IsOn: 1 +--- !u!1 &613864944 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 613864945} + - component: {fileID: 613864948} + - component: {fileID: 613864947} + - component: {fileID: 613864946} + m_Layer: 5 + m_Name: Viewport + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &613864945 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613864944} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1650016386} + m_Father: {fileID: 1744565207} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -18, y: 0} + m_Pivot: {x: 0, y: 1} +--- !u!114 &613864946 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613864944} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10917, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &613864947 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613864944} + m_CullTransparentMesh: 1 +--- !u!114 &613864948 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 613864944} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 31a19414c41e5ae4aae2af33fee712f6, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ShowMaskGraphic: 0 --- !u!1 &633501904 GameObject: m_ObjectHideFlags: 0 @@ -13534,6 +13862,81 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 665091893} m_CullTransparentMesh: 1 +--- !u!1 &667826759 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 667826760} + - component: {fileID: 667826762} + - component: {fileID: 667826761} + m_Layer: 5 + m_Name: Item Background + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &667826760 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 667826759} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1851638710} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &667826761 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 667826759} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &667826762 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 667826759} + m_CullTransparentMesh: 1 --- !u!1 &668484487 GameObject: m_ObjectHideFlags: 0 @@ -17246,6 +17649,264 @@ MonoBehaviour: m_EditorClassIdentifier: m_HorizontalFit: 0 m_VerticalFit: 2 +--- !u!1 &793890127 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 793890128} + - component: {fileID: 793890131} + - component: {fileID: 793890130} + - component: {fileID: 793890129} + m_Layer: 5 + m_Name: Scrollbar + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &793890128 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 793890127} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 279726708} + m_Father: {fileID: 1744565207} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 20, y: 0} + m_Pivot: {x: 1, y: 1} +--- !u!114 &793890129 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 793890127} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2a4db7a114972834c8e4117be1d82ba3, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1883289382} + m_HandleRect: {fileID: 1883289381} + m_Direction: 2 + m_Value: 0 + m_Size: 0.2 + m_NumberOfSteps: 0 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &793890130 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 793890127} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &793890131 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 793890127} + m_CullTransparentMesh: 1 +--- !u!1 &801393420 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 801393421} + - component: {fileID: 801393424} + - component: {fileID: 801393423} + - component: {fileID: 801393422} + m_Layer: 5 + m_Name: Button + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &801393421 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 801393420} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1890798835} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 1} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: -0.000061035156, y: 0} + m_SizeDelta: {x: 50, y: 50} + m_Pivot: {x: 1, y: 1} +--- !u!114 &801393422 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 801393420} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 801393423} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1890798834} + m_TargetAssemblyTypeName: UnityEngine.GameObject, UnityEngine + m_MethodName: SetActive + m_Mode: 6 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &801393423 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 801393420} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0.6415094, g: 0.6415094, b: 0.6415094, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 8fac55fff4ce5fa40a7b2efefc0e617a, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &801393424 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 801393420} + m_CullTransparentMesh: 1 --- !u!1 &804543525 GameObject: m_ObjectHideFlags: 0 @@ -23685,6 +24346,101 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1104495874} m_CullTransparentMesh: 1 +--- !u!1 &1111410414 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1111410418} + - component: {fileID: 1111410417} + - component: {fileID: 1111410415} + - component: {fileID: 1111410416} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1111410415 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111410414} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 0 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_FontData: + m_Font: {fileID: 12800000, guid: 036631af73b15ac41a9d10f75f5bbafe, type: 3} + m_FontSize: 22 + m_FontStyle: 0 + m_BestFit: 0 + m_MinSize: 0 + m_MaxSize: 117 + m_Alignment: 0 + m_AlignByGeometry: 0 + m_RichText: 1 + m_HorizontalOverflow: 0 + m_VerticalOverflow: 1 + m_LineSpacing: 1 + m_Text: +--- !u!114 &1111410416 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111410414} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: e19747de3f5aca642ab2be37e372fb86, type: 3} + m_Name: + m_EditorClassIdentifier: + m_EffectColor: {r: 0, g: 0, b: 0, a: 1} + m_EffectDistance: {x: 1, y: 1} + m_UseGraphicAlpha: 1 +--- !u!222 &1111410417 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111410414} + m_CullTransparentMesh: 1 +--- !u!224 &1111410418 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1111410414} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1890798835} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 10, y: -10} + m_SizeDelta: {x: 540, y: 190} + m_Pivot: {x: 0, y: 1} --- !u!1 &1111689041 GameObject: m_ObjectHideFlags: 0 @@ -25673,6 +26429,139 @@ MonoBehaviour: m_StringArgument: m_BoolArgument: 0 m_CallState: 2 +--- !u!1 &1199042425 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1199042429} + - component: {fileID: 1199042428} + - component: {fileID: 1199042427} + - component: {fileID: 1199042426} + m_Layer: 5 + m_Name: Button + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1199042426 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1199042425} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1199042427} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1564959567} + m_TargetAssemblyTypeName: UmaViewerUI, umamusume + m_MethodName: ChangeMainPath + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 1 + m_CallState: 2 +--- !u!114 &1199042427 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1199042425} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1199042428 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1199042425} + m_CullTransparentMesh: 1 +--- !u!224 &1199042429 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1199042425} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 370099770} + m_Father: {fileID: 1226114733} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &1200264882 GameObject: m_ObjectHideFlags: 0 @@ -26556,6 +27445,82 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1225680051} m_CullTransparentMesh: 1 +--- !u!1 &1226114732 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1226114733} + - component: {fileID: 1226114735} + - component: {fileID: 1226114734} + m_Layer: 5 + m_Name: ChangeDataPath + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1226114733 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1226114732} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1199042429} + m_Father: {fileID: 93905314} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 283, y: -175} + m_SizeDelta: {x: 283, y: 50} + m_Pivot: {x: 1, y: 0.5} +--- !u!114 &1226114734 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1226114732} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 0.19607843} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1226114735 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1226114732} + m_CullTransparentMesh: 1 --- !u!1 &1227575449 GameObject: m_ObjectHideFlags: 0 @@ -27465,7 +28430,19 @@ MonoBehaviour: m_TargetGraphic: {fileID: 1280435373} m_OnClick: m_PersistentCalls: - m_Calls: [] + m_Calls: + - m_Target: {fileID: 1564959567} + m_TargetAssemblyTypeName: UmaViewerUI, umamusume + m_MethodName: PlayLive + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 --- !u!114 &1280435373 MonoBehaviour: m_ObjectHideFlags: 0 @@ -32625,6 +33602,8 @@ MonoBehaviour: PropPageCtrl: {fileID: 1552044446} SceneList: {fileID: 835845609} ScenePageCtrl: {fileID: 1045478985} + MessagePannel: {fileID: 1890798834} + MessageText: {fileID: 1111410415} EmotionList: {fileID: 1699478760} FacialList: {fileID: 1684693614} EarList: {fileID: 1809477290} @@ -32675,6 +33654,8 @@ MonoBehaviour: GifSlider: {fileID: 776477047} GifButton: {fileID: 964213177} VMDButton: {fileID: 668484488} + UpdateDBButton: {fileID: 1516377151} + WorkModeDropdown: {fileID: 1909384047} TogglablePanels: - {fileID: 1974252710} - {fileID: 87578738} @@ -34344,6 +35325,42 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1648089197} m_CullTransparentMesh: 1 +--- !u!1 &1650016385 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1650016386} + m_Layer: 5 + m_Name: Content + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1650016386 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1650016385} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1851638710} + m_Father: {fileID: 613864945} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 48} + m_Pivot: {x: 0.5, y: 1} --- !u!1 &1650576421 GameObject: m_ObjectHideFlags: 0 @@ -35530,6 +36547,140 @@ MonoBehaviour: m_OnValueChanged: m_PersistentCalls: m_Calls: [] +--- !u!1 &1679584761 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1679584764} + - component: {fileID: 1679584763} + - component: {fileID: 1679584762} + m_Layer: 5 + m_Name: Item Label + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1679584762 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1679584761} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: Option A + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: + serializedVersion: 2 + rgba: 4294967295 + m_fontColor: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: 0 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 18 + m_fontSizeBase: 18 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 1 + m_HorizontalAlignment: 1 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!222 &1679584763 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1679584761} + m_CullTransparentMesh: 1 +--- !u!224 &1679584764 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1679584761} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1851638710} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 5, y: -0.5} + m_SizeDelta: {x: -30, y: -3} + m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &1682865915 GameObject: m_ObjectHideFlags: 0 @@ -36947,6 +38098,114 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1740272110} m_CullTransparentMesh: 1 +--- !u!1 &1744565206 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1744565207} + - component: {fileID: 1744565210} + - component: {fileID: 1744565209} + - component: {fileID: 1744565208} + m_Layer: 5 + m_Name: Template + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!224 &1744565207 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1744565206} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 613864945} + - {fileID: 793890128} + m_Father: {fileID: 1909384048} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 0} + m_AnchoredPosition: {x: 0, y: 2} + m_SizeDelta: {x: 0, y: 150} + m_Pivot: {x: 0.5, y: 1} +--- !u!114 &1744565208 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1744565206} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 1aa08ab6e0800fa44ae55d278d1423e3, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Content: {fileID: 1650016386} + m_Horizontal: 0 + m_Vertical: 1 + m_MovementType: 2 + m_Elasticity: 0.1 + m_Inertia: 1 + m_DecelerationRate: 0.135 + m_ScrollSensitivity: 1 + m_Viewport: {fileID: 613864945} + m_HorizontalScrollbar: {fileID: 0} + m_VerticalScrollbar: {fileID: 793890129} + m_HorizontalScrollbarVisibility: 0 + m_VerticalScrollbarVisibility: 2 + m_HorizontalScrollbarSpacing: 0 + m_VerticalScrollbarSpacing: -3 + m_OnValueChanged: + m_PersistentCalls: + m_Calls: [] +--- !u!114 &1744565209 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1744565206} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1744565210 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1744565206} + m_CullTransparentMesh: 1 --- !u!1 &1749344627 GameObject: m_ObjectHideFlags: 0 @@ -38787,6 +40046,140 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1840536501} m_CullTransparentMesh: 1 +--- !u!1 &1846143404 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1846143407} + - component: {fileID: 1846143406} + - component: {fileID: 1846143405} + m_Layer: 5 + m_Name: Label + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1846143405 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1846143404} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: Defalut + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: + serializedVersion: 2 + rgba: 4281479730 + m_fontColor: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: -1183493901 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 18 + m_fontSizeBase: 18 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 1 + m_HorizontalAlignment: 1 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!222 &1846143406 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1846143404} + m_CullTransparentMesh: 1 +--- !u!224 &1846143407 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1846143404} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1909384048} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: -7.5, y: -0.5} + m_SizeDelta: {x: -35, y: -13} + m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &1849308817 GameObject: m_ObjectHideFlags: 0 @@ -38970,6 +40363,93 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1849463548} m_CullTransparentMesh: 1 +--- !u!1 &1851638709 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1851638710} + - component: {fileID: 1851638711} + m_Layer: 5 + m_Name: Item + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1851638710 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1851638709} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 667826760} + - {fileID: 105646723} + - {fileID: 1679584764} + m_Father: {fileID: 1650016386} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0.5} + m_AnchorMax: {x: 1, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 40} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1851638711 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1851638709} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 9085046f02f69544eb97fd06b6048fe2, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 667826761} + toggleTransition: 1 + graphic: {fileID: 105646724} + m_Group: {fileID: 0} + onValueChanged: + m_PersistentCalls: + m_Calls: [] + m_IsOn: 1 --- !u!1 &1862189159 GameObject: m_ObjectHideFlags: 0 @@ -39440,12 +40920,164 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1882365341} m_CullTransparentMesh: 1 +--- !u!1 &1883289380 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1883289381} + - component: {fileID: 1883289383} + - component: {fileID: 1883289382} + m_Layer: 5 + m_Name: Handle + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1883289381 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1883289380} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 279726708} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 0.2} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 20, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1883289382 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1883289380} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1883289383 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1883289380} + m_CullTransparentMesh: 1 --- !u!224 &1887819554 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 22448498, guid: 916ee089a0d7b63419075f91e1c657ec, type: 3} m_PrefabInstance: {fileID: 695731892} m_PrefabAsset: {fileID: 0} +--- !u!1 &1890798834 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1890798835} + - component: {fileID: 1890798837} + - component: {fileID: 1890798836} + m_Layer: 5 + m_Name: background + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!224 &1890798835 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1890798834} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1111410418} + - {fileID: 801393421} + m_Father: {fileID: 566097865} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 1} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: -300, y: -60.000122} + m_SizeDelta: {x: 600, y: 200} + m_Pivot: {x: 1, y: 1} +--- !u!114 &1890798836 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1890798834} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.39215687} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1890798837 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1890798834} + m_CullTransparentMesh: 1 --- !u!1 &1907940556 GameObject: m_ObjectHideFlags: 0 @@ -39521,6 +41153,155 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1907940556} m_CullTransparentMesh: 1 +--- !u!1 &1909384046 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1909384048} + - component: {fileID: 1909384050} + - component: {fileID: 1909384049} + - component: {fileID: 1909384047} + m_Layer: 5 + m_Name: Dropdown + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1909384047 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1909384046} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 7b743370ac3e4ec2a1668f5455a8ef8a, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1909384049} + m_Template: {fileID: 1744565207} + m_CaptionText: {fileID: 1846143405} + m_CaptionImage: {fileID: 0} + m_Placeholder: {fileID: 0} + m_ItemText: {fileID: 1679584762} + m_ItemImage: {fileID: 0} + m_Value: 0 + m_Options: + m_Options: + - m_Text: Defalut + m_Image: {fileID: 0} + - m_Text: Standalone + m_Image: {fileID: 0} + m_OnValueChanged: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1564959567} + m_TargetAssemblyTypeName: UmaViewerUI, umamusume + m_MethodName: ChangeWorkMode + m_Mode: 0 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_AlphaFadeSpeed: 0.15 +--- !u!224 &1909384048 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1909384046} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 1846143407} + - {fileID: 2132543292} + - {fileID: 1744565207} + m_Father: {fileID: 2122030934} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0.00024414062, y: 0} + m_SizeDelta: {x: 170, y: 0} + m_Pivot: {x: 1, y: 0.5} +--- !u!114 &1909384049 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1909384046} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1909384050 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1909384046} + m_CullTransparentMesh: 1 --- !u!1 &1916293856 GameObject: m_ObjectHideFlags: 0 @@ -42218,6 +43999,140 @@ RectTransform: m_AnchoredPosition: {x: -5, y: 0} m_SizeDelta: {x: -20, y: 0} m_Pivot: {x: 0.5, y: 0.5} +--- !u!1 &2021517957 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2021517958} + - component: {fileID: 2021517960} + - component: {fileID: 2021517959} + m_Layer: 5 + m_Name: Text (TMP) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &2021517958 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2021517957} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 2122030934} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 113, y: 0} + m_Pivot: {x: 0, y: 0.5} +--- !u!114 &2021517959 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2021517957} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: 'WorkMode:' + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: + serializedVersion: 2 + rgba: 4294967295 + m_fontColor: {r: 1, g: 1, b: 1, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: -1183493901 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 18 + m_fontSizeBase: 18 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 1 + m_HorizontalAlignment: 2 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!222 &2021517960 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2021517957} + m_CullTransparentMesh: 1 --- !u!1 &2024555994 GameObject: m_ObjectHideFlags: 0 @@ -43359,11 +45274,11 @@ RectTransform: m_Children: - {fileID: 1516377150} m_Father: {fileID: 93905314} - m_RootOrder: 1 + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1} - m_AnchoredPosition: {x: 283, y: -75} + m_AnchoredPosition: {x: 283, y: -125} m_SizeDelta: {x: 283, y: 50} m_Pivot: {x: 1, y: 0.5} --- !u!114 &2073237537 @@ -44943,6 +46858,43 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 2119831267} m_CullTransparentMesh: 1 +--- !u!1 &2122030933 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2122030934} + m_Layer: 5 + m_Name: WorkMode + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &2122030934 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2122030933} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: + - {fileID: 2021517958} + - {fileID: 1909384048} + m_Father: {fileID: 93905314} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 141.5, y: -75} + m_SizeDelta: {x: 283, y: 50} + m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &2126459760 GameObject: m_ObjectHideFlags: 0 @@ -45153,6 +47105,81 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 2129326812} m_CullTransparentMesh: 1 +--- !u!1 &2132543291 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2132543292} + - component: {fileID: 2132543294} + - component: {fileID: 2132543293} + m_Layer: 5 + m_Name: Arrow + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &2132543292 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2132543291} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_Children: [] + m_Father: {fileID: 1909384048} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 1, y: 0.5} + m_AnchorMax: {x: 1, y: 0.5} + m_AnchoredPosition: {x: -15, y: 0} + m_SizeDelta: {x: 20, y: 20} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &2132543293 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2132543291} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10915, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &2132543294 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2132543291} + m_CullTransparentMesh: 1 --- !u!1 &2133681985 GameObject: m_ObjectHideFlags: 0 diff --git a/Assets/Scripts/CameraOrbit.cs b/Assets/Scripts/CameraOrbit.cs index 219b2df..6207f6d 100644 --- a/Assets/Scripts/CameraOrbit.cs +++ b/Assets/Scripts/CameraOrbit.cs @@ -131,7 +131,6 @@ public class CameraOrbit : MonoBehaviour if (Input.GetMouseButton(0) && controlOn) { position -= Input.GetAxis("Mouse X") * transform.right * OrbitCamSpeedSlider.value; - OrbitCamZoomSlider.value -= Input.mouseScrollDelta.y * OrbitCamZoomSpeedSlider.value; OrbitCamHeightSlider.value -= Input.GetAxis("Mouse Y") * OrbitCamSpeedSlider.value; } else @@ -139,6 +138,11 @@ public class CameraOrbit : MonoBehaviour controlOn = false; } + if (!eventSystem.IsPointerOverGameObject()) + { + OrbitCamZoomSlider.value -= Input.mouseScrollDelta.y * OrbitCamZoomSpeedSlider.value; + } + if ((Input.GetMouseButtonDown(2) || Input.GetKeyDown(KeyCode.LeftControl)) && !eventSystem.IsPointerOverGameObject()) { CameraTargetHelper.SetActive(true); @@ -153,6 +157,7 @@ public class CameraOrbit : MonoBehaviour CameraTargetHelper.SetActive(false); } + float camDist = OrbitCamZoomSlider.value; OrbitCamHeightSlider.maxValue = camDist + 1 - camDist * 0.2f; OrbitCamHeightSlider.minValue = -camDist + 1 + camDist * 0.2f; diff --git a/Assets/Scripts/Config.cs b/Assets/Scripts/Config.cs index d0e1cd1..4465a5c 100644 --- a/Assets/Scripts/Config.cs +++ b/Assets/Scripts/Config.cs @@ -1,23 +1,27 @@ using System; -using System.Collections; -using System.Collections.Generic; using System.IO; using UnityEngine; public class Config { + public static string configPath = Application.dataPath + "/../Config.json"; public static Config Instance; public string Version = ""; + public string LanguageTip = "Affects Uma names on the list. Language options: 0 - En, 1 - Jp"; public Language Language = Language.En; - public string MainPathTip = "Path to game folder, eg. D:\\Backup\\Cygames\\umamusume or D:/Backup/Cygames/umamusume"; + + public string MainPathTip = "Path to game folder, eg. D:/Backup/Cygames/umamusume"; public string MainPath = ""; + public string WorkModeTip = "Affects how application work, options: 0 - work with game client, 1 - work without game client, Database needs to be updated manually"; + public WorkMode WorkMode = WorkMode.Default; + + public Config() { //TODO: Updating config file Version = Application.version; - string configPath = Application.dataPath + "/../Config.json"; MainPath = $@"{Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData) + "Low"}\Cygames\umamusume"; if (!File.Exists(configPath)) @@ -32,17 +36,31 @@ public class Config } catch (Exception ex) { - UmaViewerUI.Instance.LyricsText.text = "Config load error. Using default path. " + ex.Message; + UmaViewerUI.Instance.MessagePannel.SetActive(true); + UmaViewerUI.Instance.MessageText.text = "Config load error. Using default. " + ex.Message; MainPath = $@"{Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData) + "Low"}\Cygames\umamusume"; } } Instance = this; } + + public void UpdateConfig() + { + File.WriteAllText(configPath, JsonUtility.ToJson(this, true)); + UmaViewerUI.Instance.MessagePannel.SetActive(true); + UmaViewerUI.Instance.MessageText.text = "The configuration has changed. Please restart the application."; + } } public enum Language { En, Jp +} + +public enum WorkMode +{ + Default, + Standalone } \ No newline at end of file diff --git a/Assets/Scripts/Manifest/ManifestDB.cs b/Assets/Scripts/Manifest/ManifestDB.cs index 0f36d3a..93e53eb 100644 --- a/Assets/Scripts/Manifest/ManifestDB.cs +++ b/Assets/Scripts/Manifest/ManifestDB.cs @@ -17,7 +17,7 @@ public class ManifestDB public ManifestDB() { - string DBPath = $"{Config.Instance.MainPath}\\meta"; + string DBPath = $"{Config.Instance.MainPath}\\meta_umaviewer"; ManifestDB.DBPath = DBPath; if (!File.Exists(DBPath)) { @@ -177,7 +177,7 @@ public class ManifestDB callback?.Invoke($"Checking master.mdb"); SqliteCommand command = new SqliteCommand("SELECT h FROM a WHERE n LIKE 'master.mdb.lz4'", MetaDB); var reader = command.ExecuteReader(); - + if (reader.Read()) { var hash = reader.GetString(0); @@ -230,28 +230,26 @@ public class ManifestDB ulong count = reader.GetRowCount(); ManifestEntry[] manifests = new ManifestEntry[count]; - if (kind == Kind.Default) + for (ulong i = 0; i < count; i++) { - for (ulong i = 0; i < count; i++) + manifests[i].kind = (int)kind; + if (kind == Kind.Default) { - manifests[i].kind = (int)kind; if (!reader.ReadLine(ManifestEntry.GetBsvParser(ManifestEntry.Format.Full, reader), ref manifests[i])) { Debug.LogError("ReadLineError"); return null; } + } - } - else - { - for (ulong i = 0; i < count; i++) + else { - manifests[i].kind = (int)kind; if (!reader.ReadLine(ManifestEntry.GetBsvParser(ManifestEntry.Format.Simplified, reader), ref manifests[i])) { Debug.LogError("ReadLineError"); return null; } + } } return manifests; @@ -320,6 +318,6 @@ public class ManifestDB } return platformEntrys[0]; } - + } diff --git a/Assets/Scripts/UmaDatabase/UmaDataTypes.cs b/Assets/Scripts/UmaDatabase/UmaDataTypes.cs index 3d1fd58..fb701c6 100644 --- a/Assets/Scripts/UmaDatabase/UmaDataTypes.cs +++ b/Assets/Scripts/UmaDatabase/UmaDataTypes.cs @@ -1,8 +1,8 @@ -using RootMotion.Dynamics; -using System.Collections; +using System.Collections; using System.Collections.Generic; using UnityEngine; using Gallop; +using System.IO; public class UmaDatabaseEntry { @@ -11,7 +11,30 @@ public class UmaDatabaseEntry public string Url; public string Checksum; public string Prerequisites; - public string FilePath => $"{Config.Instance.MainPath}\\dat\\{Url.Substring(0, 2)}\\{Url}"; + public string FilePath + { + get + { + var path = $"{Config.Instance.MainPath}\\dat\\{Url.Substring(0, 2)}\\{Url}"; + if (!File.Exists(path) && Config.Instance.WorkMode == WorkMode.Standalone) + { + UmaViewerMain.Instance.StartCoroutine(DownloadAsset(this)); + } + return path; + } + } + + + public static IEnumerator DownloadAsset(UmaDatabaseEntry entry) + { + var path = $"{Config.Instance.MainPath}\\dat\\{entry.Url.Substring(0, 2)}\\{entry.Url}"; + yield return UmaViewerDownload.DownloadAsset(entry, path , delegate(string msg) + { + UmaViewerUI.Instance.MessagePannel.SetActive(true); + UmaViewerUI.Instance.MessageText.text = msg; + }); + } + } public class UmaCharaData diff --git a/Assets/Scripts/UmaDatabase/UmaDatabaseController.cs b/Assets/Scripts/UmaDatabase/UmaDatabaseController.cs index 93d5ef0..168703d 100644 --- a/Assets/Scripts/UmaDatabase/UmaDatabaseController.cs +++ b/Assets/Scripts/UmaDatabase/UmaDatabaseController.cs @@ -57,7 +57,15 @@ public class UmaDatabaseController { try { - metaDb = new SqliteConnection($@"Data Source={Config.Instance.MainPath}\meta;"); + if(Config.Instance.WorkMode == WorkMode.Standalone) + { + metaDb = new SqliteConnection($@"Data Source={Config.Instance.MainPath}\meta_umaviewer;"); + } + else + { + metaDb = new SqliteConnection($@"Data Source={Config.Instance.MainPath}\meta;"); + } + masterDb = new SqliteConnection($@"Data Source={Config.Instance.MainPath}\master\master.mdb;"); metaDb.Open(); @@ -71,8 +79,17 @@ public class UmaDatabaseController } catch { - UmaViewerUI.Instance.LyricsText.text = $"Database not found: \n{Config.Instance.MainPath}\\meta\n{Config.Instance.MainPath}\\master\\master.mdb"; - UmaViewerUI.Instance.LyricsText.color = Color.red; + UmaViewerUI.Instance.MessagePannel.SetActive(true); + UmaViewerUI.Instance.MessageText.text = $"Database not found at: {Config.Instance.MainPath}"; + if(Config.Instance.WorkMode == WorkMode.Standalone) + { + UmaViewerUI.Instance.MessageText.text += "\nPlease update the database in the settings panel"; + } + else + { + UmaViewerUI.Instance.MessageText.text += "\nPlease install the dmm game client"; + } + masterDb.Close(); metaDb.Close(); } @@ -186,4 +203,5 @@ public class UmaDatabaseController masterDb.Close(); metaDb.Close(); } + } diff --git a/Assets/Scripts/UmaViewerBuilder.cs b/Assets/Scripts/UmaViewerBuilder.cs index 7ce1267..30dfca0 100644 --- a/Assets/Scripts/UmaViewerBuilder.cs +++ b/Assets/Scripts/UmaViewerBuilder.cs @@ -1277,6 +1277,7 @@ public class UmaViewerBuilder : MonoBehaviour foreach (var bundle in Main.LoadedBundles) { + if(bundle.Value) bundle.Value.Unload(unloadAllObjects); } if (unloadAllObjects) diff --git a/Assets/Scripts/UmaViewerDownload.cs b/Assets/Scripts/UmaViewerDownload.cs index ad2be80..cd2ec5d 100644 --- a/Assets/Scripts/UmaViewerDownload.cs +++ b/Assets/Scripts/UmaViewerDownload.cs @@ -1,5 +1,7 @@ +using System; using System.Collections; using System.Collections.Generic; +using System.IO; using UnityEngine; using UnityEngine.Networking; @@ -26,6 +28,31 @@ public class UmaViewerDownload : MonoBehaviour } } + public static IEnumerator DownloadAsset(UmaDatabaseEntry entry,string path, Action callback = null) + { + string baseurl = GetAssetRequestUrl(entry.Url); + if (!string.IsNullOrEmpty(Path.GetExtension(entry.Name))) + { + baseurl = GetGenericRequestUrl(entry.Url); + } + + using UnityWebRequest www = UnityWebRequest.Get(baseurl); + callback?.Invoke($"Downloading missing asset : {Path.GetFileName(entry.Name)}\n"); + yield return www.SendWebRequest(); + if (www.result != UnityWebRequest.Result.Success) + { + Debug.LogError(www.error); + callback?.Invoke($"Failed to download resources : {www.error}"); + } + else + { + Debug.Log("saving " + entry.Url); + Directory.CreateDirectory(Path.GetDirectoryName(path)); + File.WriteAllBytes(path, www.downloadHandler.data); + callback?.Invoke($"Downloading missing asset : {Path.GetFileName(entry.Name)}\ncompleted, please load again"); + } + } + public static string GetManifestRequestUrl(string hash) { return $"{MANIFEST_ROOT_URL}/{hash.Substring(0, 2)}/{hash}"; diff --git a/Assets/Scripts/UmaViewerUI.cs b/Assets/Scripts/UmaViewerUI.cs index 1ffaaf8..e1a8cf6 100644 --- a/Assets/Scripts/UmaViewerUI.cs +++ b/Assets/Scripts/UmaViewerUI.cs @@ -1,4 +1,5 @@ using Gallop; +using SFB; using System; using System.Collections; using System.Collections.Generic; @@ -23,18 +24,23 @@ public class UmaViewerUI : MonoBehaviour public ScrollRect AnimationSetList; public ScrollRect AnimationList; public PageManager AnimationPageCtrl; + [Header("mini models")] public ScrollRect MiniCharactersList; public ScrollRect MiniCostumeList; public ScrollRect MiniAnimationSetList; public ScrollRect MiniAnimationList; public PageManager MiniAnimationPageCtrl; + [Header("other")] public ScrollRect PropList; public PageManager PropPageCtrl; public ScrollRect SceneList; public PageManager ScenePageCtrl; + public GameObject MessagePannel; + public Text MessageText; + [Header("lists")] public ScrollRect EmotionList; public Transform FacialList; public ScrollRect EarList; @@ -49,6 +55,7 @@ public class UmaViewerUI : MonoBehaviour public ScrollRect NormalSubSoundList; public PageManager NormalSoundCtrl; + [Header("audio")] public Slider AudioSlider; public Button AudioPlayButton; @@ -92,13 +99,15 @@ public class UmaViewerUI : MonoBehaviour public Toggle GifTransparent; public Slider GifQuality; public TextMeshProUGUI GifQualityLabel; - public Slider GifSlider; public Button GifButton; public Button VMDButton; + public Button UpdateDBButton; + public TMP_Dropdown WorkModeDropdown; public List TogglablePanels = new List(); public List TogglableFacials = new List(); + [Header("prefabs")] public GameObject UmaContainerPrefab; public GameObject UmaContainerCostumePrefab; public GameObject UmaContainerLivePrefab; @@ -129,6 +138,11 @@ public class UmaViewerUI : MonoBehaviour if (Application.platform == RuntimePlatform.Android) canvasScaler.screenMatchMode = CanvasScaler.ScreenMatchMode.Shrink; } + private void Start() + { + WorkModeDropdown.SetValueWithoutNotify((int)Config.Instance.WorkMode); + UpdateDBButton.interactable = (Config.Instance.WorkMode == WorkMode.Standalone); + } private void Update() { @@ -1143,11 +1157,33 @@ public class UmaViewerUI : MonoBehaviour } public void UpdateGameDB() { - if (UpdateResVerCoroutine != null) return; + if (UpdateResVerCoroutine != null&&Config.Instance.WorkMode != WorkMode.Standalone) return; UmaDatabaseController.Instance.CloseAllConnection(); ManifestDB dB = new ManifestDB(); - UpdateResVerCoroutine = dB.UpdateResourceVersion(delegate (string msg) { LyricsText.text = msg; }); + UpdateResVerCoroutine = dB.UpdateResourceVersion(delegate (string msg) { MessagePannel.SetActive(true); MessageText.text = msg; }); StartCoroutine(UpdateResVerCoroutine); } + public void ChangeWorkMode(int mode) + { + if((int)Config.Instance.WorkMode != mode) + { + Config.Instance.WorkMode = (WorkMode)mode; + Config.Instance.UpdateConfig(); + } + } + + public void ChangeMainPath() + { + var path = StandaloneFileBrowser.OpenFolderPanel("Select Folder", Config.Instance.MainPath, false); + if (path != null && path.Length > 0 && !string.IsNullOrEmpty(path[0])) + { + if(path[0] != Config.Instance.MainPath) + { + Config.Instance.MainPath = path[0]; + Config.Instance.UpdateConfig(); + } + } + } + } diff --git a/Assets/Scripts/umamusume.asmdef b/Assets/Scripts/umamusume.asmdef index 8708632..bb8172b 100644 --- a/Assets/Scripts/umamusume.asmdef +++ b/Assets/Scripts/umamusume.asmdef @@ -4,7 +4,8 @@ "references": [ "GUID:6055be8ebefd69e48b49212b09b47b2f", "GUID:800597811bcc5d848b15e12807d6de45", - "GUID:d60799ab2a985554ea1a39cd38695018" + "GUID:d60799ab2a985554ea1a39cd38695018", + "GUID:145e2572884581c48a08acf566c1a1d6" ], "includePlatforms": [], "excludePlatforms": [],