Essentials + extra crap
Loadings Startups Movement Camera
This commit is contained in:
1 parent
662f4a1d05
commit
5f5ace1b52
734 files changed
+107316
-1706
No files matched your search
Generated
+6
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
+228
-13
@@ -4,12 +4,161 @@
|
|||||||
<option name="autoReloadType" value="SELECTIVE" />
|
<option name="autoReloadType" value="SELECTIVE" />
|
||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="ed1a3c4f-83ac-4211-ae32-004a26afd5d8" name="Changes" comment="" />
|
<list default="true" id="ed1a3c4f-83ac-4211-ae32-004a26afd5d8" name="Changes" comment="">
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Character.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Character/LiminalCharacterController.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Character/LiminalCharacterController.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Player.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Player/PlayerAnimator.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Player/PlayerAnimator.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Player/PlayerFactory.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Player/PlayerFactory.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Player/PlayerMovementController.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Example/Liminal/Player/PlayerMovementController.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/AppStateMachine.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/AppStateMachine.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/PapaInstaller.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/PapaInstaller.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/SceneInstallers.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/SceneInstallers/GameplaySceneInstaller.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/SceneInstallers/GameplaySceneInstaller.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/SceneInstallers/MainMenuSceneInstaller.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/SceneInstallers/MainMenuSceneInstaller.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/States.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/States/BootstrapState.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/States/BootstrapState.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/States/GameplayState.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/States/GameplayState.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/States/MainMenuState.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/App/States/MainMenuState.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraFactory.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraFactory.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraSettings.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraSettings.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStateMachine.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStateMachine.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStateMachineRunner.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStateMachineRunner.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStates.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStates/BaseCameraState.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStates/BaseCameraState.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStates/FirstPersonCameraState.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStates/FirstPersonCameraState.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStates/NoneCameraState.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Camera/CameraStates/NoneCameraState.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Configs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Configs/ConfigLocator.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Configs/ConfigLocator.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Configs/SystemConfigsReferences.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Configs/SystemConfigsReferences.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/ConfigGenerator.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/ConfigGenerator.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/SceneLoaderGenerator.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/SceneLoaderGenerator.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Input.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Input/ActionMappings.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Input/ActionMappings.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Input/IInputService.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Input/IInputService.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Input/InputService.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Input/InputService.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Loadings.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Loadings/Loading.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Loadings/Loading.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/SceneLoader.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/SceneLoader/SceneId.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/SceneLoader/SceneId.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/SceneLoader/SceneLoader.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/SceneLoader/SceneLoader.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/SceneLoader/ScenesAssetReferences.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/SceneLoader/ScenesAssetReferences.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/StateMachine/AbstractStateMachine.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/StateMachine/BaseState.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/Code.Infrastructure.Camera.CameraStateMachine.Generated.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/Code.Infrastructure.Camera.CameraStateMachine.Generated.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/DebugClassConfig.Generated.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/DebugClassConfig.Generated.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/IConfigLocator.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/IConfigLocator.cs.meta" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/SceneInfoConfig.Generated.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/SceneInfoConfig.Generated.cs.meta" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/.idea.Infratest/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/.idea.Infratest/.idea/workspace.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug/DebugInstaller.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug/DebugInstaller.cs.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug/DebugStateMachine.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug/DebugStateMachine.cs.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug/States.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug/States/FirstState.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Debug/States/FirstState.cs.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Generators.meta" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators.meta" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Generators/Attributes.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/Attributes.cs" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Generators/Attributes.cs.meta" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/Attributes.cs.meta" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Generators/StateMachineGenerator.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/StateMachineGenerator.cs" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/Generators/StateMachineGenerator.cs.meta" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/Generators/StateMachineGenerator.cs.meta" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/StateMachine.meta" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/StateMachine.meta" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/StateMachine/AbstractStateMachine.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/StateMachine/AbstractStateMachine.cs.meta" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/StateMachine/AbstractStateMachine.cs.meta" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/StateMachine/BaseState.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Code/StateMachine/BaseState.cs.meta" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Code/Infrastructure/StateMachine/BaseState.cs.meta" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/InputSystem_Actions.inputactions" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/InputSystem_Actions.inputactions" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Readme.asset" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Readme.asset.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Scenes/SampleScene.unity" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Scenes/SampleScene.unity.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/Settings/Mobile_RPAsset.asset" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Settings/Mobile_RPAsset.asset" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Icons.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Icons/URP.png" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Icons/URP.png.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Layout.wlt" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Layout.wlt.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Scripts.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Scripts/Editor.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Scripts/Editor/ReadmeEditor.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Scripts/Editor/ReadmeEditor.cs.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Scripts/Readme.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/TutorialInfo/Scripts/Readme.cs.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/Code.Debug.DebugStateMachine.Generated.cs" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Assets/UnityCodeGen.Generated/Code.Debug.DebugStateMachine.Generated.cs.meta" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Packages/manifest.json" beforeDir="false" afterPath="$PROJECT_DIR$/Packages/manifest.json" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Packages/packages-lock.json" beforeDir="false" afterPath="$PROJECT_DIR$/Packages/packages-lock.json" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/ProjectSettings/EditorBuildSettings.asset" beforeDir="false" afterPath="$PROJECT_DIR$/ProjectSettings/EditorBuildSettings.asset" afterDir="false" />
|
||||||
|
</list>
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||||
</component>
|
</component>
|
||||||
|
<component name="DpaMonitoringSettings">
|
||||||
|
<option name="autoShow" value="false" />
|
||||||
|
</component>
|
||||||
|
<component name="Git.Settings">
|
||||||
|
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
||||||
|
</component>
|
||||||
|
<component name="HighlightingSettingsPerFile">
|
||||||
|
<setting file="file://$PROJECT_DIR$/Assets/Code/Infrastructure/Loadings/Loading.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.cysharp.unitask@a85b92a8e443/Runtime/External/Addressables/AddressablesAsyncExtensions.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.cysharp.unitask@a85b92a8e443/Runtime/UniTaskScheduler.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.gustavopsantos.reflex@b77d36a82a21/Core/Container.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.gustavopsantos.reflex@b77d36a82a21/Core/SceneScope.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.gustavopsantos.reflex@b77d36a82a21/Extensions/SceneExtensions.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.gustavopsantos.reflex@b77d36a82a21/Injectors/MethodInjector.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.unity.addressables@45e9abf44299/Runtime/ResourceManager/AsyncOperations/AsyncOperationBase.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.unity.addressables@45e9abf44299/Runtime/ResourceManager/AsyncOperations/AsyncOperationHandle.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.unity.addressables@45e9abf44299/Runtime/ResourceManager/AsyncOperations/ChainOperation.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.unity.addressables@45e9abf44299/Runtime/ResourceManager/Util/DelegateList.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Library/PackageCache/com.unity.addressables@45e9abf44299/Runtime/ResourceManager/Util/MonoBehaviourCallbackHooks.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/DecompilerCache/decompiler/1eb9db207454431c84a47bcd81e79c3746ae00/50/ee0759d6/Dictionary`2.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/DecompilerCache/decompiler/493b407efcb64dddad59f28bb0b831d3212400/1d/b6f4672d/Vector2.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/DecompilerCache/decompiler/493b407efcb64dddad59f28bb0b831d3212400/e6/06b4bbec/Component.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/DecompilerCache/decompiler/6faa6124236442759eb396cfbfdad50810fc00/3f/3a201145/Enumerable.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
</component>
|
||||||
<component name="ProjectColorInfo">{
|
<component name="ProjectColorInfo">{
|
||||||
"customColor": "",
|
"customColor": "",
|
||||||
"associatedIndex": 2
|
"associatedIndex": 2
|
||||||
@@ -19,17 +168,20 @@
|
|||||||
<option name="hideEmptyMiddlePackages" value="true" />
|
<option name="hideEmptyMiddlePackages" value="true" />
|
||||||
<option name="showLibraryContents" value="true" />
|
<option name="showLibraryContents" value="true" />
|
||||||
</component>
|
</component>
|
||||||
<component name="PropertiesComponent">{
|
<component name="PropertiesComponent"><![CDATA[{
|
||||||
"keyToString": {
|
"keyToString": {
|
||||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
"Attach to Unity Editor.Attach to Unity Editor.executor": "Debug",
|
||||||
"node.js.detected.package.eslint": "true",
|
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||||
"node.js.detected.package.tslint": "true",
|
"XThreadsFramesViewSplitterKey": "0.31173185",
|
||||||
"node.js.selected.package.eslint": "(autodetect)",
|
"git-widget-placeholder": "main",
|
||||||
"node.js.selected.package.tslint": "(autodetect)",
|
"node.js.detected.package.eslint": "true",
|
||||||
"nodejs_package_manager_path": "npm",
|
"node.js.detected.package.tslint": "true",
|
||||||
"vue.rearranger.settings.migration": "true"
|
"node.js.selected.package.eslint": "(autodetect)",
|
||||||
|
"node.js.selected.package.tslint": "(autodetect)",
|
||||||
|
"nodejs_package_manager_path": "npm",
|
||||||
|
"vue.rearranger.settings.migration": "true"
|
||||||
}
|
}
|
||||||
}</component>
|
}]]></component>
|
||||||
<component name="RunManager" selected="Attach to Unity Editor.Attach to Unity Editor">
|
<component name="RunManager" selected="Attach to Unity Editor.Attach to Unity Editor">
|
||||||
<configuration name="Start Unity" type="RunUnityExe" factoryName="Unity Executable">
|
<configuration name="Start Unity" type="RunUnityExe" factoryName="Unity Executable">
|
||||||
<option name="EXE_PATH" value="C:\Program Files\Unity\Hub\Editor\6000.3.1f1\Editor\Unity.exe" />
|
<option name="EXE_PATH" value="C:\Program Files\Unity\Hub\Editor\6000.3.1f1\Editor\Unity.exe" />
|
||||||
@@ -57,10 +209,10 @@
|
|||||||
</option>
|
</option>
|
||||||
<method v="2" />
|
<method v="2" />
|
||||||
</configuration>
|
</configuration>
|
||||||
<configuration name="Attach to Unity Editor" type="UNITY_DEBUG_RUN_CONFIGURATION" factoryName="Unity Debug" show_console_on_std_err="false" show_console_on_std_out="false" port="50000" address="localhost">
|
<configuration name="Attach to Unity Editor" type="UNITY_DEBUG_RUN_CONFIGURATION" factoryName="Unity Debug" show_console_on_std_err="false" show_console_on_std_out="false" port="50000" address="localhost" ignored-value-for-modified-check="3060">
|
||||||
<option name="allowRunningInParallel" value="false" />
|
<option name="allowRunningInParallel" value="false" />
|
||||||
<option name="listenPortForConnections" value="false" />
|
<option name="listenPortForConnections" value="false" />
|
||||||
<option name="pid" />
|
<option name="pid" value="3060" />
|
||||||
<option name="projectPathOnTarget" />
|
<option name="projectPathOnTarget" />
|
||||||
<option name="selectedOptions">
|
<option name="selectedOptions">
|
||||||
<list />
|
<list />
|
||||||
@@ -79,6 +231,37 @@
|
|||||||
<workItem from="1765484046742" duration="37000" />
|
<workItem from="1765484046742" duration="37000" />
|
||||||
<workItem from="1765563458889" duration="2363000" />
|
<workItem from="1765563458889" duration="2363000" />
|
||||||
<workItem from="1765565856967" duration="4048000" />
|
<workItem from="1765565856967" duration="4048000" />
|
||||||
|
<workItem from="1765571690951" duration="1572000" />
|
||||||
|
<workItem from="1765654445746" duration="7492000" />
|
||||||
|
<workItem from="1765710200508" duration="1720000" />
|
||||||
|
<workItem from="1765739167324" duration="1645000" />
|
||||||
|
<workItem from="1765807248186" duration="146000" />
|
||||||
|
<workItem from="1765819568689" duration="2799000" />
|
||||||
|
<workItem from="1766055969510" duration="1007000" />
|
||||||
|
<workItem from="1766265597174" duration="4285000" />
|
||||||
|
<workItem from="1766315048238" duration="1145000" />
|
||||||
|
<workItem from="1766316233335" duration="2681000" />
|
||||||
|
<workItem from="1766323020628" duration="2888000" />
|
||||||
|
<workItem from="1766346650075" duration="4684000" />
|
||||||
|
<workItem from="1766352222210" duration="2296000" />
|
||||||
|
<workItem from="1766391303487" duration="7968000" />
|
||||||
|
<workItem from="1766423252120" duration="5198000" />
|
||||||
|
<workItem from="1766429681099" duration="2739000" />
|
||||||
|
<workItem from="1766435971449" duration="4383000" />
|
||||||
|
<workItem from="1766482727810" duration="1392000" />
|
||||||
|
<workItem from="1766487044462" duration="3317000" />
|
||||||
|
<workItem from="1766568793481" duration="521000" />
|
||||||
|
<workItem from="1766605302950" duration="7235000" />
|
||||||
|
<workItem from="1766652230493" duration="6495000" />
|
||||||
|
<workItem from="1766682673058" duration="131000" />
|
||||||
|
<workItem from="1767005411118" duration="652000" />
|
||||||
|
<workItem from="1767124896223" duration="3117000" />
|
||||||
|
<workItem from="1767273884512" duration="3710000" />
|
||||||
|
<workItem from="1767289567634" duration="1511000" />
|
||||||
|
<workItem from="1767296452251" duration="6287000" />
|
||||||
|
<workItem from="1767345100869" duration="2686000" />
|
||||||
|
<workItem from="1768124782138" duration="5579000" />
|
||||||
|
<workItem from="1768228201670" duration="4137000" />
|
||||||
</task>
|
</task>
|
||||||
<servers />
|
<servers />
|
||||||
</component>
|
</component>
|
||||||
@@ -95,4 +278,36 @@
|
|||||||
<component name="VcsManagerConfiguration">
|
<component name="VcsManagerConfiguration">
|
||||||
<option name="CLEAR_INITIAL_COMMIT_MESSAGE" value="true" />
|
<option name="CLEAR_INITIAL_COMMIT_MESSAGE" value="true" />
|
||||||
</component>
|
</component>
|
||||||
|
<component name="XDebuggerManager">
|
||||||
|
<breakpoint-manager>
|
||||||
|
<breakpoints>
|
||||||
|
<line-breakpoint enabled="true" type="DotNet Breakpoints">
|
||||||
|
<url>file://$PROJECT_DIR$/Assets/Code/Example/Liminal/Character/LiminalCharacterController.cs</url>
|
||||||
|
<line>239</line>
|
||||||
|
<properties documentPath="A:\Projects\Infratest\Assets\Code\Example\Liminal\Character\LiminalCharacterController.cs" containingFunctionPresentation="Method 'UpdateRotation'">
|
||||||
|
<startOffsets>
|
||||||
|
<option value="8514" />
|
||||||
|
</startOffsets>
|
||||||
|
<endOffsets>
|
||||||
|
<option value="8672" />
|
||||||
|
</endOffsets>
|
||||||
|
</properties>
|
||||||
|
<option name="timeStamp" value="57" />
|
||||||
|
</line-breakpoint>
|
||||||
|
<line-breakpoint enabled="true" type="DotNet Breakpoints">
|
||||||
|
<url>file://$PROJECT_DIR$/Assets/Code/Example/Liminal/Character/LiminalCharacterController.cs</url>
|
||||||
|
<line>245</line>
|
||||||
|
<properties documentPath="A:\Projects\Infratest\Assets\Code\Example\Liminal\Character\LiminalCharacterController.cs" containingFunctionPresentation="Method 'UpdateRotation'">
|
||||||
|
<startOffsets>
|
||||||
|
<option value="8967" />
|
||||||
|
</startOffsets>
|
||||||
|
<endOffsets>
|
||||||
|
<option value="9010" />
|
||||||
|
</endOffsets>
|
||||||
|
</properties>
|
||||||
|
<option name="timeStamp" value="58" />
|
||||||
|
</line-breakpoint>
|
||||||
|
</breakpoints>
|
||||||
|
</breakpoint-manager>
|
||||||
|
</component>
|
||||||
</project>
|
</project>
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: ba062aa6c92b140379dbc06b43dd3b9b
|
guid: 76a37d2969dbaf94bb633f4cea6406a6
|
||||||
folderAsset: yes
|
folderAsset: yes
|
||||||
DefaultImporter:
|
DefaultImporter:
|
||||||
externalObjects: {}
|
externalObjects: {}
|
||||||
@@ -0,0 +1,117 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: 468a46d0ae32c3544b7d98094e6448a9, type: 3}
|
||||||
|
m_Name: AddressableAssetSettings
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Settings.AddressableAssetSettings
|
||||||
|
m_DefaultGroup: d790534e015d692428ac5a9ce7d2ceb6
|
||||||
|
m_currentHash:
|
||||||
|
serializedVersion: 2
|
||||||
|
Hash: 00000000000000000000000000000000
|
||||||
|
m_OptimizeCatalogSize: 0
|
||||||
|
m_BuildRemoteCatalog: 0
|
||||||
|
m_CatalogRequestsTimeout: 0
|
||||||
|
m_DisableCatalogUpdateOnStart: 0
|
||||||
|
m_InternalIdNamingMode: 0
|
||||||
|
m_InternalBundleIdMode: 1
|
||||||
|
m_AssetLoadMode: 0
|
||||||
|
m_BundledAssetProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.BundledAssetProvider
|
||||||
|
m_AssetBundleProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.AssetBundleProvider
|
||||||
|
m_IgnoreUnsupportedFilesInBuild: 0
|
||||||
|
m_UniqueBundleIds: 0
|
||||||
|
m_EnableJsonCatalog: 0
|
||||||
|
m_NonRecursiveBuilding: 1
|
||||||
|
m_AllowNestedBundleFolders: 0
|
||||||
|
m_CCDEnabled: 0
|
||||||
|
m_maxConcurrentWebRequests: 3
|
||||||
|
m_UseUWRForLocalBundles: 0
|
||||||
|
m_BundleTimeout: 0
|
||||||
|
m_BundleRetryCount: 0
|
||||||
|
m_BundleRedirectLimit: -1
|
||||||
|
m_SharedBundleSettings: 0
|
||||||
|
m_SharedBundleSettingsCustomGroupIndex: 0
|
||||||
|
m_ContiguousBundles: 1
|
||||||
|
m_StripUnityVersionFromBundleBuild: 0
|
||||||
|
m_DisableVisibleSubAssetRepresentations: 0
|
||||||
|
m_BuiltInBundleNaming: 0
|
||||||
|
mBuiltInBundleCustomNaming:
|
||||||
|
m_MonoScriptBundleNaming: 0
|
||||||
|
m_CheckForContentUpdateRestrictionsOption: 0
|
||||||
|
m_MonoScriptBundleCustomNaming:
|
||||||
|
m_RemoteCatalogBuildPath:
|
||||||
|
m_Id:
|
||||||
|
m_RemoteCatalogLoadPath:
|
||||||
|
m_Id:
|
||||||
|
m_ContentStateBuildPathProfileVariableName:
|
||||||
|
m_CustomContentStateBuildPath:
|
||||||
|
m_ContentStateBuildPath:
|
||||||
|
m_BuildAddressablesWithPlayerBuild: 0
|
||||||
|
m_overridePlayerVersion: '[UnityEditor.PlayerSettings.bundleVersion]'
|
||||||
|
m_GroupAssets:
|
||||||
|
- {fileID: 11400000, guid: cd5d8f0bccfc1e5489a5c528087c4feb, type: 2}
|
||||||
|
m_BuildSettings:
|
||||||
|
m_LogResourceManagerExceptions: 1
|
||||||
|
m_BundleBuildPath: Temp/com.unity.addressables/AssetBundles
|
||||||
|
m_ProfileSettings:
|
||||||
|
m_Profiles:
|
||||||
|
- m_InheritedParent:
|
||||||
|
m_Id: 4d4a686241dde1e4497a09458afd84bb
|
||||||
|
m_ProfileName: Default
|
||||||
|
m_Values:
|
||||||
|
- m_Id: 0625bc81bb6ebfe4badeca8150066832
|
||||||
|
m_Value: '{UnityEngine.AddressableAssets.Addressables.RuntimePath}/[BuildTarget]'
|
||||||
|
- m_Id: 1bb9adf321c2adb418292ec670ab6046
|
||||||
|
m_Value: <undefined>
|
||||||
|
- m_Id: b355ca0b0b0f746439d7ce9bb4b81fe3
|
||||||
|
m_Value: 'ServerData/[BuildTarget]'
|
||||||
|
- m_Id: c177911d3f5ed754588b22d7ec9ed060
|
||||||
|
m_Value: '[UnityEngine.AddressableAssets.Addressables.BuildPath]/[BuildTarget]'
|
||||||
|
- m_Id: d9deedb924b434d4cb90947cdc187fd0
|
||||||
|
m_Value: '[UnityEditor.EditorUserBuildSettings.activeBuildTarget]'
|
||||||
|
m_ProfileEntryNames:
|
||||||
|
- m_Id: 0625bc81bb6ebfe4badeca8150066832
|
||||||
|
m_Name: Local.LoadPath
|
||||||
|
m_InlineUsage: 0
|
||||||
|
- m_Id: 1bb9adf321c2adb418292ec670ab6046
|
||||||
|
m_Name: Remote.LoadPath
|
||||||
|
m_InlineUsage: 0
|
||||||
|
- m_Id: b355ca0b0b0f746439d7ce9bb4b81fe3
|
||||||
|
m_Name: Remote.BuildPath
|
||||||
|
m_InlineUsage: 0
|
||||||
|
- m_Id: c177911d3f5ed754588b22d7ec9ed060
|
||||||
|
m_Name: Local.BuildPath
|
||||||
|
m_InlineUsage: 0
|
||||||
|
- m_Id: d9deedb924b434d4cb90947cdc187fd0
|
||||||
|
m_Name: BuildTarget
|
||||||
|
m_InlineUsage: 0
|
||||||
|
m_ProfileVersion: 1
|
||||||
|
m_LabelTable:
|
||||||
|
m_LabelNames:
|
||||||
|
- default
|
||||||
|
- SceneConfig
|
||||||
|
- CameraConfig
|
||||||
|
m_SchemaTemplates: []
|
||||||
|
m_GroupTemplateObjects:
|
||||||
|
- {fileID: 11400000, guid: af0b5782a0090884db056705d7776701, type: 2}
|
||||||
|
m_InitializationObjects: []
|
||||||
|
m_CertificateHandlerType:
|
||||||
|
m_AssemblyName:
|
||||||
|
m_ClassName:
|
||||||
|
m_ActivePlayerDataBuilderIndex: 2
|
||||||
|
m_DataBuilders:
|
||||||
|
- {fileID: 11400000, guid: 5828571a72b3c88408152ee845605cf6, type: 2}
|
||||||
|
- {fileID: 11400000, guid: d324b578f252a7142a647b3ce6fe7c0a, type: 2}
|
||||||
|
- {fileID: 11400000, guid: c32f2fcaa3a15e3439364993cf5d280b, type: 2}
|
||||||
|
m_ActiveProfileId: 4d4a686241dde1e4497a09458afd84bb
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: c6c4cec5a69c4d144a5dfabd0405f447
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
+2
-3
@@ -1,9 +1,8 @@
|
|||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 8a0c9218a650547d98138cd835033977
|
guid: 44b2636e90c07ac43af77e6a70dd70da
|
||||||
folderAsset: yes
|
folderAsset: yes
|
||||||
timeCreated: 1484670163
|
|
||||||
licenseType: Store
|
|
||||||
DefaultImporter:
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
userData:
|
userData:
|
||||||
assetBundleName:
|
assetBundleName:
|
||||||
assetBundleVariant:
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &-3087431505975437863
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 1
|
||||||
|
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: 5834b5087d578d24c926ce20cd31e6d6, type: 3}
|
||||||
|
m_Name: ContentUpdateGroupSchema
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Settings.GroupSchemas.ContentUpdateGroupSchema
|
||||||
|
m_Group: {fileID: 0}
|
||||||
|
m_StaticContent: 0
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: 1a3c5d64ac83548c09dd1678b9f6f1cd, type: 3}
|
||||||
|
m_Name: Packed Assets
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Settings.AddressableAssetGroupTemplate
|
||||||
|
m_SchemaObjects:
|
||||||
|
- {fileID: 4637821248306542994}
|
||||||
|
- {fileID: -3087431505975437863}
|
||||||
|
m_Description: Pack assets into asset bundles.
|
||||||
|
m_Settings: {fileID: 11400000, guid: c6c4cec5a69c4d144a5dfabd0405f447, type: 2}
|
||||||
|
--- !u!114 &4637821248306542994
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 1
|
||||||
|
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: e5d17a21594effb4e9591490b009e7aa, type: 3}
|
||||||
|
m_Name: BundledAssetGroupSchema
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Settings.GroupSchemas.BundledAssetGroupSchema
|
||||||
|
m_Group: {fileID: 0}
|
||||||
|
m_InternalBundleIdMode: 1
|
||||||
|
m_Compression: 1
|
||||||
|
m_IncludeAddressInCatalog: 1
|
||||||
|
m_IncludeGUIDInCatalog: 1
|
||||||
|
m_IncludeLabelsInCatalog: 1
|
||||||
|
m_InternalIdNamingMode: 0
|
||||||
|
m_CacheClearBehavior: 0
|
||||||
|
m_IncludeInBuild: 1
|
||||||
|
m_BundledAssetProviderType:
|
||||||
|
m_AssemblyName:
|
||||||
|
m_ClassName:
|
||||||
|
m_StripDownloadOptions: 0
|
||||||
|
m_ForceUniqueProvider: 0
|
||||||
|
m_UseAssetBundleCache: 1
|
||||||
|
m_UseAssetBundleCrc: 1
|
||||||
|
m_UseAssetBundleCrcForCachedBundles: 1
|
||||||
|
m_UseUWRForLocalBundles: 0
|
||||||
|
m_Timeout: 0
|
||||||
|
m_ChunkedTransfer: 0
|
||||||
|
m_RedirectLimit: -1
|
||||||
|
m_RetryCount: 0
|
||||||
|
m_BuildPath:
|
||||||
|
m_Id:
|
||||||
|
m_LoadPath:
|
||||||
|
m_Id:
|
||||||
|
m_BundleMode: 0
|
||||||
|
m_AssetBundleProviderType:
|
||||||
|
m_AssemblyName:
|
||||||
|
m_ClassName:
|
||||||
|
m_UseDefaultSchemaSettings: 0
|
||||||
|
m_SelectedPathPairIndex: 0
|
||||||
|
m_BundleNaming: 0
|
||||||
|
m_AssetLoadMode: 0
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: af0b5782a0090884db056705d7776701
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 69dcc014c1bac254f9abce1606c33df7
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,82 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: bbb281ee3bf0b054c82ac2347e9e782c, type: 3}
|
||||||
|
m_Name: Default Local Group
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Settings.AddressableAssetGroup
|
||||||
|
m_GroupName: Default Local Group
|
||||||
|
m_GUID: d790534e015d692428ac5a9ce7d2ceb6
|
||||||
|
m_SerializeEntries:
|
||||||
|
- m_GUID: 4a97987e3a94e0f43b1b57b6ddccac23
|
||||||
|
m_Address: Assets/Resources_moved/Configs/Camera/CameraSettingsConfig.asset
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels:
|
||||||
|
- CameraConfig
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: 4ad92ea93f2a0664191607510b1b623d
|
||||||
|
m_Address: Assets/Resources_moved/Configs/Scenes/Gameplay.asset
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels:
|
||||||
|
- SceneConfig
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: 8d54a5646fc9ef34383c560ce3c3d6ff
|
||||||
|
m_Address: Liminal/Settings/InputServiceConfig
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: a78f552da8f156b469b95652e4b0209d
|
||||||
|
m_Address: DebugClassConfig
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: becf493a34b841e4d8ea927261a05e9b
|
||||||
|
m_Address: Camera/Camera
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: c42e39e2fb64cdd45b2ebc4b723d9d0c
|
||||||
|
m_Address: Assets/Resources_moved/Configs/Camera/GameCameraConfig.asset
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: c9ba47101ea957549b0379d4e5fae54c
|
||||||
|
m_Address: Assets/Scenes/MainMenu.unity
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: d54fabdcc748a594aa0551dcd235c7c2
|
||||||
|
m_Address: ScenesAssetReferences
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: df809fbbdc1f51f43b4d42a7896a0919
|
||||||
|
m_Address: Assets/Scenes/Gameplay.unity
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels: []
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: f146779bcd07c524097072c871162bff
|
||||||
|
m_Address: Assets/Resources_moved/Configs/Camera/FPSConfig.asset
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels:
|
||||||
|
- CameraConfig
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
- m_GUID: f5e16d3d2576c5a4ca27ea09aeb18733
|
||||||
|
m_Address: Assets/Resources_moved/Configs/Scenes/MainMenu.asset
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_SerializedLabels:
|
||||||
|
- SceneConfig
|
||||||
|
FlaggedDuringContentUpdateRestriction: 0
|
||||||
|
m_ReadOnly: 0
|
||||||
|
m_Settings: {fileID: 11400000, guid: c6c4cec5a69c4d144a5dfabd0405f447, type: 2}
|
||||||
|
m_SchemaSet:
|
||||||
|
m_Schemas:
|
||||||
|
- {fileID: 11400000, guid: 15788cbd058e4e54d8cdf200fa21904a, type: 2}
|
||||||
|
- {fileID: 11400000, guid: 818d1cfb2f3daeb41942c3e5367f4fbc, type: 2}
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: cd5d8f0bccfc1e5489a5c528087c4feb
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 59cf85b8277d19b498da8736741b34f4
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
+48
@@ -0,0 +1,48 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: e5d17a21594effb4e9591490b009e7aa, type: 3}
|
||||||
|
m_Name: Default Local Group_BundledAssetGroupSchema
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Settings.GroupSchemas.BundledAssetGroupSchema
|
||||||
|
m_Group: {fileID: 11400000, guid: cd5d8f0bccfc1e5489a5c528087c4feb, type: 2}
|
||||||
|
m_InternalBundleIdMode: 1
|
||||||
|
m_Compression: 1
|
||||||
|
m_IncludeAddressInCatalog: 1
|
||||||
|
m_IncludeGUIDInCatalog: 1
|
||||||
|
m_IncludeLabelsInCatalog: 1
|
||||||
|
m_InternalIdNamingMode: 0
|
||||||
|
m_CacheClearBehavior: 0
|
||||||
|
m_IncludeInBuild: 1
|
||||||
|
m_BundledAssetProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.BundledAssetProvider
|
||||||
|
m_StripDownloadOptions: 0
|
||||||
|
m_ForceUniqueProvider: 0
|
||||||
|
m_UseAssetBundleCache: 1
|
||||||
|
m_UseAssetBundleCrc: 1
|
||||||
|
m_UseAssetBundleCrcForCachedBundles: 1
|
||||||
|
m_UseUWRForLocalBundles: 0
|
||||||
|
m_Timeout: 0
|
||||||
|
m_ChunkedTransfer: 0
|
||||||
|
m_RedirectLimit: -1
|
||||||
|
m_RetryCount: 0
|
||||||
|
m_BuildPath:
|
||||||
|
m_Id: c177911d3f5ed754588b22d7ec9ed060
|
||||||
|
m_LoadPath:
|
||||||
|
m_Id: 0625bc81bb6ebfe4badeca8150066832
|
||||||
|
m_BundleMode: 0
|
||||||
|
m_AssetBundleProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.AssetBundleProvider
|
||||||
|
m_UseDefaultSchemaSettings: 0
|
||||||
|
m_SelectedPathPairIndex: 0
|
||||||
|
m_BundleNaming: 0
|
||||||
|
m_AssetLoadMode: 0
|
||||||
+8
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 15788cbd058e4e54d8cdf200fa21904a
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
+16
@@ -0,0 +1,16 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: 5834b5087d578d24c926ce20cd31e6d6, type: 3}
|
||||||
|
m_Name: Default Local Group_ContentUpdateGroupSchema
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Settings.GroupSchemas.ContentUpdateGroupSchema
|
||||||
|
m_Group: {fileID: 11400000, guid: cd5d8f0bccfc1e5489a5c528087c4feb, type: 2}
|
||||||
|
m_StaticContent: 0
|
||||||
+8
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 818d1cfb2f3daeb41942c3e5367f4fbc
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: df12fa2b84c582c498081bd75e380012
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: 88d21199f5d473f4db36845f2318f180, type: 3}
|
||||||
|
m_Name: BuildScriptFastMode
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Build.DataBuilders.BuildScriptFastMode
|
||||||
|
instanceProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.InstanceProvider
|
||||||
|
sceneProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.SceneProvider
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5828571a72b3c88408152ee845605cf6
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: 3e2e0ffa088c91d41a086d0b8cb16bdc, type: 3}
|
||||||
|
m_Name: BuildScriptPackedMode
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Build.DataBuilders.BuildScriptPackedMode
|
||||||
|
instanceProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.InstanceProvider
|
||||||
|
sceneProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.SceneProvider
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: c32f2fcaa3a15e3439364993cf5d280b
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: ad8c280d42ee0ed41a27db23b43dd2bf, type: 3}
|
||||||
|
m_Name: BuildScriptPackedPlayMode
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.Build.DataBuilders.BuildScriptPackedPlayMode
|
||||||
|
instanceProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.InstanceProvider
|
||||||
|
sceneProviderType:
|
||||||
|
m_AssemblyName: Unity.ResourceManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||||
|
m_ClassName: UnityEngine.ResourceManagement.ResourceProviders.SceneProvider
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: d324b578f252a7142a647b3ce6fe7c0a
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!114 &11400000
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
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: 3a189bb168d8d90478a09ea08c2f3d72, type: 3}
|
||||||
|
m_Name: DefaultObject
|
||||||
|
m_EditorClassIdentifier: Unity.Addressables.Editor::UnityEditor.AddressableAssets.AddressableAssetSettingsDefaultObject
|
||||||
|
m_AddressableAssetSettingsGuid: c6c4cec5a69c4d144a5dfabd0405f447
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 4500108910384ba44a8f6f5ec4deb9c3
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 11400000
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
fileFormatVersion: 2
|
|
||||||
guid: 3487788d480845039f84f7aa89195d0b
|
|
||||||
timeCreated: 1765564013
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
using Reflex.Core;
|
|
||||||
|
|
||||||
namespace Code.Debug
|
|
||||||
{
|
|
||||||
public class DebugInstaller : IInstaller
|
|
||||||
{
|
|
||||||
public void InstallBindings(ContainerBuilder containerBuilder)
|
|
||||||
{
|
|
||||||
containerBuilder.AddSingleton(typeof(DebugStateMachine));
|
|
||||||
|
|
||||||
containerBuilder.OnContainerBuilt += Bootstrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void Bootstrap(Container container)
|
|
||||||
{
|
|
||||||
container.Resolve<DebugStateMachine>();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
fileFormatVersion: 2
|
|
||||||
guid: 35352cf8cf4f4b638e1a1693a704f052
|
|
||||||
timeCreated: 1765565958
|
|
||||||
@@ -1,20 +0,0 @@
|
|||||||
using System;
|
|
||||||
using Code.StateMachine;
|
|
||||||
|
|
||||||
namespace Code.Debug
|
|
||||||
{
|
|
||||||
public enum DebugStates
|
|
||||||
{
|
|
||||||
First,
|
|
||||||
Second,
|
|
||||||
Third
|
|
||||||
}
|
|
||||||
public class DebugStateMachineContext
|
|
||||||
{
|
|
||||||
public int SomeValue;
|
|
||||||
}
|
|
||||||
|
|
||||||
[Generators.StateMachine(typeof(DebugStateMachineContext), typeof(DebugStates))]
|
|
||||||
public partial class DebugStateMachine
|
|
||||||
{ }
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
fileFormatVersion: 2
|
|
||||||
guid: 71d501bd1540463496c6df3fa0bbb0ca
|
|
||||||
timeCreated: 1765564028
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
fileFormatVersion: 2
|
|
||||||
guid: 6e84c82fd2ce4c449bee71acf27ed874
|
|
||||||
timeCreated: 1765566284
|
|
||||||
@@ -1,24 +0,0 @@
|
|||||||
using Code.Generators;
|
|
||||||
using Code.StateMachine;
|
|
||||||
|
|
||||||
namespace Code.Debug.States
|
|
||||||
{
|
|
||||||
[State(typeof(DebugStateMachineContext) )]
|
|
||||||
public partial class FirstState : BaseState<DebugStates, DebugStateMachineContext>
|
|
||||||
{
|
|
||||||
public FirstState(DebugStateMachineContext context) : base(context)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
public override DebugStates myState => DebugStates.First;
|
|
||||||
}
|
|
||||||
[State(typeof(DebugStateMachineContext) )]
|
|
||||||
public partial class SecondState : BaseState<DebugStates, DebugStateMachineContext>
|
|
||||||
{
|
|
||||||
public SecondState(DebugStateMachineContext context) : base(context)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
public override DebugStates myState => DebugStates.First;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
fileFormatVersion: 2
|
|
||||||
guid: 24af5a4d2545481589242a5945bbafa5
|
|
||||||
timeCreated: 1765566292
|
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 07cf07a937934e0094469237b5865b60
|
||||||
|
timeCreated: 1766350980
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b03c560586d24e78b3fee9249e2f3d61
|
||||||
|
timeCreated: 1766605332
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b44837d95edd481087730e30635ab5fc
|
||||||
|
timeCreated: 1766605342
|
||||||
@@ -0,0 +1,483 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using KinematicCharacterController;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Example.Liminal.Character
|
||||||
|
{
|
||||||
|
public enum CharacterState
|
||||||
|
{
|
||||||
|
Default,
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum OrientationMethod
|
||||||
|
{
|
||||||
|
TowardsCamera,
|
||||||
|
TowardsMovement,
|
||||||
|
}
|
||||||
|
|
||||||
|
public class PlayerCharacterInputs
|
||||||
|
{
|
||||||
|
public float MoveAxisForward;
|
||||||
|
public float MoveAxisRight;
|
||||||
|
public Quaternion CameraRotation;
|
||||||
|
public bool CrouchDown;
|
||||||
|
public bool CrouchUp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public struct AICharacterInputs
|
||||||
|
{
|
||||||
|
public Vector3 MoveVector;
|
||||||
|
public Vector3 LookVector;
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum BonusOrientationMethod
|
||||||
|
{
|
||||||
|
None,
|
||||||
|
TowardsGravity,
|
||||||
|
TowardsGroundSlopeAndGravity,
|
||||||
|
}
|
||||||
|
|
||||||
|
public class LiminalCharacterController : MonoBehaviour, ICharacterController
|
||||||
|
{
|
||||||
|
public KinematicCharacterMotor Motor;
|
||||||
|
|
||||||
|
[Header("Stable Movement")] public float MaxStableMoveSpeed = 10f;
|
||||||
|
public float StableMovementSharpness = 15f;
|
||||||
|
public float OrientationSharpness = 10f;
|
||||||
|
public bool InfinitelySharpRotation;
|
||||||
|
public OrientationMethod OrientationMethod = OrientationMethod.TowardsCamera;
|
||||||
|
|
||||||
|
[Header("Air Movement")] public float MaxAirMoveSpeed = 15f;
|
||||||
|
public float AirAccelerationSpeed = 15f;
|
||||||
|
public float Drag = 0.1f;
|
||||||
|
|
||||||
|
[Header("Misc")] public List<Collider> IgnoredColliders = new List<Collider>();
|
||||||
|
public BonusOrientationMethod BonusOrientationMethod = BonusOrientationMethod.None;
|
||||||
|
public float BonusOrientationSharpness = 10f;
|
||||||
|
|
||||||
|
public Vector3 Gravity = new Vector3(0, -30f, 0);
|
||||||
|
|
||||||
|
// public Transform MeshRoot;
|
||||||
|
public float CrouchedCapsuleHeight = 1f;
|
||||||
|
|
||||||
|
public CharacterState CurrentCharacterState { get; private set; }
|
||||||
|
|
||||||
|
private Collider[] _probedColliders = new Collider[8];
|
||||||
|
private RaycastHit[] _probedHits = new RaycastHit[8];
|
||||||
|
private Vector3 _moveInputVector;
|
||||||
|
private Vector3 _lookInputVector;
|
||||||
|
private Vector3 _internalVelocityAdd = Vector3.zero;
|
||||||
|
private bool _shouldBeCrouching = false;
|
||||||
|
private bool _isCrouching = false;
|
||||||
|
|
||||||
|
|
||||||
|
public void Teleport(Vector3 position, Quaternion rotation)
|
||||||
|
{
|
||||||
|
Motor.SetPosition(position);
|
||||||
|
Motor.SetRotation(rotation);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Awake()
|
||||||
|
{
|
||||||
|
// Handle initial state
|
||||||
|
TransitionToState(CharacterState.Default);
|
||||||
|
|
||||||
|
// Assign the characterController to the motor
|
||||||
|
Motor.CharacterController = this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Handles movement state transitions and enter/exit callbacks
|
||||||
|
/// </summary>
|
||||||
|
public void TransitionToState(CharacterState newState)
|
||||||
|
{
|
||||||
|
CharacterState tmpInitialState = CurrentCharacterState;
|
||||||
|
OnStateExit(tmpInitialState, newState);
|
||||||
|
CurrentCharacterState = newState;
|
||||||
|
OnStateEnter(newState, tmpInitialState);
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Event when entering a state
|
||||||
|
/// </summary>
|
||||||
|
private void OnStateEnter(CharacterState state, CharacterState fromState)
|
||||||
|
{
|
||||||
|
switch (state)
|
||||||
|
{
|
||||||
|
case CharacterState.Default:
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Event when exiting a state
|
||||||
|
/// </summary>
|
||||||
|
private void OnStateExit(CharacterState state, CharacterState toState)
|
||||||
|
{
|
||||||
|
switch (state)
|
||||||
|
{
|
||||||
|
case CharacterState.Default:
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// This is called every frame by ExamplePlayer in order to tell the character what its inputs are
|
||||||
|
/// </summary>
|
||||||
|
public void SetInputs(PlayerCharacterInputs inputs)
|
||||||
|
{
|
||||||
|
// Clamp input
|
||||||
|
Vector3 moveInputVector =
|
||||||
|
Vector3.ClampMagnitude(new Vector3(inputs.MoveAxisRight, 0f, inputs.MoveAxisForward), 1f);
|
||||||
|
|
||||||
|
// Calculate camera direction and rotation on the character plane
|
||||||
|
Vector3 cameraPlanarDirection =
|
||||||
|
Vector3.ProjectOnPlane(inputs.CameraRotation * Vector3.forward, Motor.CharacterUp).normalized;
|
||||||
|
if (cameraPlanarDirection.sqrMagnitude == 0f)
|
||||||
|
{
|
||||||
|
cameraPlanarDirection = Vector3.ProjectOnPlane(inputs.CameraRotation * Vector3.up, Motor.CharacterUp)
|
||||||
|
.normalized;
|
||||||
|
}
|
||||||
|
|
||||||
|
Quaternion cameraPlanarRotation = Quaternion.LookRotation(cameraPlanarDirection, Motor.CharacterUp);
|
||||||
|
|
||||||
|
switch (CurrentCharacterState)
|
||||||
|
{
|
||||||
|
case CharacterState.Default:
|
||||||
|
{
|
||||||
|
// Move and look inputs
|
||||||
|
_moveInputVector = cameraPlanarRotation * moveInputVector;
|
||||||
|
|
||||||
|
switch (OrientationMethod)
|
||||||
|
{
|
||||||
|
case OrientationMethod.TowardsCamera:
|
||||||
|
_lookInputVector = cameraPlanarDirection;
|
||||||
|
break;
|
||||||
|
case OrientationMethod.TowardsMovement:
|
||||||
|
_lookInputVector = _moveInputVector.normalized;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Crouching input
|
||||||
|
if (inputs.CrouchDown)
|
||||||
|
{
|
||||||
|
_shouldBeCrouching = true;
|
||||||
|
|
||||||
|
if (!_isCrouching)
|
||||||
|
{
|
||||||
|
_isCrouching = true;
|
||||||
|
Motor.SetCapsuleDimensions(0.5f, CrouchedCapsuleHeight, CrouchedCapsuleHeight * 0.5f);
|
||||||
|
// MeshRoot.localScale = new Vector3(1f, 0.5f, 1f);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (inputs.CrouchUp)
|
||||||
|
{
|
||||||
|
_shouldBeCrouching = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// This is called every frame by the AI script in order to tell the character what its inputs are
|
||||||
|
/// </summary>
|
||||||
|
public void SetInputs(ref AICharacterInputs inputs)
|
||||||
|
{
|
||||||
|
_moveInputVector = inputs.MoveVector;
|
||||||
|
_lookInputVector = inputs.LookVector;
|
||||||
|
}
|
||||||
|
|
||||||
|
private Quaternion _tmpTransientRot;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// (Called by KinematicCharacterMotor during its update cycle)
|
||||||
|
/// This is called before the character begins its movement update
|
||||||
|
/// </summary>
|
||||||
|
public void BeforeCharacterUpdate(float deltaTime)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// (Called by KinematicCharacterMotor during its update cycle)
|
||||||
|
/// This is where you tell your character what its rotation should be right now.
|
||||||
|
/// This is the ONLY place where you should set the character's rotation
|
||||||
|
/// </summary>
|
||||||
|
public void UpdateRotation(ref Quaternion currentRotation, float deltaTime)
|
||||||
|
{
|
||||||
|
switch (CurrentCharacterState)
|
||||||
|
{
|
||||||
|
case CharacterState.Default:
|
||||||
|
{
|
||||||
|
if (!InfinitelySharpRotation)
|
||||||
|
{
|
||||||
|
if (_lookInputVector.sqrMagnitude > 0f && OrientationSharpness > 0f)
|
||||||
|
{
|
||||||
|
// Smoothly interpolate from current to target look direction
|
||||||
|
Vector3 smoothedLookInputDirection = Vector3.Slerp(Motor.CharacterForward,
|
||||||
|
_lookInputVector, 1 - Mathf.Exp(-OrientationSharpness * deltaTime)).normalized;
|
||||||
|
|
||||||
|
// Set the current rotation (which will be used by the KinematicCharacterMotor)
|
||||||
|
currentRotation =
|
||||||
|
Quaternion.LookRotation(smoothedLookInputDirection, Motor.CharacterUp);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
currentRotation = Quaternion.LookRotation(_lookInputVector, Motor.CharacterUp);
|
||||||
|
}
|
||||||
|
|
||||||
|
Vector3 currentUp = (currentRotation * Vector3.up);
|
||||||
|
if (BonusOrientationMethod == BonusOrientationMethod.TowardsGravity)
|
||||||
|
{
|
||||||
|
// Rotate from current up to invert gravity
|
||||||
|
Vector3 smoothedGravityDir = Vector3.Slerp(currentUp, -Gravity.normalized,
|
||||||
|
1 - Mathf.Exp(-BonusOrientationSharpness * deltaTime));
|
||||||
|
currentRotation = Quaternion.FromToRotation(currentUp, smoothedGravityDir) * currentRotation;
|
||||||
|
}
|
||||||
|
else if (BonusOrientationMethod == BonusOrientationMethod.TowardsGroundSlopeAndGravity)
|
||||||
|
{
|
||||||
|
if (Motor.GroundingStatus.IsStableOnGround)
|
||||||
|
{
|
||||||
|
Vector3 initialCharacterBottomHemiCenter =
|
||||||
|
Motor.TransientPosition + (currentUp * Motor.Capsule.radius);
|
||||||
|
|
||||||
|
Vector3 smoothedGroundNormal = Vector3.Slerp(Motor.CharacterUp,
|
||||||
|
Motor.GroundingStatus.GroundNormal,
|
||||||
|
1 - Mathf.Exp(-BonusOrientationSharpness * deltaTime));
|
||||||
|
currentRotation = Quaternion.FromToRotation(currentUp, smoothedGroundNormal) *
|
||||||
|
currentRotation;
|
||||||
|
|
||||||
|
// Move the position to create a rotation around the bottom hemi center instead of around the pivot
|
||||||
|
Motor.SetTransientPosition(initialCharacterBottomHemiCenter +
|
||||||
|
(currentRotation * Vector3.down * Motor.Capsule.radius));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Vector3 smoothedGravityDir = Vector3.Slerp(currentUp, -Gravity.normalized,
|
||||||
|
1 - Mathf.Exp(-BonusOrientationSharpness * deltaTime));
|
||||||
|
currentRotation = Quaternion.FromToRotation(currentUp, smoothedGravityDir) *
|
||||||
|
currentRotation;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Vector3 smoothedGravityDir = Vector3.Slerp(currentUp, Vector3.up,
|
||||||
|
1 - Mathf.Exp(-BonusOrientationSharpness * deltaTime));
|
||||||
|
currentRotation = Quaternion.FromToRotation(currentUp, smoothedGravityDir) * currentRotation;
|
||||||
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// (Called by KinematicCharacterMotor during its update cycle)
|
||||||
|
/// This is where you tell your character what its velocity should be right now.
|
||||||
|
/// This is the ONLY place where you can set the character's velocity
|
||||||
|
/// </summary>
|
||||||
|
public void UpdateVelocity(ref Vector3 currentVelocity, float deltaTime)
|
||||||
|
{
|
||||||
|
switch (CurrentCharacterState)
|
||||||
|
{
|
||||||
|
case CharacterState.Default:
|
||||||
|
{
|
||||||
|
// Ground movement
|
||||||
|
if (Motor.GroundingStatus.IsStableOnGround)
|
||||||
|
{
|
||||||
|
float currentVelocityMagnitude = currentVelocity.magnitude;
|
||||||
|
|
||||||
|
Vector3 effectiveGroundNormal = Motor.GroundingStatus.GroundNormal;
|
||||||
|
|
||||||
|
// Reorient velocity on slope
|
||||||
|
currentVelocity = Motor.GetDirectionTangentToSurface(currentVelocity, effectiveGroundNormal) *
|
||||||
|
currentVelocityMagnitude;
|
||||||
|
|
||||||
|
// Calculate target velocity
|
||||||
|
Vector3 inputRight = Vector3.Cross(_moveInputVector, Motor.CharacterUp);
|
||||||
|
Vector3 reorientedInput = Vector3.Cross(effectiveGroundNormal, inputRight).normalized *
|
||||||
|
_moveInputVector.magnitude;
|
||||||
|
Vector3 targetMovementVelocity = reorientedInput * MaxStableMoveSpeed;
|
||||||
|
|
||||||
|
// Smooth movement Velocity
|
||||||
|
currentVelocity = Vector3.Lerp(currentVelocity, targetMovementVelocity,
|
||||||
|
1f - Mathf.Exp(-StableMovementSharpness * deltaTime));
|
||||||
|
}
|
||||||
|
// Air movement
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Add move input
|
||||||
|
if (_moveInputVector.sqrMagnitude > 0f)
|
||||||
|
{
|
||||||
|
Vector3 addedVelocity = _moveInputVector * AirAccelerationSpeed * deltaTime;
|
||||||
|
|
||||||
|
Vector3 currentVelocityOnInputsPlane =
|
||||||
|
Vector3.ProjectOnPlane(currentVelocity, Motor.CharacterUp);
|
||||||
|
|
||||||
|
// Limit air velocity from inputs
|
||||||
|
if (currentVelocityOnInputsPlane.magnitude < MaxAirMoveSpeed)
|
||||||
|
{
|
||||||
|
// clamp addedVel to make total vel not exceed max vel on inputs plane
|
||||||
|
Vector3 newTotal = Vector3.ClampMagnitude(currentVelocityOnInputsPlane + addedVelocity,
|
||||||
|
MaxAirMoveSpeed);
|
||||||
|
addedVelocity = newTotal - currentVelocityOnInputsPlane;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Make sure added vel doesn't go in the direction of the already-exceeding velocity
|
||||||
|
if (Vector3.Dot(currentVelocityOnInputsPlane, addedVelocity) > 0f)
|
||||||
|
{
|
||||||
|
addedVelocity = Vector3.ProjectOnPlane(addedVelocity,
|
||||||
|
currentVelocityOnInputsPlane.normalized);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Prevent air-climbing sloped walls
|
||||||
|
if (Motor.GroundingStatus.FoundAnyGround)
|
||||||
|
{
|
||||||
|
if (Vector3.Dot(currentVelocity + addedVelocity, addedVelocity) > 0f)
|
||||||
|
{
|
||||||
|
Vector3 perpenticularObstructionNormal = Vector3
|
||||||
|
.Cross(Vector3.Cross(Motor.CharacterUp, Motor.GroundingStatus.GroundNormal),
|
||||||
|
Motor.CharacterUp).normalized;
|
||||||
|
addedVelocity =
|
||||||
|
Vector3.ProjectOnPlane(addedVelocity, perpenticularObstructionNormal);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Apply added velocity
|
||||||
|
currentVelocity += addedVelocity;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Gravity
|
||||||
|
currentVelocity += Gravity * deltaTime;
|
||||||
|
|
||||||
|
// Drag
|
||||||
|
currentVelocity *= (1f / (1f + (Drag * deltaTime)));
|
||||||
|
}
|
||||||
|
|
||||||
|
// Take into account additive velocity
|
||||||
|
if (_internalVelocityAdd.sqrMagnitude > 0f)
|
||||||
|
{
|
||||||
|
currentVelocity += _internalVelocityAdd;
|
||||||
|
_internalVelocityAdd = Vector3.zero;
|
||||||
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// (Called by KinematicCharacterMotor during its update cycle)
|
||||||
|
/// This is called after the character has finished its movement update
|
||||||
|
/// </summary>
|
||||||
|
public void AfterCharacterUpdate(float deltaTime)
|
||||||
|
{
|
||||||
|
switch (CurrentCharacterState)
|
||||||
|
{
|
||||||
|
case CharacterState.Default:
|
||||||
|
{
|
||||||
|
// Handle uncrouching
|
||||||
|
if (_isCrouching && !_shouldBeCrouching)
|
||||||
|
{
|
||||||
|
// Do an overlap test with the character's standing height to see if there are any obstructions
|
||||||
|
Motor.SetCapsuleDimensions(0.5f, 2f, 1f);
|
||||||
|
if (Motor.CharacterOverlap(
|
||||||
|
Motor.TransientPosition,
|
||||||
|
Motor.TransientRotation,
|
||||||
|
_probedColliders,
|
||||||
|
Motor.CollidableLayers,
|
||||||
|
QueryTriggerInteraction.Ignore) > 0)
|
||||||
|
{
|
||||||
|
// If obstructions, just stick to crouching dimensions
|
||||||
|
Motor.SetCapsuleDimensions(0.5f, CrouchedCapsuleHeight, CrouchedCapsuleHeight * 0.5f);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// If no obstructions, uncrouch
|
||||||
|
// MeshRoot.localScale = new Vector3(1f, 1f, 1f);
|
||||||
|
_isCrouching = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void PostGroundingUpdate(float deltaTime)
|
||||||
|
{
|
||||||
|
// Handle landing and leaving ground
|
||||||
|
if (Motor.GroundingStatus.IsStableOnGround && !Motor.LastGroundingStatus.IsStableOnGround)
|
||||||
|
{
|
||||||
|
OnLanded();
|
||||||
|
}
|
||||||
|
else if (!Motor.GroundingStatus.IsStableOnGround && Motor.LastGroundingStatus.IsStableOnGround)
|
||||||
|
{
|
||||||
|
OnLeaveStableGround();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public bool IsColliderValidForCollisions(Collider coll)
|
||||||
|
{
|
||||||
|
if (IgnoredColliders.Count == 0)
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (IgnoredColliders.Contains(coll))
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void OnGroundHit(Collider hitCollider, Vector3 hitNormal, Vector3 hitPoint,
|
||||||
|
ref HitStabilityReport hitStabilityReport)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public void OnMovementHit(Collider hitCollider, Vector3 hitNormal, Vector3 hitPoint,
|
||||||
|
ref HitStabilityReport hitStabilityReport)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public void AddVelocity(Vector3 velocity)
|
||||||
|
{
|
||||||
|
switch (CurrentCharacterState)
|
||||||
|
{
|
||||||
|
case CharacterState.Default:
|
||||||
|
{
|
||||||
|
_internalVelocityAdd += velocity;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void ProcessHitStabilityReport(Collider hitCollider, Vector3 hitNormal, Vector3 hitPoint,
|
||||||
|
Vector3 atCharacterPosition, Quaternion atCharacterRotation, ref HitStabilityReport hitStabilityReport)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void OnLanded()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void OnLeaveStableGround()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public void OnDiscreteCollisionDetected(Collider hitCollider)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ba1cb0200be742ec8d680ad8b2d662cb
|
||||||
|
timeCreated: 1766610552
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: d7569a6973424ff5802b1635c5338316
|
||||||
|
timeCreated: 1766611137
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
using KinematicCharacterController;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Example.Liminal.Player
|
||||||
|
{
|
||||||
|
public class PlayerAnimator : MonoBehaviour
|
||||||
|
{
|
||||||
|
private static readonly int Velocity = Animator.StringToHash("Velocity");
|
||||||
|
|
||||||
|
[SerializeField] private Animator animator;
|
||||||
|
[SerializeField] private KinematicCharacterMotor characterMotor;
|
||||||
|
|
||||||
|
private void Update()
|
||||||
|
{
|
||||||
|
animator.SetFloat(Velocity, characterMotor.Velocity.magnitude);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e79636518658432a99481e476aeebc66
|
||||||
|
timeCreated: 1766610269
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
namespace Code.Example.Liminal.Player
|
||||||
|
{
|
||||||
|
public class PlayerFactory
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 60b7c1aa1c8c4189a2b442d2b4c628eb
|
||||||
|
timeCreated: 1766652945
|
||||||
@@ -0,0 +1,74 @@
|
|||||||
|
using System;
|
||||||
|
using Code.Example.Liminal.Character;
|
||||||
|
using Code.Infrastructure.Camera;
|
||||||
|
using Code.Infrastructure.Camera.CameraStates;
|
||||||
|
using Code.Infrastructure.Input;
|
||||||
|
using Reflex.Attributes;
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.InputSystem;
|
||||||
|
|
||||||
|
namespace Code.Example.Liminal.Player
|
||||||
|
{
|
||||||
|
public class PlayerMovementController : MonoBehaviour
|
||||||
|
{
|
||||||
|
[SerializeField] private LiminalCharacterController characterController;
|
||||||
|
private PlayerCharacterInputs _currentInputs = new();
|
||||||
|
private IInputService _inputService;
|
||||||
|
|
||||||
|
private CameraStateMachine _cameraStateMachine;
|
||||||
|
|
||||||
|
public Transform PlayerHeadPoint;
|
||||||
|
|
||||||
|
[Inject]
|
||||||
|
private void Construct(IInputService inputService, CameraStateMachine stateMachine)
|
||||||
|
{
|
||||||
|
_inputService = inputService;
|
||||||
|
_inputService.BindActionPerformed((int) ActionMappings.Gameplay, (int) GameplayActions.Move, OnMovePerformed);
|
||||||
|
_inputService.BindActionCancel((int) ActionMappings.Gameplay, (int) GameplayActions.Move, OnMoveCanceled);
|
||||||
|
_inputService.BindActionPerformed((int) ActionMappings.Gameplay, (int) GameplayActions.Crouch, OnCrouchPerformed);
|
||||||
|
_inputService.BindActionCancel((int) ActionMappings.Gameplay, (int) GameplayActions.Crouch, OnCrouchCanceled);
|
||||||
|
|
||||||
|
_cameraStateMachine = stateMachine;
|
||||||
|
((FirstPersonCameraState)stateMachine.CurrentBaseState).SetPlayer(this);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Awake()
|
||||||
|
{
|
||||||
|
_currentInputs.MoveAxisForward = 0;
|
||||||
|
_currentInputs.MoveAxisRight = 0;
|
||||||
|
_currentInputs.CrouchUp = true;
|
||||||
|
_currentInputs.CrouchDown = false;
|
||||||
|
_currentInputs.CameraRotation = Quaternion.identity;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void SetCameraRotation(Quaternion rotation) => _currentInputs.CameraRotation = rotation;
|
||||||
|
private void OnMovePerformed(InputAction.CallbackContext context)
|
||||||
|
{
|
||||||
|
_currentInputs.MoveAxisForward = context.ReadValue<Vector2>().y;
|
||||||
|
_currentInputs.MoveAxisRight = context.ReadValue<Vector2>().x;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnMoveCanceled(InputAction.CallbackContext context)
|
||||||
|
{
|
||||||
|
_currentInputs.MoveAxisForward = 0;
|
||||||
|
_currentInputs.MoveAxisRight = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnCrouchPerformed(InputAction.CallbackContext context)
|
||||||
|
{
|
||||||
|
_currentInputs.CrouchDown = true;
|
||||||
|
_currentInputs.CrouchUp = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnCrouchCanceled(InputAction.CallbackContext context)
|
||||||
|
{
|
||||||
|
_currentInputs.CrouchUp = true;
|
||||||
|
_currentInputs.CrouchDown = false;
|
||||||
|
}
|
||||||
|
private void Update()
|
||||||
|
{
|
||||||
|
characterController.SetInputs(_currentInputs);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8dd688d33c434f999d0ff7cd0553f1ee
|
||||||
|
timeCreated: 1766611089
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
using System;
|
|
||||||
|
|
||||||
namespace Code.Generators
|
|
||||||
{
|
|
||||||
public class StateMachine : Attribute
|
|
||||||
{
|
|
||||||
public Type StateMachineContextType;
|
|
||||||
public Type StateMachineEnumType;
|
|
||||||
|
|
||||||
public StateMachine(Type stateMachineContextType, Type stateMachineEnumType)
|
|
||||||
{
|
|
||||||
StateMachineContextType = stateMachineContextType;
|
|
||||||
StateMachineEnumType = stateMachineEnumType;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public class State : Attribute
|
|
||||||
{
|
|
||||||
public Type StateMachineContextType;
|
|
||||||
public State (Type stateMachineContextType )
|
|
||||||
{
|
|
||||||
StateMachineContextType = stateMachineContextType;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 8ae0afd22327405eb4098d4106118b68
|
||||||
|
timeCreated: 1766056068
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 378d32559e654d4b91e761f7f5d4cee6
|
||||||
|
timeCreated: 1765572320
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
using Code.Infrastructure.Camera;
|
||||||
|
using Reflex.Attributes;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.App
|
||||||
|
{
|
||||||
|
public enum AppStates
|
||||||
|
{
|
||||||
|
Bootstrap,
|
||||||
|
Gameplay,
|
||||||
|
MainMenu
|
||||||
|
}
|
||||||
|
|
||||||
|
public class AppStateMachineContext
|
||||||
|
{
|
||||||
|
[Inject] public SceneLoader.SceneLoader SceneLoader { get; set; }
|
||||||
|
[Inject] public CameraStateMachine Camera { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
[Generators.StateMachine(typeof(AppStateMachineContext),typeof(AppStates))]
|
||||||
|
public partial class AppStateMachine
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5627248405434f028be921cb7916f823
|
||||||
|
timeCreated: 1765572329
|
||||||
@@ -0,0 +1,69 @@
|
|||||||
|
using Code.Infrastructure.Camera;
|
||||||
|
using Code.Infrastructure.Configs;
|
||||||
|
using Code.Infrastructure.Input;
|
||||||
|
using Code.Infrastructure.Loadings;
|
||||||
|
using Code.Infrastructure.SceneLoader;
|
||||||
|
using Reflex.Core;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.App
|
||||||
|
{
|
||||||
|
public class PapaInstaller : MonoBehaviour, IInstaller, ISceneConfigsLoadedHandle, IInputServiceInitializedHandle, ICameraInitializedHandle
|
||||||
|
{
|
||||||
|
public void InstallBindings(ContainerBuilder containerBuilder)
|
||||||
|
{
|
||||||
|
containerBuilder.AddSingleton(typeof(EventBus.EventBus));
|
||||||
|
containerBuilder.AddSingleton(typeof(ConfigLocator), typeof(IConfigLocator));
|
||||||
|
containerBuilder.AddSingleton(typeof(SceneLoader.SceneLoader));
|
||||||
|
containerBuilder.AddSingleton(typeof(InputService),typeof(IInputService));
|
||||||
|
|
||||||
|
containerBuilder.OnContainerBuilt += Bootstrap;
|
||||||
|
|
||||||
|
containerBuilder.AddSingleton(typeof(AppStateMachine));
|
||||||
|
containerBuilder.AddSingleton(typeof(AppStateMachineContext));
|
||||||
|
|
||||||
|
containerBuilder.AddSingleton(typeof(CameraFactory));
|
||||||
|
containerBuilder.AddSingleton(typeof(CameraStateMachine));
|
||||||
|
containerBuilder.AddSingleton(typeof(CameraStateMachineContext));
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private Loading initialLoading;
|
||||||
|
private Container _thatRightContainer;
|
||||||
|
private void Bootstrap(Container container)
|
||||||
|
{
|
||||||
|
_thatRightContainer = container;
|
||||||
|
|
||||||
|
container.Resolve<EventBus.EventBus>().Subscribe(this);
|
||||||
|
container.Resolve<SceneLoader.SceneLoader>();
|
||||||
|
container.Resolve<IInputService>();
|
||||||
|
container.Resolve<CameraFactory>().CreateCameraStateMachine(container.Resolve<CameraStateMachine>()).Forget();
|
||||||
|
|
||||||
|
initialLoading = new Loading(3, () => EssentialLoadEnded(container));
|
||||||
|
}
|
||||||
|
|
||||||
|
private void EssentialLoadEnded(Container container)
|
||||||
|
{
|
||||||
|
container.Resolve<AppStateMachine>().SwitchState(AppStates.Bootstrap).AllowStateTransition(AppStates.Gameplay);
|
||||||
|
container.Resolve<EventBus.EventBus>().Unsubscribe(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void SceneConfigsLoaded()
|
||||||
|
{
|
||||||
|
initialLoading.DoProgress();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void InputServiceInitialized()
|
||||||
|
{
|
||||||
|
initialLoading.DoProgress();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void CameraInitialized(CameraStateMachineContext.CameraLoadedData data)
|
||||||
|
{
|
||||||
|
_thatRightContainer.Resolve<CameraStateMachineContext>().cameraLoadedData = data;
|
||||||
|
_thatRightContainer.Resolve<CameraStateMachine>().SwitchState(CameraMode.None)
|
||||||
|
.AllowStateTransition(CameraMode.FirstPerson);
|
||||||
|
initialLoading.DoProgress();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e62d9c9e01334727887a684e008440a6
|
||||||
|
timeCreated: 1765572590
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 30a683bd88f74628b64f7e17315b0c5d
|
||||||
|
timeCreated: 1766393607
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
using Reflex.Core;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.App.SceneInstallers
|
||||||
|
{
|
||||||
|
public class GameplaySceneInstaller : MonoBehaviour, IInstaller
|
||||||
|
{
|
||||||
|
public void InstallBindings(ContainerBuilder containerBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
containerBuilder.OnContainerBuilt += PostInstall;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void PostInstall(Container container)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ab7d8da1f0cc44bf99ae978a6b75847a
|
||||||
|
timeCreated: 1768127778
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
using Code.Example;
|
||||||
|
using Reflex.Core;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.App.SceneInstallers
|
||||||
|
{
|
||||||
|
public class MainMenuSceneInstaller : MonoBehaviour, IInstaller
|
||||||
|
{
|
||||||
|
public void InstallBindings(ContainerBuilder containerBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
containerBuilder.OnContainerBuilt += PostInstall;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void PostInstall(Container container)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 067978788f51445ca3af5381eafec386
|
||||||
|
timeCreated: 1766393632
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 778cb4118a914d9c8b1cac8bef4295a5
|
||||||
|
timeCreated: 1765572459
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
using Code.Infrastructure.Camera;
|
||||||
|
using Code.Infrastructure.Generators;
|
||||||
|
using Code.Infrastructure.SceneLoader;
|
||||||
|
using Cysharp.Threading.Tasks;
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.SceneManagement;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.App.States
|
||||||
|
{
|
||||||
|
[State(typeof(AppStates),typeof(AppStateMachineContext))]
|
||||||
|
[StateRaisingEvent]
|
||||||
|
public partial class BootstrapState : IOnGameplaySceneLoadedHandler
|
||||||
|
{
|
||||||
|
private EventBus.EventBus _eventBus;
|
||||||
|
public BootstrapState(AppStateMachineContext context, EventBus.EventBus eventBus) : base(context,eventBus)
|
||||||
|
{
|
||||||
|
_eventBus = eventBus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public override AppStates myState => AppStates.Bootstrap;
|
||||||
|
protected override void OnEnterState()
|
||||||
|
{
|
||||||
|
_eventBus.Subscribe(this);
|
||||||
|
Context.Camera.SwitchState(CameraMode.FirstPerson).AllowStateTransition(CameraMode.None);
|
||||||
|
Context.SceneLoader.LoadSceneAsync(SceneId.Gameplay, LoadSceneMode.Single).Forget();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnExitState()
|
||||||
|
{
|
||||||
|
_eventBus.Unsubscribe(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void OnGameplaySceneLoaded()
|
||||||
|
{
|
||||||
|
Debug.Log("Spermageddon");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 71df5370ea2e4819bfbdb9cbb8e6c0ab
|
||||||
|
timeCreated: 1765572469
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
using Code.Infrastructure.Camera;
|
||||||
|
using Code.Infrastructure.Generators;
|
||||||
|
using Code.Infrastructure.SceneLoader;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.App.States
|
||||||
|
{
|
||||||
|
[State(typeof(AppStates),typeof(AppStateMachineContext))]
|
||||||
|
[StateRaisingEvent]
|
||||||
|
public partial class GameplayState : IOnGameplaySceneLoadedHandler
|
||||||
|
{
|
||||||
|
public GameplayState(AppStateMachineContext context, EventBus.EventBus eventBus) : base(context, eventBus)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public override AppStates myState => AppStates.Gameplay;
|
||||||
|
protected override void OnEnterState()
|
||||||
|
{
|
||||||
|
Context.Camera.SwitchState(CameraMode.FirstPerson).AllowStateTransition(CameraMode.None);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnExitState()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public void OnGameplaySceneLoaded()
|
||||||
|
{
|
||||||
|
Debug.Log("Spermageddon");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e543193800134f7b858502743ab3a43d
|
||||||
|
timeCreated: 1766436900
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
using Code.Infrastructure.Generators;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.App.States
|
||||||
|
{
|
||||||
|
[State(typeof(AppStates),typeof(AppStateMachineContext))]
|
||||||
|
[StateRaisingEvent]
|
||||||
|
public partial class MainMenuState
|
||||||
|
{
|
||||||
|
public MainMenuState(AppStateMachineContext context, EventBus.EventBus eventBus) : base(context,eventBus)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public override AppStates myState => AppStates.MainMenu;
|
||||||
|
protected override void OnEnterState()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnExitState()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5a17221ff27a400e80c42a2ea60bb4ee
|
||||||
|
timeCreated: 1766436796
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b7c28b6e1fe145b189d52cb829e06521
|
||||||
|
timeCreated: 1766655751
|
||||||
@@ -0,0 +1,61 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using Code.Infrastructure.Configs;
|
||||||
|
using Cysharp.Threading.Tasks;
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
using UnityEngine.ResourceManagement.AsyncOperations;
|
||||||
|
using Object = UnityEngine.Object;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Camera
|
||||||
|
{
|
||||||
|
public class CameraFactory : IDisposable
|
||||||
|
{
|
||||||
|
private AsyncOperationHandle<GameCameraConfig> _configHandle;
|
||||||
|
private GameCameraConfig _config;
|
||||||
|
private AssetReference _gameCameraConfigReference;
|
||||||
|
|
||||||
|
private AsyncOperationHandle<IList<CameraSettingsConfig>> _settingsConfigsHandle;
|
||||||
|
private Dictionary<CameraMode, CameraSettingsConfig> _settingsConfigs;
|
||||||
|
private string _cameraConfigsLabel;
|
||||||
|
|
||||||
|
private EventBus.EventBus _eventBus;
|
||||||
|
private UnityEngine.Camera _camera;
|
||||||
|
private IDisposable _disposableImplementation;
|
||||||
|
|
||||||
|
public CameraFactory(IConfigLocator configLocator, EventBus.EventBus eventBus)
|
||||||
|
{
|
||||||
|
_gameCameraConfigReference = configLocator.TryGetConfigAssetReference<GameCameraConfig>();
|
||||||
|
_cameraConfigsLabel = configLocator.TryGetManyConfigAssetReferences<CameraSettingsConfig>();
|
||||||
|
|
||||||
|
_eventBus = eventBus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public async UniTaskVoid CreateCameraStateMachine(CameraStateMachine stateMachine)
|
||||||
|
{
|
||||||
|
_settingsConfigsHandle = Addressables
|
||||||
|
.LoadAssetsAsync<CameraSettingsConfig>(_cameraConfigsLabel, null, Addressables.MergeMode.Union);
|
||||||
|
await _settingsConfigsHandle.ToUniTask();
|
||||||
|
_settingsConfigs = _settingsConfigsHandle.Result.ToDictionary(x => x.cameraMode);
|
||||||
|
|
||||||
|
_configHandle = Addressables.LoadAssetAsync<GameCameraConfig>(_gameCameraConfigReference);
|
||||||
|
await _configHandle.ToUniTask();
|
||||||
|
_config = _configHandle.Result;
|
||||||
|
|
||||||
|
var cameraObject = await Addressables.InstantiateAsync(_config.Camera).ToUniTask();
|
||||||
|
_camera = cameraObject.GetComponent<UnityEngine.Camera>();
|
||||||
|
|
||||||
|
cameraObject.GetComponent<CameraStateMachineRunner>().StateMachine = stateMachine;
|
||||||
|
Object.DontDestroyOnLoad(cameraObject);
|
||||||
|
|
||||||
|
_eventBus.RaiseEvent<ICameraInitializedHandle>(x => x.CameraInitialized(new(_camera, _settingsConfigs)));
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Dispose()
|
||||||
|
{
|
||||||
|
Addressables.Release(_configHandle);
|
||||||
|
Addressables.Release(_settingsConfigsHandle);
|
||||||
|
Addressables.ReleaseInstance(_camera.gameObject);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 4c05e01628b742be94dfd0bbbdfb87fa
|
||||||
|
timeCreated: 1767302222
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
using Code.Infrastructure.Generators;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Camera
|
||||||
|
{
|
||||||
|
[Config("Configs/Camera/CameraSettings", true)]
|
||||||
|
public class CameraSettings
|
||||||
|
{
|
||||||
|
// Расстояния от персонажа до камеры
|
||||||
|
[ToConfig] public float defaultDistance = 6f; // Стандартное расстояние камеры от цели
|
||||||
|
|
||||||
|
[ToConfig] public float minDistance = 3f; // Минимальное расстояние при зуме
|
||||||
|
|
||||||
|
[ToConfig] public float maxDistance = 10f; // Максимальное расстояние при зуме
|
||||||
|
|
||||||
|
[ToConfig] public float distanceMovementSpeed = 5f; // Множитель скорости изменения дистанции при зуме
|
||||||
|
|
||||||
|
// Скорость поворота камеры
|
||||||
|
[ToConfig] public float rotationSpeed = 0.3f;
|
||||||
|
|
||||||
|
[ToConfig] public float rotationSharpness = 100f; // Коэффициент плавности вращения камеры (чем выше - тем резче)
|
||||||
|
|
||||||
|
[ToConfig] public float followSharpness = 100f; // Коэффициент плавности следования за движущейся целью (чем выше - тем резче)
|
||||||
|
|
||||||
|
[ToConfig] public float minVerticalAngle = -70f; // Минимальный угол наклона камеры (вниз)
|
||||||
|
|
||||||
|
[ToConfig] public float maxVerticalAngle = 70f; // Максимальный угол наклона камеры (вверх)
|
||||||
|
|
||||||
|
[ToConfig] public float defaultVerticalAngle = 10f; // Стандартный угол наклона камеры
|
||||||
|
|
||||||
|
[ToConfig] public float fov = 60; // Комментарии оставляет только нейросеть и долбаёбы, никому и так не будет понятно, что ты высрал
|
||||||
|
|
||||||
|
[ToConfig] public CameraMode cameraMode;
|
||||||
|
|
||||||
|
// Позиция следования по умолчанию
|
||||||
|
[ToConfig] public Vector3 defaultFollowPosition = Vector3.zero;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 5442de773645443b99f8b0733199a854
|
||||||
|
timeCreated: 1766657458
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using Code.Infrastructure.EventBus;
|
||||||
|
using Code.Infrastructure.Generators;
|
||||||
|
using Code.Infrastructure.Input;
|
||||||
|
using Reflex.Attributes;
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Camera
|
||||||
|
{
|
||||||
|
public enum CameraMode
|
||||||
|
{
|
||||||
|
None,
|
||||||
|
FirstPerson,
|
||||||
|
Static,
|
||||||
|
Cinematic
|
||||||
|
}
|
||||||
|
|
||||||
|
[Config("Configs/Camera/CameraConfig")]
|
||||||
|
public class GameCamera
|
||||||
|
{
|
||||||
|
[ToConfig] public AssetReference Camera;
|
||||||
|
}
|
||||||
|
|
||||||
|
public interface ICameraInitializedHandle : IGlobalSubscriber
|
||||||
|
{
|
||||||
|
void CameraInitialized(CameraStateMachineContext.CameraLoadedData data);
|
||||||
|
}
|
||||||
|
|
||||||
|
public class CameraStateMachineContext
|
||||||
|
{
|
||||||
|
public class CameraLoadedData
|
||||||
|
{
|
||||||
|
public UnityEngine.Camera Camera;
|
||||||
|
public Dictionary<CameraMode, CameraSettingsConfig> SettingsConfigs;
|
||||||
|
|
||||||
|
public CameraLoadedData(UnityEngine.Camera camera, Dictionary<CameraMode, CameraSettingsConfig> settingsConfigs)
|
||||||
|
{
|
||||||
|
Camera = camera;
|
||||||
|
SettingsConfigs = settingsConfigs;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public CameraLoadedData cameraLoadedData;
|
||||||
|
|
||||||
|
[Inject] public IInputService InputService;
|
||||||
|
[Inject] public EventBus.EventBus EventBus;
|
||||||
|
}
|
||||||
|
|
||||||
|
[Generators.StateMachine(typeof(CameraStateMachineContext), typeof(CameraMode))]
|
||||||
|
public partial class CameraStateMachine
|
||||||
|
{
|
||||||
|
public UnityEngine.Camera Camera => StateMachineContext.cameraLoadedData.Camera;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b220b02510c34ea08257cc951d949fd7
|
||||||
|
timeCreated: 1761671720
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
using Code.Infrastructure.Camera.CameraStates;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Camera
|
||||||
|
{
|
||||||
|
public class CameraStateMachineRunner : MonoBehaviour
|
||||||
|
{
|
||||||
|
public CameraStateMachine StateMachine;
|
||||||
|
|
||||||
|
private void Update()
|
||||||
|
{
|
||||||
|
((BaseCameraState)StateMachine.CurrentBaseState).Update();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void LateUpdate()
|
||||||
|
{
|
||||||
|
((BaseCameraState)StateMachine.CurrentBaseState).LateUpdate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 293de8ebc2f54fa097ba2f1be8c8ed41
|
||||||
|
timeCreated: 1767277431
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: d7399e433dff42a185f62d79b546b059
|
||||||
|
timeCreated: 1761671908
|
||||||
@@ -0,0 +1,48 @@
|
|||||||
|
using Code.Infrastructure.StateMachine;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Camera.CameraStates
|
||||||
|
{
|
||||||
|
// [State(typeof(CameraMode),typeof(CameraStateMachineContext))]
|
||||||
|
public abstract class BaseCameraState : BaseState<CameraMode, CameraStateMachineContext>
|
||||||
|
{
|
||||||
|
protected EventBus.EventBus _eventBus;
|
||||||
|
|
||||||
|
|
||||||
|
// Трансформ объекта, за которым следует камера
|
||||||
|
protected Transform FollowTransform;
|
||||||
|
|
||||||
|
// Позиция следования: текущая сглаженная позиция и горизонтальное направление камеры
|
||||||
|
protected Vector3 CurrentFollowPosition;
|
||||||
|
|
||||||
|
// Целевой вертикальный угол камеры (наклон вверх/вниз)
|
||||||
|
protected float TargetVerticalAngle;
|
||||||
|
|
||||||
|
// Текущая и целевая дистанция камеры от цели
|
||||||
|
protected float CurrentDistance, TargetDistance;
|
||||||
|
|
||||||
|
// Исходные значения дистанции для восстановления
|
||||||
|
protected float OriginalDefaultDistance, OriginalMinDistance, OriginalMaxDistance;
|
||||||
|
|
||||||
|
// Горизонтальное направление камеры (проекция forward на плоскость)
|
||||||
|
protected Vector3 PlanarDirection { get; set; }
|
||||||
|
protected BaseCameraState(CameraStateMachineContext context, EventBus.EventBus eventBus) : base(context, eventBus)
|
||||||
|
{
|
||||||
|
_eventBus = eventBus;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Основной метод обновления камеры, вызываемый извне каждый кадр
|
||||||
|
protected void UpdateWithInput(float deltaTime, Vector3 rotationInput)
|
||||||
|
{
|
||||||
|
// Обработка ввода и позиционирования
|
||||||
|
HandleRotationInput(deltaTime, rotationInput, out var targetRotation);
|
||||||
|
HandlePosition(deltaTime , targetRotation);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected abstract void HandlePosition(float deltaTime, object o);
|
||||||
|
|
||||||
|
protected abstract void HandleRotationInput(float deltaTime, Vector3 rotationInput, out Quaternion q);
|
||||||
|
public abstract void Update();
|
||||||
|
public abstract void LateUpdate();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 7901175f2c0646fda8741c4c269ce54b
|
||||||
|
timeCreated: 1767127681
|
||||||
@@ -0,0 +1,110 @@
|
|||||||
|
using Code.Example.Liminal.Player;
|
||||||
|
using Code.Infrastructure.Generators;
|
||||||
|
using Code.Infrastructure.Input;
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.InputSystem;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Camera.CameraStates
|
||||||
|
{
|
||||||
|
|
||||||
|
[State(typeof(CameraMode),typeof(CameraStateMachineContext), true)]
|
||||||
|
public partial class FirstPersonCameraState : BaseCameraState
|
||||||
|
{
|
||||||
|
private CameraSettingsConfig _settings;
|
||||||
|
|
||||||
|
public FirstPersonCameraState(CameraStateMachineContext context, EventBus.EventBus eventBus) : base(context, eventBus)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public override CameraMode myState => CameraMode.FirstPerson;
|
||||||
|
protected override void OnEnterState()
|
||||||
|
{
|
||||||
|
_settings = Context.cameraLoadedData.SettingsConfigs[myState];
|
||||||
|
|
||||||
|
Context.InputService.BindActionPerformed((int)ActionMappings.Gameplay, (int) GameplayActions.Look, OnLookPerformed);
|
||||||
|
Context.InputService.BindActionCancel((int)ActionMappings.Gameplay, (int) GameplayActions.Look, OnLookCanceled);
|
||||||
|
}
|
||||||
|
protected override void HandleRotationInput(float deltaTime, Vector3 rotationInput, out Quaternion targetRotation)
|
||||||
|
{
|
||||||
|
// Вращение вокруг вертикальной оси (горизонтальный поворот)
|
||||||
|
var rotationFromInput = Quaternion.Euler(Vector3.up * (rotationInput.x * _settings.rotationSpeed));
|
||||||
|
PlanarDirection = rotationFromInput * PlanarDirection;
|
||||||
|
var planarRotation = Quaternion.LookRotation(PlanarDirection, FollowTransform.up);
|
||||||
|
|
||||||
|
// Вращение вокруг горизонтальной оси (вертикальный наклон)
|
||||||
|
TargetVerticalAngle -= rotationInput.y * _settings.rotationSpeed;
|
||||||
|
TargetVerticalAngle = Mathf.Clamp(TargetVerticalAngle, _settings.minVerticalAngle, _settings.maxVerticalAngle);
|
||||||
|
var verticalRotation = Quaternion.Euler(TargetVerticalAngle, 0, 0);
|
||||||
|
|
||||||
|
// Интерполяция к целевому вращению для плавности
|
||||||
|
targetRotation = Quaternion.Slerp(Context.cameraLoadedData.Camera.transform.rotation, planarRotation * verticalRotation, deltaTime * _settings.rotationSharpness);
|
||||||
|
|
||||||
|
// Применение финального вращения
|
||||||
|
Context.cameraLoadedData.Camera.transform.rotation = targetRotation;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnExitState()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void HandlePosition(float deltaTime, object targetRotation)
|
||||||
|
{
|
||||||
|
// Плавное следование за целью с использованием экспоненциального сглаживания
|
||||||
|
// CurrentFollowPosition = Vector3.Lerp(CurrentFollowPosition, FollowTransform.position, 1f - Mathf.Exp(-_settings.followSharpness * deltaTime));
|
||||||
|
|
||||||
|
// В FirstPerson режиме камера находится прямо на позиции цели Да ну нахуй чё правда пиздец
|
||||||
|
// var targetPosition = CurrentFollowPosition;
|
||||||
|
|
||||||
|
// Установка финальной позиции камеры Да ну нахуй чё правда пиздец
|
||||||
|
Context.cameraLoadedData.Camera.transform.position = FollowTransform.position;
|
||||||
|
}
|
||||||
|
|
||||||
|
private Vector2 _lookInput;
|
||||||
|
|
||||||
|
private void OnLookPerformed(InputAction.CallbackContext context)
|
||||||
|
{
|
||||||
|
_lookInput = context.ReadValue<Vector2>();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnLookCanceled(InputAction.CallbackContext context)
|
||||||
|
{
|
||||||
|
_lookInput = Vector2.zero;
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Update()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void LateUpdate()
|
||||||
|
{
|
||||||
|
// Обновляем камеру только если есть цель для следования
|
||||||
|
// if (FollowTransform)
|
||||||
|
// {
|
||||||
|
// UpdateWithInput(Time.deltaTime, _lookInput);
|
||||||
|
// }
|
||||||
|
if (_playerMovementController)
|
||||||
|
{
|
||||||
|
UpdateWithInput(Time.deltaTime, _lookInput);
|
||||||
|
|
||||||
|
_playerMovementController.SetCameraRotation(Context.cameraLoadedData.Camera.transform.rotation);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void SetFollowTransform(Transform t)
|
||||||
|
{
|
||||||
|
FollowTransform = t;
|
||||||
|
CurrentFollowPosition = t.position;
|
||||||
|
PlanarDirection = t.forward; // Начальное направление совпадает с направлением цели
|
||||||
|
}
|
||||||
|
|
||||||
|
private PlayerMovementController _playerMovementController;
|
||||||
|
public void SetPlayer(PlayerMovementController playerMovementController)
|
||||||
|
{
|
||||||
|
_playerMovementController = playerMovementController;
|
||||||
|
|
||||||
|
FollowTransform = _playerMovementController.PlayerHeadPoint;
|
||||||
|
CurrentFollowPosition = _playerMovementController.PlayerHeadPoint.position;
|
||||||
|
PlanarDirection = _playerMovementController.PlayerHeadPoint.forward; // Начальное направление совпадает с направлением цели
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 850f6325ab66480e9f7d1c03dbb37030
|
||||||
|
timeCreated: 1767346203
|
||||||
@@ -0,0 +1,40 @@
|
|||||||
|
using Code.Infrastructure.Generators;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Camera.CameraStates
|
||||||
|
{
|
||||||
|
[State(typeof(CameraMode),typeof(CameraStateMachineContext), true)]
|
||||||
|
public partial class NoneCameraState : BaseCameraState
|
||||||
|
{
|
||||||
|
public NoneCameraState(CameraStateMachineContext context, EventBus.EventBus eventBus) : base(context, eventBus)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public override CameraMode myState => CameraMode.None;
|
||||||
|
protected override void OnEnterState()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnExitState()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void HandlePosition(float deltaTime, object targetRotation)
|
||||||
|
{
|
||||||
|
throw new System.NotImplementedException();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void HandleRotationInput(float deltaTime, Vector3 rotationInput, out Quaternion q)
|
||||||
|
{
|
||||||
|
throw new System.NotImplementedException();
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Update()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void LateUpdate()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: cb14de48ff13488c8edb4431ac34e5be
|
||||||
|
timeCreated: 1767301090
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ef0499dec5324e12b82f8688c6d3b3d8
|
||||||
|
timeCreated: 1765711304
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using Code.Infrastructure.SceneLoader;
|
||||||
|
using Cysharp.Threading.Tasks;
|
||||||
|
using Reflex.Core;
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Configs
|
||||||
|
{
|
||||||
|
public partial class ConfigLocator : IConfigLocator
|
||||||
|
{
|
||||||
|
private Dictionary<Type, AssetReference> _singleConfigReferences = new();
|
||||||
|
private Dictionary<Type, string> _multipleConfigReferences = new();
|
||||||
|
|
||||||
|
public AssetReference TryGetConfigAssetReference<T>() => _singleConfigReferences.GetValueOrDefault(typeof(T), null);
|
||||||
|
public string TryGetManyConfigAssetReferences<T>() => _multipleConfigReferences.GetValueOrDefault(typeof(T), null);
|
||||||
|
|
||||||
|
partial void LoadConfigs();
|
||||||
|
|
||||||
|
public ConfigLocator()
|
||||||
|
{
|
||||||
|
LoadSystemConfigs();
|
||||||
|
|
||||||
|
LoadConfigs();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void LoadSystemConfigs()
|
||||||
|
{
|
||||||
|
SystemConfigsReferences systemConfigsReferences = Resources.Load<SystemConfigsReferences>("SystemConfigsReferences");
|
||||||
|
|
||||||
|
_singleConfigReferences.Add(typeof(ScenesAssetReferences), systemConfigsReferences.scenesAssetReferences);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 42496064fd5d42fea1c889f91e6a7e98
|
||||||
|
timeCreated: 1765711330
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Configs
|
||||||
|
{
|
||||||
|
[CreateAssetMenu(fileName = "SystemConfigsReferences", menuName = "Configs/SystemConfigsReferences")]
|
||||||
|
public partial class SystemConfigsReferences : ScriptableObject
|
||||||
|
{
|
||||||
|
public AssetReference scenesAssetReferences;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 728b0ad306a64bd28d47fc4d052c5e81
|
||||||
|
timeCreated: 1766325607
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 7b34014c0c80c914baed6d14ef39dada
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -0,0 +1,69 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using Cysharp.Threading.Tasks;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.EventBus
|
||||||
|
{
|
||||||
|
public class EventBus
|
||||||
|
{
|
||||||
|
private Dictionary<Type, SubscribersList<IGlobalSubscriber>> s_Subscribers
|
||||||
|
= new();
|
||||||
|
|
||||||
|
public void Subscribe(IGlobalSubscriber subscriber)
|
||||||
|
{
|
||||||
|
List<Type> subscriberTypes = EventBusHelper.GetSubscriberTypes(subscriber);
|
||||||
|
foreach (Type t in subscriberTypes)
|
||||||
|
{
|
||||||
|
if (!s_Subscribers.ContainsKey(t))
|
||||||
|
{
|
||||||
|
s_Subscribers[t] = new SubscribersList<IGlobalSubscriber>();
|
||||||
|
}
|
||||||
|
s_Subscribers[t].Add(subscriber);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Unsubscribe(IGlobalSubscriber subscriber)
|
||||||
|
{
|
||||||
|
List<Type> subscriberTypes = EventBusHelper.GetSubscriberTypes(subscriber);
|
||||||
|
foreach (Type t in subscriberTypes)
|
||||||
|
{
|
||||||
|
if (s_Subscribers.ContainsKey(t))
|
||||||
|
s_Subscribers[t].Remove(subscriber);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void RaiseEvent<TSubscriber>(Action<TSubscriber> action)
|
||||||
|
where TSubscriber : class, IGlobalSubscriber
|
||||||
|
{
|
||||||
|
if (!s_Subscribers.ContainsKey(typeof(TSubscriber))) return;
|
||||||
|
|
||||||
|
SubscribersList<IGlobalSubscriber> subscribers = s_Subscribers[typeof(TSubscriber)];
|
||||||
|
|
||||||
|
subscribers.Executing = true;
|
||||||
|
|
||||||
|
InvokeSubscribers(action, subscribers);
|
||||||
|
|
||||||
|
subscribers.Executing = false;
|
||||||
|
subscribers.Cleanup();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void InvokeSubscribers<TSubscriber>(Action<TSubscriber> action, SubscribersList<IGlobalSubscriber> subscribers)
|
||||||
|
where TSubscriber : class, IGlobalSubscriber
|
||||||
|
{
|
||||||
|
for ( int i = 0; i < subscribers.List.Count; i++)
|
||||||
|
{
|
||||||
|
Debug.Log("Invoking " + typeof(TSubscriber).Name);
|
||||||
|
IGlobalSubscriber subscriber = subscribers.List[i];
|
||||||
|
try
|
||||||
|
{
|
||||||
|
action.Invoke(subscriber as TSubscriber);
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Debug.LogError(e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: b0547f2543ccf5e47b9ec486f35aa2df
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.EventBus
|
||||||
|
{
|
||||||
|
internal static class EventBusHelper
|
||||||
|
{
|
||||||
|
private static Dictionary<Type, List<Type>> s_CashedSubscriberTypes =
|
||||||
|
new();
|
||||||
|
|
||||||
|
public static List<Type> GetSubscriberTypes(
|
||||||
|
IGlobalSubscriber globalSubscriber)
|
||||||
|
{
|
||||||
|
Type type = globalSubscriber.GetType();
|
||||||
|
if (s_CashedSubscriberTypes.ContainsKey(type))
|
||||||
|
{
|
||||||
|
return s_CashedSubscriberTypes[type];
|
||||||
|
}
|
||||||
|
|
||||||
|
List<Type> subscriberTypes = type
|
||||||
|
.GetInterfaces()
|
||||||
|
.Where(t => t.GetInterfaces()
|
||||||
|
.Contains(typeof(IGlobalSubscriber)))
|
||||||
|
.ToList();
|
||||||
|
|
||||||
|
s_CashedSubscriberTypes[type] = subscriberTypes;
|
||||||
|
return subscriberTypes;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ab2b1bcff76d5614dbda77a3c7b24158
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
namespace Code.Infrastructure.EventBus
|
||||||
|
{
|
||||||
|
public interface IGlobalSubscriber
|
||||||
|
{ }
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: fe414b0de24841347b03eec77d1855c0
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.EventBus
|
||||||
|
{
|
||||||
|
internal class SubscribersList<TSubscriber> where TSubscriber : class
|
||||||
|
{
|
||||||
|
private bool m_NeedsCleanUp;
|
||||||
|
|
||||||
|
public bool Executing;
|
||||||
|
|
||||||
|
public readonly List<TSubscriber> List = new(); // TODO Weakptr
|
||||||
|
|
||||||
|
public void Add(TSubscriber subscriber)
|
||||||
|
{
|
||||||
|
List.Add(subscriber);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Remove(TSubscriber subscriber)
|
||||||
|
{
|
||||||
|
if (Executing)
|
||||||
|
{
|
||||||
|
var i = List.IndexOf(subscriber);
|
||||||
|
if (i >= 0)
|
||||||
|
{
|
||||||
|
m_NeedsCleanUp = true;
|
||||||
|
List[i] = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
List.Remove(subscriber);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void Cleanup()
|
||||||
|
{
|
||||||
|
if (!m_NeedsCleanUp)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
List.RemoveAll(s => s == null);
|
||||||
|
m_NeedsCleanUp = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: d364e9c8ac1c255428486d5892d23c1d
|
||||||
File renamed without changes.
@@ -0,0 +1,49 @@
|
|||||||
|
using System;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Generators
|
||||||
|
{
|
||||||
|
public class StateMachine : Attribute
|
||||||
|
{
|
||||||
|
public Type StateMachineContextType;
|
||||||
|
public Type StateMachineEnumType;
|
||||||
|
|
||||||
|
public StateMachine(Type stateMachineContextType, Type stateMachineEnumType)
|
||||||
|
{
|
||||||
|
StateMachineContextType = stateMachineContextType;
|
||||||
|
StateMachineEnumType = stateMachineEnumType;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public class State : Attribute
|
||||||
|
{
|
||||||
|
public Type StateEnum;
|
||||||
|
public Type StateMachineContext;
|
||||||
|
public bool SilentBitch; // Поэтому нейминг переменных очень важен
|
||||||
|
|
||||||
|
public State(Type stateEnum,Type stateMachineContext, bool silentBitch = false)
|
||||||
|
{
|
||||||
|
StateEnum = stateEnum;
|
||||||
|
StateMachineContext = stateMachineContext;
|
||||||
|
SilentBitch = silentBitch;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public class StateRaisingEvent : Attribute
|
||||||
|
{
|
||||||
|
}
|
||||||
|
public class Config : Attribute
|
||||||
|
{
|
||||||
|
public bool Multiple;
|
||||||
|
public string MenuName;
|
||||||
|
public Config(string menuName, bool multiple = false)
|
||||||
|
{
|
||||||
|
Multiple = multiple;
|
||||||
|
MenuName = menuName;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public class ToConfig : Attribute
|
||||||
|
{
|
||||||
|
}
|
||||||
|
public class SceneIdEnum : Attribute
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
File renamed without changes.
@@ -0,0 +1,109 @@
|
|||||||
|
using System.Linq;
|
||||||
|
using Unity.VisualScripting;
|
||||||
|
using UnityCodeGen;
|
||||||
|
using UnityEditor;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Generators
|
||||||
|
{
|
||||||
|
[Generator]
|
||||||
|
public class ConfigGenerator : ICodeGenerator
|
||||||
|
{
|
||||||
|
public void Execute(GeneratorContext context)
|
||||||
|
{
|
||||||
|
var configs = TypeCache.GetTypesWithAttribute<Config>();
|
||||||
|
|
||||||
|
var configsCode = "";
|
||||||
|
var configAddCode = "";
|
||||||
|
var configReferencesCode = "";
|
||||||
|
var configReferencesUsingsCode = "";
|
||||||
|
var configOfConfigsCode = "";
|
||||||
|
|
||||||
|
foreach (var cfg in configs)
|
||||||
|
{
|
||||||
|
var configFields = "";
|
||||||
|
var configUsings = "";
|
||||||
|
|
||||||
|
var mem = cfg.GetFields();
|
||||||
|
var members = mem.Where(m => m.HasAttribute<ToConfig>()).ToList();
|
||||||
|
foreach (var m in members)
|
||||||
|
{
|
||||||
|
configUsings += $"using {m.FieldType.Namespace};\n";
|
||||||
|
configFields += $"public {m.FieldType.FullName} {m.Name};\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
var attribute = cfg.GetAttribute<Config>();
|
||||||
|
|
||||||
|
configUsings += @"
|
||||||
|
using UnityEngine;
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
";
|
||||||
|
var configCode = $@"
|
||||||
|
#pragma warning disable CS0105
|
||||||
|
{configUsings}
|
||||||
|
namespace {cfg.Namespace}{{
|
||||||
|
#pragma warning restore CS0105
|
||||||
|
[CreateAssetMenu(fileName = ""{cfg.Name}Config"", menuName = ""{attribute.MenuName}"")]
|
||||||
|
public class {cfg.Name}Config : ScriptableObject
|
||||||
|
{{
|
||||||
|
{configFields}
|
||||||
|
}}
|
||||||
|
}}
|
||||||
|
";
|
||||||
|
context.AddCode($"{cfg.Name}Config.Generated.cs", configCode);
|
||||||
|
|
||||||
|
configReferencesUsingsCode += $"using {cfg.Namespace};\n";
|
||||||
|
|
||||||
|
if (attribute.Multiple)
|
||||||
|
{
|
||||||
|
configReferencesCode += $"public string {cfg.Name};\n";
|
||||||
|
configAddCode += $@"
|
||||||
|
_multipleConfigReferences.Add(typeof({cfg.FullName}Config), systemConfigsReferences.{cfg.Name});
|
||||||
|
";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
configReferencesCode += $"public AssetReference {cfg.Name};\n";
|
||||||
|
configAddCode += $@"
|
||||||
|
_singleConfigReferences.Add(typeof({cfg.FullName}Config), systemConfigsReferences.{cfg.Name});
|
||||||
|
";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
configsCode += $@"
|
||||||
|
#pragma warning disable CS0105
|
||||||
|
{configReferencesUsingsCode}
|
||||||
|
using UnityEngine;
|
||||||
|
#pragma warning restore CS0105
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Configs
|
||||||
|
{{
|
||||||
|
|
||||||
|
public partial class ConfigLocator
|
||||||
|
{{
|
||||||
|
partial void LoadConfigs()
|
||||||
|
{{
|
||||||
|
SystemConfigsReferences systemConfigsReferences = Resources.Load<SystemConfigsReferences>(""SystemConfigsReferences"");
|
||||||
|
{configAddCode}
|
||||||
|
//_singleConfigReferences.Add(typeof(ScenesAssetReferences), systemConfigsReferences.scenesAssetReferences);
|
||||||
|
}}
|
||||||
|
}}
|
||||||
|
}}
|
||||||
|
";
|
||||||
|
context.AddCode($"ConfigLocator.Generated.cs", configsCode);
|
||||||
|
|
||||||
|
configOfConfigsCode += $@"
|
||||||
|
#pragma warning disable CS0105
|
||||||
|
{configReferencesUsingsCode}
|
||||||
|
using UnityEngine.AddressableAssets;
|
||||||
|
#pragma warning restore CS0105
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Configs{{
|
||||||
|
public partial class SystemConfigsReferences
|
||||||
|
{{
|
||||||
|
{configReferencesCode}
|
||||||
|
}}
|
||||||
|
}}
|
||||||
|
";
|
||||||
|
context.AddCode($"SystemConfigsReferences.Generated.cs", configOfConfigsCode);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 026403be8eae4546adcb407308031c1d
|
||||||
|
timeCreated: 1765660396
|
||||||
@@ -0,0 +1,148 @@
|
|||||||
|
using System.Linq;
|
||||||
|
using Unity.VisualScripting;
|
||||||
|
using UnityCodeGen;
|
||||||
|
using UnityEditor;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.Generators
|
||||||
|
{
|
||||||
|
[Generator]
|
||||||
|
public class SceneLoaderGenerator : ICodeGenerator
|
||||||
|
{
|
||||||
|
public void Execute(GeneratorContext context)
|
||||||
|
{
|
||||||
|
var Enum = TypeCache.GetTypesWithAttribute<SceneIdEnum>();
|
||||||
|
|
||||||
|
var loaderCode = "";
|
||||||
|
var dictionaryCode = "";
|
||||||
|
var interfacesCode = "";
|
||||||
|
var interfacesUsingsCode = $@"
|
||||||
|
using Code.Infrastructure.EventBus;
|
||||||
|
";
|
||||||
|
|
||||||
|
foreach (var en in Enum)
|
||||||
|
{
|
||||||
|
if (!en.IsEnum) return;
|
||||||
|
|
||||||
|
var members = en.GetFields();
|
||||||
|
foreach (var member in members)
|
||||||
|
{
|
||||||
|
if(member.FieldType.FullName != en.FullName) continue;
|
||||||
|
interfacesCode += $@"
|
||||||
|
public interface IOn{member.Name}SceneLoadedHandler : IGlobalSubscriber
|
||||||
|
{{
|
||||||
|
void On{member.Name}SceneLoaded();
|
||||||
|
}}
|
||||||
|
";
|
||||||
|
dictionaryCode += $@"
|
||||||
|
|
||||||
|
_scenesActions.Add(SceneId.{member.Name},() => _eventBus.RaiseEvent<IOn{member.Name}SceneLoadedHandler>(h=> h.On{member.Name}SceneLoaded()));
|
||||||
|
";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
loaderCode = $@"
|
||||||
|
#pragma warning disable CS0105
|
||||||
|
{interfacesUsingsCode}
|
||||||
|
#pragma warning restore CS0105
|
||||||
|
|
||||||
|
namespace Code.Infrastructure.SceneLoader
|
||||||
|
{{
|
||||||
|
public partial class SceneLoader{{
|
||||||
|
partial void SetupScenesInfo(){{
|
||||||
|
{dictionaryCode}
|
||||||
|
}}
|
||||||
|
}}
|
||||||
|
{interfacesCode}
|
||||||
|
}}
|
||||||
|
";
|
||||||
|
context.AddCode($"SceneLoader.Generated.cs", loaderCode);
|
||||||
|
// var configsCode = "";
|
||||||
|
// var configCode = "";
|
||||||
|
// var configUsings = "";
|
||||||
|
// var configFields = "";
|
||||||
|
// var configAddCode = "";
|
||||||
|
// var configReferencesCode = "";
|
||||||
|
// var configReferencesUsingsCode = "";
|
||||||
|
// var configOfConfigsCode = "";
|
||||||
|
//
|
||||||
|
// foreach (var cfg in configs)
|
||||||
|
// {
|
||||||
|
// var mem = cfg.GetFields();
|
||||||
|
// var members = mem.Where(m => m.HasAttribute<ToConfig>()).ToList();
|
||||||
|
// foreach (var m in members)
|
||||||
|
// {
|
||||||
|
// configUsings += $"using {m.FieldType.Namespace};\n";
|
||||||
|
// configFields += $"public {m.FieldType.FullName} {m.Name};\n";
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// var attribute = cfg.GetAttribute<Config>();
|
||||||
|
//
|
||||||
|
// configUsings += @"
|
||||||
|
// using UnityEngine;
|
||||||
|
// using UnityEngine.AddressableAssets;
|
||||||
|
// ";
|
||||||
|
// configCode = $@"
|
||||||
|
// {configUsings}
|
||||||
|
// namespace {cfg.Namespace}{{
|
||||||
|
// [CreateAssetMenu(fileName = ""{cfg.Name}Config"", menuName = ""{attribute.MenuName}"")]
|
||||||
|
// public class {cfg.Name}Config : ScriptableObject
|
||||||
|
// {{
|
||||||
|
// {configFields}
|
||||||
|
// }}
|
||||||
|
// }}
|
||||||
|
// ";
|
||||||
|
// context.AddCode($"{cfg.Name}Config.Generated.cs", configCode);
|
||||||
|
//
|
||||||
|
// configReferencesUsingsCode += $"using {cfg.Namespace};\n";
|
||||||
|
//
|
||||||
|
// if (attribute.Multiple)
|
||||||
|
// {
|
||||||
|
// configReferencesCode += $"public String {cfg.Name};\n";
|
||||||
|
// configAddCode += $@"
|
||||||
|
// _multipleConfigReferences.Add(typeof({cfg.FullName}), systemConfigsReferences.{cfg.Name});
|
||||||
|
// ";
|
||||||
|
// }
|
||||||
|
// else
|
||||||
|
// {
|
||||||
|
// configReferencesCode += $"public AssetReference {cfg.Name};\n";
|
||||||
|
// configAddCode += $@"
|
||||||
|
// _singleConfigReferences.Add(typeof({cfg.FullName}Config), systemConfigsReferences.{cfg.Name});
|
||||||
|
// ";
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// configsCode += $@"
|
||||||
|
// {configReferencesUsingsCode}
|
||||||
|
// using UnityEngine;
|
||||||
|
//
|
||||||
|
// namespace Code.Infrastructure.Configs
|
||||||
|
// {{
|
||||||
|
//
|
||||||
|
// public partial class ConfigLocator
|
||||||
|
// {{
|
||||||
|
// partial void LoadConfigs()
|
||||||
|
// {{
|
||||||
|
// SystemConfigsReferences systemConfigsReferences = Resources.Load<SystemConfigsReferences>(""SystemConfigsReferences"");
|
||||||
|
// {configAddCode}
|
||||||
|
// //_singleConfigReferences.Add(typeof(ScenesAssetReferences), systemConfigsReferences.scenesAssetReferences);
|
||||||
|
// }}
|
||||||
|
// }}
|
||||||
|
// }}
|
||||||
|
// ";
|
||||||
|
// context.AddCode($"ConfigLocator.Generated.cs", configsCode);
|
||||||
|
//
|
||||||
|
// configOfConfigsCode += $@"
|
||||||
|
// {configReferencesUsingsCode}
|
||||||
|
// using UnityEngine.AddressableAssets;
|
||||||
|
//
|
||||||
|
// namespace Code.Infrastructure.Configs{{
|
||||||
|
// public partial class SystemConfigsReferences
|
||||||
|
// {{
|
||||||
|
// {configReferencesCode}
|
||||||
|
// }}
|
||||||
|
// }}
|
||||||
|
// ";
|
||||||
|
// context.AddCode($"SystemConfigsReferences.Generated.cs", configOfConfigsCode);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Loaded 100 of 734 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user