Added BaseLifetimescope and gameplay scene
This commit is contained in:
@@ -0,0 +1,18 @@
|
|||||||
|
using Darkmatter.Libs.Installers;
|
||||||
|
using UnityEngine;
|
||||||
|
using VContainer;
|
||||||
|
using VContainer.Unity;
|
||||||
|
|
||||||
|
public abstract class BaseLifetimeScope : LifetimeScope
|
||||||
|
{
|
||||||
|
[SerializeField] private MonoBehaviour[] serviceModules;
|
||||||
|
|
||||||
|
protected override void Configure(IContainerBuilder builder)
|
||||||
|
{
|
||||||
|
foreach (var module in serviceModules)
|
||||||
|
{
|
||||||
|
if (module is IServiceModule serviceModule)
|
||||||
|
serviceModule.Register(builder);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 14a5b12dfbd0540478508a72b0bcc3cc
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
using VContainer;
|
||||||
|
|
||||||
|
public class GameLifetimeScope : BaseLifetimeScope
|
||||||
|
{
|
||||||
|
protected override void Configure(IContainerBuilder builder)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 4ca410c053f074e1cba2f7041f500d34
|
||||||
@@ -1,18 +1,9 @@
|
|||||||
using Darkmatter.Libs.Installers;
|
|
||||||
using UnityEngine;
|
|
||||||
using VContainer;
|
using VContainer;
|
||||||
using VContainer.Unity;
|
using VContainer.Unity;
|
||||||
|
|
||||||
public class RootLifetimeScope : LifetimeScope
|
public class RootLifetimeScope : BaseLifetimeScope
|
||||||
{
|
{
|
||||||
[SerializeField] private MonoBehaviour[] serviceModules;
|
|
||||||
|
|
||||||
protected override void Configure(IContainerBuilder builder)
|
protected override void Configure(IContainerBuilder builder)
|
||||||
{
|
{
|
||||||
foreach (var module in serviceModules)
|
|
||||||
{
|
|
||||||
if (module is IServiceModule serviceModule)
|
|
||||||
serviceModule.Register(builder);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
8
Assets/Darkmatter/Code/Core/Contracts/Paper.meta
Normal file
8
Assets/Darkmatter/Code/Core/Contracts/Paper.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 1f91f821f605f4d1ba438f41e4232df0
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Darkmatter.Core.Contracts.Paper
|
||||||
|
{
|
||||||
|
public interface IArtInputBridge
|
||||||
|
{
|
||||||
|
bool TryScreenToArtWorld(Vector2 screenPos, out Vector2 artWorldPos);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 39f0c8bfbf53c4b299d6beb0a01fd32b
|
||||||
13
Assets/Darkmatter/Code/Core/Contracts/Paper/IPaperRig.cs
Normal file
13
Assets/Darkmatter/Code/Core/Contracts/Paper/IPaperRig.cs
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Darkmatter.Core.Contracts.Paper
|
||||||
|
{
|
||||||
|
public interface IPaperRig
|
||||||
|
{
|
||||||
|
Camera ArtCamera { get; }
|
||||||
|
RenderTexture Surface { get; }
|
||||||
|
Vector2Int SurfaceSize { get; }
|
||||||
|
float DesignHalfSize { get; }
|
||||||
|
Transform PaperRoot { get; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: a51496fa9463b41f7baeb4ff40055835
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: bf985c17631794cc8ba5e0b581de7b4e
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
using System.Threading;
|
||||||
|
using Cysharp.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Darkmatter.Core.Contracts.Services.Capture
|
||||||
|
{
|
||||||
|
public interface ICaptureService
|
||||||
|
{
|
||||||
|
UniTask<byte[]> CapturePngAsync(CancellationToken cancellationToken = default);
|
||||||
|
|
||||||
|
UniTask<byte[]> CaptureThumbnailPngAsync(int size, CancellationToken cancellationToken = default);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: bffc27fabc18d4014bee348129b73cf7
|
||||||
@@ -3,6 +3,7 @@ namespace Darkmatter.Core.Enums.Services.Camera
|
|||||||
public enum CameraType
|
public enum CameraType
|
||||||
{
|
{
|
||||||
MainCamera,
|
MainCamera,
|
||||||
UICamera
|
UICamera,
|
||||||
|
ArtCamera
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,9 +17,9 @@ namespace Darkmatter.Services.Camera.Installers
|
|||||||
var cameras = new Dictionary<CameraType, UnityEngine.Camera>
|
var cameras = new Dictionary<CameraType, UnityEngine.Camera>
|
||||||
{
|
{
|
||||||
{ CameraType.MainCamera, mainCamera },
|
{ CameraType.MainCamera, mainCamera },
|
||||||
{ CameraType.UICamera, uiCamera },
|
{ CameraType.UICamera, uiCamera }
|
||||||
};
|
};
|
||||||
builder.Register<ICameraService, CameraService>(Lifetime.Singleton);
|
builder.Register<ICameraService, CameraService>(Lifetime.Singleton).WithParameter(cameras);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
8
Assets/Darkmatter/Content.meta
Normal file
8
Assets/Darkmatter/Content.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 50b7af2b4f0f74bcd9a0257839d6f0ca
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Assets/Darkmatter/Content/Gameplay.meta
Normal file
8
Assets/Darkmatter/Content/Gameplay.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 227c245961aab4de9b09eae4fe4a619c
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
8
Assets/Darkmatter/Content/Gameplay/PaperRig.meta
Normal file
8
Assets/Darkmatter/Content/Gameplay/PaperRig.meta
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 68afb1ec24cda44d6a6a57436462a65c
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!84 &8400000
|
||||||
|
RenderTexture:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_Name: ArtCameraTexture
|
||||||
|
m_ImageContentsHash:
|
||||||
|
serializedVersion: 2
|
||||||
|
Hash: 00000000000000000000000000000000
|
||||||
|
m_IsAlphaChannelOptional: 0
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Width: 1920
|
||||||
|
m_Height: 1080
|
||||||
|
m_AntiAliasing: 1
|
||||||
|
m_MipCount: -1
|
||||||
|
m_DepthStencilFormat: 94
|
||||||
|
m_ColorFormat: 8
|
||||||
|
m_MipMap: 0
|
||||||
|
m_GenerateMips: 1
|
||||||
|
m_SRGB: 0
|
||||||
|
m_UseDynamicScale: 0
|
||||||
|
m_UseDynamicScaleExplicit: 0
|
||||||
|
m_BindMS: 0
|
||||||
|
m_EnableCompatibleFormat: 1
|
||||||
|
m_EnableRandomWrite: 0
|
||||||
|
m_TextureSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_FilterMode: 1
|
||||||
|
m_Aniso: 0
|
||||||
|
m_MipBias: 0
|
||||||
|
m_WrapU: 1
|
||||||
|
m_WrapV: 1
|
||||||
|
m_WrapW: 1
|
||||||
|
m_Dimension: 2
|
||||||
|
m_VolumeDepth: 1
|
||||||
|
m_ShadowSamplingMode: 2
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 00ba58b6f31d046c1849805f2cb9a57d
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 8400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -129,7 +129,6 @@ GameObject:
|
|||||||
m_Component:
|
m_Component:
|
||||||
- component: {fileID: 82022335}
|
- component: {fileID: 82022335}
|
||||||
- component: {fileID: 82022334}
|
- component: {fileID: 82022334}
|
||||||
- component: {fileID: 82022333}
|
|
||||||
- component: {fileID: 82022332}
|
- component: {fileID: 82022332}
|
||||||
m_Layer: 0
|
m_Layer: 0
|
||||||
m_Name: UI Camera
|
m_Name: UI Camera
|
||||||
@@ -182,14 +181,6 @@ MonoBehaviour:
|
|||||||
m_VarianceClampScale: 0.9
|
m_VarianceClampScale: 0.9
|
||||||
m_ContrastAdaptiveSharpening: 0
|
m_ContrastAdaptiveSharpening: 0
|
||||||
m_Version: 2
|
m_Version: 2
|
||||||
--- !u!81 &82022333
|
|
||||||
AudioListener:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 82022331}
|
|
||||||
m_Enabled: 1
|
|
||||||
--- !u!20 &82022334
|
--- !u!20 &82022334
|
||||||
Camera:
|
Camera:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -281,12 +272,12 @@ Transform:
|
|||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 147402014}
|
m_GameObject: {fileID: 147402014}
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
m_LocalPosition: {x: 16.30939, y: 8.32207, z: 0}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 1050564725}
|
m_Father: {fileID: 274737044}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!114 &147402016
|
--- !u!114 &147402016
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
@@ -301,6 +292,39 @@ MonoBehaviour:
|
|||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier: Services.Inputs::Darkmatter.Services.Inputs.InputServiceModule
|
m_EditorClassIdentifier: Services.Inputs::Darkmatter.Services.Inputs.InputServiceModule
|
||||||
inputReaderSO: {fileID: 11400000, guid: f9b7ed848ae3b4036923bbbb2f77fe40, type: 2}
|
inputReaderSO: {fileID: 11400000, guid: f9b7ed848ae3b4036923bbbb2f77fe40, type: 2}
|
||||||
|
--- !u!1 &274737043
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 274737044}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: ServiceModule
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &274737044
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 274737043}
|
||||||
|
serializedVersion: 2
|
||||||
|
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_ConstrainProportionsScale: 0
|
||||||
|
m_Children:
|
||||||
|
- {fileID: 292698384}
|
||||||
|
- {fileID: 147402015}
|
||||||
|
m_Father: {fileID: 329578012}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &292698383
|
--- !u!1 &292698383
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -326,12 +350,12 @@ Transform:
|
|||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 292698383}
|
m_GameObject: {fileID: 292698383}
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
m_LocalPosition: {x: 16.30939, y: 8.32207, z: 0}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 1050564725}
|
m_Father: {fileID: 274737044}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!114 &292698385
|
--- !u!114 &292698385
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
@@ -347,6 +371,58 @@ MonoBehaviour:
|
|||||||
m_EditorClassIdentifier: Services.Camera::Darkmatter.Services.Camera.Installers.CameraServiceModule
|
m_EditorClassIdentifier: Services.Camera::Darkmatter.Services.Camera.Installers.CameraServiceModule
|
||||||
mainCamera: {fileID: 519420031}
|
mainCamera: {fileID: 519420031}
|
||||||
uiCamera: {fileID: 82022334}
|
uiCamera: {fileID: 82022334}
|
||||||
|
--- !u!1 &329578011
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 329578012}
|
||||||
|
- component: {fileID: 329578013}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: GameLifetimeScope
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &329578012
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 329578011}
|
||||||
|
serializedVersion: 2
|
||||||
|
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_ConstrainProportionsScale: 0
|
||||||
|
m_Children:
|
||||||
|
- {fileID: 274737044}
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!114 &329578013
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 329578011}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 4ca410c053f074e1cba2f7041f500d34, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier: Darkmatter.App::GameLifetimeScope
|
||||||
|
parentReference:
|
||||||
|
TypeName:
|
||||||
|
autoRun: 1
|
||||||
|
autoInjectGameObjects: []
|
||||||
|
serviceModules:
|
||||||
|
- {fileID: 292698385}
|
||||||
|
- {fileID: 147402016}
|
||||||
--- !u!1 &519420028
|
--- !u!1 &519420028
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -458,7 +534,7 @@ Camera:
|
|||||||
m_Depth: -1
|
m_Depth: -1
|
||||||
m_CullingMask:
|
m_CullingMask:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_Bits: 23
|
m_Bits: 0
|
||||||
m_RenderingPath: -1
|
m_RenderingPath: -1
|
||||||
m_TargetTexture: {fileID: 0}
|
m_TargetTexture: {fileID: 0}
|
||||||
m_TargetDisplay: 0
|
m_TargetDisplay: 0
|
||||||
@@ -485,90 +561,6 @@ Transform:
|
|||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &619394800
|
|
||||||
GameObject:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
serializedVersion: 6
|
|
||||||
m_Component:
|
|
||||||
- component: {fileID: 619394802}
|
|
||||||
- component: {fileID: 619394801}
|
|
||||||
m_Layer: 0
|
|
||||||
m_Name: Global Light 2D
|
|
||||||
m_TagString: Untagged
|
|
||||||
m_Icon: {fileID: 0}
|
|
||||||
m_NavMeshLayer: 0
|
|
||||||
m_StaticEditorFlags: 0
|
|
||||||
m_IsActive: 1
|
|
||||||
--- !u!114 &619394801
|
|
||||||
MonoBehaviour:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 619394800}
|
|
||||||
m_Enabled: 1
|
|
||||||
m_EditorHideFlags: 0
|
|
||||||
m_Script: {fileID: 11500000, guid: 073797afb82c5a1438f328866b10b3f0, type: 3}
|
|
||||||
m_Name:
|
|
||||||
m_EditorClassIdentifier:
|
|
||||||
m_ComponentVersion: 2
|
|
||||||
m_LightType: 4
|
|
||||||
m_BlendStyleIndex: 0
|
|
||||||
m_FalloffIntensity: 0.5
|
|
||||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
|
||||||
m_Intensity: 1
|
|
||||||
m_LightVolumeIntensity: 1
|
|
||||||
m_LightVolumeEnabled: 0
|
|
||||||
m_ApplyToSortingLayers: 00000000
|
|
||||||
m_LightCookieSprite: {fileID: 0}
|
|
||||||
m_DeprecatedPointLightCookieSprite: {fileID: 0}
|
|
||||||
m_LightOrder: 0
|
|
||||||
m_AlphaBlendOnOverlap: 0
|
|
||||||
m_OverlapOperation: 0
|
|
||||||
m_NormalMapDistance: 3
|
|
||||||
m_NormalMapQuality: 2
|
|
||||||
m_UseNormalMap: 0
|
|
||||||
m_ShadowsEnabled: 0
|
|
||||||
m_ShadowIntensity: 0.75
|
|
||||||
m_ShadowSoftness: 0
|
|
||||||
m_ShadowSoftnessFalloffIntensity: 0.5
|
|
||||||
m_ShadowVolumeIntensityEnabled: 0
|
|
||||||
m_ShadowVolumeIntensity: 0.75
|
|
||||||
m_LocalBounds:
|
|
||||||
m_Center: {x: 0, y: -0.00000011920929, z: 0}
|
|
||||||
m_Extent: {x: 0.9985302, y: 0.99853027, z: 0}
|
|
||||||
m_PointLightInnerAngle: 360
|
|
||||||
m_PointLightOuterAngle: 360
|
|
||||||
m_PointLightInnerRadius: 0
|
|
||||||
m_PointLightOuterRadius: 1
|
|
||||||
m_ShapeLightParametricSides: 5
|
|
||||||
m_ShapeLightParametricAngleOffset: 0
|
|
||||||
m_ShapeLightParametricRadius: 1
|
|
||||||
m_ShapeLightFalloffSize: 0.5
|
|
||||||
m_ShapeLightFalloffOffset: {x: 0, y: 0}
|
|
||||||
m_ShapePath:
|
|
||||||
- {x: -0.5, y: -0.5, z: 0}
|
|
||||||
- {x: 0.5, y: -0.5, z: 0}
|
|
||||||
- {x: 0.5, y: 0.5, z: 0}
|
|
||||||
- {x: -0.5, y: 0.5, z: 0}
|
|
||||||
--- !u!4 &619394802
|
|
||||||
Transform:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 619394800}
|
|
||||||
serializedVersion: 2
|
|
||||||
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_ConstrainProportionsScale: 0
|
|
||||||
m_Children: []
|
|
||||||
m_Father: {fileID: 0}
|
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
|
||||||
--- !u!1 &1050564724
|
--- !u!1 &1050564724
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -597,9 +589,7 @@ Transform:
|
|||||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children: []
|
||||||
- {fileID: 292698384}
|
|
||||||
- {fileID: 147402015}
|
|
||||||
m_Father: {fileID: 1798580248}
|
m_Father: {fileID: 1798580248}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &1798580247
|
--- !u!1 &1798580247
|
||||||
@@ -651,14 +641,12 @@ MonoBehaviour:
|
|||||||
TypeName:
|
TypeName:
|
||||||
autoRun: 1
|
autoRun: 1
|
||||||
autoInjectGameObjects: []
|
autoInjectGameObjects: []
|
||||||
serviceModules:
|
serviceModules: []
|
||||||
- {fileID: 147402016}
|
|
||||||
- {fileID: 292698385}
|
|
||||||
--- !u!1660057539 &9223372036854775807
|
--- !u!1660057539 &9223372036854775807
|
||||||
SceneRoots:
|
SceneRoots:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
m_Roots:
|
m_Roots:
|
||||||
- {fileID: 519420032}
|
- {fileID: 519420032}
|
||||||
- {fileID: 82022335}
|
- {fileID: 82022335}
|
||||||
- {fileID: 619394802}
|
|
||||||
- {fileID: 1798580248}
|
- {fileID: 1798580248}
|
||||||
|
- {fileID: 329578012}
|
||||||
|
|||||||
339
Assets/Darkmatter/Scenes/GamePlay.unity
Normal file
339
Assets/Darkmatter/Scenes/GamePlay.unity
Normal file
@@ -0,0 +1,339 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!29 &1
|
||||||
|
OcclusionCullingSettings:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
serializedVersion: 2
|
||||||
|
m_OcclusionBakeSettings:
|
||||||
|
smallestOccluder: 5
|
||||||
|
smallestHole: 0.25
|
||||||
|
backfaceThreshold: 100
|
||||||
|
m_SceneGUID: 00000000000000000000000000000000
|
||||||
|
m_OcclusionCullingData: {fileID: 0}
|
||||||
|
--- !u!104 &2
|
||||||
|
RenderSettings:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
serializedVersion: 10
|
||||||
|
m_Fog: 0
|
||||||
|
m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
|
||||||
|
m_FogMode: 3
|
||||||
|
m_FogDensity: 0.01
|
||||||
|
m_LinearFogStart: 0
|
||||||
|
m_LinearFogEnd: 300
|
||||||
|
m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
|
||||||
|
m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
|
||||||
|
m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
|
||||||
|
m_AmbientIntensity: 1
|
||||||
|
m_AmbientMode: 3
|
||||||
|
m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
|
||||||
|
m_SkyboxMaterial: {fileID: 0}
|
||||||
|
m_HaloStrength: 0.5
|
||||||
|
m_FlareStrength: 1
|
||||||
|
m_FlareFadeSpeed: 3
|
||||||
|
m_HaloTexture: {fileID: 0}
|
||||||
|
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
|
||||||
|
m_DefaultReflectionMode: 0
|
||||||
|
m_DefaultReflectionResolution: 128
|
||||||
|
m_ReflectionBounces: 1
|
||||||
|
m_ReflectionIntensity: 1
|
||||||
|
m_CustomReflection: {fileID: 0}
|
||||||
|
m_Sun: {fileID: 0}
|
||||||
|
m_UseRadianceAmbientProbe: 0
|
||||||
|
--- !u!157 &3
|
||||||
|
LightmapSettings:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
serializedVersion: 13
|
||||||
|
m_BakeOnSceneLoad: 0
|
||||||
|
m_GISettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_BounceScale: 1
|
||||||
|
m_IndirectOutputScale: 1
|
||||||
|
m_AlbedoBoost: 1
|
||||||
|
m_EnvironmentLightingMode: 0
|
||||||
|
m_EnableBakedLightmaps: 0
|
||||||
|
m_EnableRealtimeLightmaps: 0
|
||||||
|
m_LightmapEditorSettings:
|
||||||
|
serializedVersion: 12
|
||||||
|
m_Resolution: 2
|
||||||
|
m_BakeResolution: 40
|
||||||
|
m_AtlasSize: 1024
|
||||||
|
m_AO: 0
|
||||||
|
m_AOMaxDistance: 1
|
||||||
|
m_CompAOExponent: 1
|
||||||
|
m_CompAOExponentDirect: 0
|
||||||
|
m_ExtractAmbientOcclusion: 0
|
||||||
|
m_Padding: 2
|
||||||
|
m_LightmapParameters: {fileID: 0}
|
||||||
|
m_LightmapsBakeMode: 1
|
||||||
|
m_TextureCompression: 1
|
||||||
|
m_ReflectionCompression: 2
|
||||||
|
m_MixedBakeMode: 2
|
||||||
|
m_BakeBackend: 2
|
||||||
|
m_PVRSampling: 1
|
||||||
|
m_PVRDirectSampleCount: 32
|
||||||
|
m_PVRSampleCount: 512
|
||||||
|
m_PVRBounces: 2
|
||||||
|
m_PVREnvironmentSampleCount: 256
|
||||||
|
m_PVREnvironmentReferencePointCount: 2048
|
||||||
|
m_PVRFilteringMode: 1
|
||||||
|
m_PVRDenoiserTypeDirect: 1
|
||||||
|
m_PVRDenoiserTypeIndirect: 1
|
||||||
|
m_PVRDenoiserTypeAO: 1
|
||||||
|
m_PVRFilterTypeDirect: 0
|
||||||
|
m_PVRFilterTypeIndirect: 0
|
||||||
|
m_PVRFilterTypeAO: 0
|
||||||
|
m_PVREnvironmentMIS: 1
|
||||||
|
m_PVRCulling: 1
|
||||||
|
m_PVRFilteringGaussRadiusDirect: 1
|
||||||
|
m_PVRFilteringGaussRadiusIndirect: 1
|
||||||
|
m_PVRFilteringGaussRadiusAO: 1
|
||||||
|
m_PVRFilteringAtrousPositionSigmaDirect: 0.5
|
||||||
|
m_PVRFilteringAtrousPositionSigmaIndirect: 2
|
||||||
|
m_PVRFilteringAtrousPositionSigmaAO: 1
|
||||||
|
m_ExportTrainingData: 0
|
||||||
|
m_TrainingDataDestination: TrainingData
|
||||||
|
m_LightProbeSampleCountMultiplier: 4
|
||||||
|
m_LightingDataAsset: {fileID: 20201, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
|
m_LightingSettings: {fileID: 0}
|
||||||
|
--- !u!196 &4
|
||||||
|
NavMeshSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_BuildSettings:
|
||||||
|
serializedVersion: 3
|
||||||
|
agentTypeID: 0
|
||||||
|
agentRadius: 0.5
|
||||||
|
agentHeight: 2
|
||||||
|
agentSlope: 45
|
||||||
|
agentClimb: 0.4
|
||||||
|
ledgeDropHeight: 0
|
||||||
|
maxJumpAcrossDistance: 0
|
||||||
|
minRegionArea: 2
|
||||||
|
manualCellSize: 0
|
||||||
|
cellSize: 0.16666667
|
||||||
|
manualTileSize: 0
|
||||||
|
tileSize: 256
|
||||||
|
buildHeightMesh: 0
|
||||||
|
maxJobWorkers: 0
|
||||||
|
preserveTilesOutsideBounds: 0
|
||||||
|
debug:
|
||||||
|
m_Flags: 0
|
||||||
|
m_NavMeshData: {fileID: 0}
|
||||||
|
--- !u!1 &619394800
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 619394802}
|
||||||
|
- component: {fileID: 619394801}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: Global Light 2D
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!114 &619394801
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 619394800}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: 073797afb82c5a1438f328866b10b3f0, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
m_ComponentVersion: 2
|
||||||
|
m_LightType: 4
|
||||||
|
m_BlendStyleIndex: 0
|
||||||
|
m_FalloffIntensity: 0.5
|
||||||
|
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
m_Intensity: 1
|
||||||
|
m_LightVolumeIntensity: 1
|
||||||
|
m_LightVolumeEnabled: 0
|
||||||
|
m_ApplyToSortingLayers: 00000000
|
||||||
|
m_LightCookieSprite: {fileID: 0}
|
||||||
|
m_DeprecatedPointLightCookieSprite: {fileID: 0}
|
||||||
|
m_LightOrder: 0
|
||||||
|
m_AlphaBlendOnOverlap: 0
|
||||||
|
m_OverlapOperation: 0
|
||||||
|
m_NormalMapDistance: 3
|
||||||
|
m_NormalMapQuality: 2
|
||||||
|
m_UseNormalMap: 0
|
||||||
|
m_ShadowsEnabled: 0
|
||||||
|
m_ShadowIntensity: 0.75
|
||||||
|
m_ShadowSoftness: 0
|
||||||
|
m_ShadowSoftnessFalloffIntensity: 0.5
|
||||||
|
m_ShadowVolumeIntensityEnabled: 0
|
||||||
|
m_ShadowVolumeIntensity: 0.75
|
||||||
|
m_LocalBounds:
|
||||||
|
m_Center: {x: 0, y: -0.00000011920929, z: 0}
|
||||||
|
m_Extent: {x: 0.9985302, y: 0.99853027, z: 0}
|
||||||
|
m_PointLightInnerAngle: 360
|
||||||
|
m_PointLightOuterAngle: 360
|
||||||
|
m_PointLightInnerRadius: 0
|
||||||
|
m_PointLightOuterRadius: 1
|
||||||
|
m_ShapeLightParametricSides: 5
|
||||||
|
m_ShapeLightParametricAngleOffset: 0
|
||||||
|
m_ShapeLightParametricRadius: 1
|
||||||
|
m_ShapeLightFalloffSize: 0.5
|
||||||
|
m_ShapeLightFalloffOffset: {x: 0, y: 0}
|
||||||
|
m_ShapePath:
|
||||||
|
- {x: -0.5, y: -0.5, z: 0}
|
||||||
|
- {x: 0.5, y: -0.5, z: 0}
|
||||||
|
- {x: 0.5, y: 0.5, z: 0}
|
||||||
|
- {x: -0.5, y: 0.5, z: 0}
|
||||||
|
--- !u!4 &619394802
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 619394800}
|
||||||
|
serializedVersion: 2
|
||||||
|
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_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!1 &942391588
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 942391592}
|
||||||
|
- component: {fileID: 942391591}
|
||||||
|
- component: {fileID: 942391589}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: ArtCamera
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!114 &942391589
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 942391588}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: a79441f348de89743a2939f4d699eac1, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier: Unity.RenderPipelines.Universal.Runtime::UnityEngine.Rendering.Universal.UniversalAdditionalCameraData
|
||||||
|
m_RenderShadows: 1
|
||||||
|
m_RequiresDepthTextureOption: 2
|
||||||
|
m_RequiresOpaqueTextureOption: 2
|
||||||
|
m_CameraType: 0
|
||||||
|
m_Cameras: []
|
||||||
|
m_RendererIndex: -1
|
||||||
|
m_VolumeLayerMask:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 1
|
||||||
|
m_VolumeTrigger: {fileID: 0}
|
||||||
|
m_VolumeFrameworkUpdateModeOption: 2
|
||||||
|
m_RenderPostProcessing: 0
|
||||||
|
m_Antialiasing: 0
|
||||||
|
m_AntialiasingQuality: 2
|
||||||
|
m_StopNaN: 0
|
||||||
|
m_Dithering: 0
|
||||||
|
m_ClearDepth: 1
|
||||||
|
m_AllowXRRendering: 1
|
||||||
|
m_AllowHDROutput: 1
|
||||||
|
m_UseScreenCoordOverride: 0
|
||||||
|
m_ScreenSizeOverride: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_ScreenCoordScaleBias: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
m_RequiresDepthTexture: 0
|
||||||
|
m_RequiresColorTexture: 0
|
||||||
|
m_TaaSettings:
|
||||||
|
m_Quality: 3
|
||||||
|
m_FrameInfluence: 0.1
|
||||||
|
m_JitterScale: 1
|
||||||
|
m_MipBias: 0
|
||||||
|
m_VarianceClampScale: 0.9
|
||||||
|
m_ContrastAdaptiveSharpening: 0
|
||||||
|
m_Version: 2
|
||||||
|
--- !u!20 &942391591
|
||||||
|
Camera:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 942391588}
|
||||||
|
m_Enabled: 1
|
||||||
|
serializedVersion: 2
|
||||||
|
m_ClearFlags: 1
|
||||||
|
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0}
|
||||||
|
m_projectionMatrixMode: 1
|
||||||
|
m_GateFitMode: 2
|
||||||
|
m_FOVAxisMode: 0
|
||||||
|
m_Iso: 200
|
||||||
|
m_ShutterSpeed: 0.005
|
||||||
|
m_Aperture: 16
|
||||||
|
m_FocusDistance: 10
|
||||||
|
m_FocalLength: 50
|
||||||
|
m_BladeCount: 5
|
||||||
|
m_Curvature: {x: 2, y: 11}
|
||||||
|
m_BarrelClipping: 0.25
|
||||||
|
m_Anamorphism: 0
|
||||||
|
m_SensorSize: {x: 36, y: 24}
|
||||||
|
m_LensShift: {x: 0, y: 0}
|
||||||
|
m_NormalizedViewPortRect:
|
||||||
|
serializedVersion: 2
|
||||||
|
x: 0
|
||||||
|
y: 0
|
||||||
|
width: 1
|
||||||
|
height: 1
|
||||||
|
near clip plane: 0.3
|
||||||
|
far clip plane: 1000
|
||||||
|
field of view: 60
|
||||||
|
orthographic: 1
|
||||||
|
orthographic size: 5
|
||||||
|
m_Depth: 0
|
||||||
|
m_CullingMask:
|
||||||
|
serializedVersion: 2
|
||||||
|
m_Bits: 23
|
||||||
|
m_RenderingPath: -1
|
||||||
|
m_TargetTexture: {fileID: 8400000, guid: 00ba58b6f31d046c1849805f2cb9a57d, type: 2}
|
||||||
|
m_TargetDisplay: 0
|
||||||
|
m_TargetEye: 3
|
||||||
|
m_HDR: 1
|
||||||
|
m_AllowMSAA: 1
|
||||||
|
m_AllowDynamicResolution: 0
|
||||||
|
m_ForceIntoRT: 0
|
||||||
|
m_OcclusionCulling: 1
|
||||||
|
m_StereoConvergence: 10
|
||||||
|
m_StereoSeparation: 0.022
|
||||||
|
--- !u!4 &942391592
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 942391588}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 0, y: 0, z: -10}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!1660057539 &9223372036854775807
|
||||||
|
SceneRoots:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_Roots:
|
||||||
|
- {fileID: 619394802}
|
||||||
|
- {fileID: 942391592}
|
||||||
7
Assets/Darkmatter/Scenes/GamePlay.unity.meta
Normal file
7
Assets/Darkmatter/Scenes/GamePlay.unity.meta
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e5f73f24e812e4a98b4c17d533fd3d6d
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
57
Readme.md
57
Readme.md
@@ -88,6 +88,9 @@ Assets/Darkmatter/Code/
|
|||||||
│ ├── Coloring/
|
│ ├── Coloring/
|
||||||
│ │ ├── IColorPalette.cs
|
│ │ ├── IColorPalette.cs
|
||||||
│ │ └── PaintCommandDTO.cs
|
│ │ └── PaintCommandDTO.cs
|
||||||
|
│ ├── Paper/ (shared art rig — RT-as-paper)
|
||||||
|
│ │ ├── IPaperRig.cs
|
||||||
|
│ │ └── IArtInputBridge.cs
|
||||||
│ ├── History/
|
│ ├── History/
|
||||||
│ │ ├── ICommand.cs
|
│ │ ├── ICommand.cs
|
||||||
│ │ └── IUndoStack.cs
|
│ │ └── IUndoStack.cs
|
||||||
@@ -122,6 +125,7 @@ Assets/Darkmatter/Code/
|
|||||||
└── Features/
|
└── Features/
|
||||||
├── MainMenu/
|
├── MainMenu/
|
||||||
├── DrawingCatalog/
|
├── DrawingCatalog/
|
||||||
|
├── Paper/ (RT paper rig — ArtCamera + RenderTexture + input bridge)
|
||||||
├── ShapeBuilder/
|
├── ShapeBuilder/
|
||||||
├── Coloring/
|
├── Coloring/
|
||||||
├── History/
|
├── History/
|
||||||
@@ -209,33 +213,60 @@ Failures show a child-friendly retry screen; never crash.
|
|||||||
|
|
||||||
## 7. Rendering Strategy
|
## 7. Rendering Strategy
|
||||||
|
|
||||||
Hybrid: **Sprites for artwork, Canvas for HUD**.
|
**RT-as-paper.** ArtCamera renders the drawing world to an offscreen `RenderTexture`. A Canvas `RawImage` displays that RT. HUD lives on the same Canvas, above the RawImage. The RT *is* the paper — same fixed coordinate system on every device.
|
||||||
|
|
||||||
|
```
|
||||||
|
┌──────────────────────────────────────────────────────┐
|
||||||
|
│ UICanvas (Screen-Space - Camera, UICamera) │
|
||||||
|
│ │
|
||||||
|
│ ┌────────────────────────────────────┐ │
|
||||||
|
│ │ RawImage (AspectRatioFitter 1:1) │ [HUD] │
|
||||||
|
│ │ └─ texture = PaperRig.Surface │ palette │
|
||||||
|
│ │ │ undo etc │
|
||||||
|
│ │ ArtCamera renders → here │ │
|
||||||
|
│ └────────────────────────────────────┘ │
|
||||||
|
│ │
|
||||||
|
└──────────────────────────────────────────────────────┘
|
||||||
|
▲
|
||||||
|
│ rendered offscreen
|
||||||
|
│
|
||||||
|
ArtCamera (orthographicSize fixed, aspect = 1f)
|
||||||
|
culling mask: Artwork, PaperBackground, Effects
|
||||||
|
target texture: PaperRig.Surface (2048×2048 ARGB32)
|
||||||
|
```
|
||||||
|
|
||||||
### Cameras
|
### Cameras
|
||||||
|
|
||||||
| Camera | Type | Culling Mask | Purpose |
|
| Camera | Type | Culling Mask | Render Target | Purpose |
|
||||||
|---|---|---|---|
|
|---|---|---|---|---|
|
||||||
| `ArtCamera` | Orthographic | `Artwork`, `PaperBackground` | Renders the drawing only. Source for capture. |
|
| `ArtCamera` | Orthographic, **fixed ortho size**, aspect = 1 | `Artwork`, `PaperBackground`, `Effects` | `PaperRig.Surface` (offscreen RT) | Renders the drawing world. Never sees the screen. |
|
||||||
| `UICamera` | Overlay (or screen-space) | `UI` | HUD canvas, palette, buttons. |
|
| `UICamera` | Camera (Screen-Space – Camera) | `UI` | Screen | Displays the paper RawImage + HUD. |
|
||||||
|
|
||||||
### Layers
|
### Layers
|
||||||
|
|
||||||
| Layer | Used by |
|
| Layer | Used by |
|
||||||
|---|---|
|
|---|---|
|
||||||
| `Artwork` | Drawing region sprites, shape pieces, paper bg |
|
| `Artwork` | Drawing region sprites, shape pieces, paper bg, all in ArtCamera world |
|
||||||
| `UI` | All Canvas elements |
|
| `Effects` | Particle bursts, sparkles — also in ArtCamera world (so they're captured into the PNG) |
|
||||||
| `Effects` | Particle bursts, sparkles on completion |
|
| `UI` | All Canvas elements (RawImage paper + HUD) |
|
||||||
|
|
||||||
### Why hybrid
|
### Why RT-as-paper
|
||||||
|
|
||||||
| Need | Choice | Why |
|
| Need | Choice | Why |
|
||||||
|---|---|---|
|
|---|---|---|
|
||||||
| Per-region tap-to-fill | Sprites + `PolygonCollider2D` | Clean `Physics2D.OverlapPoint`; deterministic; no shader work for the toddler region count (5–20). |
|
| Per-region tap-to-fill | Sprites + `PolygonCollider2D` in ArtCamera world; tapped via `IArtInputBridge` | Coordinate system is fixed (RT space). One `Physics2D.OverlapPoint` call after screen→art-world conversion. |
|
||||||
| Drag/drop shape pieces | Sprites + Physics2D | Natural world bounds, easy snap distance checks. |
|
| Drag/drop shape pieces | Sprites + Physics2D in art world | Same fixed bounds on every device — no per-aspect tray layout. |
|
||||||
| Capture to PNG with paper bg | Sprites under dedicated Camera | `RenderTexture` from `ArtCamera` excludes HUD automatically. |
|
| Capture to PNG | `RT → Texture2D → PNG` | The RT *is* the saved image. No camera state override, no compositing pass, no determinism worries. |
|
||||||
| Color palette, buttons | Canvas | Anchors handle aspect ratios. Buttons + ScrollRect free. |
|
| Multi-resolution support | `AspectRatioFitter (1:1, FitInParent)` on the RawImage | The "fit camera" problem reduces to a single Canvas property. Letterbox/pillarbox = whatever the Canvas around the RawImage looks like. |
|
||||||
|
| Color palette, buttons | Canvas above the RawImage | Anchors handle aspect ratios. Buttons + ScrollRect free. |
|
||||||
| Drawing catalog grid | Canvas | `GridLayoutGroup` + ScrollRect, async thumbnail loader. |
|
| Drawing catalog grid | Canvas | `GridLayoutGroup` + ScrollRect, async thumbnail loader. |
|
||||||
|
|
||||||
|
### Multi-resolution rule
|
||||||
|
|
||||||
|
The artwork world is **screen-size-independent by construction.** Author every drawing in a fixed 2048×2048 design rect (or 20×20 world units at PPU=100). Pieces, regions, snap radii, slot positions — all expressed in this space and never scaled at runtime. Different screen sizes only change how the *RawImage* is laid out on the Canvas; the contents of the RT stay identical.
|
||||||
|
|
||||||
|
If you need a backdrop (wood/cloth behind the paper), it's a sibling Canvas Image *outside* the RawImage, sized to fill the screen. The RT itself has a transparent or paper-colored background.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## 8. Core Contracts
|
## 8. Core Contracts
|
||||||
|
|||||||
Reference in New Issue
Block a user