@ -1,114 +0,0 @@ |
|||||||
fileFormatVersion: 2 |
|
||||||
guid: 50c4d83bd5fd7e0499753e3b7d19c7f1 |
|
||||||
TextureImporter: |
|
||||||
internalIDToNameTable: [] |
|
||||||
externalObjects: {} |
|
||||||
serializedVersion: 13 |
|
||||||
mipmaps: |
|
||||||
mipMapMode: 0 |
|
||||||
enableMipMap: 0 |
|
||||||
sRGBTexture: 1 |
|
||||||
linearTexture: 0 |
|
||||||
fadeOut: 0 |
|
||||||
borderMipMap: 0 |
|
||||||
mipMapsPreserveCoverage: 0 |
|
||||||
alphaTestReferenceValue: 0.5 |
|
||||||
mipMapFadeDistanceStart: 1 |
|
||||||
mipMapFadeDistanceEnd: 3 |
|
||||||
bumpmap: |
|
||||||
convertToNormalMap: 0 |
|
||||||
externalNormalMap: 0 |
|
||||||
heightScale: 0.25 |
|
||||||
normalMapFilter: 0 |
|
||||||
flipGreenChannel: 0 |
|
||||||
isReadable: 0 |
|
||||||
streamingMipmaps: 0 |
|
||||||
streamingMipmapsPriority: 0 |
|
||||||
vTOnly: 0 |
|
||||||
ignoreMipmapLimit: 0 |
|
||||||
grayScaleToAlpha: 0 |
|
||||||
generateCubemap: 6 |
|
||||||
cubemapConvolution: 0 |
|
||||||
seamlessCubemap: 0 |
|
||||||
textureFormat: 1 |
|
||||||
maxTextureSize: 2048 |
|
||||||
textureSettings: |
|
||||||
serializedVersion: 2 |
|
||||||
filterMode: 1 |
|
||||||
aniso: 1 |
|
||||||
mipBias: 0 |
|
||||||
wrapU: 1 |
|
||||||
wrapV: 1 |
|
||||||
wrapW: 1 |
|
||||||
nPOTScale: 0 |
|
||||||
lightmap: 0 |
|
||||||
compressionQuality: 50 |
|
||||||
spriteMode: 1 |
|
||||||
spriteExtrude: 1 |
|
||||||
spriteMeshType: 1 |
|
||||||
alignment: 0 |
|
||||||
spritePivot: {x: 0.5, y: 0.5} |
|
||||||
spritePixelsToUnits: 100 |
|
||||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0} |
|
||||||
spriteGenerateFallbackPhysicsShape: 1 |
|
||||||
alphaUsage: 1 |
|
||||||
alphaIsTransparency: 1 |
|
||||||
spriteTessellationDetail: -1 |
|
||||||
textureType: 8 |
|
||||||
textureShape: 1 |
|
||||||
singleChannelComponent: 0 |
|
||||||
flipbookRows: 1 |
|
||||||
flipbookColumns: 1 |
|
||||||
maxTextureSizeSet: 0 |
|
||||||
compressionQualitySet: 0 |
|
||||||
textureFormatSet: 0 |
|
||||||
ignorePngGamma: 0 |
|
||||||
applyGammaDecoding: 0 |
|
||||||
swizzle: 50462976 |
|
||||||
cookieLightType: 0 |
|
||||||
platformSettings: |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: DefaultTexturePlatform |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: Standalone |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
spriteSheet: |
|
||||||
serializedVersion: 2 |
|
||||||
sprites: [] |
|
||||||
outline: [] |
|
||||||
physicsShape: [] |
|
||||||
bones: [] |
|
||||||
spriteID: 5e97eb03825dee720800000000000000 |
|
||||||
internalID: 0 |
|
||||||
vertices: [] |
|
||||||
indices: |
|
||||||
edges: [] |
|
||||||
weights: [] |
|
||||||
secondaryTextures: [] |
|
||||||
nameFileIdTable: {} |
|
||||||
mipmapLimitGroupName: |
|
||||||
pSDRemoveMatte: 0 |
|
||||||
userData: |
|
||||||
assetBundleName: |
|
||||||
assetBundleVariant: |
|
||||||
@ -1,114 +0,0 @@ |
|||||||
fileFormatVersion: 2 |
|
||||||
guid: 53b217500b4d7fe478d05cd63b600446 |
|
||||||
TextureImporter: |
|
||||||
internalIDToNameTable: [] |
|
||||||
externalObjects: {} |
|
||||||
serializedVersion: 13 |
|
||||||
mipmaps: |
|
||||||
mipMapMode: 0 |
|
||||||
enableMipMap: 0 |
|
||||||
sRGBTexture: 1 |
|
||||||
linearTexture: 0 |
|
||||||
fadeOut: 0 |
|
||||||
borderMipMap: 0 |
|
||||||
mipMapsPreserveCoverage: 0 |
|
||||||
alphaTestReferenceValue: 0.5 |
|
||||||
mipMapFadeDistanceStart: 1 |
|
||||||
mipMapFadeDistanceEnd: 3 |
|
||||||
bumpmap: |
|
||||||
convertToNormalMap: 0 |
|
||||||
externalNormalMap: 0 |
|
||||||
heightScale: 0.25 |
|
||||||
normalMapFilter: 0 |
|
||||||
flipGreenChannel: 0 |
|
||||||
isReadable: 0 |
|
||||||
streamingMipmaps: 0 |
|
||||||
streamingMipmapsPriority: 0 |
|
||||||
vTOnly: 0 |
|
||||||
ignoreMipmapLimit: 0 |
|
||||||
grayScaleToAlpha: 0 |
|
||||||
generateCubemap: 6 |
|
||||||
cubemapConvolution: 0 |
|
||||||
seamlessCubemap: 0 |
|
||||||
textureFormat: 1 |
|
||||||
maxTextureSize: 2048 |
|
||||||
textureSettings: |
|
||||||
serializedVersion: 2 |
|
||||||
filterMode: 1 |
|
||||||
aniso: 1 |
|
||||||
mipBias: 0 |
|
||||||
wrapU: 1 |
|
||||||
wrapV: 1 |
|
||||||
wrapW: 1 |
|
||||||
nPOTScale: 0 |
|
||||||
lightmap: 0 |
|
||||||
compressionQuality: 50 |
|
||||||
spriteMode: 1 |
|
||||||
spriteExtrude: 1 |
|
||||||
spriteMeshType: 1 |
|
||||||
alignment: 0 |
|
||||||
spritePivot: {x: 0.5, y: 0.5} |
|
||||||
spritePixelsToUnits: 100 |
|
||||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0} |
|
||||||
spriteGenerateFallbackPhysicsShape: 1 |
|
||||||
alphaUsage: 1 |
|
||||||
alphaIsTransparency: 1 |
|
||||||
spriteTessellationDetail: -1 |
|
||||||
textureType: 8 |
|
||||||
textureShape: 1 |
|
||||||
singleChannelComponent: 0 |
|
||||||
flipbookRows: 1 |
|
||||||
flipbookColumns: 1 |
|
||||||
maxTextureSizeSet: 0 |
|
||||||
compressionQualitySet: 0 |
|
||||||
textureFormatSet: 0 |
|
||||||
ignorePngGamma: 0 |
|
||||||
applyGammaDecoding: 0 |
|
||||||
swizzle: 50462976 |
|
||||||
cookieLightType: 0 |
|
||||||
platformSettings: |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: DefaultTexturePlatform |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: Standalone |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
spriteSheet: |
|
||||||
serializedVersion: 2 |
|
||||||
sprites: [] |
|
||||||
outline: [] |
|
||||||
physicsShape: [] |
|
||||||
bones: [] |
|
||||||
spriteID: 5e97eb03825dee720800000000000000 |
|
||||||
internalID: 0 |
|
||||||
vertices: [] |
|
||||||
indices: |
|
||||||
edges: [] |
|
||||||
weights: [] |
|
||||||
secondaryTextures: [] |
|
||||||
nameFileIdTable: {} |
|
||||||
mipmapLimitGroupName: |
|
||||||
pSDRemoveMatte: 0 |
|
||||||
userData: |
|
||||||
assetBundleName: |
|
||||||
assetBundleVariant: |
|
||||||
@ -1,114 +0,0 @@ |
|||||||
fileFormatVersion: 2 |
|
||||||
guid: c1d54513d7bc7f645b4bcfe5974d4b4d |
|
||||||
TextureImporter: |
|
||||||
internalIDToNameTable: [] |
|
||||||
externalObjects: {} |
|
||||||
serializedVersion: 13 |
|
||||||
mipmaps: |
|
||||||
mipMapMode: 0 |
|
||||||
enableMipMap: 0 |
|
||||||
sRGBTexture: 1 |
|
||||||
linearTexture: 0 |
|
||||||
fadeOut: 0 |
|
||||||
borderMipMap: 0 |
|
||||||
mipMapsPreserveCoverage: 0 |
|
||||||
alphaTestReferenceValue: 0.5 |
|
||||||
mipMapFadeDistanceStart: 1 |
|
||||||
mipMapFadeDistanceEnd: 3 |
|
||||||
bumpmap: |
|
||||||
convertToNormalMap: 0 |
|
||||||
externalNormalMap: 0 |
|
||||||
heightScale: 0.25 |
|
||||||
normalMapFilter: 0 |
|
||||||
flipGreenChannel: 0 |
|
||||||
isReadable: 0 |
|
||||||
streamingMipmaps: 0 |
|
||||||
streamingMipmapsPriority: 0 |
|
||||||
vTOnly: 0 |
|
||||||
ignoreMipmapLimit: 0 |
|
||||||
grayScaleToAlpha: 0 |
|
||||||
generateCubemap: 6 |
|
||||||
cubemapConvolution: 0 |
|
||||||
seamlessCubemap: 0 |
|
||||||
textureFormat: 1 |
|
||||||
maxTextureSize: 2048 |
|
||||||
textureSettings: |
|
||||||
serializedVersion: 2 |
|
||||||
filterMode: 1 |
|
||||||
aniso: 1 |
|
||||||
mipBias: 0 |
|
||||||
wrapU: 1 |
|
||||||
wrapV: 1 |
|
||||||
wrapW: 1 |
|
||||||
nPOTScale: 0 |
|
||||||
lightmap: 0 |
|
||||||
compressionQuality: 50 |
|
||||||
spriteMode: 1 |
|
||||||
spriteExtrude: 1 |
|
||||||
spriteMeshType: 1 |
|
||||||
alignment: 0 |
|
||||||
spritePivot: {x: 0.5, y: 0.5} |
|
||||||
spritePixelsToUnits: 100 |
|
||||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0} |
|
||||||
spriteGenerateFallbackPhysicsShape: 1 |
|
||||||
alphaUsage: 1 |
|
||||||
alphaIsTransparency: 1 |
|
||||||
spriteTessellationDetail: -1 |
|
||||||
textureType: 8 |
|
||||||
textureShape: 1 |
|
||||||
singleChannelComponent: 0 |
|
||||||
flipbookRows: 1 |
|
||||||
flipbookColumns: 1 |
|
||||||
maxTextureSizeSet: 0 |
|
||||||
compressionQualitySet: 0 |
|
||||||
textureFormatSet: 0 |
|
||||||
ignorePngGamma: 0 |
|
||||||
applyGammaDecoding: 0 |
|
||||||
swizzle: 50462976 |
|
||||||
cookieLightType: 0 |
|
||||||
platformSettings: |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: DefaultTexturePlatform |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: Standalone |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
spriteSheet: |
|
||||||
serializedVersion: 2 |
|
||||||
sprites: [] |
|
||||||
outline: [] |
|
||||||
physicsShape: [] |
|
||||||
bones: [] |
|
||||||
spriteID: 5e97eb03825dee720800000000000000 |
|
||||||
internalID: 0 |
|
||||||
vertices: [] |
|
||||||
indices: |
|
||||||
edges: [] |
|
||||||
weights: [] |
|
||||||
secondaryTextures: [] |
|
||||||
nameFileIdTable: {} |
|
||||||
mipmapLimitGroupName: |
|
||||||
pSDRemoveMatte: 0 |
|
||||||
userData: |
|
||||||
assetBundleName: |
|
||||||
assetBundleVariant: |
|
||||||
@ -1,114 +0,0 @@ |
|||||||
fileFormatVersion: 2 |
|
||||||
guid: d66af192588a35c469ca7ccd1c34296f |
|
||||||
TextureImporter: |
|
||||||
internalIDToNameTable: [] |
|
||||||
externalObjects: {} |
|
||||||
serializedVersion: 13 |
|
||||||
mipmaps: |
|
||||||
mipMapMode: 0 |
|
||||||
enableMipMap: 0 |
|
||||||
sRGBTexture: 1 |
|
||||||
linearTexture: 0 |
|
||||||
fadeOut: 0 |
|
||||||
borderMipMap: 0 |
|
||||||
mipMapsPreserveCoverage: 0 |
|
||||||
alphaTestReferenceValue: 0.5 |
|
||||||
mipMapFadeDistanceStart: 1 |
|
||||||
mipMapFadeDistanceEnd: 3 |
|
||||||
bumpmap: |
|
||||||
convertToNormalMap: 0 |
|
||||||
externalNormalMap: 0 |
|
||||||
heightScale: 0.25 |
|
||||||
normalMapFilter: 0 |
|
||||||
flipGreenChannel: 0 |
|
||||||
isReadable: 0 |
|
||||||
streamingMipmaps: 0 |
|
||||||
streamingMipmapsPriority: 0 |
|
||||||
vTOnly: 0 |
|
||||||
ignoreMipmapLimit: 0 |
|
||||||
grayScaleToAlpha: 0 |
|
||||||
generateCubemap: 6 |
|
||||||
cubemapConvolution: 0 |
|
||||||
seamlessCubemap: 0 |
|
||||||
textureFormat: 1 |
|
||||||
maxTextureSize: 2048 |
|
||||||
textureSettings: |
|
||||||
serializedVersion: 2 |
|
||||||
filterMode: 1 |
|
||||||
aniso: 1 |
|
||||||
mipBias: 0 |
|
||||||
wrapU: 1 |
|
||||||
wrapV: 1 |
|
||||||
wrapW: 1 |
|
||||||
nPOTScale: 0 |
|
||||||
lightmap: 0 |
|
||||||
compressionQuality: 50 |
|
||||||
spriteMode: 1 |
|
||||||
spriteExtrude: 1 |
|
||||||
spriteMeshType: 1 |
|
||||||
alignment: 0 |
|
||||||
spritePivot: {x: 0.5, y: 0.5} |
|
||||||
spritePixelsToUnits: 100 |
|
||||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0} |
|
||||||
spriteGenerateFallbackPhysicsShape: 1 |
|
||||||
alphaUsage: 1 |
|
||||||
alphaIsTransparency: 1 |
|
||||||
spriteTessellationDetail: -1 |
|
||||||
textureType: 8 |
|
||||||
textureShape: 1 |
|
||||||
singleChannelComponent: 0 |
|
||||||
flipbookRows: 1 |
|
||||||
flipbookColumns: 1 |
|
||||||
maxTextureSizeSet: 0 |
|
||||||
compressionQualitySet: 0 |
|
||||||
textureFormatSet: 0 |
|
||||||
ignorePngGamma: 0 |
|
||||||
applyGammaDecoding: 0 |
|
||||||
swizzle: 50462976 |
|
||||||
cookieLightType: 0 |
|
||||||
platformSettings: |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: DefaultTexturePlatform |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
- serializedVersion: 3 |
|
||||||
buildTarget: Standalone |
|
||||||
maxTextureSize: 2048 |
|
||||||
resizeAlgorithm: 0 |
|
||||||
textureFormat: -1 |
|
||||||
textureCompression: 1 |
|
||||||
compressionQuality: 50 |
|
||||||
crunchedCompression: 0 |
|
||||||
allowsAlphaSplitting: 0 |
|
||||||
overridden: 0 |
|
||||||
ignorePlatformSupport: 0 |
|
||||||
androidETC2FallbackOverride: 0 |
|
||||||
forceMaximumCompressionQuality_BC6H_BC7: 0 |
|
||||||
spriteSheet: |
|
||||||
serializedVersion: 2 |
|
||||||
sprites: [] |
|
||||||
outline: [] |
|
||||||
physicsShape: [] |
|
||||||
bones: [] |
|
||||||
spriteID: 5e97eb03825dee720800000000000000 |
|
||||||
internalID: 0 |
|
||||||
vertices: [] |
|
||||||
indices: |
|
||||||
edges: [] |
|
||||||
weights: [] |
|
||||||
secondaryTextures: [] |
|
||||||
nameFileIdTable: {} |
|
||||||
mipmapLimitGroupName: |
|
||||||
pSDRemoveMatte: 0 |
|
||||||
userData: |
|
||||||
assetBundleName: |
|
||||||
assetBundleVariant: |
|
||||||
@ -0,0 +1,97 @@ |
|||||||
|
using System.Collections; |
||||||
|
using System.Collections.Generic; |
||||||
|
using UnityEngine; |
||||||
|
using UnityEngine.Events; |
||||||
|
|
||||||
|
namespace UltraCombos |
||||||
|
{ |
||||||
|
public class DisplayConfig : MonoBehaviour |
||||||
|
{ |
||||||
|
[Header( "Display" )] |
||||||
|
[SerializeField] private FullScreenMode mode = FullScreenMode.Windowed; |
||||||
|
[SerializeField] private int displayCount = 1; |
||||||
|
[SerializeField] private Vector2Int resolution = new Vector2Int( 1600, 900 ); |
||||||
|
[SerializeField] private int fps = 60; |
||||||
|
|
||||||
|
[Header( "Misc" )] |
||||||
|
[Range( 0, 10 )] |
||||||
|
[SerializeField] private float autoHideCursor = 0; |
||||||
|
private float cursorStamp; |
||||||
|
private Vector2 cursorLastPosition; |
||||||
|
[SerializeField] private bool exitOnEsc = true; |
||||||
|
|
||||||
|
private float timestamp = -1; |
||||||
|
public float currentFps = 30.0f; |
||||||
|
|
||||||
|
[Header( "Event" )] |
||||||
|
public UnityEvent onQuit = new UnityEvent(); |
||||||
|
|
||||||
|
private void Awake() |
||||||
|
{ |
||||||
|
Application.targetFrameRate = fps; |
||||||
|
|
||||||
|
#if UNITY_STANDALONE || UNITY_EDITOR |
||||||
|
if ( mode == FullScreenMode.ExclusiveFullScreen ) |
||||||
|
{ |
||||||
|
var displays = Display.displays; |
||||||
|
int num = Mathf.Min( Mathf.Max( displayCount, 1 ), displays.Length ); |
||||||
|
for ( int i = 0; i < num; ++i ) |
||||||
|
{ |
||||||
|
displays[i].Activate(); |
||||||
|
} |
||||||
|
Screen.SetResolution( Screen.width, Screen.height, mode ); |
||||||
|
} |
||||||
|
else if ( mode == FullScreenMode.FullScreenWindow ) |
||||||
|
{ |
||||||
|
Screen.SetResolution( Screen.width, Screen.height, mode ); |
||||||
|
} |
||||||
|
else |
||||||
|
{ |
||||||
|
Screen.SetResolution( resolution.x, resolution.y, mode ); |
||||||
|
} |
||||||
|
#else |
||||||
|
Screen.sleepTimeout = SleepTimeout.NeverSleep; |
||||||
|
#endif |
||||||
|
} |
||||||
|
|
||||||
|
private void Update() |
||||||
|
{ |
||||||
|
if ( autoHideCursor > 0 ) |
||||||
|
{ |
||||||
|
#if ENABLE_INPUT_SYSTEM |
||||||
|
var pos = UnityEngine.InputSystem.Mouse.current.position.ReadValue(); |
||||||
|
#else |
||||||
|
var pos = (Vector2)Input.mousePosition; |
||||||
|
#endif |
||||||
|
var bias = pos - cursorLastPosition; |
||||||
|
if ( bias.magnitude > 1 ) |
||||||
|
{ |
||||||
|
cursorLastPosition = pos; |
||||||
|
cursorStamp = Time.time; |
||||||
|
} |
||||||
|
|
||||||
|
Cursor.visible = Time.time - cursorStamp < autoHideCursor; |
||||||
|
} |
||||||
|
|
||||||
|
if ( Time.time - timestamp > 0 ) |
||||||
|
{ |
||||||
|
currentFps = Mathf.Lerp( currentFps, 1.0f / (Time.time - timestamp), Time.deltaTime ); |
||||||
|
timestamp = Time.time; |
||||||
|
} |
||||||
|
|
||||||
|
if ( exitOnEsc ) |
||||||
|
{ |
||||||
|
#if ENABLE_INPUT_SYSTEM |
||||||
|
if ( UnityEngine.InputSystem.Keyboard.current.escapeKey.isPressed ) |
||||||
|
#else |
||||||
|
if ( Input.GetKey( KeyCode.Escape ) ) |
||||||
|
#endif |
||||||
|
{ |
||||||
|
onQuit.Invoke(); |
||||||
|
Application.Quit(); |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
} |
||||||
@ -0,0 +1,11 @@ |
|||||||
|
fileFormatVersion: 2 |
||||||
|
guid: 6d1f2e9d772901a48bbe11c43a697154 |
||||||
|
MonoImporter: |
||||||
|
externalObjects: {} |
||||||
|
serializedVersion: 2 |
||||||
|
defaultReferences: [] |
||||||
|
executionOrder: 0 |
||||||
|
icon: {instanceID: 0} |
||||||
|
userData: |
||||||
|
assetBundleName: |
||||||
|
assetBundleVariant: |
||||||
@ -0,0 +1,42 @@ |
|||||||
|
using System.Collections; |
||||||
|
using System.Collections.Generic; |
||||||
|
using System.IO; |
||||||
|
using UnityEngine; |
||||||
|
using UnityEngine.UI; |
||||||
|
|
||||||
|
public class loadMaskFile : MonoBehaviour |
||||||
|
{ |
||||||
|
RawImage rawImage; |
||||||
|
public string imagePath; |
||||||
|
// Start is called before the first frame update |
||||||
|
void Start() |
||||||
|
{ |
||||||
|
rawImage = GetComponent<RawImage>(); |
||||||
|
|
||||||
|
if (File.Exists(imagePath)) |
||||||
|
{ |
||||||
|
byte[] imageBytes = File.ReadAllBytes(imagePath); |
||||||
|
Texture2D texture = new Texture2D(2, 2); // Initial size, will be resized by LoadImage |
||||||
|
texture.LoadImage(imageBytes); |
||||||
|
|
||||||
|
if (rawImage != null) |
||||||
|
{ |
||||||
|
rawImage.texture = texture; |
||||||
|
} |
||||||
|
else |
||||||
|
{ |
||||||
|
Debug.LogError("RawImage component not assigned!"); |
||||||
|
} |
||||||
|
} |
||||||
|
else |
||||||
|
{ |
||||||
|
Debug.LogError("Image file not found at path: " + imagePath); |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
// Update is called once per frame |
||||||
|
void Update() |
||||||
|
{ |
||||||
|
|
||||||
|
} |
||||||
|
} |
||||||
@ -0,0 +1,11 @@ |
|||||||
|
fileFormatVersion: 2 |
||||||
|
guid: 3e47ac129448e9f4488c01f5b7182798 |
||||||
|
MonoImporter: |
||||||
|
externalObjects: {} |
||||||
|
serializedVersion: 2 |
||||||
|
defaultReferences: [] |
||||||
|
executionOrder: 0 |
||||||
|
icon: {instanceID: 0} |
||||||
|
userData: |
||||||
|
assetBundleName: |
||||||
|
assetBundleVariant: |
||||||
|
After Width: | Height: | Size: 528 KiB |
|
Before Width: | Height: | Size: 1.8 MiB After Width: | Height: | Size: 1.8 MiB |
|
Before Width: | Height: | Size: 1.1 MiB After Width: | Height: | Size: 1.1 MiB |
|
Before Width: | Height: | Size: 1.1 MiB After Width: | Height: | Size: 1.1 MiB |
|
Before Width: | Height: | Size: 1.0 MiB After Width: | Height: | Size: 1.0 MiB |
@ -0,0 +1 @@ |
|||||||
|
{"installed":{"client_id":"30989913678-hk8sipecu98lp5vdsk0ictf5gufmn33p.apps.googleusercontent.com","project_id":"thegreattipsy","auth_uri":"https://accounts.google.com/o/oauth2/auth","token_uri":"https://oauth2.googleapis.com/token","auth_provider_x509_cert_url":"https://www.googleapis.com/oauth2/v1/certs","client_secret":"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","redirect_uris":["http://localhost"]}} |
||||||
@ -0,0 +1,13 @@ |
|||||||
|
{ |
||||||
|
"type": "service_account", |
||||||
|
"project_id": "tech-277909", |
||||||
|
"private_key_id": "8bd38efb7464c27306c564b36fd797de06dbdb17", |
||||||
|
"private_key": "-----BEGIN PRIVATE KEY-----\nMIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQC30a54VgYQQuCN\n4DlMBUl+PZi6DaTAG59LDO/BG4plHFcM3AuIgDLboyO7limvDOQ8fsJh3XOCAfPS\nzA75JA7NwyukjE4FVwj0Nsk7LSfNbaqMpXS7ypftbSDIZ4j3/4/zhpmjHTc6f3+2\npK853nQqFpmRjEbydu/7KK49bmd4tvRWyoUmCq8yD5DPWeoAJX4vo6rHxuT4LDHr\nS7Enm4Efjyrl5XnL/9/KIL1n6AVUNOu0UrvQhJbPDunadTU+RoII28+RQt2U5J5p\n2LQ8RaRdW1Sv86Do+nHQyUMMb2VHl7pEM/N92Q7bFTl/WUB6XALA40OFgYjcvtV+\nojuZm1rjAgMBAAECggEAOJdg1+JgBoSYXoWADlP4Xtm22dzWcmBup6vpajHA50UU\n1bwu/sy9G5p7p0ZhOefFooxB6uBDLezM9IJnP7OmrRlfp86cPI+hjZIKXOIXhWq0\nXY2YxTHnmSyGMbySUguHdWlkhm+5r5ROLNxBqBbA+64uhD1EIGSWmGPbVMVXLLXc\nMqrMse8UPOPu0Z8PYMmucc+15T+5pPy2TQ2NXVaqU6TC5mKPM8kkwh/6FuYj8ghX\niV11V85RvztNTsD6KbbkU+l0US5cFfMLhBxDKDY3aWAqUW97FkEMOIGeKx5PGhtR\nf91C90rGmnphWeSX0UJGSNhB7FV/4Cf0/y8BHKbc/QKBgQD0yGxLVdBSIqz40U0O\nhtplzWVIe9UspI+LQsZfY61l1nhJ71SKnIjvzFgI+/703Yln55m1s+pKKaaoSzVc\niaYoE+7ha0+HeaRg5AcuKh/sqgidP3DMFddvn/3szf5xwwt7t/nCNe+8BBpUfFqf\nVmnnJolk9xtYZEEAP7dK/IowtwKBgQDAPhWojTGTKyg1BMuib8usOymfrO4S1X6n\nIXcFYoLTw/jIPrk2G2tia9fjvjvXzY9vc6phFn9rTLyBDLyaQ+48f2SJkyq1udFi\nrXpKRcUqnWJw364FZ3vEmiufxj3Q0Sv92WSAvS8NTl/mWMkTs9bpFYNhlZgiEvoL\n/ioT/5vjNQKBgQDnB89mXy0KiJ3XDbx7zH2O/gftHKt7wimVF8YhO/PpnT3VEmUp\nmkqIgcZJXIYrWHiar/XckF2994fLaYiIuYYwZ3fcHCtowz+JD09TnACbn3QX7kuo\n46h9O3UvLtFLT/qjn2XEjqGhRAIR4Xiq0KWNvEqLF8sgZycOdBSsWqSXCwKBgEh1\nnjg/r9XmyGrjedWqCbzLN+8lgT68Fdbs+C2haepjzVu8uJa6Uwlv2JnQ1EGNC2lY\n0Xlyv2g0LkD+CgCjZiKLadupCsogVdm5xYRFNAHR/I7K4I7M6Iu8CIFaeWZB0TEH\nRah4pkl/pwntoSy59mE4aKLZfdQqDvGCRV3wVFOZAoGBAMgJHb+hnEfwVDX3UgcU\nZpDYIDLrqeuURGIyTJCHwdhFsNvI1GyxqhKXlvOJ6ORP1lAAvF2SB/Y2zVo2w8eF\nuXCN+k1skVJCCthy5R/TJasiw7gKquUwR1CfVFqQKgBGc1QpTJLdCS78Xx7tJozB\nVafDEZ+6qu946JSz345IELEU\n-----END PRIVATE KEY-----\n", |
||||||
|
"client_email": "id-4070-thegreattipsy-upload@tech-277909.iam.gserviceaccount.com", |
||||||
|
"client_id": "114682548158877455724", |
||||||
|
"auth_uri": "https://accounts.google.com/o/oauth2/auth", |
||||||
|
"token_uri": "https://oauth2.googleapis.com/token", |
||||||
|
"auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs", |
||||||
|
"client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/id-4070-thegreattipsy-upload%40tech-277909.iam.gserviceaccount.com", |
||||||
|
"universe_domain": "googleapis.com" |
||||||
|
} |
||||||
@ -0,0 +1 @@ |
|||||||
|
{"access_token":"ya29.a0AS3H6NwRUsoFAQHYoCUxiG8MZloceVHP0rBERc4LrTytdN8IExp5dR5NJ1cZUyRLC7tBgJ_VpPFY0YjHNz3_w2jlxdE3InDzEha0WowTa8JsL2t29ukowQ-YPTP9HuRPMmD_a8-o5_ZunyjfviFiJJdWhQdKTMEhCMG9dpfOPrbbrHaEE_N3chnlTofJb6bNXTjWWqXWaCgYKASwSARESFQHGX2Mi0WuAalhD_HzlFf0jEK3Vng0207","token_type":"Bearer","expires_in":3599,"refresh_token":"1//0e-urCtqMVSK6CgYIARAAGA4SNwF-L9IrTWfNUsKFuBn8-mJmQxbXhkBlRW8776bD9xuFk1rFTaMH0dA9yRyESXHTchyXJDAJgkU","scope":"https://www.googleapis.com/auth/drive","Issued":"2025-09-12T11:04:03.046+08:00","IssuedUtc":"2025-09-12T03:04:03.046Z"} |
||||||
@ -0,0 +1,16 @@ |
|||||||
|
%YAML 1.1 |
||||||
|
%TAG !u! tag:unity3d.com,2011: |
||||||
|
--- !u!114 &1 |
||||||
|
MonoBehaviour: |
||||||
|
m_ObjectHideFlags: 53 |
||||||
|
m_CorrespondingSourceObject: {fileID: 0} |
||||||
|
m_PrefabInstance: {fileID: 0} |
||||||
|
m_PrefabAsset: {fileID: 0} |
||||||
|
m_GameObject: {fileID: 0} |
||||||
|
m_Enabled: 1 |
||||||
|
m_EditorHideFlags: 0 |
||||||
|
m_Script: {fileID: 11500000, guid: a287be6c49135cd4f9b2b8666c39d999, type: 3} |
||||||
|
m_Name: |
||||||
|
m_EditorClassIdentifier: |
||||||
|
assetDefaultFramerate: 60 |
||||||
|
m_DefaultFrameRate: 60 |
||||||