├── Assets ├── Plane │ ├── plane.fbx │ ├── Plane_Blue.png │ ├── Plane_White.png │ ├── Plane_Orange.png │ ├── Plane_Yellow.png │ ├── Plane.mat.meta │ ├── plane.fbx.meta │ ├── Plane_Blue.png.meta │ ├── Plane_Orange.png.meta │ ├── Plane_White.png.meta │ ├── Plane_Yellow.png.meta │ └── Plane.mat ├── SampleInfo │ ├── Icons │ │ ├── BrgIcon.png │ │ ├── Help_Icon.png │ │ ├── BrgIcon.png.meta │ │ └── Help_Icon.png.meta │ ├── Layout.wlt.meta │ ├── Icons.meta │ ├── Scripts.meta │ └── Scripts │ │ ├── Editor.meta │ │ ├── Editor │ │ ├── ReadmeEditor.cs.meta │ │ └── ReadmeEditor.cs │ │ ├── Readme.cs │ │ └── Readme.cs.meta ├── Prefabs │ ├── Bullet.prefab.meta │ ├── Enemy.prefab.meta │ ├── MainCharacter.prefab.meta │ ├── Enemy.prefab │ ├── Bullet.prefab │ └── MainCharacter.prefab ├── Plane.meta ├── Prefabs.meta ├── Presets.meta ├── Scenes.meta ├── Scenes │ ├── brg_shooter.unity.meta │ ├── SampleSceneLightingSettings.lighting.meta │ └── SampleSceneLightingSettings.lighting ├── Scripts.meta ├── Materials.meta ├── Settings.meta ├── Presets │ ├── Defaults.meta │ ├── AudioCompressedInMemory.preset.meta │ ├── AudioStreaming.preset.meta │ ├── Defaults │ │ ├── AudioDecompressOnLoad.preset.meta │ │ ├── AlbedoTexture_Default.preset.meta │ │ ├── DirectionalLight_Default.preset.meta │ │ ├── DirectionalLight_Default.preset │ │ └── AudioDecompressOnLoad.preset │ ├── NormalTexture.preset.meta │ ├── UtilityTexture.preset.meta │ ├── AudioStreaming.preset │ └── AudioCompressedInMemory.preset ├── Scripts │ ├── Gameplay.meta │ ├── BRG_Debris.cs.meta │ ├── BRG_Background.cs.meta │ ├── BRG_Container.cs.meta │ ├── Gameplay │ │ ├── WaveSpawner.cs.meta │ │ ├── EnemyMovement.cs.meta │ │ ├── BulletKillingEnemy.cs.meta │ │ ├── MainCharacterMovement.cs.meta │ │ ├── EnemyMovement.cs │ │ ├── BulletKillingEnemy.cs │ │ ├── WaveSpawner.cs │ │ └── MainCharacterMovement.cs │ ├── SRPBatcherProfiler.cs.meta │ └── SRPBatcherProfiler.cs ├── Readme.asset.meta ├── Materials │ ├── Skybox_Mat.mat.meta │ ├── tmp_mat.mat.meta │ ├── Bullet_Mat.mat.meta │ ├── EnemyBody.mat.meta │ ├── debris_mat.mat.meta │ ├── main_ship.mat.meta │ ├── background_mat.mat.meta │ ├── Skybox_Mat.mat │ ├── Bullet_Mat.mat │ ├── tmp_mat.mat │ ├── main_ship.mat │ ├── EnemyBody.mat │ ├── background_mat.mat │ └── debris_mat.mat ├── Settings │ ├── UniversalRenderer.asset.meta │ ├── SampleSceneProfile.asset.meta │ ├── UniversalRP-LowQuality.asset.meta │ ├── UniversalRP-HighQuality.asset.meta │ ├── UniversalRP-MediumQuality.asset.meta │ ├── UniversalRenderer.asset │ ├── SampleSceneProfile.asset │ ├── UniversalRP-HighQuality.asset │ ├── UniversalRP-LowQuality.asset │ └── UniversalRP-MediumQuality.asset ├── SampleInfo.meta ├── UniversalRenderPipelineGlobalSettings.asset.meta ├── Readme.asset └── UniversalRenderPipelineGlobalSettings.asset ├── img └── brg_shooter_img.png ├── ProjectSettings ├── ProjectVersion.txt ├── CommonBurstAotSettings.json ├── Packages │ └── com.unity.testtools.codecoverage │ │ └── Settings.json ├── ClusterInputManager.asset ├── XRSettings.asset ├── VersionControlSettings.asset ├── TimeManager.asset ├── EditorBuildSettings.asset ├── BurstAotSettings_StandaloneWindows.json ├── URPProjectSettings.asset ├── BurstAotSettings_Android.json ├── AudioManager.asset ├── ShaderGraphSettings.asset ├── TagManager.asset ├── VFXManager.asset ├── PresetManager.asset ├── UnityConnectSettings.asset ├── PackageManagerSettings.asset ├── MemorySettings.asset ├── DynamicsManager.asset ├── EditorSettings.asset ├── NavMeshAreas.asset ├── Physics2DSettings.asset ├── GraphicsSettings.asset ├── QualitySettings.asset └── SceneTemplateSettings.json ├── .vsconfig ├── UserSettings ├── Search.index ├── Search.settings └── EditorUserSettings.asset ├── README.md ├── LICENCE.md ├── Packages ├── manifest.json └── packages-lock.json └── .gitignore /Assets/Plane/plane.fbx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/Assets/Plane/plane.fbx -------------------------------------------------------------------------------- /img/brg_shooter_img.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/img/brg_shooter_img.png -------------------------------------------------------------------------------- /Assets/Plane/Plane_Blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/Assets/Plane/Plane_Blue.png -------------------------------------------------------------------------------- /Assets/Plane/Plane_White.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/Assets/Plane/Plane_White.png -------------------------------------------------------------------------------- /Assets/Plane/Plane_Orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/Assets/Plane/Plane_Orange.png -------------------------------------------------------------------------------- /Assets/Plane/Plane_Yellow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/Assets/Plane/Plane_Yellow.png -------------------------------------------------------------------------------- /ProjectSettings/ProjectVersion.txt: -------------------------------------------------------------------------------- 1 | m_EditorVersion: 2022.3.5f1 2 | m_EditorVersionWithRevision: 2022.3.5f1 (dfb457fab3c3) 3 | -------------------------------------------------------------------------------- /.vsconfig: -------------------------------------------------------------------------------- 1 | { 2 | "version": "1.0", 3 | "components": [ 4 | "Microsoft.VisualStudio.Workload.ManagedGame" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Icons/BrgIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/Assets/SampleInfo/Icons/BrgIcon.png -------------------------------------------------------------------------------- /Assets/SampleInfo/Icons/Help_Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Unity-Technologies/brg-shooter/main/Assets/SampleInfo/Icons/Help_Icon.png -------------------------------------------------------------------------------- /ProjectSettings/CommonBurstAotSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "MonoBehaviour": { 3 | "Version": 4, 4 | "DisabledWarnings": "" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /ProjectSettings/Packages/com.unity.testtools.codecoverage/Settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "m_Dictionary": { 3 | "m_DictionaryValues": [] 4 | } 5 | } -------------------------------------------------------------------------------- /ProjectSettings/ClusterInputManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!236 &1 4 | ClusterInputManager: 5 | m_ObjectHideFlags: 0 6 | m_Inputs: [] 7 | -------------------------------------------------------------------------------- /Assets/Prefabs/Bullet.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a8fdc418aafc8fc46a3c60a4b3f32fb3 3 | PrefabImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Prefabs/Enemy.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 56702322f5b1bd749b8d4d3032bb3d4b 3 | PrefabImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Plane.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 6147f36022919d842916d0d936fcacef 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Prefabs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a6d9bb41b7d86674d9926d6de292e194 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Prefabs/MainCharacter.prefab.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: be0b4e06cf41f5e4ba480f21230ade79 3 | PrefabImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Presets.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 558255460b74ec04fa70b5570e9327bd 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scenes.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c3328e9b52d0a6d4ca329386a6b26cba 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scenes/brg_shooter.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: f9e3cbf4310160c45a0cab2e00c2e7ac 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /Assets/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 02a3527b6b33a924e8ec66aa805ea717 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d0234ba368eeec9418390da711bfdad0 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Settings.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0735c275001a2c84dafdb30deced5d8d 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Presets/Defaults.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 71ea82b02df99c2439e0dc8e4e1ebc24 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1942b4a78afa4864894ad4c1095ae448 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Readme.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 83c2ed844a8c74b779a4c823d16594b1 3 | timeCreated: 1484217493 4 | licenseType: Store 5 | NativeFormatImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /ProjectSettings/XRSettings.asset: -------------------------------------------------------------------------------- 1 | { 2 | "m_SettingKeys": [ 3 | "VR Device Disabled", 4 | "VR Device User Alert" 5 | ], 6 | "m_SettingValues": [ 7 | "False", 8 | "False" 9 | ] 10 | } -------------------------------------------------------------------------------- /Assets/SampleInfo/Layout.wlt.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: eabc9546105bf4accac1fd62a63e88e6 3 | timeCreated: 1487337779 4 | licenseType: Store 5 | DefaultImporter: 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Plane/Plane.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7075db04099d1124c8d4de698c0df50a 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2100000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials/Skybox_Mat.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0ffaa0b7117ba8c47a9d05ae701d4b4d 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials/tmp_mat.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 479323ed597cc2844a62a28d9b5f961f 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2100000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials/Bullet_Mat.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 9d51b65aa0935484598903b7c9363ec9 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2100000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials/EnemyBody.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0d9631960905a0b4091d0287b1d097b8 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2100000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials/debris_mat.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7a3349277855dc346ab16cf8972e24bb 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2100000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials/main_ship.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 95865321b62321d4aa2a335d122f3c25 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2100000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRenderer.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 4a8e21d5c33334b11b34a596161b9360 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Materials/background_mat.mat.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 49a93f36c3c21d64c8287224384667f6 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2100000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/SampleInfo.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 49110bb8dcada46328ad741970bce702 3 | folderAsset: yes 4 | timeCreated: 1475590612 5 | licenseType: Store 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Settings/SampleSceneProfile.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 10fc4df2da32a41aaa32d77bc913491c 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRP-LowQuality.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a31e9f9f9c9d4b9429ed0d1234e22103 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Presets/AudioCompressedInMemory.preset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2dd802e4d37c65149922028d3e973832 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Icons.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8a0c9218a650547d98138cd835033977 3 | folderAsset: yes 4 | timeCreated: 1484670163 5 | licenseType: Store 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRP-HighQuality.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 19ba41d7c0026c3459d37c2fe90c55a0 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRP-MediumQuality.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d847b876476d3d6468f5dfcd34266f96 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /ProjectSettings/VersionControlSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!890905787 &1 4 | VersionControlSettings: 5 | m_ObjectHideFlags: 0 6 | m_Mode: Visible Meta Files 7 | m_CollabEditorSettings: 8 | inProgressEnabled: 1 9 | -------------------------------------------------------------------------------- /Assets/Presets/AudioStreaming.preset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 86bcce7f5575b54408aa0f3a7d321039 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2655988077585873504 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Presets/Defaults/AudioDecompressOnLoad.preset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e7689051185d12f4298e1ebb2693a29f 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Presets/NormalTexture.preset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 14a57cf3b9fa1c74b884aa7e0dcf1faa 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2655988077585873504 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Presets/UtilityTexture.preset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 45f7b2e3c78185248b3adbb14429c2ab 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2655988077585873504 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Scripts.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 5a9bcd70e6a4b4b05badaa72e827d8e0 3 | folderAsset: yes 4 | timeCreated: 1475835190 5 | licenseType: Store 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/Scenes/SampleSceneLightingSettings.lighting.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 477cc4148fad3449482a3bc3178594e2 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 0 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Scripts/Editor.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3ad9b87dffba344c89909c6d1b1c17e1 3 | folderAsset: yes 4 | timeCreated: 1475593892 5 | licenseType: Store 6 | DefaultImporter: 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /Assets/UniversalRenderPipelineGlobalSettings.asset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 38b35347542e5af4c9b140950c5b18db 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 11400000 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /ProjectSettings/TimeManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!5 &1 4 | TimeManager: 5 | m_ObjectHideFlags: 0 6 | Fixed Timestep: 0.02 7 | Maximum Allowed Timestep: 0.1 8 | m_TimeScale: 1 9 | Maximum Particle Timestep: 0.03 10 | -------------------------------------------------------------------------------- /Assets/Presets/Defaults/AlbedoTexture_Default.preset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e8537455c6c08bd4e8bf0be3707da685 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2655988077585873504 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Presets/Defaults/DirectionalLight_Default.preset.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 463065d4f17d1d94d848aa127b94dd43 3 | NativeFormatImporter: 4 | externalObjects: {} 5 | mainObjectFileID: 2655988077585873504 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Assets/Scripts/BRG_Debris.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7449c4404a3625741a3e72167067be21 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /UserSettings/Search.index: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Assets", 3 | "roots": ["Assets"], 4 | "includes": [], 5 | "excludes": [], 6 | "options": { 7 | "types": true, 8 | "properties": true, 9 | "extended": false, 10 | "dependencies": false 11 | }, 12 | "baseScore": 999 13 | } -------------------------------------------------------------------------------- /Assets/Scripts/BRG_Background.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3ecf2a1b2fa26634ba667ee5052be355 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: -2 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Scripts/BRG_Container.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 11a5e4c87bcd4024681ba0e919adb264 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/WaveSpawner.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: a31056a56d411084e8cc1d373440aa55 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Scripts/SRPBatcherProfiler.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 39e5fcc7f828db74284c663be8dc1d8f 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/EnemyMovement.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: b825dedc6d9b3984db3e243a63276ee5 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/BulletKillingEnemy.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: bd68be9d714d1f84e880c24fb8e12ffb 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/MainCharacterMovement.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: e8cd07e59c84452409c83579637fdcc2 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /ProjectSettings/EditorBuildSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1045 &1 4 | EditorBuildSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_Scenes: 8 | - enabled: 1 9 | path: Assets/Scenes/brg_shooter.unity 10 | guid: f9e3cbf4310160c45a0cab2e00c2e7ac 11 | m_configObjects: {} 12 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Scripts/Editor/ReadmeEditor.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 476cc7d7cd9874016adc216baab94a0a 3 | timeCreated: 1484146680 4 | licenseType: Store 5 | MonoImporter: 6 | serializedVersion: 2 7 | defaultReferences: [] 8 | executionOrder: 0 9 | icon: {instanceID: 0} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # BatchRendererGroup Shooter Demo 2 | 3 | ![My Image](img/brg_shooter_img.png) 4 | 5 | Unity sample showing BatchRendererGroup API direct use and Burst/JobSystem. Focus is high performance even on budget mobile devices. Unity 2022.3.5 or above required. 6 | 7 | More details in [this blog post](https://blog.unity.com/engine-platform/batchrenderergroup-sample-high-frame-rate-on-budget-devices) 8 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Scripts/Readme.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using UnityEngine; 3 | 4 | public class Readme : ScriptableObject 5 | { 6 | public Texture2D icon; 7 | public string title; 8 | public Section[] sections; 9 | public bool loadedLayout; 10 | 11 | [Serializable] 12 | public class Section 13 | { 14 | public string heading, text, linkText, url; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Scripts/Readme.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: fcf7219bab7fe46a1ad266029b2fee19 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: 7 | - icon: {fileID: 2800000, guid: d4743ba2e2a59f946b2125c074582ce7, type: 3} 8 | executionOrder: 0 9 | icon: {fileID: 2800000, guid: a186f8a87ca4f4d3aa864638ad5dfb65, type: 3} 10 | userData: 11 | assetBundleName: 12 | assetBundleVariant: 13 | -------------------------------------------------------------------------------- /ProjectSettings/BurstAotSettings_StandaloneWindows.json: -------------------------------------------------------------------------------- 1 | { 2 | "MonoBehaviour": { 3 | "Version": 4, 4 | "EnableBurstCompilation": true, 5 | "EnableOptimisations": true, 6 | "EnableSafetyChecks": false, 7 | "EnableDebugInAllBuilds": false, 8 | "CpuMinTargetX32": 0, 9 | "CpuMaxTargetX32": 0, 10 | "CpuMinTargetX64": 0, 11 | "CpuMaxTargetX64": 0, 12 | "CpuTargetsX32": 6, 13 | "CpuTargetsX64": 72, 14 | "OptimizeFor": 0 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /ProjectSettings/URPProjectSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &1 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 61 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 247994e1f5a72c2419c26a37e9334c01, type: 3} 13 | m_Name: 14 | m_EditorClassIdentifier: 15 | m_LastMaterialVersion: 7 16 | -------------------------------------------------------------------------------- /ProjectSettings/BurstAotSettings_Android.json: -------------------------------------------------------------------------------- 1 | { 2 | "MonoBehaviour": { 3 | "Version": 4, 4 | "EnableBurstCompilation": true, 5 | "EnableOptimisations": true, 6 | "EnableSafetyChecks": false, 7 | "EnableDebugInAllBuilds": false, 8 | "DebugDataKind": 0, 9 | "EnableArmv9SecurityFeatures": false, 10 | "CpuMinTargetX32": 0, 11 | "CpuMaxTargetX32": 0, 12 | "CpuMinTargetX64": 0, 13 | "CpuMaxTargetX64": 0, 14 | "CpuTargetsArm64": 0, 15 | "OptimizeFor": 0 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /ProjectSettings/AudioManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!11 &1 4 | AudioManager: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_Volume: 1 8 | Rolloff Scale: 1 9 | Doppler Factor: 1 10 | Default Speaker Mode: 2 11 | m_SampleRate: 0 12 | m_DSPBufferSize: 1024 13 | m_VirtualVoiceCount: 512 14 | m_RealVoiceCount: 32 15 | m_SpatializerPlugin: 16 | m_AmbisonicDecoderPlugin: 17 | m_DisableAudio: 0 18 | m_VirtualizeEffects: 1 19 | m_RequestedDSPBufferSize: 0 20 | -------------------------------------------------------------------------------- /LICENCE.md: -------------------------------------------------------------------------------- 1 | BatchRendererGroup Shooter Demo copyright © 2023 Unity Technologies 2 | 3 | Licensed under the Unity Companion License for Unity-dependent projects (see https://unity3d.com/legal/licenses/unity_companion_license). 4 | Unless expressly provided otherwise, the Software under this license is made available strictly on an “AS IS” BASIS WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED. Please review the license for details on these and other terms and conditions. 5 | 6 | ============================================================================================ 7 | -------------------------------------------------------------------------------- /ProjectSettings/ShaderGraphSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &1 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 61 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: de02f9e1d18f588468e474319d09a723, type: 3} 13 | m_Name: 14 | m_EditorClassIdentifier: 15 | customInterpolatorErrorThreshold: 32 16 | customInterpolatorWarningThreshold: 16 17 | -------------------------------------------------------------------------------- /ProjectSettings/TagManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!78 &1 4 | TagManager: 5 | serializedVersion: 2 6 | tags: 7 | - Enemy 8 | layers: 9 | - Default 10 | - TransparentFX 11 | - Ignore Raycast 12 | - 13 | - Water 14 | - UI 15 | - 16 | - 17 | - 18 | - 19 | - 20 | - 21 | - 22 | - 23 | - 24 | - 25 | - 26 | - 27 | - 28 | - 29 | - 30 | - 31 | - 32 | - 33 | - 34 | - 35 | - 36 | - 37 | - 38 | - 39 | - 40 | - 41 | m_SortingLayers: 42 | - name: Default 43 | uniqueID: 0 44 | locked: 0 45 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/EnemyMovement.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | 5 | public class EnemyMovement : MonoBehaviour 6 | { 7 | // Start is called before the first frame update 8 | public float m_rndHueColor; 9 | private void Start() 10 | { 11 | } 12 | // Update is called once per frame 13 | void Update() 14 | { 15 | } 16 | 17 | public void Explode() 18 | { 19 | if (BRG_Debris.gDebrisManager != null) 20 | BRG_Debris.gDebrisManager.GenerateBurstOfDebris(transform.position, 1024, m_rndHueColor); 21 | } 22 | 23 | void OnDestroy() 24 | { 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ProjectSettings/VFXManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!937362698 &1 4 | VFXManager: 5 | m_ObjectHideFlags: 0 6 | m_IndirectShader: {fileID: 7200000, guid: 84a17cfa13e40ae4082ef42714f0a81c, type: 3} 7 | m_CopyBufferShader: {fileID: 7200000, guid: 23c51f21a3503f6428b527b01f8a2f4e, type: 3} 8 | m_SortShader: {fileID: 7200000, guid: ea257ca3cfb12a642a5025e612af6b2a, type: 3} 9 | m_StripUpdateShader: {fileID: 7200000, guid: 8fa6c4009fe2a4d4486c62736fc30ad8, type: 3} 10 | m_RenderPipeSettingsPath: 11 | m_FixedTimeStep: 0.016666668 12 | m_MaxDeltaTime: 0.05 13 | m_MaxScrubTime: 30 14 | m_CompiledVersion: 6 15 | m_RuntimeVersion: 33 16 | m_RuntimeResources: {fileID: 11400000, guid: bc10b42afe3813544bffd38ae2cd893d, type: 2} 17 | m_BatchEmptyLifetime: 300 18 | -------------------------------------------------------------------------------- /Assets/Readme.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: fcf7219bab7fe46a1ad266029b2fee19, type: 3} 13 | m_Name: Readme 14 | m_EditorClassIdentifier: 15 | icon: {fileID: 2800000, guid: 7801804018a7dcf42abb827444e18660, type: 3} 16 | title: BatchRendererGroup Shooter Demo 17 | sections: 18 | - heading: BatchRendererGroup Shooter Demo 19 | text: 'This project demonstrates BatchRendererGroup API direct use to render tons of objects. The project also takes advantage of C# Job System and Burst compiler to run fast even on a budget mobile device.' 20 | linkText: 21 | url: 22 | loadedLayout: 1 23 | -------------------------------------------------------------------------------- /ProjectSettings/PresetManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1386491679 &1 4 | PresetManager: 5 | m_ObjectHideFlags: 0 6 | m_DefaultList: 7 | - type: 8 | m_NativeTypeID: 108 9 | m_ManagedTypePPtr: {fileID: 0} 10 | m_ManagedTypeFallback: 11 | defaultPresets: 12 | - m_Preset: {fileID: 2655988077585873504, guid: 463065d4f17d1d94d848aa127b94dd43, 13 | type: 2} 14 | - type: 15 | m_NativeTypeID: 1020 16 | m_ManagedTypePPtr: {fileID: 0} 17 | m_ManagedTypeFallback: 18 | defaultPresets: 19 | - m_Preset: {fileID: 2655988077585873504, guid: e7689051185d12f4298e1ebb2693a29f, 20 | type: 2} 21 | - type: 22 | m_NativeTypeID: 1006 23 | m_ManagedTypePPtr: {fileID: 0} 24 | m_ManagedTypeFallback: 25 | defaultPresets: 26 | - m_Preset: {fileID: 2655988077585873504, guid: e8537455c6c08bd4e8bf0be3707da685, 27 | type: 2} 28 | -------------------------------------------------------------------------------- /Packages/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "com.unity.feature.development": "1.0.1", 4 | "com.unity.render-pipelines.universal": "14.0.8", 5 | "com.unity.ugui": "1.0.0", 6 | "com.unity.modules.ai": "1.0.0", 7 | "com.unity.modules.androidjni": "1.0.0", 8 | "com.unity.modules.animation": "1.0.0", 9 | "com.unity.modules.assetbundle": "1.0.0", 10 | "com.unity.modules.audio": "1.0.0", 11 | "com.unity.modules.cloth": "1.0.0", 12 | "com.unity.modules.director": "1.0.0", 13 | "com.unity.modules.imageconversion": "1.0.0", 14 | "com.unity.modules.imgui": "1.0.0", 15 | "com.unity.modules.jsonserialize": "1.0.0", 16 | "com.unity.modules.physics": "1.0.0", 17 | "com.unity.modules.physics2d": "1.0.0", 18 | "com.unity.modules.screencapture": "1.0.0", 19 | "com.unity.modules.ui": "1.0.0", 20 | "com.unity.modules.uielements": "1.0.0", 21 | "com.unity.modules.vehicles": "1.0.0", 22 | "com.unity.modules.vr": "1.0.0", 23 | "com.unity.modules.wind": "1.0.0", 24 | "com.unity.modules.xr": "1.0.0" 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /ProjectSettings/UnityConnectSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!310 &1 4 | UnityConnectSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 1 7 | m_Enabled: 0 8 | m_TestMode: 0 9 | m_EventOldUrl: https://api.uca.cloud.unity3d.com/v1/events 10 | m_EventUrl: https://cdp.cloud.unity3d.com/v1/events 11 | m_ConfigUrl: https://config.uca.cloud.unity3d.com 12 | m_DashboardUrl: https://dashboard.unity3d.com 13 | m_TestInitMode: 0 14 | CrashReportingSettings: 15 | m_EventUrl: https://perf-events.cloud.unity3d.com 16 | m_Enabled: 0 17 | m_LogBufferSize: 10 18 | m_CaptureEditorExceptions: 1 19 | UnityPurchasingSettings: 20 | m_Enabled: 0 21 | m_TestMode: 0 22 | UnityAnalyticsSettings: 23 | m_Enabled: 0 24 | m_TestMode: 0 25 | m_InitializeOnStartup: 1 26 | UnityAdsSettings: 27 | m_Enabled: 0 28 | m_InitializeOnStartup: 1 29 | m_TestMode: 0 30 | m_IosGameId: 31 | m_AndroidGameId: 32 | m_GameIds: {} 33 | m_GameId: 34 | PerformanceReportingSettings: 35 | m_Enabled: 0 36 | -------------------------------------------------------------------------------- /ProjectSettings/PackageManagerSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &1 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 61 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 13964, guid: 0000000000000000e000000000000000, type: 0} 13 | m_Name: 14 | m_EditorClassIdentifier: 15 | m_EnablePreReleasePackages: 0 16 | m_AdvancedSettingsExpanded: 1 17 | m_ScopedRegistriesSettingsExpanded: 1 18 | m_SeeAllPackageVersions: 0 19 | m_DismissPreviewPackagesInUse: 0 20 | oneTimeWarningShown: 0 21 | m_Registries: 22 | - m_Id: main 23 | m_Name: 24 | m_Url: https://packages.unity.com 25 | m_Scopes: [] 26 | m_IsDefault: 1 27 | m_Capabilities: 7 28 | m_UserSelectedRegistryName: 29 | m_UserAddingNewScopedRegistry: 0 30 | m_RegistryInfoDraft: 31 | m_Modified: 0 32 | m_ErrorMessage: 33 | m_UserModificationsInstanceId: -864 34 | m_OriginalInstanceId: -866 35 | m_LoadAssets: 0 36 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # This .gitignore file should be placed at the root of your Unity project directory 2 | # 3 | # Get latest from https://github.com/github/gitignore/blob/master/Unity.gitignore 4 | # 5 | /[Ll]ibrary/ 6 | /[Tt]emp/ 7 | /[Oo]bj/ 8 | /[Bb]uild/ 9 | /[Bb]uilds/ 10 | /[Ll]ogs/ 11 | /[Mm]emoryCaptures/ 12 | 13 | # Asset meta data should only be ignored when the corresponding asset is also ignored 14 | !/[Aa]ssets/**/*.meta 15 | 16 | # Uncomment this line if you wish to ignore the asset store tools plugin 17 | # /[Aa]ssets/AssetStoreTools* 18 | 19 | # Autogenerated Jetbrains Rider plugin 20 | [Aa]ssets/Plugins/Editor/JetBrains* 21 | 22 | # Visual Studio cache directory 23 | .vs/ 24 | 25 | # Gradle cache directory 26 | .gradle/ 27 | 28 | # Autogenerated VS/MD/Consulo solution and project files 29 | ExportedObj/ 30 | .consulo/ 31 | *.csproj 32 | *.unityproj 33 | *.sln 34 | *.suo 35 | *.tmp 36 | *.user 37 | *.userprefs 38 | *.pidb 39 | *.booproj 40 | *.svd 41 | *.pdb 42 | *.mdb 43 | *.opendb 44 | *.VC.db 45 | 46 | # Unity3D generated meta files 47 | *.pidb.meta 48 | *.pdb.meta 49 | *.mdb.meta 50 | 51 | # Unity3D generated file on crash reports 52 | sysinfo.txt 53 | 54 | # Builds 55 | *.apk 56 | *.unitypackage 57 | 58 | # Crashlytics generated file 59 | crashlytics-build.properties 60 | 61 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/BulletKillingEnemy.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using UnityEngine; 5 | 6 | public class BulletKillingEnemy : MonoBehaviour 7 | { 8 | 9 | private Vector3 m_prevPos; 10 | private void Awake() 11 | { 12 | m_prevPos = transform.position; 13 | } 14 | private void Update() 15 | { 16 | float dt = Time.deltaTime; 17 | transform.Translate(0,0,dt*50.0f); 18 | if ( transform.position.z > 100 ) 19 | { 20 | Destroy(this.gameObject); 21 | } 22 | else 23 | { 24 | if (BRG_Background.gBackgroundManager != null) 25 | BRG_Background.gBackgroundManager.SetMagnetCell(m_prevPos, transform.position); 26 | m_prevPos = transform.position; 27 | } 28 | } 29 | 30 | // Start is called before the first frame update 31 | private void OnTriggerEnter(Collider other) 32 | { 33 | if (other.gameObject.tag == "Enemy") 34 | { 35 | EnemyMovement enemy = other.gameObject.GetComponent(); 36 | if ( enemy != null) 37 | { 38 | enemy.Explode(); 39 | } 40 | Destroy(other.gameObject); 41 | Destroy(this.gameObject); 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /ProjectSettings/MemorySettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!387306366 &1 4 | MemorySettings: 5 | m_ObjectHideFlags: 0 6 | m_EditorMemorySettings: 7 | m_MainAllocatorBlockSize: -1 8 | m_ThreadAllocatorBlockSize: -1 9 | m_MainGfxBlockSize: -1 10 | m_ThreadGfxBlockSize: -1 11 | m_CacheBlockSize: -1 12 | m_TypetreeBlockSize: -1 13 | m_ProfilerBlockSize: -1 14 | m_ProfilerEditorBlockSize: -1 15 | m_BucketAllocatorGranularity: -1 16 | m_BucketAllocatorBucketsCount: -1 17 | m_BucketAllocatorBlockSize: -1 18 | m_BucketAllocatorBlockCount: -1 19 | m_ProfilerBucketAllocatorGranularity: -1 20 | m_ProfilerBucketAllocatorBucketsCount: -1 21 | m_ProfilerBucketAllocatorBlockSize: -1 22 | m_ProfilerBucketAllocatorBlockCount: -1 23 | m_TempAllocatorSizeMain: -1 24 | m_JobTempAllocatorBlockSize: -1 25 | m_BackgroundJobTempAllocatorBlockSize: -1 26 | m_JobTempAllocatorReducedBlockSize: -1 27 | m_TempAllocatorSizeGIBakingWorker: -1 28 | m_TempAllocatorSizeNavMeshWorker: -1 29 | m_TempAllocatorSizeAudioWorker: -1 30 | m_TempAllocatorSizeCloudWorker: -1 31 | m_TempAllocatorSizeGfx: -1 32 | m_TempAllocatorSizeJobWorker: -1 33 | m_TempAllocatorSizeBackgroundWorker: -1 34 | m_TempAllocatorSizePreloadManager: -1 35 | m_PlatformMemorySettings: {} 36 | -------------------------------------------------------------------------------- /Assets/UniversalRenderPipelineGlobalSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 2ec995e51a6e251468d2a3fd8a686257, type: 3} 13 | m_Name: UniversalRenderPipelineGlobalSettings 14 | m_EditorClassIdentifier: 15 | k_AssetVersion: 3 16 | m_RenderingLayerNames: 17 | - Light Layer default 18 | - Light Layer 1 19 | - Light Layer 2 20 | - Light Layer 3 21 | - Light Layer 4 22 | - Light Layer 5 23 | - Light Layer 6 24 | - Light Layer 7 25 | m_ValidRenderingLayers: 255 26 | lightLayerName0: Light Layer default 27 | lightLayerName1: Light Layer 1 28 | lightLayerName2: Light Layer 2 29 | lightLayerName3: Light Layer 3 30 | lightLayerName4: Light Layer 4 31 | lightLayerName5: Light Layer 5 32 | lightLayerName6: Light Layer 6 33 | lightLayerName7: Light Layer 7 34 | m_StripDebugVariants: 1 35 | m_StripUnusedPostProcessingVariants: 1 36 | m_StripUnusedVariants: 1 37 | m_StripUnusedLODCrossFadeVariants: 1 38 | m_StripScreenCoordOverrideVariants: 1 39 | supportRuntimeDebugDisplay: 0 40 | m_ShaderVariantLogLevel: 0 41 | m_ExportShaderVariants: 1 42 | -------------------------------------------------------------------------------- /ProjectSettings/DynamicsManager.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!55 &1 4 | PhysicsManager: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 14 7 | m_Gravity: {x: 0, y: -9.81, z: 0} 8 | m_DefaultMaterial: {fileID: 0} 9 | m_BounceThreshold: 2 10 | m_DefaultMaxDepenetrationVelocity: 10 11 | m_SleepThreshold: 0.005 12 | m_DefaultContactOffset: 0.01 13 | m_DefaultSolverIterations: 1 14 | m_DefaultSolverVelocityIterations: 1 15 | m_QueriesHitBackfaces: 0 16 | m_QueriesHitTriggers: 1 17 | m_EnableAdaptiveForce: 0 18 | m_ClothInterCollisionDistance: 0.1 19 | m_ClothInterCollisionStiffness: 0.2 20 | m_ContactsGeneration: 1 21 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 22 | m_SimulationMode: 1 23 | m_AutoSyncTransforms: 0 24 | m_ReuseCollisionCallbacks: 1 25 | m_InvokeCollisionCallbacks: 1 26 | m_ClothInterCollisionSettingsToggle: 0 27 | m_ClothGravity: {x: 0, y: -9.81, z: 0} 28 | m_ContactPairsMode: 0 29 | m_BroadphaseType: 0 30 | m_WorldBounds: 31 | m_Center: {x: 0, y: 0, z: 0} 32 | m_Extent: {x: 250, y: 250, z: 250} 33 | m_WorldSubdivisions: 8 34 | m_FrictionType: 0 35 | m_EnableEnhancedDeterminism: 0 36 | m_EnableUnifiedHeightmaps: 1 37 | m_ImprovedPatchFriction: 0 38 | m_SolverType: 0 39 | m_DefaultMaxAngularSpeed: 7 40 | -------------------------------------------------------------------------------- /UserSettings/Search.settings: -------------------------------------------------------------------------------- 1 | trackSelection = true 2 | fetchPreview = true 3 | defaultFlags = 0 4 | keepOpen = false 5 | queryFolder = "Assets" 6 | onBoardingDoNotAskAgain = true 7 | showPackageIndexes = false 8 | showStatusBar = false 9 | scopes = { 10 | "picker_window_position_offset.74AD8FDB" = "682;272;321.2;550" 11 | "picker_search_text.74AD8FDB" = "default " 12 | "last_search.74AD8FDB" = "default " 13 | "OpenInspectorPreview.74AD8FDB" = "0" 14 | "currentGroup.74AD8FDB" = "all" 15 | } 16 | providers = { 17 | adb = { 18 | active = false 19 | priority = 2500 20 | defaultAction = null 21 | } 22 | asset = { 23 | active = true 24 | priority = 25 25 | defaultAction = null 26 | } 27 | store = { 28 | active = true 29 | priority = 100 30 | defaultAction = null 31 | } 32 | find = { 33 | active = true 34 | priority = 25 35 | defaultAction = null 36 | } 37 | log = { 38 | active = false 39 | priority = 210 40 | defaultAction = null 41 | } 42 | packages = { 43 | active = true 44 | priority = 90 45 | defaultAction = null 46 | } 47 | performance = { 48 | active = false 49 | priority = 100 50 | defaultAction = null 51 | } 52 | scene = { 53 | active = true 54 | priority = 50 55 | defaultAction = null 56 | } 57 | } 58 | objectSelectors = { 59 | } 60 | recentSearches = [ 61 | ] 62 | searchItemFavorites = [ 63 | ] 64 | savedSearchesSortOrder = 0 65 | showSavedSearchPanel = false 66 | expandedQueries = [ 67 | ] 68 | queryBuilder = false 69 | ignoredProperties = "id;name;classname;imagecontentshash" 70 | helperWidgetCurrentArea = "all" 71 | disabledIndexers = "" -------------------------------------------------------------------------------- /ProjectSettings/EditorSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!159 &1 4 | EditorSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 12 7 | m_SerializationMode: 2 8 | m_LineEndingsForNewScripts: 0 9 | m_DefaultBehaviorMode: 0 10 | m_PrefabRegularEnvironment: {fileID: 0} 11 | m_PrefabUIEnvironment: {fileID: 0} 12 | m_SpritePackerMode: 0 13 | m_SpritePackerCacheSize: 10 14 | m_SpritePackerPaddingPower: 1 15 | m_Bc7TextureCompressor: 0 16 | m_EtcTextureCompressorBehavior: 1 17 | m_EtcTextureFastCompressor: 1 18 | m_EtcTextureNormalCompressor: 2 19 | m_EtcTextureBestCompressor: 4 20 | m_ProjectGenerationIncludedExtensions: txt;xml;fnt;cd;asmdef;asmref;rsp 21 | m_ProjectGenerationRootNamespace: 22 | m_EnableTextureStreamingInEditMode: 1 23 | m_EnableTextureStreamingInPlayMode: 1 24 | m_EnableEditorAsyncCPUTextureLoading: 0 25 | m_AsyncShaderCompilation: 1 26 | m_PrefabModeAllowAutoSave: 1 27 | m_EnterPlayModeOptionsEnabled: 0 28 | m_EnterPlayModeOptions: 3 29 | m_GameObjectNamingDigits: 1 30 | m_GameObjectNamingScheme: 0 31 | m_AssetNamingUsesSpace: 1 32 | m_InspectorUseIMGUIDefaultInspector: 0 33 | m_UseLegacyProbeSampleCount: 0 34 | m_SerializeInlineMappingsOnOneLine: 1 35 | m_DisableCookiesInLightmapper: 1 36 | m_AssetPipelineMode: 1 37 | m_RefreshImportMode: 0 38 | m_CacheServerMode: 0 39 | m_CacheServerEndpoint: 40 | m_CacheServerNamespacePrefix: default 41 | m_CacheServerEnableDownload: 1 42 | m_CacheServerEnableUpload: 1 43 | m_CacheServerEnableAuth: 0 44 | m_CacheServerEnableTls: 0 45 | m_CacheServerValidationMode: 2 46 | m_CacheServerDownloadBatchSize: 128 47 | m_EnableEnlightenBakedGI: 0 48 | -------------------------------------------------------------------------------- /ProjectSettings/NavMeshAreas.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!126 &1 4 | NavMeshProjectSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | areas: 8 | - name: Walkable 9 | cost: 1 10 | - name: Not Walkable 11 | cost: 1 12 | - name: Jump 13 | cost: 2 14 | - name: 15 | cost: 1 16 | - name: 17 | cost: 1 18 | - name: 19 | cost: 1 20 | - name: 21 | cost: 1 22 | - name: 23 | cost: 1 24 | - name: 25 | cost: 1 26 | - name: 27 | cost: 1 28 | - name: 29 | cost: 1 30 | - name: 31 | cost: 1 32 | - name: 33 | cost: 1 34 | - name: 35 | cost: 1 36 | - name: 37 | cost: 1 38 | - name: 39 | cost: 1 40 | - name: 41 | cost: 1 42 | - name: 43 | cost: 1 44 | - name: 45 | cost: 1 46 | - name: 47 | cost: 1 48 | - name: 49 | cost: 1 50 | - name: 51 | cost: 1 52 | - name: 53 | cost: 1 54 | - name: 55 | cost: 1 56 | - name: 57 | cost: 1 58 | - name: 59 | cost: 1 60 | - name: 61 | cost: 1 62 | - name: 63 | cost: 1 64 | - name: 65 | cost: 1 66 | - name: 67 | cost: 1 68 | - name: 69 | cost: 1 70 | - name: 71 | cost: 1 72 | m_LastAgentTypeID: -887442657 73 | m_Settings: 74 | - serializedVersion: 2 75 | agentTypeID: 0 76 | agentRadius: 0.5 77 | agentHeight: 2 78 | agentSlope: 45 79 | agentClimb: 0.75 80 | ledgeDropHeight: 0 81 | maxJumpAcrossDistance: 0 82 | minRegionArea: 2 83 | manualCellSize: 0 84 | cellSize: 0.16666667 85 | manualTileSize: 0 86 | tileSize: 256 87 | accuratePlacement: 0 88 | debug: 89 | m_Flags: 0 90 | m_SettingNames: 91 | - Humanoid 92 | -------------------------------------------------------------------------------- /Assets/Scenes/SampleSceneLightingSettings.lighting: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!850595691 &4890085278179872738 4 | LightingSettings: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_Name: SampleSceneLightingSettings 10 | serializedVersion: 2 11 | m_GIWorkflowMode: 0 12 | m_EnableBakedLightmaps: 1 13 | m_EnableRealtimeLightmaps: 0 14 | m_RealtimeEnvironmentLighting: 0 15 | m_BounceScale: 1 16 | m_AlbedoBoost: 1 17 | m_IndirectOutputScale: 1 18 | m_UsingShadowmask: 0 19 | m_BakeBackend: 1 20 | m_LightmapMaxSize: 512 21 | m_BakeResolution: 32 22 | m_Padding: 2 23 | m_TextureCompression: 1 24 | m_AO: 1 25 | m_AOMaxDistance: 1 26 | m_CompAOExponent: 1 27 | m_CompAOExponentDirect: 0.3 28 | m_ExtractAO: 0 29 | m_MixedBakeMode: 0 30 | m_LightmapsBakeMode: 1 31 | m_FilterMode: 1 32 | m_LightmapParameters: {fileID: 0} 33 | m_ExportTrainingData: 0 34 | m_TrainingDataDestination: TrainingData 35 | m_RealtimeResolution: 2 36 | m_ForceWhiteAlbedo: 0 37 | m_ForceUpdates: 0 38 | m_FinalGather: 0 39 | m_FinalGatherRayCount: 256 40 | m_FinalGatherFiltering: 1 41 | m_PVRCulling: 1 42 | m_PVRSampling: 1 43 | m_PVRDirectSampleCount: 32 44 | m_PVRSampleCount: 256 45 | m_PVREnvironmentSampleCount: 256 46 | m_PVREnvironmentReferencePointCount: 2048 47 | m_LightProbeSampleCountMultiplier: 4 48 | m_PVRBounces: 2 49 | m_PVRRussianRouletteStartBounce: 2 50 | m_PVREnvironmentMIS: 0 51 | m_PVRFilteringMode: 1 52 | m_PVRDenoiserTypeDirect: 0 53 | m_PVRDenoiserTypeIndirect: 0 54 | m_PVRDenoiserTypeAO: 0 55 | m_PVRFilterTypeDirect: 0 56 | m_PVRFilterTypeIndirect: 0 57 | m_PVRFilterTypeAO: 0 58 | m_PVRFilteringGaussRadiusDirect: 1 59 | m_PVRFilteringGaussRadiusIndirect: 5 60 | m_PVRFilteringGaussRadiusAO: 2 61 | m_PVRFilteringAtrousPositionSigmaDirect: 0.548 62 | m_PVRFilteringAtrousPositionSigmaIndirect: 2 63 | m_PVRFilteringAtrousPositionSigmaAO: 1 64 | -------------------------------------------------------------------------------- /ProjectSettings/Physics2DSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!19 &1 4 | Physics2DSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 4 7 | m_Gravity: {x: 0, y: -9.81} 8 | m_DefaultMaterial: {fileID: 0} 9 | m_VelocityIterations: 8 10 | m_PositionIterations: 3 11 | m_VelocityThreshold: 1 12 | m_MaxLinearCorrection: 0.2 13 | m_MaxAngularCorrection: 8 14 | m_MaxTranslationSpeed: 100 15 | m_MaxRotationSpeed: 360 16 | m_BaumgarteScale: 0.2 17 | m_BaumgarteTimeOfImpactScale: 0.75 18 | m_TimeToSleep: 0.5 19 | m_LinearSleepTolerance: 0.01 20 | m_AngularSleepTolerance: 2 21 | m_DefaultContactOffset: 0.01 22 | m_JobOptions: 23 | serializedVersion: 2 24 | useMultithreading: 0 25 | useConsistencySorting: 0 26 | m_InterpolationPosesPerJob: 100 27 | m_NewContactsPerJob: 30 28 | m_CollideContactsPerJob: 100 29 | m_ClearFlagsPerJob: 200 30 | m_ClearBodyForcesPerJob: 200 31 | m_SyncDiscreteFixturesPerJob: 50 32 | m_SyncContinuousFixturesPerJob: 50 33 | m_FindNearestContactsPerJob: 100 34 | m_UpdateTriggerContactsPerJob: 100 35 | m_IslandSolverCostThreshold: 100 36 | m_IslandSolverBodyCostScale: 1 37 | m_IslandSolverContactCostScale: 10 38 | m_IslandSolverJointCostScale: 10 39 | m_IslandSolverBodiesPerJob: 50 40 | m_IslandSolverContactsPerJob: 50 41 | m_AutoSimulation: 1 42 | m_QueriesHitTriggers: 1 43 | m_QueriesStartInColliders: 1 44 | m_CallbacksOnDisable: 1 45 | m_ReuseCollisionCallbacks: 1 46 | m_AutoSyncTransforms: 0 47 | m_AlwaysShowColliders: 0 48 | m_ShowColliderSleep: 1 49 | m_ShowColliderContacts: 0 50 | m_ShowColliderAABB: 0 51 | m_ContactArrowScale: 0.2 52 | m_ColliderAwakeColor: {r: 0.5686275, g: 0.95686275, b: 0.54509807, a: 0.7529412} 53 | m_ColliderAsleepColor: {r: 0.5686275, g: 0.95686275, b: 0.54509807, a: 0.36078432} 54 | m_ColliderContactColor: {r: 1, g: 0, b: 1, a: 0.6862745} 55 | m_ColliderAABBColor: {r: 1, g: 1, b: 0, a: 0.2509804} 56 | m_LayerCollisionMatrix: ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 57 | -------------------------------------------------------------------------------- /UserSettings/EditorUserSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!162 &1 4 | EditorUserSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 4 7 | m_ConfigSettings: 8 | RecentlyUsedSceneGuid-0: 9 | value: 0700575554055059090c597611270a44154f19782e7a7e63757c4f6be7b66068 10 | flags: 0 11 | RecentlyUsedSceneGuid-1: 12 | value: 0207075e06510c0f5f5e5d2049735c444f4e1c297f7f7135742a4a36b4b2313b 13 | flags: 0 14 | RecentlyUsedSceneGuid-2: 15 | value: 565502075d025b585e085a2740255b44424e4979742c7762797b1b60b3b26560 16 | flags: 0 17 | RecentlyUsedSceneGuid-3: 18 | value: 02550200010d0c5f5b560d2140275e44124f4e7f752976347e7d1e60e3e23260 19 | flags: 0 20 | RecentlyUsedSceneGuid-4: 21 | value: 5a550652000d0f0c5d56097a46725b4417164d7a287822347f7c1c37e6e6353d 22 | flags: 0 23 | RecentlyUsedSceneGuid-5: 24 | value: 0508515506570f0f5e5f5c7346735c44431648292d2a74357d791e61e7b7353b 25 | flags: 0 26 | UnityEditor.ShaderGraph.Blackboard: 27 | value: 18135939215a0a5004000b0e15254b524c030a3f2964643d120d1230e9e93a3fd6e826abbd2e2d293c4ead313b08042de6030a0afa240c0d020be94c4ba75e435d8715fa32c70d15d11612dacc11fee5d3c5d1fe9ab1bf968e93e2ffcbc3e7e2f0b3ffe0e8b0be9af8ffaeffff8e85dd8390e3949c8899daa7 28 | flags: 0 29 | UnityEditor.ShaderGraph.FloatingWindowsLayout2: 30 | value: 181344140043005e1a220d3b1f364b524c0c5a27130c293326201334cee5322ca0bd30e8eb293a707b0fd0180b3d0a36fc0d3d04e649500d1002ee0b5dbd1d2c27c00ad113cb1e10e41f1addc80993b98d9884a69ae6d8f0d1cda9e8fbfefaf9f9dea3fdb9ade882f0f7b0e1e380cafbf2c3adc18e9cd285a2908b82ec869c818986d5878bd5888c89def1dff7dce5bdd1fbf5c4c1ebcef2c4c7c4e537eafd39303f3fefa1a5ab 31 | flags: 0 32 | UnityEditor.ShaderGraph.InspectorWindow: 33 | value: 18135939215a0a5004000b0e15254b524c030a3f2964643d120d1230e9e93a3fd6e826abbd2e2d293c4ead313b08042de6030a0afa240c0d020be94c4ba75e435d8715fa32c70d15d11612dacc11fee5d3c5d1fe9ab1b7968e93e2ffcbc3e7e2f0b3ffe0e8b0be9af9ffaeffff8e85dd8390e59398889197ea82808bed8282868d80dccbc4 34 | flags: 0 35 | vcSharedLogLevel: 36 | value: 0d5e400f0650 37 | flags: 0 38 | m_VCAutomaticAdd: 1 39 | m_VCDebugCom: 0 40 | m_VCDebugCmd: 0 41 | m_VCDebugOut: 0 42 | m_SemanticMergeMode: 2 43 | m_DesiredImportWorkerCount: 9 44 | m_StandbyImportWorkerCount: 2 45 | m_IdleImportWorkerShutdownDelay: 60000 46 | m_VCShowFailedCheckout: 1 47 | m_VCOverwriteFailedCheckoutAssets: 1 48 | m_VCProjectOverlayIcons: 1 49 | m_VCHierarchyOverlayIcons: 1 50 | m_VCOtherOverlayIcons: 1 51 | m_VCAllowAsyncUpdate: 1 52 | m_ArtifactGarbageCollection: 1 53 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRenderer.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: de640fe3d0db1804a85f9fc8f5cadab6, type: 3} 13 | m_Name: UniversalRenderer 14 | m_EditorClassIdentifier: 15 | debugShaders: 16 | debugReplacementPS: {fileID: 4800000, guid: cf852408f2e174538bcd9b7fda1c5ae7, type: 3} 17 | hdrDebugViewPS: {fileID: 4800000, guid: 573620ae32aec764abd4d728906d2587, type: 3} 18 | m_RendererFeatures: [] 19 | m_RendererFeatureMap: 20 | m_UseNativeRenderPass: 0 21 | postProcessData: {fileID: 0} 22 | xrSystemData: {fileID: 11400000, guid: 60e1133243b97e347b653163a8c01b64, type: 2} 23 | shaders: 24 | blitPS: {fileID: 4800000, guid: c17132b1f77d20942aa75f8429c0f8bc, type: 3} 25 | copyDepthPS: {fileID: 4800000, guid: d6dae50ee9e1bfa4db75f19f99355220, type: 3} 26 | screenSpaceShadowPS: {fileID: 4800000, guid: 0f854b35a0cf61a429bd5dcfea30eddd, type: 3} 27 | samplingPS: {fileID: 4800000, guid: 04c410c9937594faa893a11dceb85f7e, type: 3} 28 | stencilDeferredPS: {fileID: 4800000, guid: e9155b26e1bc55942a41e518703fe304, type: 3} 29 | fallbackErrorPS: {fileID: 4800000, guid: e6e9a19c3678ded42a3bc431ebef7dbd, type: 3} 30 | fallbackLoadingPS: {fileID: 4800000, guid: 7f888aff2ac86494babad1c2c5daeee2, type: 3} 31 | materialErrorPS: {fileID: 4800000, guid: 5fd9a8feb75a4b5894c241777f519d4e, type: 3} 32 | coreBlitPS: {fileID: 4800000, guid: 93446b5c5339d4f00b85c159e1159b7c, type: 3} 33 | coreBlitColorAndDepthPS: {fileID: 4800000, guid: d104b2fc1ca6445babb8e90b0758136b, type: 3} 34 | blitHDROverlay: {fileID: 4800000, guid: a89bee29cffa951418fc1e2da94d1959, type: 3} 35 | cameraMotionVector: {fileID: 4800000, guid: c56b7e0d4c7cb484e959caeeedae9bbf, type: 3} 36 | objectMotionVector: {fileID: 4800000, guid: 7b3ede40266cd49a395def176e1bc486, type: 3} 37 | dataDrivenLensFlare: {fileID: 4800000, guid: 6cda457ac28612740adb23da5d39ea92, type: 3} 38 | m_AssetVersion: 2 39 | m_OpaqueLayerMask: 40 | serializedVersion: 2 41 | m_Bits: 4294967295 42 | m_TransparentLayerMask: 43 | serializedVersion: 2 44 | m_Bits: 4294967295 45 | m_DefaultStencilState: 46 | overrideStencilState: 0 47 | stencilReference: 0 48 | stencilCompareFunction: 8 49 | passOperation: 2 50 | failOperation: 0 51 | zFailOperation: 0 52 | m_ShadowTransparentReceive: 1 53 | m_RenderingMode: 0 54 | m_DepthPrimingMode: 0 55 | m_CopyDepthMode: 0 56 | m_AccurateGbufferNormals: 0 57 | m_IntermediateTextureMode: 1 58 | -------------------------------------------------------------------------------- /Assets/Materials/Skybox_Mat.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 6 6 | m_ObjectHideFlags: 0 7 | m_PrefabParentObject: {fileID: 0} 8 | m_PrefabInternal: {fileID: 0} 9 | m_Name: Skybox_Mat 10 | m_Shader: {fileID: 106, guid: 0000000000000000f000000000000000, type: 0} 11 | m_ShaderKeywords: _METALLIC_SETUP _SUNDISK_HIGH_QUALITY 12 | m_LightmapFlags: 4 13 | m_EnableInstancingVariants: 0 14 | m_DoubleSidedGI: 0 15 | m_CustomRenderQueue: -1 16 | stringTagMap: {} 17 | disabledShaderPasses: [] 18 | m_SavedProperties: 19 | serializedVersion: 3 20 | m_TexEnvs: 21 | - _BumpMap: 22 | m_Texture: {fileID: 0} 23 | m_Scale: {x: 1, y: 1} 24 | m_Offset: {x: 0, y: 0} 25 | - _DetailAlbedoMap: 26 | m_Texture: {fileID: 0} 27 | m_Scale: {x: 1, y: 1} 28 | m_Offset: {x: 0, y: 0} 29 | - _DetailMask: 30 | m_Texture: {fileID: 0} 31 | m_Scale: {x: 1, y: 1} 32 | m_Offset: {x: 0, y: 0} 33 | - _DetailNormalMap: 34 | m_Texture: {fileID: 0} 35 | m_Scale: {x: 1, y: 1} 36 | m_Offset: {x: 0, y: 0} 37 | - _EmissionMap: 38 | m_Texture: {fileID: 0} 39 | m_Scale: {x: 1, y: 1} 40 | m_Offset: {x: 0, y: 0} 41 | - _MainTex: 42 | m_Texture: {fileID: 0} 43 | m_Scale: {x: 1, y: 1} 44 | m_Offset: {x: 0, y: 0} 45 | - _MetallicGlossMap: 46 | m_Texture: {fileID: 0} 47 | m_Scale: {x: 1, y: 1} 48 | m_Offset: {x: 0, y: 0} 49 | - _OcclusionMap: 50 | m_Texture: {fileID: 0} 51 | m_Scale: {x: 1, y: 1} 52 | m_Offset: {x: 0, y: 0} 53 | - _ParallaxMap: 54 | m_Texture: {fileID: 0} 55 | m_Scale: {x: 1, y: 1} 56 | m_Offset: {x: 0, y: 0} 57 | - _SpecGlossMap: 58 | m_Texture: {fileID: 0} 59 | m_Scale: {x: 1, y: 1} 60 | m_Offset: {x: 0, y: 0} 61 | m_Floats: 62 | - _AtmosphereThickness: 0.53 63 | - _BumpScale: 1 64 | - _Cutoff: 0.5 65 | - _DetailNormalMapScale: 1 66 | - _DstBlend: 0 67 | - _Exposure: 1.25 68 | - _GlossMapScale: 1 69 | - _Glossiness: 0.5 70 | - _GlossyReflections: 1 71 | - _Metallic: 0 72 | - _Mode: 0 73 | - _OcclusionStrength: 1 74 | - _Parallax: 0.02 75 | - _SmoothnessTextureChannel: 0 76 | - _SpecularHighlights: 1 77 | - _SrcBlend: 1 78 | - _SunDisk: 2 79 | - _SunSize: 0.04 80 | - _SunSizeConvergence: 5 81 | - _UVSec: 0 82 | - _WorkflowMode: 1 83 | - _ZWrite: 1 84 | m_Colors: 85 | - _Color: {r: 1, g: 1, b: 1, a: 1} 86 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 87 | - _GroundColor: {r: 0.6392157, g: 0.6901961, b: 0.7411765, a: 1} 88 | - _SkyTint: {r: 1, g: 1, b: 1, a: 1} 89 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 90 | -------------------------------------------------------------------------------- /ProjectSettings/GraphicsSettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!30 &1 4 | GraphicsSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 15 7 | m_Deferred: 8 | m_Mode: 1 9 | m_Shader: {fileID: 69, guid: 0000000000000000f000000000000000, type: 0} 10 | m_DeferredReflections: 11 | m_Mode: 1 12 | m_Shader: {fileID: 74, guid: 0000000000000000f000000000000000, type: 0} 13 | m_ScreenSpaceShadows: 14 | m_Mode: 1 15 | m_Shader: {fileID: 64, guid: 0000000000000000f000000000000000, type: 0} 16 | m_DepthNormals: 17 | m_Mode: 1 18 | m_Shader: {fileID: 62, guid: 0000000000000000f000000000000000, type: 0} 19 | m_MotionVectors: 20 | m_Mode: 1 21 | m_Shader: {fileID: 75, guid: 0000000000000000f000000000000000, type: 0} 22 | m_LightHalo: 23 | m_Mode: 1 24 | m_Shader: {fileID: 105, guid: 0000000000000000f000000000000000, type: 0} 25 | m_LensFlare: 26 | m_Mode: 1 27 | m_Shader: {fileID: 102, guid: 0000000000000000f000000000000000, type: 0} 28 | m_VideoShadersIncludeMode: 2 29 | m_AlwaysIncludedShaders: 30 | - {fileID: 7, guid: 0000000000000000f000000000000000, type: 0} 31 | - {fileID: 15104, guid: 0000000000000000f000000000000000, type: 0} 32 | - {fileID: 15105, guid: 0000000000000000f000000000000000, type: 0} 33 | - {fileID: 15106, guid: 0000000000000000f000000000000000, type: 0} 34 | - {fileID: 10753, guid: 0000000000000000f000000000000000, type: 0} 35 | - {fileID: 10770, guid: 0000000000000000f000000000000000, type: 0} 36 | - {fileID: 10783, guid: 0000000000000000f000000000000000, type: 0} 37 | - {fileID: 16000, guid: 0000000000000000f000000000000000, type: 0} 38 | - {fileID: 16001, guid: 0000000000000000f000000000000000, type: 0} 39 | - {fileID: 17000, guid: 0000000000000000f000000000000000, type: 0} 40 | m_PreloadedShaders: [] 41 | m_PreloadShadersBatchTimeLimit: -1 42 | m_SpritesDefaultMaterial: {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} 43 | m_CustomRenderPipeline: {fileID: 11400000, guid: 19ba41d7c0026c3459d37c2fe90c55a0, type: 2} 44 | m_TransparencySortMode: 0 45 | m_TransparencySortAxis: {x: 0, y: 0, z: 1} 46 | m_DefaultRenderingPath: 1 47 | m_DefaultMobileRenderingPath: 1 48 | m_TierSettings: [] 49 | m_LightmapStripping: 0 50 | m_FogStripping: 0 51 | m_InstancingStripping: 0 52 | m_BrgStripping: 2 53 | m_LightmapKeepPlain: 1 54 | m_LightmapKeepDirCombined: 1 55 | m_LightmapKeepDynamicPlain: 1 56 | m_LightmapKeepDynamicDirCombined: 1 57 | m_LightmapKeepShadowMask: 1 58 | m_LightmapKeepSubtractive: 1 59 | m_FogKeepLinear: 1 60 | m_FogKeepExp: 1 61 | m_FogKeepExp2: 1 62 | m_AlbedoSwatchInfos: [] 63 | m_LightsUseLinearIntensity: 1 64 | m_LightsUseColorTemperature: 1 65 | m_DefaultRenderingLayerMask: 1 66 | m_LogWhenShaderIsCompiled: 0 67 | m_SRPDefaultSettings: 68 | UnityEngine.Rendering.Universal.UniversalRenderPipeline: {fileID: 11400000, guid: 38b35347542e5af4c9b140950c5b18db, type: 2} 69 | m_LightProbeOutsideHullStrategy: 0 70 | -------------------------------------------------------------------------------- /Assets/Settings/SampleSceneProfile.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &-7893295128165547882 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 3 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: 0b2db86121404754db890f4c8dfe81b2, type: 3} 13 | m_Name: Bloom 14 | m_EditorClassIdentifier: 15 | active: 1 16 | m_AdvancedMode: 0 17 | threshold: 18 | m_OverrideState: 1 19 | m_Value: 1 20 | min: 0 21 | intensity: 22 | m_OverrideState: 1 23 | m_Value: 1 24 | min: 0 25 | scatter: 26 | m_OverrideState: 0 27 | m_Value: 0.7 28 | min: 0 29 | max: 1 30 | clamp: 31 | m_OverrideState: 0 32 | m_Value: 65472 33 | min: 0 34 | tint: 35 | m_OverrideState: 0 36 | m_Value: {r: 1, g: 1, b: 1, a: 1} 37 | hdr: 0 38 | showAlpha: 0 39 | showEyeDropper: 1 40 | highQualityFiltering: 41 | m_OverrideState: 0 42 | m_Value: 0 43 | dirtTexture: 44 | m_OverrideState: 0 45 | m_Value: {fileID: 0} 46 | dirtIntensity: 47 | m_OverrideState: 0 48 | m_Value: 0 49 | min: 0 50 | --- !u!114 &-7011558710299706105 51 | MonoBehaviour: 52 | m_ObjectHideFlags: 3 53 | m_CorrespondingSourceObject: {fileID: 0} 54 | m_PrefabInstance: {fileID: 0} 55 | m_PrefabAsset: {fileID: 0} 56 | m_GameObject: {fileID: 0} 57 | m_Enabled: 1 58 | m_EditorHideFlags: 0 59 | m_Script: {fileID: 11500000, guid: 899c54efeace73346a0a16faa3afe726, type: 3} 60 | m_Name: Vignette 61 | m_EditorClassIdentifier: 62 | active: 1 63 | m_AdvancedMode: 0 64 | color: 65 | m_OverrideState: 0 66 | m_Value: {r: 0, g: 0, b: 0, a: 1} 67 | hdr: 0 68 | showAlpha: 0 69 | showEyeDropper: 1 70 | center: 71 | m_OverrideState: 0 72 | m_Value: {x: 0.5, y: 0.5} 73 | intensity: 74 | m_OverrideState: 1 75 | m_Value: 0.25 76 | min: 0 77 | max: 1 78 | smoothness: 79 | m_OverrideState: 1 80 | m_Value: 0.4 81 | min: 0.01 82 | max: 1 83 | rounded: 84 | m_OverrideState: 0 85 | m_Value: 0 86 | --- !u!114 &11400000 87 | MonoBehaviour: 88 | m_ObjectHideFlags: 0 89 | m_CorrespondingSourceObject: {fileID: 0} 90 | m_PrefabInstance: {fileID: 0} 91 | m_PrefabAsset: {fileID: 0} 92 | m_GameObject: {fileID: 0} 93 | m_Enabled: 1 94 | m_EditorHideFlags: 0 95 | m_Script: {fileID: 11500000, guid: d7fd9488000d3734a9e00ee676215985, type: 3} 96 | m_Name: SampleSceneProfile 97 | m_EditorClassIdentifier: 98 | components: 99 | - {fileID: 849379129802519247} 100 | - {fileID: -7893295128165547882} 101 | - {fileID: -7011558710299706105} 102 | --- !u!114 &849379129802519247 103 | MonoBehaviour: 104 | m_ObjectHideFlags: 3 105 | m_CorrespondingSourceObject: {fileID: 0} 106 | m_PrefabInstance: {fileID: 0} 107 | m_PrefabAsset: {fileID: 0} 108 | m_GameObject: {fileID: 0} 109 | m_Enabled: 1 110 | m_EditorHideFlags: 0 111 | m_Script: {fileID: 11500000, guid: 97c23e3b12dc18c42a140437e53d3951, type: 3} 112 | m_Name: Tonemapping 113 | m_EditorClassIdentifier: 114 | active: 1 115 | m_AdvancedMode: 0 116 | mode: 117 | m_OverrideState: 1 118 | m_Value: 2 119 | -------------------------------------------------------------------------------- /Assets/Plane/plane.fbx.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 27e8c81c66b852f4b8a7544bc62dc04d 3 | ModelImporter: 4 | serializedVersion: 22200 5 | internalIDToNameTable: [] 6 | externalObjects: {} 7 | materials: 8 | materialImportMode: 0 9 | materialName: 0 10 | materialSearch: 1 11 | materialLocation: 1 12 | animations: 13 | legacyGenerateAnimations: 4 14 | bakeSimulation: 0 15 | resampleCurves: 1 16 | optimizeGameObjects: 0 17 | removeConstantScaleCurves: 0 18 | motionNodeName: 19 | rigImportErrors: 20 | rigImportWarnings: 21 | animationImportErrors: 22 | animationImportWarnings: 23 | animationRetargetingWarnings: 24 | animationDoRetargetingWarnings: 0 25 | importAnimatedCustomProperties: 0 26 | importConstraints: 0 27 | animationCompression: 1 28 | animationRotationError: 0.5 29 | animationPositionError: 0.5 30 | animationScaleError: 0.5 31 | animationWrapMode: 0 32 | extraExposedTransformPaths: [] 33 | extraUserProperties: [] 34 | clipAnimations: [] 35 | isReadable: 0 36 | meshes: 37 | lODScreenPercentages: [] 38 | globalScale: 1 39 | meshCompression: 0 40 | addColliders: 0 41 | useSRGBMaterialColor: 1 42 | sortHierarchyByName: 1 43 | importPhysicalCameras: 1 44 | importVisibility: 0 45 | importBlendShapes: 0 46 | importCameras: 0 47 | importLights: 0 48 | nodeNameCollisionStrategy: 1 49 | fileIdsGeneration: 2 50 | swapUVChannels: 0 51 | generateSecondaryUV: 0 52 | useFileUnits: 1 53 | keepQuads: 0 54 | weldVertices: 1 55 | bakeAxisConversion: 0 56 | preserveHierarchy: 0 57 | skinWeightsMode: 0 58 | maxBonesPerVertex: 4 59 | minBoneWeight: 0.001 60 | optimizeBones: 1 61 | meshOptimizationFlags: -1 62 | indexFormat: 0 63 | secondaryUVAngleDistortion: 8 64 | secondaryUVAreaDistortion: 15.000001 65 | secondaryUVHardAngle: 88 66 | secondaryUVMarginMethod: 1 67 | secondaryUVMinLightmapResolution: 40 68 | secondaryUVMinObjectScale: 1 69 | secondaryUVPackMargin: 4 70 | useFileScale: 0 71 | strictVertexDataChecks: 0 72 | tangentSpace: 73 | normalSmoothAngle: 60 74 | normalImportMode: 0 75 | tangentImportMode: 3 76 | normalCalculationMode: 4 77 | legacyComputeAllNormalsFromSmoothingGroupsWhenMeshHasBlendShapes: 0 78 | blendShapeNormalImportMode: 1 79 | normalSmoothingSource: 0 80 | referencedClips: [] 81 | importAnimation: 0 82 | humanDescription: 83 | serializedVersion: 3 84 | human: [] 85 | skeleton: [] 86 | armTwist: 0.5 87 | foreArmTwist: 0.5 88 | upperLegTwist: 0.5 89 | legTwist: 0.5 90 | armStretch: 0.05 91 | legStretch: 0.05 92 | feetSpacing: 0 93 | globalScale: 1 94 | rootMotionBoneName: 95 | hasTranslationDoF: 0 96 | hasExtraRoot: 0 97 | skeletonHasParents: 1 98 | lastHumanDescriptionAvatarSource: {instanceID: 0} 99 | autoGenerateAvatarMappingIfUnspecified: 1 100 | animationType: 0 101 | humanoidOversampling: 1 102 | avatarSetup: 0 103 | addHumanoidExtraRootOnlyWhenUsingAvatar: 1 104 | importBlendShapeDeformPercent: 1 105 | remapMaterialsIfMaterialImportModeIsNone: 0 106 | additionalBone: 0 107 | userData: 108 | assetBundleName: 109 | assetBundleVariant: 110 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Icons/BrgIcon.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 7801804018a7dcf42abb827444e18660 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | externalObjects: {} 6 | serializedVersion: 5 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | grayScaleToAlpha: 0 25 | generateCubemap: 6 26 | cubemapConvolution: 0 27 | seamlessCubemap: 0 28 | textureFormat: 1 29 | maxTextureSize: 2048 30 | textureSettings: 31 | serializedVersion: 2 32 | filterMode: -1 33 | aniso: 2 34 | mipBias: -1 35 | wrapU: -1 36 | wrapV: -1 37 | wrapW: -1 38 | nPOTScale: 1 39 | lightmap: 0 40 | compressionQuality: 50 41 | spriteMode: 0 42 | spriteExtrude: 1 43 | spriteMeshType: 1 44 | alignment: 0 45 | spritePivot: {x: 0.5, y: 0.5} 46 | spritePixelsToUnits: 100 47 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 48 | spriteGenerateFallbackPhysicsShape: 1 49 | alphaUsage: 1 50 | alphaIsTransparency: 0 51 | spriteTessellationDetail: -1 52 | textureType: 0 53 | textureShape: 1 54 | singleChannelComponent: 0 55 | maxTextureSizeSet: 0 56 | compressionQualitySet: 0 57 | textureFormatSet: 0 58 | platformSettings: 59 | - serializedVersion: 2 60 | buildTarget: DefaultTexturePlatform 61 | maxTextureSize: 8192 62 | resizeAlgorithm: 0 63 | textureFormat: -1 64 | textureCompression: 1 65 | compressionQuality: 50 66 | crunchedCompression: 0 67 | allowsAlphaSplitting: 0 68 | overridden: 0 69 | androidETC2FallbackOverride: 0 70 | - serializedVersion: 2 71 | buildTarget: Standalone 72 | maxTextureSize: 8192 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | androidETC2FallbackOverride: 0 81 | - serializedVersion: 2 82 | buildTarget: iPhone 83 | maxTextureSize: 8192 84 | resizeAlgorithm: 0 85 | textureFormat: -1 86 | textureCompression: 1 87 | compressionQuality: 50 88 | crunchedCompression: 0 89 | allowsAlphaSplitting: 0 90 | overridden: 0 91 | androidETC2FallbackOverride: 0 92 | - serializedVersion: 2 93 | buildTarget: Android 94 | maxTextureSize: 8192 95 | resizeAlgorithm: 0 96 | textureFormat: -1 97 | textureCompression: 1 98 | compressionQuality: 50 99 | crunchedCompression: 0 100 | allowsAlphaSplitting: 0 101 | overridden: 0 102 | androidETC2FallbackOverride: 0 103 | - serializedVersion: 2 104 | buildTarget: Windows Store Apps 105 | maxTextureSize: 8192 106 | resizeAlgorithm: 0 107 | textureFormat: -1 108 | textureCompression: 1 109 | compressionQuality: 50 110 | crunchedCompression: 0 111 | allowsAlphaSplitting: 0 112 | overridden: 0 113 | androidETC2FallbackOverride: 0 114 | spriteSheet: 115 | serializedVersion: 2 116 | sprites: [] 117 | outline: [] 118 | physicsShape: [] 119 | bones: [] 120 | spriteID: 121 | vertices: [] 122 | indices: 123 | edges: [] 124 | weights: [] 125 | spritePackingTag: 126 | userData: 127 | assetBundleName: 128 | assetBundleVariant: 129 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Icons/Help_Icon.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 34f556d724b1bbf4097ca6220db2c581 3 | TextureImporter: 4 | fileIDToRecycleName: {} 5 | externalObjects: {} 6 | serializedVersion: 5 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 0 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | grayScaleToAlpha: 0 25 | generateCubemap: 6 26 | cubemapConvolution: 0 27 | seamlessCubemap: 0 28 | textureFormat: 1 29 | maxTextureSize: 2048 30 | textureSettings: 31 | serializedVersion: 2 32 | filterMode: -1 33 | aniso: 1 34 | mipBias: -1 35 | wrapU: 1 36 | wrapV: 1 37 | wrapW: -1 38 | nPOTScale: 0 39 | lightmap: 0 40 | compressionQuality: 50 41 | spriteMode: 0 42 | spriteExtrude: 1 43 | spriteMeshType: 1 44 | alignment: 0 45 | spritePivot: {x: 0.5, y: 0.5} 46 | spritePixelsToUnits: 100 47 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 48 | spriteGenerateFallbackPhysicsShape: 1 49 | alphaUsage: 1 50 | alphaIsTransparency: 1 51 | spriteTessellationDetail: -1 52 | textureType: 2 53 | textureShape: 1 54 | singleChannelComponent: 0 55 | maxTextureSizeSet: 0 56 | compressionQualitySet: 0 57 | textureFormatSet: 0 58 | platformSettings: 59 | - serializedVersion: 2 60 | buildTarget: DefaultTexturePlatform 61 | maxTextureSize: 8192 62 | resizeAlgorithm: 0 63 | textureFormat: -1 64 | textureCompression: 1 65 | compressionQuality: 50 66 | crunchedCompression: 0 67 | allowsAlphaSplitting: 0 68 | overridden: 0 69 | androidETC2FallbackOverride: 0 70 | - serializedVersion: 2 71 | buildTarget: Standalone 72 | maxTextureSize: 8192 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | androidETC2FallbackOverride: 0 81 | - serializedVersion: 2 82 | buildTarget: iPhone 83 | maxTextureSize: 8192 84 | resizeAlgorithm: 0 85 | textureFormat: -1 86 | textureCompression: 1 87 | compressionQuality: 50 88 | crunchedCompression: 0 89 | allowsAlphaSplitting: 0 90 | overridden: 0 91 | androidETC2FallbackOverride: 0 92 | - serializedVersion: 2 93 | buildTarget: Android 94 | maxTextureSize: 8192 95 | resizeAlgorithm: 0 96 | textureFormat: -1 97 | textureCompression: 1 98 | compressionQuality: 50 99 | crunchedCompression: 0 100 | allowsAlphaSplitting: 0 101 | overridden: 0 102 | androidETC2FallbackOverride: 0 103 | - serializedVersion: 2 104 | buildTarget: Windows Store Apps 105 | maxTextureSize: 8192 106 | resizeAlgorithm: 0 107 | textureFormat: -1 108 | textureCompression: 1 109 | compressionQuality: 50 110 | crunchedCompression: 0 111 | allowsAlphaSplitting: 0 112 | overridden: 0 113 | androidETC2FallbackOverride: 0 114 | spriteSheet: 115 | serializedVersion: 2 116 | sprites: [] 117 | outline: [] 118 | physicsShape: [] 119 | bones: [] 120 | spriteID: 121 | vertices: [] 122 | indices: 123 | edges: [] 124 | weights: [] 125 | spritePackingTag: 126 | userData: 127 | assetBundleName: 128 | assetBundleVariant: 129 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/WaveSpawner.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | 5 | public class WaveSpawner : MonoBehaviour 6 | { 7 | 8 | public GameObject m_objToSpawn; 9 | public int m_waveCount; 10 | public float m_startTime; 11 | public float m_waveLinearSpeed; 12 | public float m_waveCircularSpeed; 13 | public float m_waveRadius; 14 | public float m_waveLenInDegree; 15 | 16 | 17 | private GameObject[] m_spawnedObjects; 18 | private Vector3 m_wavePos; 19 | private float m_clock; 20 | private float m_angle; 21 | private int m_instantiatePos; 22 | 23 | 24 | // Start is called before the first frame update 25 | void Start() 26 | { 27 | if (m_objToSpawn == null) 28 | { 29 | // delete spawner if level designer forget to fill the spawn type :) 30 | Debug.Log("WARNING: SpawnableObject with empty m_objToSpawn field"); 31 | Destroy(gameObject); 32 | } 33 | else 34 | { 35 | m_wavePos = transform.position; 36 | m_spawnedObjects = new GameObject[m_waveCount]; 37 | m_instantiatePos = 0; 38 | } 39 | } 40 | 41 | void OnDrawGizmos() 42 | { 43 | Gizmos.color = new Color(1, 1, 0, 0.5f); 44 | Gizmos.DrawCube(transform.position, new Vector3(2, 2, 2)); 45 | } 46 | 47 | private int UpdateWavePos(float dt) 48 | { 49 | float angle = m_angle; 50 | int count = 0; 51 | for (int i = 0; i < m_instantiatePos; i++) 52 | { 53 | if (m_spawnedObjects[i] != null) 54 | { 55 | Vector3 pos = transform.position; 56 | pos.x = m_wavePos.x + m_waveRadius * Mathf.Cos(angle); 57 | pos.z = m_wavePos.z + m_waveRadius * Mathf.Sin(angle); 58 | m_spawnedObjects[i].transform.position = pos; 59 | 60 | if (m_spawnedObjects[i].transform.position.z < 0) 61 | { 62 | Destroy(m_spawnedObjects[i]); 63 | m_spawnedObjects[i] = null; 64 | } 65 | else 66 | { 67 | count++; 68 | } 69 | 70 | } 71 | angle += m_waveLenInDegree * 3.1415926f / (180.0f * (float)m_waveCount); 72 | } 73 | 74 | m_angle += dt * m_waveCircularSpeed; 75 | m_wavePos.z -= dt * m_waveLinearSpeed; 76 | 77 | return count; 78 | } 79 | 80 | 81 | // Update is called once per frame 82 | void Update() 83 | { 84 | float dt = Time.deltaTime; 85 | m_clock += dt; 86 | if ( m_clock >= m_startTime ) 87 | { 88 | if (m_instantiatePos < m_waveCount) 89 | { 90 | int i = m_instantiatePos; 91 | m_spawnedObjects[i] = Instantiate(m_objToSpawn); 92 | float rndHue = UnityEngine.Random.Range(0.0f, 1.0f); 93 | Renderer r = m_spawnedObjects[i].GetComponent(); 94 | EnemyMovement enemy = m_spawnedObjects[i].GetComponent(); 95 | enemy.m_rndHueColor = rndHue; 96 | r.material.color = Color.HSVToRGB(rndHue, 0.8f, 1); 97 | m_instantiatePos++; 98 | } 99 | 100 | int count = UpdateWavePos(dt); 101 | 102 | // if wave emitter is empty (all dead) AND outside of playground, reset it 103 | if ((count == 0) && (m_wavePos.z < 0.0f)) 104 | { 105 | m_clock = 0.0f; 106 | m_wavePos = transform.position; 107 | m_instantiatePos = 0; 108 | } 109 | } 110 | } 111 | } 112 | -------------------------------------------------------------------------------- /Assets/Plane/Plane_Blue.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 53629c386ebe5f3469ffb10ea4d5e5ff 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 0 41 | wrapV: 0 42 | wrapW: 0 43 | nPOTScale: 1 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 0 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 0 56 | spriteTessellationDetail: -1 57 | textureType: 0 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | - serializedVersion: 3 110 | buildTarget: Android 111 | maxTextureSize: 2048 112 | resizeAlgorithm: 0 113 | textureFormat: -1 114 | textureCompression: 1 115 | compressionQuality: 50 116 | crunchedCompression: 0 117 | allowsAlphaSplitting: 0 118 | overridden: 0 119 | ignorePlatformSupport: 0 120 | androidETC2FallbackOverride: 0 121 | forceMaximumCompressionQuality_BC6H_BC7: 0 122 | spriteSheet: 123 | serializedVersion: 2 124 | sprites: [] 125 | outline: [] 126 | physicsShape: [] 127 | bones: [] 128 | spriteID: 129 | internalID: 0 130 | vertices: [] 131 | indices: 132 | edges: [] 133 | weights: [] 134 | secondaryTextures: [] 135 | nameFileIdTable: {} 136 | mipmapLimitGroupName: 137 | pSDRemoveMatte: 0 138 | userData: 139 | assetBundleName: 140 | assetBundleVariant: 141 | -------------------------------------------------------------------------------- /Assets/Plane/Plane_Orange.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8b9069338ce9beb4b846c989e2c537a5 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 0 41 | wrapV: 0 42 | wrapW: 0 43 | nPOTScale: 1 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 0 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 0 56 | spriteTessellationDetail: -1 57 | textureType: 0 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | - serializedVersion: 3 110 | buildTarget: Android 111 | maxTextureSize: 2048 112 | resizeAlgorithm: 0 113 | textureFormat: -1 114 | textureCompression: 1 115 | compressionQuality: 50 116 | crunchedCompression: 0 117 | allowsAlphaSplitting: 0 118 | overridden: 0 119 | ignorePlatformSupport: 0 120 | androidETC2FallbackOverride: 0 121 | forceMaximumCompressionQuality_BC6H_BC7: 0 122 | spriteSheet: 123 | serializedVersion: 2 124 | sprites: [] 125 | outline: [] 126 | physicsShape: [] 127 | bones: [] 128 | spriteID: 129 | internalID: 0 130 | vertices: [] 131 | indices: 132 | edges: [] 133 | weights: [] 134 | secondaryTextures: [] 135 | nameFileIdTable: {} 136 | mipmapLimitGroupName: 137 | pSDRemoveMatte: 0 138 | userData: 139 | assetBundleName: 140 | assetBundleVariant: 141 | -------------------------------------------------------------------------------- /Assets/Plane/Plane_White.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0ca5dc7c0e5123c42b1844c2e10a6150 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 0 41 | wrapV: 0 42 | wrapW: 0 43 | nPOTScale: 1 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 0 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 0 56 | spriteTessellationDetail: -1 57 | textureType: 0 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | - serializedVersion: 3 110 | buildTarget: Android 111 | maxTextureSize: 2048 112 | resizeAlgorithm: 0 113 | textureFormat: -1 114 | textureCompression: 1 115 | compressionQuality: 50 116 | crunchedCompression: 0 117 | allowsAlphaSplitting: 0 118 | overridden: 0 119 | ignorePlatformSupport: 0 120 | androidETC2FallbackOverride: 0 121 | forceMaximumCompressionQuality_BC6H_BC7: 0 122 | spriteSheet: 123 | serializedVersion: 2 124 | sprites: [] 125 | outline: [] 126 | physicsShape: [] 127 | bones: [] 128 | spriteID: 129 | internalID: 0 130 | vertices: [] 131 | indices: 132 | edges: [] 133 | weights: [] 134 | secondaryTextures: [] 135 | nameFileIdTable: {} 136 | mipmapLimitGroupName: 137 | pSDRemoveMatte: 0 138 | userData: 139 | assetBundleName: 140 | assetBundleVariant: 141 | -------------------------------------------------------------------------------- /Assets/Plane/Plane_Yellow.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: dd44cbea900ada84393f3eecf7650652 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 12 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | flipGreenChannel: 0 24 | isReadable: 0 25 | streamingMipmaps: 0 26 | streamingMipmapsPriority: 0 27 | vTOnly: 0 28 | ignoreMipmapLimit: 0 29 | grayScaleToAlpha: 0 30 | generateCubemap: 6 31 | cubemapConvolution: 0 32 | seamlessCubemap: 0 33 | textureFormat: 1 34 | maxTextureSize: 2048 35 | textureSettings: 36 | serializedVersion: 2 37 | filterMode: 1 38 | aniso: 1 39 | mipBias: 0 40 | wrapU: 0 41 | wrapV: 0 42 | wrapW: 0 43 | nPOTScale: 1 44 | lightmap: 0 45 | compressionQuality: 50 46 | spriteMode: 0 47 | spriteExtrude: 1 48 | spriteMeshType: 1 49 | alignment: 0 50 | spritePivot: {x: 0.5, y: 0.5} 51 | spritePixelsToUnits: 100 52 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 53 | spriteGenerateFallbackPhysicsShape: 1 54 | alphaUsage: 1 55 | alphaIsTransparency: 0 56 | spriteTessellationDetail: -1 57 | textureType: 0 58 | textureShape: 1 59 | singleChannelComponent: 0 60 | flipbookRows: 1 61 | flipbookColumns: 1 62 | maxTextureSizeSet: 0 63 | compressionQualitySet: 0 64 | textureFormatSet: 0 65 | ignorePngGamma: 0 66 | applyGammaDecoding: 0 67 | swizzle: 50462976 68 | cookieLightType: 0 69 | platformSettings: 70 | - serializedVersion: 3 71 | buildTarget: DefaultTexturePlatform 72 | maxTextureSize: 2048 73 | resizeAlgorithm: 0 74 | textureFormat: -1 75 | textureCompression: 1 76 | compressionQuality: 50 77 | crunchedCompression: 0 78 | allowsAlphaSplitting: 0 79 | overridden: 0 80 | ignorePlatformSupport: 0 81 | androidETC2FallbackOverride: 0 82 | forceMaximumCompressionQuality_BC6H_BC7: 0 83 | - serializedVersion: 3 84 | buildTarget: Standalone 85 | maxTextureSize: 2048 86 | resizeAlgorithm: 0 87 | textureFormat: -1 88 | textureCompression: 1 89 | compressionQuality: 50 90 | crunchedCompression: 0 91 | allowsAlphaSplitting: 0 92 | overridden: 0 93 | ignorePlatformSupport: 0 94 | androidETC2FallbackOverride: 0 95 | forceMaximumCompressionQuality_BC6H_BC7: 0 96 | - serializedVersion: 3 97 | buildTarget: Server 98 | maxTextureSize: 2048 99 | resizeAlgorithm: 0 100 | textureFormat: -1 101 | textureCompression: 1 102 | compressionQuality: 50 103 | crunchedCompression: 0 104 | allowsAlphaSplitting: 0 105 | overridden: 0 106 | ignorePlatformSupport: 0 107 | androidETC2FallbackOverride: 0 108 | forceMaximumCompressionQuality_BC6H_BC7: 0 109 | - serializedVersion: 3 110 | buildTarget: Android 111 | maxTextureSize: 2048 112 | resizeAlgorithm: 0 113 | textureFormat: -1 114 | textureCompression: 1 115 | compressionQuality: 50 116 | crunchedCompression: 0 117 | allowsAlphaSplitting: 0 118 | overridden: 0 119 | ignorePlatformSupport: 0 120 | androidETC2FallbackOverride: 0 121 | forceMaximumCompressionQuality_BC6H_BC7: 0 122 | spriteSheet: 123 | serializedVersion: 2 124 | sprites: [] 125 | outline: [] 126 | physicsShape: [] 127 | bones: [] 128 | spriteID: 129 | internalID: 0 130 | vertices: [] 131 | indices: 132 | edges: [] 133 | weights: [] 134 | secondaryTextures: [] 135 | nameFileIdTable: {} 136 | mipmapLimitGroupName: 137 | pSDRemoveMatte: 0 138 | userData: 139 | assetBundleName: 140 | assetBundleVariant: 141 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRP-HighQuality.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: bf2edee5c58d82540a51f03df9d42094, type: 3} 13 | m_Name: UniversalRP-HighQuality 14 | m_EditorClassIdentifier: 15 | k_AssetVersion: 11 16 | k_AssetPreviousVersion: 11 17 | m_RendererType: 1 18 | m_RendererData: {fileID: 0} 19 | m_RendererDataList: 20 | - {fileID: 11400000, guid: 4a8e21d5c33334b11b34a596161b9360, type: 2} 21 | m_DefaultRendererIndex: 0 22 | m_RequireDepthTexture: 0 23 | m_RequireOpaqueTexture: 0 24 | m_OpaqueDownsampling: 1 25 | m_SupportsTerrainHoles: 1 26 | m_SupportsHDR: 1 27 | m_HDRColorBufferPrecision: 0 28 | m_MSAA: 2 29 | m_RenderScale: 1 30 | m_UpscalingFilter: 0 31 | m_FsrOverrideSharpness: 0 32 | m_FsrSharpness: 0.92 33 | m_EnableLODCrossFade: 1 34 | m_LODCrossFadeDitheringType: 1 35 | m_ShEvalMode: 0 36 | m_MainLightRenderingMode: 1 37 | m_MainLightShadowsSupported: 1 38 | m_MainLightShadowmapResolution: 2048 39 | m_AdditionalLightsRenderingMode: 1 40 | m_AdditionalLightsPerObjectLimit: 4 41 | m_AdditionalLightShadowsSupported: 1 42 | m_AdditionalLightsShadowmapResolution: 2048 43 | m_AdditionalLightsShadowResolutionTierLow: 512 44 | m_AdditionalLightsShadowResolutionTierMedium: 1024 45 | m_AdditionalLightsShadowResolutionTierHigh: 2048 46 | m_ReflectionProbeBlending: 1 47 | m_ReflectionProbeBoxProjection: 0 48 | m_ShadowDistance: 50 49 | m_ShadowCascadeCount: 2 50 | m_Cascade2Split: 0.25 51 | m_Cascade3Split: {x: 0.1, y: 0.3} 52 | m_Cascade4Split: {x: 0.067, y: 0.2, z: 0.467} 53 | m_CascadeBorder: 0.1 54 | m_ShadowDepthBias: 1 55 | m_ShadowNormalBias: 1 56 | m_AnyShadowsSupported: 1 57 | m_SoftShadowsSupported: 1 58 | m_ConservativeEnclosingSphere: 0 59 | m_NumIterationsEnclosingSphere: 64 60 | m_SoftShadowQuality: 2 61 | m_AdditionalLightsCookieResolution: 2048 62 | m_AdditionalLightsCookieFormat: 3 63 | m_UseSRPBatcher: 1 64 | m_SupportsDynamicBatching: 0 65 | m_MixedLightingSupported: 1 66 | m_SupportsLightCookies: 1 67 | m_SupportsLightLayers: 0 68 | m_DebugLevel: 0 69 | m_StoreActionsOptimization: 0 70 | m_EnableRenderGraph: 0 71 | m_UseAdaptivePerformance: 1 72 | m_ColorGradingMode: 0 73 | m_ColorGradingLutSize: 32 74 | m_UseFastSRGBLinearConversion: 0 75 | m_SupportDataDrivenLensFlare: 1 76 | m_ShadowType: 1 77 | m_LocalShadowsSupported: 0 78 | m_LocalShadowsAtlasResolution: 256 79 | m_MaxPixelLights: 0 80 | m_ShadowAtlasResolution: 256 81 | m_VolumeFrameworkUpdateMode: 0 82 | m_Textures: 83 | blueNoise64LTex: {fileID: 2800000, guid: e3d24661c1e055f45a7560c033dbb837, type: 3} 84 | bayerMatrixTex: {fileID: 2800000, guid: f9ee4ed84c1d10c49aabb9b210b0fc44, type: 3} 85 | m_PrefilteringModeMainLightShadows: 3 86 | m_PrefilteringModeAdditionalLight: 3 87 | m_PrefilteringModeAdditionalLightShadows: 2 88 | m_PrefilterXRKeywords: 1 89 | m_PrefilteringModeForwardPlus: 0 90 | m_PrefilteringModeDeferredRendering: 0 91 | m_PrefilteringModeScreenSpaceOcclusion: 0 92 | m_PrefilterDebugKeywords: 1 93 | m_PrefilterWriteRenderingLayers: 1 94 | m_PrefilterHDROutput: 1 95 | m_PrefilterSSAODepthNormals: 1 96 | m_PrefilterSSAOSourceDepthLow: 1 97 | m_PrefilterSSAOSourceDepthMedium: 1 98 | m_PrefilterSSAOSourceDepthHigh: 1 99 | m_PrefilterSSAOInterleaved: 1 100 | m_PrefilterSSAOBlueNoise: 1 101 | m_PrefilterSSAOSampleCountLow: 1 102 | m_PrefilterSSAOSampleCountMedium: 1 103 | m_PrefilterSSAOSampleCountHigh: 1 104 | m_PrefilterDBufferMRT1: 1 105 | m_PrefilterDBufferMRT2: 1 106 | m_PrefilterDBufferMRT3: 1 107 | m_PrefilterScreenCoord: 1 108 | m_PrefilterNativeRenderPass: 1 109 | m_ShaderVariantLogLevel: 0 110 | m_ShadowCascades: 1 111 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRP-LowQuality.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: bf2edee5c58d82540a51f03df9d42094, type: 3} 13 | m_Name: UniversalRP-LowQuality 14 | m_EditorClassIdentifier: 15 | k_AssetVersion: 11 16 | k_AssetPreviousVersion: 11 17 | m_RendererType: 1 18 | m_RendererData: {fileID: 0} 19 | m_RendererDataList: 20 | - {fileID: 11400000, guid: 4a8e21d5c33334b11b34a596161b9360, type: 2} 21 | m_DefaultRendererIndex: 0 22 | m_RequireDepthTexture: 0 23 | m_RequireOpaqueTexture: 0 24 | m_OpaqueDownsampling: 1 25 | m_SupportsTerrainHoles: 1 26 | m_SupportsHDR: 0 27 | m_HDRColorBufferPrecision: 0 28 | m_MSAA: 1 29 | m_RenderScale: 1 30 | m_UpscalingFilter: 0 31 | m_FsrOverrideSharpness: 0 32 | m_FsrSharpness: 0.92 33 | m_EnableLODCrossFade: 1 34 | m_LODCrossFadeDitheringType: 1 35 | m_ShEvalMode: 0 36 | m_MainLightRenderingMode: 1 37 | m_MainLightShadowsSupported: 0 38 | m_MainLightShadowmapResolution: 2048 39 | m_AdditionalLightsRenderingMode: 0 40 | m_AdditionalLightsPerObjectLimit: 4 41 | m_AdditionalLightShadowsSupported: 0 42 | m_AdditionalLightsShadowmapResolution: 2048 43 | m_AdditionalLightsShadowResolutionTierLow: 512 44 | m_AdditionalLightsShadowResolutionTierMedium: 1024 45 | m_AdditionalLightsShadowResolutionTierHigh: 2048 46 | m_ReflectionProbeBlending: 0 47 | m_ReflectionProbeBoxProjection: 0 48 | m_ShadowDistance: 50 49 | m_ShadowCascadeCount: 1 50 | m_Cascade2Split: 0.25 51 | m_Cascade3Split: {x: 0.1, y: 0.3} 52 | m_Cascade4Split: {x: 0.067, y: 0.2, z: 0.467} 53 | m_CascadeBorder: 0.1 54 | m_ShadowDepthBias: 1 55 | m_ShadowNormalBias: 1 56 | m_AnyShadowsSupported: 1 57 | m_SoftShadowsSupported: 0 58 | m_ConservativeEnclosingSphere: 0 59 | m_NumIterationsEnclosingSphere: 64 60 | m_SoftShadowQuality: 2 61 | m_AdditionalLightsCookieResolution: 2048 62 | m_AdditionalLightsCookieFormat: 3 63 | m_UseSRPBatcher: 1 64 | m_SupportsDynamicBatching: 0 65 | m_MixedLightingSupported: 1 66 | m_SupportsLightCookies: 1 67 | m_SupportsLightLayers: 0 68 | m_DebugLevel: 0 69 | m_StoreActionsOptimization: 0 70 | m_EnableRenderGraph: 0 71 | m_UseAdaptivePerformance: 1 72 | m_ColorGradingMode: 0 73 | m_ColorGradingLutSize: 16 74 | m_UseFastSRGBLinearConversion: 0 75 | m_SupportDataDrivenLensFlare: 1 76 | m_ShadowType: 1 77 | m_LocalShadowsSupported: 0 78 | m_LocalShadowsAtlasResolution: 256 79 | m_MaxPixelLights: 0 80 | m_ShadowAtlasResolution: 256 81 | m_VolumeFrameworkUpdateMode: 0 82 | m_Textures: 83 | blueNoise64LTex: {fileID: 2800000, guid: e3d24661c1e055f45a7560c033dbb837, type: 3} 84 | bayerMatrixTex: {fileID: 2800000, guid: f9ee4ed84c1d10c49aabb9b210b0fc44, type: 3} 85 | m_PrefilteringModeMainLightShadows: 0 86 | m_PrefilteringModeAdditionalLight: 0 87 | m_PrefilteringModeAdditionalLightShadows: 0 88 | m_PrefilterXRKeywords: 1 89 | m_PrefilteringModeForwardPlus: 0 90 | m_PrefilteringModeDeferredRendering: 0 91 | m_PrefilteringModeScreenSpaceOcclusion: 0 92 | m_PrefilterDebugKeywords: 1 93 | m_PrefilterWriteRenderingLayers: 1 94 | m_PrefilterHDROutput: 1 95 | m_PrefilterSSAODepthNormals: 1 96 | m_PrefilterSSAOSourceDepthLow: 1 97 | m_PrefilterSSAOSourceDepthMedium: 1 98 | m_PrefilterSSAOSourceDepthHigh: 1 99 | m_PrefilterSSAOInterleaved: 1 100 | m_PrefilterSSAOBlueNoise: 1 101 | m_PrefilterSSAOSampleCountLow: 1 102 | m_PrefilterSSAOSampleCountMedium: 1 103 | m_PrefilterSSAOSampleCountHigh: 1 104 | m_PrefilterDBufferMRT1: 1 105 | m_PrefilterDBufferMRT2: 1 106 | m_PrefilterDBufferMRT3: 1 107 | m_PrefilterScreenCoord: 1 108 | m_PrefilterNativeRenderPass: 1 109 | m_ShaderVariantLogLevel: 0 110 | m_ShadowCascades: 0 111 | -------------------------------------------------------------------------------- /Assets/Settings/UniversalRP-MediumQuality.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &11400000 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: bf2edee5c58d82540a51f03df9d42094, type: 3} 13 | m_Name: UniversalRP-MediumQuality 14 | m_EditorClassIdentifier: 15 | k_AssetVersion: 11 16 | k_AssetPreviousVersion: 11 17 | m_RendererType: 1 18 | m_RendererData: {fileID: 0} 19 | m_RendererDataList: 20 | - {fileID: 11400000, guid: 4a8e21d5c33334b11b34a596161b9360, type: 2} 21 | m_DefaultRendererIndex: 0 22 | m_RequireDepthTexture: 0 23 | m_RequireOpaqueTexture: 0 24 | m_OpaqueDownsampling: 1 25 | m_SupportsTerrainHoles: 1 26 | m_SupportsHDR: 0 27 | m_HDRColorBufferPrecision: 0 28 | m_MSAA: 1 29 | m_RenderScale: 1 30 | m_UpscalingFilter: 0 31 | m_FsrOverrideSharpness: 0 32 | m_FsrSharpness: 0.92 33 | m_EnableLODCrossFade: 1 34 | m_LODCrossFadeDitheringType: 1 35 | m_ShEvalMode: 0 36 | m_MainLightRenderingMode: 1 37 | m_MainLightShadowsSupported: 1 38 | m_MainLightShadowmapResolution: 2048 39 | m_AdditionalLightsRenderingMode: 1 40 | m_AdditionalLightsPerObjectLimit: 4 41 | m_AdditionalLightShadowsSupported: 0 42 | m_AdditionalLightsShadowmapResolution: 2048 43 | m_AdditionalLightsShadowResolutionTierLow: 512 44 | m_AdditionalLightsShadowResolutionTierMedium: 1024 45 | m_AdditionalLightsShadowResolutionTierHigh: 2048 46 | m_ReflectionProbeBlending: 0 47 | m_ReflectionProbeBoxProjection: 0 48 | m_ShadowDistance: 50 49 | m_ShadowCascadeCount: 1 50 | m_Cascade2Split: 0.25 51 | m_Cascade3Split: {x: 0.1, y: 0.3} 52 | m_Cascade4Split: {x: 0.067, y: 0.2, z: 0.467} 53 | m_CascadeBorder: 0.1 54 | m_ShadowDepthBias: 1 55 | m_ShadowNormalBias: 1 56 | m_AnyShadowsSupported: 1 57 | m_SoftShadowsSupported: 0 58 | m_ConservativeEnclosingSphere: 0 59 | m_NumIterationsEnclosingSphere: 64 60 | m_SoftShadowQuality: 2 61 | m_AdditionalLightsCookieResolution: 2048 62 | m_AdditionalLightsCookieFormat: 3 63 | m_UseSRPBatcher: 1 64 | m_SupportsDynamicBatching: 0 65 | m_MixedLightingSupported: 1 66 | m_SupportsLightCookies: 1 67 | m_SupportsLightLayers: 0 68 | m_DebugLevel: 0 69 | m_StoreActionsOptimization: 0 70 | m_EnableRenderGraph: 0 71 | m_UseAdaptivePerformance: 1 72 | m_ColorGradingMode: 0 73 | m_ColorGradingLutSize: 32 74 | m_UseFastSRGBLinearConversion: 0 75 | m_SupportDataDrivenLensFlare: 1 76 | m_ShadowType: 1 77 | m_LocalShadowsSupported: 0 78 | m_LocalShadowsAtlasResolution: 256 79 | m_MaxPixelLights: 0 80 | m_ShadowAtlasResolution: 256 81 | m_VolumeFrameworkUpdateMode: 0 82 | m_Textures: 83 | blueNoise64LTex: {fileID: 2800000, guid: e3d24661c1e055f45a7560c033dbb837, type: 3} 84 | bayerMatrixTex: {fileID: 2800000, guid: f9ee4ed84c1d10c49aabb9b210b0fc44, type: 3} 85 | m_PrefilteringModeMainLightShadows: 3 86 | m_PrefilteringModeAdditionalLight: 3 87 | m_PrefilteringModeAdditionalLightShadows: 0 88 | m_PrefilterXRKeywords: 1 89 | m_PrefilteringModeForwardPlus: 0 90 | m_PrefilteringModeDeferredRendering: 0 91 | m_PrefilteringModeScreenSpaceOcclusion: 0 92 | m_PrefilterDebugKeywords: 1 93 | m_PrefilterWriteRenderingLayers: 1 94 | m_PrefilterHDROutput: 1 95 | m_PrefilterSSAODepthNormals: 1 96 | m_PrefilterSSAOSourceDepthLow: 1 97 | m_PrefilterSSAOSourceDepthMedium: 1 98 | m_PrefilterSSAOSourceDepthHigh: 1 99 | m_PrefilterSSAOInterleaved: 1 100 | m_PrefilterSSAOBlueNoise: 1 101 | m_PrefilterSSAOSampleCountLow: 1 102 | m_PrefilterSSAOSampleCountMedium: 1 103 | m_PrefilterSSAOSampleCountHigh: 1 104 | m_PrefilterDBufferMRT1: 1 105 | m_PrefilterDBufferMRT2: 1 106 | m_PrefilterDBufferMRT3: 1 107 | m_PrefilterScreenCoord: 1 108 | m_PrefilterNativeRenderPass: 1 109 | m_ShaderVariantLogLevel: 0 110 | m_ShadowCascades: 0 111 | -------------------------------------------------------------------------------- /Assets/Materials/Bullet_Mat.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &-5588022611203838854 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 11 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} 13 | m_Name: 14 | m_EditorClassIdentifier: 15 | version: 7 16 | --- !u!21 &2100000 17 | Material: 18 | serializedVersion: 8 19 | m_ObjectHideFlags: 0 20 | m_CorrespondingSourceObject: {fileID: 0} 21 | m_PrefabInstance: {fileID: 0} 22 | m_PrefabAsset: {fileID: 0} 23 | m_Name: Bullet_Mat 24 | m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3} 25 | m_Parent: {fileID: 0} 26 | m_ModifiedSerializedProperties: 0 27 | m_ValidKeywords: [] 28 | m_InvalidKeywords: [] 29 | m_LightmapFlags: 4 30 | m_EnableInstancingVariants: 0 31 | m_DoubleSidedGI: 0 32 | m_CustomRenderQueue: -1 33 | stringTagMap: 34 | RenderType: Opaque 35 | disabledShaderPasses: [] 36 | m_LockedProperties: 37 | m_SavedProperties: 38 | serializedVersion: 3 39 | m_TexEnvs: 40 | - _BaseMap: 41 | m_Texture: {fileID: 0} 42 | m_Scale: {x: 1, y: 1} 43 | m_Offset: {x: 0, y: 0} 44 | - _BumpMap: 45 | m_Texture: {fileID: 0} 46 | m_Scale: {x: 1, y: 1} 47 | m_Offset: {x: 0, y: 0} 48 | - _DetailAlbedoMap: 49 | m_Texture: {fileID: 0} 50 | m_Scale: {x: 1, y: 1} 51 | m_Offset: {x: 0, y: 0} 52 | - _DetailMask: 53 | m_Texture: {fileID: 0} 54 | m_Scale: {x: 1, y: 1} 55 | m_Offset: {x: 0, y: 0} 56 | - _DetailNormalMap: 57 | m_Texture: {fileID: 0} 58 | m_Scale: {x: 1, y: 1} 59 | m_Offset: {x: 0, y: 0} 60 | - _EmissionMap: 61 | m_Texture: {fileID: 0} 62 | m_Scale: {x: 1, y: 1} 63 | m_Offset: {x: 0, y: 0} 64 | - _MainTex: 65 | m_Texture: {fileID: 0} 66 | m_Scale: {x: 1, y: 1} 67 | m_Offset: {x: 0, y: 0} 68 | - _MetallicGlossMap: 69 | m_Texture: {fileID: 0} 70 | m_Scale: {x: 1, y: 1} 71 | m_Offset: {x: 0, y: 0} 72 | - _OcclusionMap: 73 | m_Texture: {fileID: 0} 74 | m_Scale: {x: 1, y: 1} 75 | m_Offset: {x: 0, y: 0} 76 | - _ParallaxMap: 77 | m_Texture: {fileID: 0} 78 | m_Scale: {x: 1, y: 1} 79 | m_Offset: {x: 0, y: 0} 80 | - _SpecGlossMap: 81 | m_Texture: {fileID: 0} 82 | m_Scale: {x: 1, y: 1} 83 | m_Offset: {x: 0, y: 0} 84 | - unity_Lightmaps: 85 | m_Texture: {fileID: 0} 86 | m_Scale: {x: 1, y: 1} 87 | m_Offset: {x: 0, y: 0} 88 | - unity_LightmapsInd: 89 | m_Texture: {fileID: 0} 90 | m_Scale: {x: 1, y: 1} 91 | m_Offset: {x: 0, y: 0} 92 | - unity_ShadowMasks: 93 | m_Texture: {fileID: 0} 94 | m_Scale: {x: 1, y: 1} 95 | m_Offset: {x: 0, y: 0} 96 | m_Ints: [] 97 | m_Floats: 98 | - _AlphaClip: 0 99 | - _AlphaToMask: 0 100 | - _Blend: 0 101 | - _BlendModePreserveSpecular: 1 102 | - _BumpScale: 1 103 | - _ClearCoatMask: 0 104 | - _ClearCoatSmoothness: 0 105 | - _Cull: 2 106 | - _Cutoff: 0.5 107 | - _DetailAlbedoMapScale: 1 108 | - _DetailNormalMapScale: 1 109 | - _DstBlend: 0 110 | - _DstBlendAlpha: 0 111 | - _EnvironmentReflections: 1 112 | - _GlossMapScale: 0 113 | - _Glossiness: 0 114 | - _GlossyReflections: 0 115 | - _Metallic: 0 116 | - _OcclusionStrength: 1 117 | - _Parallax: 0.005 118 | - _QueueOffset: 0 119 | - _ReceiveShadows: 1 120 | - _Smoothness: 0.5 121 | - _SmoothnessTextureChannel: 0 122 | - _SpecularHighlights: 1 123 | - _SrcBlend: 1 124 | - _SrcBlendAlpha: 1 125 | - _Surface: 0 126 | - _WorkflowMode: 1 127 | - _ZWrite: 1 128 | m_Colors: 129 | - _BaseColor: {r: 1, g: 0, b: 0, a: 1} 130 | - _Color: {r: 1, g: 0, b: 0, a: 1} 131 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 132 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 133 | m_BuildTextureStacks: [] 134 | -------------------------------------------------------------------------------- /Assets/Presets/Defaults/DirectionalLight_Default.preset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!181963792 &2655988077585873504 4 | Preset: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_Name: DirectionalLight_Default 9 | m_TargetType: 10 | m_NativeTypeID: 108 11 | m_ManagedTypePPtr: {fileID: 0} 12 | m_ManagedTypeFallback: 13 | m_Properties: 14 | - target: {fileID: 0} 15 | propertyPath: m_Enabled 16 | value: 1 17 | objectReference: {fileID: 0} 18 | - target: {fileID: 0} 19 | propertyPath: m_Type 20 | value: 1 21 | objectReference: {fileID: 0} 22 | - target: {fileID: 0} 23 | propertyPath: m_Color.r 24 | value: 1 25 | objectReference: {fileID: 0} 26 | - target: {fileID: 0} 27 | propertyPath: m_Color.g 28 | value: 0.95686275 29 | objectReference: {fileID: 0} 30 | - target: {fileID: 0} 31 | propertyPath: m_Color.b 32 | value: 0.8392157 33 | objectReference: {fileID: 0} 34 | - target: {fileID: 0} 35 | propertyPath: m_Color.a 36 | value: 1 37 | objectReference: {fileID: 0} 38 | - target: {fileID: 0} 39 | propertyPath: m_Intensity 40 | value: 2 41 | objectReference: {fileID: 0} 42 | - target: {fileID: 0} 43 | propertyPath: m_Range 44 | value: 10 45 | objectReference: {fileID: 0} 46 | - target: {fileID: 0} 47 | propertyPath: m_SpotAngle 48 | value: 30 49 | objectReference: {fileID: 0} 50 | - target: {fileID: 0} 51 | propertyPath: m_CookieSize 52 | value: 10 53 | objectReference: {fileID: 0} 54 | - target: {fileID: 0} 55 | propertyPath: m_Shadows.m_Type 56 | value: 2 57 | objectReference: {fileID: 0} 58 | - target: {fileID: 0} 59 | propertyPath: m_Shadows.m_Resolution 60 | value: -1 61 | objectReference: {fileID: 0} 62 | - target: {fileID: 0} 63 | propertyPath: m_Shadows.m_CustomResolution 64 | value: -1 65 | objectReference: {fileID: 0} 66 | - target: {fileID: 0} 67 | propertyPath: m_Shadows.m_Strength 68 | value: 1 69 | objectReference: {fileID: 0} 70 | - target: {fileID: 0} 71 | propertyPath: m_Shadows.m_Bias 72 | value: 0.02 73 | objectReference: {fileID: 0} 74 | - target: {fileID: 0} 75 | propertyPath: m_Shadows.m_NormalBias 76 | value: 0.1 77 | objectReference: {fileID: 0} 78 | - target: {fileID: 0} 79 | propertyPath: m_Shadows.m_NearPlane 80 | value: 0.1 81 | objectReference: {fileID: 0} 82 | - target: {fileID: 0} 83 | propertyPath: m_Cookie 84 | value: 85 | objectReference: {fileID: 0} 86 | - target: {fileID: 0} 87 | propertyPath: m_DrawHalo 88 | value: 0 89 | objectReference: {fileID: 0} 90 | - target: {fileID: 0} 91 | propertyPath: m_Flare 92 | value: 93 | objectReference: {fileID: 0} 94 | - target: {fileID: 0} 95 | propertyPath: m_RenderMode 96 | value: 0 97 | objectReference: {fileID: 0} 98 | - target: {fileID: 0} 99 | propertyPath: m_CullingMask.m_Bits 100 | value: 4294967295 101 | objectReference: {fileID: 0} 102 | - target: {fileID: 0} 103 | propertyPath: m_Lightmapping 104 | value: 4 105 | objectReference: {fileID: 0} 106 | - target: {fileID: 0} 107 | propertyPath: m_LightShadowCasterMode 108 | value: 0 109 | objectReference: {fileID: 0} 110 | - target: {fileID: 0} 111 | propertyPath: m_AreaSize.x 112 | value: 1 113 | objectReference: {fileID: 0} 114 | - target: {fileID: 0} 115 | propertyPath: m_AreaSize.y 116 | value: 1 117 | objectReference: {fileID: 0} 118 | - target: {fileID: 0} 119 | propertyPath: m_BounceIntensity 120 | value: 1 121 | objectReference: {fileID: 0} 122 | - target: {fileID: 0} 123 | propertyPath: m_ColorTemperature 124 | value: 6570 125 | objectReference: {fileID: 0} 126 | - target: {fileID: 0} 127 | propertyPath: m_UseColorTemperature 128 | value: 0 129 | objectReference: {fileID: 0} 130 | - target: {fileID: 0} 131 | propertyPath: m_ShadowRadius 132 | value: 0 133 | objectReference: {fileID: 0} 134 | - target: {fileID: 0} 135 | propertyPath: m_ShadowAngle 136 | value: 0 137 | objectReference: {fileID: 0} 138 | -------------------------------------------------------------------------------- /Assets/Materials/tmp_mat.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 8 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: tmp_mat 11 | m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3} 12 | m_Parent: {fileID: 0} 13 | m_ModifiedSerializedProperties: 0 14 | m_ValidKeywords: [] 15 | m_InvalidKeywords: [] 16 | m_LightmapFlags: 4 17 | m_EnableInstancingVariants: 0 18 | m_DoubleSidedGI: 0 19 | m_CustomRenderQueue: -1 20 | stringTagMap: 21 | RenderType: Opaque 22 | disabledShaderPasses: [] 23 | m_LockedProperties: 24 | m_SavedProperties: 25 | serializedVersion: 3 26 | m_TexEnvs: 27 | - _BaseMap: 28 | m_Texture: {fileID: 0} 29 | m_Scale: {x: 1, y: 1} 30 | m_Offset: {x: 0, y: 0} 31 | - _BumpMap: 32 | m_Texture: {fileID: 0} 33 | m_Scale: {x: 1, y: 1} 34 | m_Offset: {x: 0, y: 0} 35 | - _DetailAlbedoMap: 36 | m_Texture: {fileID: 0} 37 | m_Scale: {x: 1, y: 1} 38 | m_Offset: {x: 0, y: 0} 39 | - _DetailMask: 40 | m_Texture: {fileID: 0} 41 | m_Scale: {x: 1, y: 1} 42 | m_Offset: {x: 0, y: 0} 43 | - _DetailNormalMap: 44 | m_Texture: {fileID: 0} 45 | m_Scale: {x: 1, y: 1} 46 | m_Offset: {x: 0, y: 0} 47 | - _EmissionMap: 48 | m_Texture: {fileID: 0} 49 | m_Scale: {x: 1, y: 1} 50 | m_Offset: {x: 0, y: 0} 51 | - _MainTex: 52 | m_Texture: {fileID: 0} 53 | m_Scale: {x: 1, y: 1} 54 | m_Offset: {x: 0, y: 0} 55 | - _MetallicGlossMap: 56 | m_Texture: {fileID: 0} 57 | m_Scale: {x: 1, y: 1} 58 | m_Offset: {x: 0, y: 0} 59 | - _OcclusionMap: 60 | m_Texture: {fileID: 0} 61 | m_Scale: {x: 1, y: 1} 62 | m_Offset: {x: 0, y: 0} 63 | - _ParallaxMap: 64 | m_Texture: {fileID: 0} 65 | m_Scale: {x: 1, y: 1} 66 | m_Offset: {x: 0, y: 0} 67 | - _SpecGlossMap: 68 | m_Texture: {fileID: 0} 69 | m_Scale: {x: 1, y: 1} 70 | m_Offset: {x: 0, y: 0} 71 | - unity_Lightmaps: 72 | m_Texture: {fileID: 0} 73 | m_Scale: {x: 1, y: 1} 74 | m_Offset: {x: 0, y: 0} 75 | - unity_LightmapsInd: 76 | m_Texture: {fileID: 0} 77 | m_Scale: {x: 1, y: 1} 78 | m_Offset: {x: 0, y: 0} 79 | - unity_ShadowMasks: 80 | m_Texture: {fileID: 0} 81 | m_Scale: {x: 1, y: 1} 82 | m_Offset: {x: 0, y: 0} 83 | m_Ints: [] 84 | m_Floats: 85 | - _AlphaClip: 0 86 | - _AlphaToMask: 0 87 | - _Blend: 0 88 | - _BlendModePreserveSpecular: 1 89 | - _BumpScale: 1 90 | - _ClearCoatMask: 0 91 | - _ClearCoatSmoothness: 0 92 | - _Cull: 2 93 | - _Cutoff: 0.5 94 | - _DetailAlbedoMapScale: 1 95 | - _DetailNormalMapScale: 1 96 | - _DstBlend: 0 97 | - _DstBlendAlpha: 0 98 | - _EnvironmentReflections: 1 99 | - _GlossMapScale: 0 100 | - _Glossiness: 0 101 | - _GlossyReflections: 0 102 | - _Metallic: 0 103 | - _OcclusionStrength: 1 104 | - _Parallax: 0.005 105 | - _QueueOffset: 0 106 | - _ReceiveShadows: 1 107 | - _Smoothness: 0.5 108 | - _SmoothnessTextureChannel: 0 109 | - _SpecularHighlights: 1 110 | - _SrcBlend: 1 111 | - _SrcBlendAlpha: 1 112 | - _Surface: 0 113 | - _WorkflowMode: 1 114 | - _ZWrite: 1 115 | m_Colors: 116 | - _BaseColor: {r: 0.88901544, g: 0.9433962, b: 0.21804914, a: 1} 117 | - _Color: {r: 0.88901544, g: 0.9433962, b: 0.21804911, a: 1} 118 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 119 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 120 | m_BuildTextureStacks: [] 121 | --- !u!114 &4040715682398789201 122 | MonoBehaviour: 123 | m_ObjectHideFlags: 11 124 | m_CorrespondingSourceObject: {fileID: 0} 125 | m_PrefabInstance: {fileID: 0} 126 | m_PrefabAsset: {fileID: 0} 127 | m_GameObject: {fileID: 0} 128 | m_Enabled: 1 129 | m_EditorHideFlags: 0 130 | m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} 131 | m_Name: 132 | m_EditorClassIdentifier: 133 | version: 7 134 | -------------------------------------------------------------------------------- /Assets/Plane/Plane.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 8 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: Plane 11 | m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3} 12 | m_Parent: {fileID: 0} 13 | m_ModifiedSerializedProperties: 0 14 | m_ValidKeywords: [] 15 | m_InvalidKeywords: [] 16 | m_LightmapFlags: 4 17 | m_EnableInstancingVariants: 0 18 | m_DoubleSidedGI: 0 19 | m_CustomRenderQueue: -1 20 | stringTagMap: 21 | RenderType: Opaque 22 | disabledShaderPasses: [] 23 | m_LockedProperties: 24 | m_SavedProperties: 25 | serializedVersion: 3 26 | m_TexEnvs: 27 | - _BaseMap: 28 | m_Texture: {fileID: 2800000, guid: 8b9069338ce9beb4b846c989e2c537a5, type: 3} 29 | m_Scale: {x: 1, y: 1} 30 | m_Offset: {x: 0, y: 0} 31 | - _BumpMap: 32 | m_Texture: {fileID: 0} 33 | m_Scale: {x: 1, y: 1} 34 | m_Offset: {x: 0, y: 0} 35 | - _DetailAlbedoMap: 36 | m_Texture: {fileID: 0} 37 | m_Scale: {x: 1, y: 1} 38 | m_Offset: {x: 0, y: 0} 39 | - _DetailMask: 40 | m_Texture: {fileID: 0} 41 | m_Scale: {x: 1, y: 1} 42 | m_Offset: {x: 0, y: 0} 43 | - _DetailNormalMap: 44 | m_Texture: {fileID: 0} 45 | m_Scale: {x: 1, y: 1} 46 | m_Offset: {x: 0, y: 0} 47 | - _EmissionMap: 48 | m_Texture: {fileID: 0} 49 | m_Scale: {x: 1, y: 1} 50 | m_Offset: {x: 0, y: 0} 51 | - _MainTex: 52 | m_Texture: {fileID: 2800000, guid: 8b9069338ce9beb4b846c989e2c537a5, type: 3} 53 | m_Scale: {x: 1, y: 1} 54 | m_Offset: {x: 0, y: 0} 55 | - _MetallicGlossMap: 56 | m_Texture: {fileID: 0} 57 | m_Scale: {x: 1, y: 1} 58 | m_Offset: {x: 0, y: 0} 59 | - _OcclusionMap: 60 | m_Texture: {fileID: 0} 61 | m_Scale: {x: 1, y: 1} 62 | m_Offset: {x: 0, y: 0} 63 | - _ParallaxMap: 64 | m_Texture: {fileID: 0} 65 | m_Scale: {x: 1, y: 1} 66 | m_Offset: {x: 0, y: 0} 67 | - _SpecGlossMap: 68 | m_Texture: {fileID: 0} 69 | m_Scale: {x: 1, y: 1} 70 | m_Offset: {x: 0, y: 0} 71 | - unity_Lightmaps: 72 | m_Texture: {fileID: 0} 73 | m_Scale: {x: 1, y: 1} 74 | m_Offset: {x: 0, y: 0} 75 | - unity_LightmapsInd: 76 | m_Texture: {fileID: 0} 77 | m_Scale: {x: 1, y: 1} 78 | m_Offset: {x: 0, y: 0} 79 | - unity_ShadowMasks: 80 | m_Texture: {fileID: 0} 81 | m_Scale: {x: 1, y: 1} 82 | m_Offset: {x: 0, y: 0} 83 | m_Ints: [] 84 | m_Floats: 85 | - _AlphaClip: 0 86 | - _AlphaToMask: 0 87 | - _Blend: 0 88 | - _BlendModePreserveSpecular: 1 89 | - _BumpScale: 1 90 | - _ClearCoatMask: 0 91 | - _ClearCoatSmoothness: 0 92 | - _Cull: 2 93 | - _Cutoff: 0.5 94 | - _DetailAlbedoMapScale: 1 95 | - _DetailNormalMapScale: 1 96 | - _DstBlend: 0 97 | - _DstBlendAlpha: 0 98 | - _EnvironmentReflections: 1 99 | - _GlossMapScale: 0 100 | - _Glossiness: 0 101 | - _GlossyReflections: 0 102 | - _Metallic: 0 103 | - _OcclusionStrength: 1 104 | - _Parallax: 0.005 105 | - _QueueOffset: 0 106 | - _ReceiveShadows: 1 107 | - _Smoothness: 0.5 108 | - _SmoothnessTextureChannel: 0 109 | - _SpecularHighlights: 1 110 | - _SrcBlend: 1 111 | - _SrcBlendAlpha: 1 112 | - _Surface: 0 113 | - _WorkflowMode: 1 114 | - _ZWrite: 1 115 | m_Colors: 116 | - _BaseColor: {r: 1, g: 1, b: 1, a: 1} 117 | - _Color: {r: 1, g: 1, b: 1, a: 1} 118 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 119 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 120 | m_BuildTextureStacks: [] 121 | --- !u!114 &2324549922406541622 122 | MonoBehaviour: 123 | m_ObjectHideFlags: 11 124 | m_CorrespondingSourceObject: {fileID: 0} 125 | m_PrefabInstance: {fileID: 0} 126 | m_PrefabAsset: {fileID: 0} 127 | m_GameObject: {fileID: 0} 128 | m_Enabled: 1 129 | m_EditorHideFlags: 0 130 | m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} 131 | m_Name: 132 | m_EditorClassIdentifier: 133 | version: 7 134 | -------------------------------------------------------------------------------- /Assets/Materials/main_ship.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!114 &-5515378981833845291 4 | MonoBehaviour: 5 | m_ObjectHideFlags: 11 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | m_GameObject: {fileID: 0} 10 | m_Enabled: 1 11 | m_EditorHideFlags: 0 12 | m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} 13 | m_Name: 14 | m_EditorClassIdentifier: 15 | version: 7 16 | --- !u!21 &2100000 17 | Material: 18 | serializedVersion: 8 19 | m_ObjectHideFlags: 0 20 | m_CorrespondingSourceObject: {fileID: 0} 21 | m_PrefabInstance: {fileID: 0} 22 | m_PrefabAsset: {fileID: 0} 23 | m_Name: main_ship 24 | m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3} 25 | m_Parent: {fileID: 0} 26 | m_ModifiedSerializedProperties: 0 27 | m_ValidKeywords: [] 28 | m_InvalidKeywords: [] 29 | m_LightmapFlags: 4 30 | m_EnableInstancingVariants: 0 31 | m_DoubleSidedGI: 0 32 | m_CustomRenderQueue: -1 33 | stringTagMap: 34 | RenderType: Opaque 35 | disabledShaderPasses: [] 36 | m_LockedProperties: 37 | m_SavedProperties: 38 | serializedVersion: 3 39 | m_TexEnvs: 40 | - _BaseMap: 41 | m_Texture: {fileID: 2800000, guid: 0ca5dc7c0e5123c42b1844c2e10a6150, type: 3} 42 | m_Scale: {x: 1, y: 1} 43 | m_Offset: {x: 0, y: 0} 44 | - _BumpMap: 45 | m_Texture: {fileID: 0} 46 | m_Scale: {x: 1, y: 1} 47 | m_Offset: {x: 0, y: 0} 48 | - _DetailAlbedoMap: 49 | m_Texture: {fileID: 0} 50 | m_Scale: {x: 1, y: 1} 51 | m_Offset: {x: 0, y: 0} 52 | - _DetailMask: 53 | m_Texture: {fileID: 0} 54 | m_Scale: {x: 1, y: 1} 55 | m_Offset: {x: 0, y: 0} 56 | - _DetailNormalMap: 57 | m_Texture: {fileID: 0} 58 | m_Scale: {x: 1, y: 1} 59 | m_Offset: {x: 0, y: 0} 60 | - _EmissionMap: 61 | m_Texture: {fileID: 0} 62 | m_Scale: {x: 1, y: 1} 63 | m_Offset: {x: 0, y: 0} 64 | - _MainTex: 65 | m_Texture: {fileID: 2800000, guid: 0ca5dc7c0e5123c42b1844c2e10a6150, type: 3} 66 | m_Scale: {x: 1, y: 1} 67 | m_Offset: {x: 0, y: 0} 68 | - _MetallicGlossMap: 69 | m_Texture: {fileID: 0} 70 | m_Scale: {x: 1, y: 1} 71 | m_Offset: {x: 0, y: 0} 72 | - _OcclusionMap: 73 | m_Texture: {fileID: 0} 74 | m_Scale: {x: 1, y: 1} 75 | m_Offset: {x: 0, y: 0} 76 | - _ParallaxMap: 77 | m_Texture: {fileID: 0} 78 | m_Scale: {x: 1, y: 1} 79 | m_Offset: {x: 0, y: 0} 80 | - _SpecGlossMap: 81 | m_Texture: {fileID: 0} 82 | m_Scale: {x: 1, y: 1} 83 | m_Offset: {x: 0, y: 0} 84 | - unity_Lightmaps: 85 | m_Texture: {fileID: 0} 86 | m_Scale: {x: 1, y: 1} 87 | m_Offset: {x: 0, y: 0} 88 | - unity_LightmapsInd: 89 | m_Texture: {fileID: 0} 90 | m_Scale: {x: 1, y: 1} 91 | m_Offset: {x: 0, y: 0} 92 | - unity_ShadowMasks: 93 | m_Texture: {fileID: 0} 94 | m_Scale: {x: 1, y: 1} 95 | m_Offset: {x: 0, y: 0} 96 | m_Ints: [] 97 | m_Floats: 98 | - _AlphaClip: 0 99 | - _AlphaToMask: 0 100 | - _Blend: 0 101 | - _BlendModePreserveSpecular: 1 102 | - _BumpScale: 1 103 | - _ClearCoatMask: 0 104 | - _ClearCoatSmoothness: 0 105 | - _Cull: 2 106 | - _Cutoff: 0.5 107 | - _DetailAlbedoMapScale: 1 108 | - _DetailNormalMapScale: 1 109 | - _DstBlend: 0 110 | - _DstBlendAlpha: 0 111 | - _EnvironmentReflections: 1 112 | - _GlossMapScale: 0 113 | - _Glossiness: 0 114 | - _GlossyReflections: 0 115 | - _Metallic: 0 116 | - _OcclusionStrength: 1 117 | - _Parallax: 0.005 118 | - _QueueOffset: 0 119 | - _ReceiveShadows: 1 120 | - _Smoothness: 0.5 121 | - _SmoothnessTextureChannel: 0 122 | - _SpecularHighlights: 1 123 | - _SrcBlend: 1 124 | - _SrcBlendAlpha: 1 125 | - _Surface: 0 126 | - _WorkflowMode: 1 127 | - _ZWrite: 1 128 | m_Colors: 129 | - _BaseColor: {r: 1, g: 1, b: 1, a: 1} 130 | - _Color: {r: 1, g: 1, b: 1, a: 1} 131 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 132 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 133 | m_BuildTextureStacks: [] 134 | -------------------------------------------------------------------------------- /Assets/Materials/EnemyBody.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 8 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: EnemyBody 11 | m_Shader: {fileID: 4800000, guid: 8d2bb70cbf9db8d4da26e15b26e74248, type: 3} 12 | m_Parent: {fileID: 0} 13 | m_ModifiedSerializedProperties: 0 14 | m_ValidKeywords: [] 15 | m_InvalidKeywords: [] 16 | m_LightmapFlags: 4 17 | m_EnableInstancingVariants: 0 18 | m_DoubleSidedGI: 0 19 | m_CustomRenderQueue: -1 20 | stringTagMap: 21 | RenderType: Opaque 22 | disabledShaderPasses: [] 23 | m_LockedProperties: 24 | m_SavedProperties: 25 | serializedVersion: 3 26 | m_TexEnvs: 27 | - _BaseMap: 28 | m_Texture: {fileID: 0} 29 | m_Scale: {x: 1, y: 1} 30 | m_Offset: {x: 0, y: 0} 31 | - _BumpMap: 32 | m_Texture: {fileID: 0} 33 | m_Scale: {x: 1, y: 1} 34 | m_Offset: {x: 0, y: 0} 35 | - _DetailAlbedoMap: 36 | m_Texture: {fileID: 0} 37 | m_Scale: {x: 1, y: 1} 38 | m_Offset: {x: 0, y: 0} 39 | - _DetailMask: 40 | m_Texture: {fileID: 0} 41 | m_Scale: {x: 1, y: 1} 42 | m_Offset: {x: 0, y: 0} 43 | - _DetailNormalMap: 44 | m_Texture: {fileID: 0} 45 | m_Scale: {x: 1, y: 1} 46 | m_Offset: {x: 0, y: 0} 47 | - _EmissionMap: 48 | m_Texture: {fileID: 0} 49 | m_Scale: {x: 1, y: 1} 50 | m_Offset: {x: 0, y: 0} 51 | - _MainTex: 52 | m_Texture: {fileID: 0} 53 | m_Scale: {x: 1, y: 1} 54 | m_Offset: {x: 0, y: 0} 55 | - _MetallicGlossMap: 56 | m_Texture: {fileID: 0} 57 | m_Scale: {x: 1, y: 1} 58 | m_Offset: {x: 0, y: 0} 59 | - _OcclusionMap: 60 | m_Texture: {fileID: 0} 61 | m_Scale: {x: 1, y: 1} 62 | m_Offset: {x: 0, y: 0} 63 | - _ParallaxMap: 64 | m_Texture: {fileID: 0} 65 | m_Scale: {x: 1, y: 1} 66 | m_Offset: {x: 0, y: 0} 67 | - _SpecGlossMap: 68 | m_Texture: {fileID: 0} 69 | m_Scale: {x: 1, y: 1} 70 | m_Offset: {x: 0, y: 0} 71 | - unity_Lightmaps: 72 | m_Texture: {fileID: 0} 73 | m_Scale: {x: 1, y: 1} 74 | m_Offset: {x: 0, y: 0} 75 | - unity_LightmapsInd: 76 | m_Texture: {fileID: 0} 77 | m_Scale: {x: 1, y: 1} 78 | m_Offset: {x: 0, y: 0} 79 | - unity_ShadowMasks: 80 | m_Texture: {fileID: 0} 81 | m_Scale: {x: 1, y: 1} 82 | m_Offset: {x: 0, y: 0} 83 | m_Ints: [] 84 | m_Floats: 85 | - _AlphaClip: 0 86 | - _AlphaToMask: 0 87 | - _Blend: 0 88 | - _BlendModePreserveSpecular: 1 89 | - _BumpScale: 1 90 | - _ClearCoatMask: 0 91 | - _ClearCoatSmoothness: 0 92 | - _Cull: 2 93 | - _Cutoff: 0.5 94 | - _DetailAlbedoMapScale: 1 95 | - _DetailNormalMapScale: 1 96 | - _DstBlend: 0 97 | - _DstBlendAlpha: 0 98 | - _EnvironmentReflections: 1 99 | - _GlossMapScale: 0 100 | - _Glossiness: 0 101 | - _GlossinessSource: 0 102 | - _GlossyReflections: 0 103 | - _Metallic: 0 104 | - _OcclusionStrength: 1 105 | - _Parallax: 0.005 106 | - _QueueOffset: 0 107 | - _ReceiveShadows: 1 108 | - _Shininess: 0 109 | - _Smoothness: 0.5 110 | - _SmoothnessSource: 0 111 | - _SmoothnessTextureChannel: 0 112 | - _SpecSource: 0 113 | - _SpecularHighlights: 1 114 | - _SrcBlend: 1 115 | - _SrcBlendAlpha: 1 116 | - _Surface: 0 117 | - _WorkflowMode: 1 118 | - _ZWrite: 1 119 | m_Colors: 120 | - _BaseColor: {r: 0.66746414, g: 0.9339623, b: 0.5683072, a: 1} 121 | - _Color: {r: 0.66746414, g: 0.9339623, b: 0.56830716, a: 1} 122 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 123 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 124 | m_BuildTextureStacks: [] 125 | --- !u!114 &8032120405755791994 126 | MonoBehaviour: 127 | m_ObjectHideFlags: 11 128 | m_CorrespondingSourceObject: {fileID: 0} 129 | m_PrefabInstance: {fileID: 0} 130 | m_PrefabAsset: {fileID: 0} 131 | m_GameObject: {fileID: 0} 132 | m_Enabled: 1 133 | m_EditorHideFlags: 0 134 | m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} 135 | m_Name: 136 | m_EditorClassIdentifier: 137 | version: 7 138 | -------------------------------------------------------------------------------- /Assets/Materials/background_mat.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 8 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: background_mat 11 | m_Shader: {fileID: 4800000, guid: 8d2bb70cbf9db8d4da26e15b26e74248, type: 3} 12 | m_Parent: {fileID: 0} 13 | m_ModifiedSerializedProperties: 0 14 | m_ValidKeywords: [] 15 | m_InvalidKeywords: [] 16 | m_LightmapFlags: 4 17 | m_EnableInstancingVariants: 0 18 | m_DoubleSidedGI: 0 19 | m_CustomRenderQueue: -1 20 | stringTagMap: 21 | RenderType: Opaque 22 | disabledShaderPasses: [] 23 | m_LockedProperties: 24 | m_SavedProperties: 25 | serializedVersion: 3 26 | m_TexEnvs: 27 | - _BaseMap: 28 | m_Texture: {fileID: 0} 29 | m_Scale: {x: 1, y: 1} 30 | m_Offset: {x: 0, y: 0} 31 | - _BumpMap: 32 | m_Texture: {fileID: 0} 33 | m_Scale: {x: 1, y: 1} 34 | m_Offset: {x: 0, y: 0} 35 | - _DetailAlbedoMap: 36 | m_Texture: {fileID: 0} 37 | m_Scale: {x: 1, y: 1} 38 | m_Offset: {x: 0, y: 0} 39 | - _DetailMask: 40 | m_Texture: {fileID: 0} 41 | m_Scale: {x: 1, y: 1} 42 | m_Offset: {x: 0, y: 0} 43 | - _DetailNormalMap: 44 | m_Texture: {fileID: 0} 45 | m_Scale: {x: 1, y: 1} 46 | m_Offset: {x: 0, y: 0} 47 | - _EmissionMap: 48 | m_Texture: {fileID: 0} 49 | m_Scale: {x: 1, y: 1} 50 | m_Offset: {x: 0, y: 0} 51 | - _MainTex: 52 | m_Texture: {fileID: 0} 53 | m_Scale: {x: 1, y: 1} 54 | m_Offset: {x: 0, y: 0} 55 | - _MetallicGlossMap: 56 | m_Texture: {fileID: 0} 57 | m_Scale: {x: 1, y: 1} 58 | m_Offset: {x: 0, y: 0} 59 | - _OcclusionMap: 60 | m_Texture: {fileID: 0} 61 | m_Scale: {x: 1, y: 1} 62 | m_Offset: {x: 0, y: 0} 63 | - _ParallaxMap: 64 | m_Texture: {fileID: 0} 65 | m_Scale: {x: 1, y: 1} 66 | m_Offset: {x: 0, y: 0} 67 | - _SpecGlossMap: 68 | m_Texture: {fileID: 0} 69 | m_Scale: {x: 1, y: 1} 70 | m_Offset: {x: 0, y: 0} 71 | - unity_Lightmaps: 72 | m_Texture: {fileID: 0} 73 | m_Scale: {x: 1, y: 1} 74 | m_Offset: {x: 0, y: 0} 75 | - unity_LightmapsInd: 76 | m_Texture: {fileID: 0} 77 | m_Scale: {x: 1, y: 1} 78 | m_Offset: {x: 0, y: 0} 79 | - unity_ShadowMasks: 80 | m_Texture: {fileID: 0} 81 | m_Scale: {x: 1, y: 1} 82 | m_Offset: {x: 0, y: 0} 83 | m_Ints: [] 84 | m_Floats: 85 | - _AlphaClip: 0 86 | - _AlphaToMask: 0 87 | - _Blend: 0 88 | - _BlendModePreserveSpecular: 1 89 | - _BumpScale: 1 90 | - _ClearCoatMask: 0 91 | - _ClearCoatSmoothness: 0 92 | - _Cull: 2 93 | - _Cutoff: 0.5 94 | - _DetailAlbedoMapScale: 1 95 | - _DetailNormalMapScale: 1 96 | - _DstBlend: 0 97 | - _DstBlendAlpha: 0 98 | - _EnvironmentReflections: 1 99 | - _GlossMapScale: 0 100 | - _Glossiness: 0 101 | - _GlossinessSource: 0 102 | - _GlossyReflections: 0 103 | - _Metallic: 0 104 | - _OcclusionStrength: 1 105 | - _Parallax: 0.005 106 | - _QueueOffset: 0 107 | - _ReceiveShadows: 1 108 | - _Shininess: 0 109 | - _Smoothness: 0 110 | - _SmoothnessSource: 0 111 | - _SmoothnessTextureChannel: 0 112 | - _SpecSource: 0 113 | - _SpecularHighlights: 1 114 | - _SrcBlend: 1 115 | - _SrcBlendAlpha: 1 116 | - _Surface: 0 117 | - _WorkflowMode: 1 118 | - _ZWrite: 1 119 | m_Colors: 120 | - _BaseColor: {r: 0.8962264, g: 0.84709007, b: 0.114142045, a: 1} 121 | - _Color: {r: 0.8962264, g: 0.84709007, b: 0.11414201, a: 1} 122 | - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} 123 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 124 | m_BuildTextureStacks: [] 125 | --- !u!114 &4040715682398789201 126 | MonoBehaviour: 127 | m_ObjectHideFlags: 11 128 | m_CorrespondingSourceObject: {fileID: 0} 129 | m_PrefabInstance: {fileID: 0} 130 | m_PrefabAsset: {fileID: 0} 131 | m_GameObject: {fileID: 0} 132 | m_Enabled: 1 133 | m_EditorHideFlags: 0 134 | m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} 135 | m_Name: 136 | m_EditorClassIdentifier: 137 | version: 7 138 | -------------------------------------------------------------------------------- /Assets/Materials/debris_mat.mat: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!21 &2100000 4 | Material: 5 | serializedVersion: 8 6 | m_ObjectHideFlags: 0 7 | m_CorrespondingSourceObject: {fileID: 0} 8 | m_PrefabInstance: {fileID: 0} 9 | m_PrefabAsset: {fileID: 0} 10 | m_Name: debris_mat 11 | m_Shader: {fileID: 4800000, guid: 8d2bb70cbf9db8d4da26e15b26e74248, type: 3} 12 | m_Parent: {fileID: 0} 13 | m_ModifiedSerializedProperties: 0 14 | m_ValidKeywords: 15 | - _RECEIVE_SHADOWS_OFF 16 | m_InvalidKeywords: [] 17 | m_LightmapFlags: 4 18 | m_EnableInstancingVariants: 0 19 | m_DoubleSidedGI: 0 20 | m_CustomRenderQueue: -1 21 | stringTagMap: 22 | RenderType: Opaque 23 | disabledShaderPasses: [] 24 | m_LockedProperties: 25 | m_SavedProperties: 26 | serializedVersion: 3 27 | m_TexEnvs: 28 | - _BaseMap: 29 | m_Texture: {fileID: 0} 30 | m_Scale: {x: 1, y: 1} 31 | m_Offset: {x: 0, y: 0} 32 | - _BumpMap: 33 | m_Texture: {fileID: 0} 34 | m_Scale: {x: 1, y: 1} 35 | m_Offset: {x: 0, y: 0} 36 | - _DetailAlbedoMap: 37 | m_Texture: {fileID: 0} 38 | m_Scale: {x: 1, y: 1} 39 | m_Offset: {x: 0, y: 0} 40 | - _DetailMask: 41 | m_Texture: {fileID: 0} 42 | m_Scale: {x: 1, y: 1} 43 | m_Offset: {x: 0, y: 0} 44 | - _DetailNormalMap: 45 | m_Texture: {fileID: 0} 46 | m_Scale: {x: 1, y: 1} 47 | m_Offset: {x: 0, y: 0} 48 | - _EmissionMap: 49 | m_Texture: {fileID: 0} 50 | m_Scale: {x: 1, y: 1} 51 | m_Offset: {x: 0, y: 0} 52 | - _MainTex: 53 | m_Texture: {fileID: 0} 54 | m_Scale: {x: 1, y: 1} 55 | m_Offset: {x: 0, y: 0} 56 | - _MetallicGlossMap: 57 | m_Texture: {fileID: 0} 58 | m_Scale: {x: 1, y: 1} 59 | m_Offset: {x: 0, y: 0} 60 | - _OcclusionMap: 61 | m_Texture: {fileID: 0} 62 | m_Scale: {x: 1, y: 1} 63 | m_Offset: {x: 0, y: 0} 64 | - _ParallaxMap: 65 | m_Texture: {fileID: 0} 66 | m_Scale: {x: 1, y: 1} 67 | m_Offset: {x: 0, y: 0} 68 | - _SpecGlossMap: 69 | m_Texture: {fileID: 0} 70 | m_Scale: {x: 1, y: 1} 71 | m_Offset: {x: 0, y: 0} 72 | - unity_Lightmaps: 73 | m_Texture: {fileID: 0} 74 | m_Scale: {x: 1, y: 1} 75 | m_Offset: {x: 0, y: 0} 76 | - unity_LightmapsInd: 77 | m_Texture: {fileID: 0} 78 | m_Scale: {x: 1, y: 1} 79 | m_Offset: {x: 0, y: 0} 80 | - unity_ShadowMasks: 81 | m_Texture: {fileID: 0} 82 | m_Scale: {x: 1, y: 1} 83 | m_Offset: {x: 0, y: 0} 84 | m_Ints: [] 85 | m_Floats: 86 | - _AlphaClip: 0 87 | - _AlphaToMask: 0 88 | - _Blend: 0 89 | - _BlendModePreserveSpecular: 1 90 | - _BumpScale: 1 91 | - _ClearCoatMask: 0 92 | - _ClearCoatSmoothness: 0 93 | - _Cull: 2 94 | - _Cutoff: 0.5 95 | - _DetailAlbedoMapScale: 1 96 | - _DetailNormalMapScale: 1 97 | - _DstBlend: 0 98 | - _DstBlendAlpha: 0 99 | - _EnvironmentReflections: 1 100 | - _GlossMapScale: 0 101 | - _Glossiness: 0 102 | - _GlossinessSource: 0 103 | - _GlossyReflections: 0 104 | - _Metallic: 1 105 | - _OcclusionStrength: 1 106 | - _Parallax: 0.005 107 | - _QueueOffset: 0 108 | - _ReceiveShadows: 0 109 | - _Shininess: 0 110 | - _Smoothness: 0.5 111 | - _SmoothnessSource: 0 112 | - _SmoothnessTextureChannel: 0 113 | - _SpecSource: 0 114 | - _SpecularHighlights: 1 115 | - _SrcBlend: 1 116 | - _SrcBlendAlpha: 1 117 | - _Surface: 0 118 | - _WorkflowMode: 1 119 | - _ZWrite: 1 120 | m_Colors: 121 | - _BaseColor: {r: 0.12744822, g: 0.9056604, b: 0.055535804, a: 1} 122 | - _Color: {r: 0.12744817, g: 0.9056604, b: 0.05553578, a: 1} 123 | - _EmissionColor: {r: 1.7207952, g: 1.7207952, b: 1.7207952, a: 1} 124 | - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} 125 | m_BuildTextureStacks: [] 126 | --- !u!114 &4040715682398789201 127 | MonoBehaviour: 128 | m_ObjectHideFlags: 11 129 | m_CorrespondingSourceObject: {fileID: 0} 130 | m_PrefabInstance: {fileID: 0} 131 | m_PrefabAsset: {fileID: 0} 132 | m_GameObject: {fileID: 0} 133 | m_Enabled: 1 134 | m_EditorHideFlags: 0 135 | m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} 136 | m_Name: 137 | m_EditorClassIdentifier: 138 | version: 7 139 | -------------------------------------------------------------------------------- /Assets/Scripts/Gameplay/MainCharacterMovement.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using Unity.Mathematics; 5 | using UnityEngine; 6 | using static UnityEngine.GraphicsBuffer; 7 | 8 | public class MainCharacterMovement: MonoBehaviour 9 | { 10 | public float m_autoShootPeriod=1.5f; 11 | public float m_sinAmplitude = 8.0f; 12 | public float m_sinSpeed = 1.0f; 13 | 14 | public GameObject bulletPrefab; 15 | public GameObject shootingPoint; 16 | 17 | 18 | private float m_autoShootTimer; 19 | private Vector3 m_initPos; 20 | private float m_sinPhase; 21 | private Material m_material; 22 | private Color m_originalColor; 23 | private Camera m_mainCamera; 24 | private Vector3 m_originalCameraPos; 25 | 26 | private const float kInvincibleDuration = 3.0f; 27 | private float m_invicibleTimer; 28 | 29 | 30 | private const float kShakeDuration = 1.0f; 31 | private float m_shakePhase; 32 | private float m_shakeTimer; 33 | 34 | private void Awake() 35 | { 36 | m_initPos = transform.position; 37 | } 38 | 39 | void Start() 40 | { 41 | //Fetch the Material from the Renderer of the GameObject 42 | Renderer[] rdr = GetComponentsInChildren(); 43 | if (rdr[0] != null ) 44 | { 45 | m_material = rdr[0].material; 46 | if ( m_material != null ) 47 | m_originalColor = m_material.color; 48 | } 49 | m_mainCamera = Camera.main; 50 | m_originalCameraPos = m_mainCamera.transform.position; 51 | m_invicibleTimer = 0.0f; 52 | } 53 | 54 | 55 | void Update() 56 | { 57 | 58 | float dt = Time.deltaTime; 59 | 60 | Vector3 newPos = m_initPos; 61 | newPos.x += m_sinAmplitude * math.sin(m_sinPhase); 62 | m_sinPhase += dt * m_sinSpeed; 63 | transform.position = newPos; 64 | 65 | float derivative = math.cos(m_sinPhase); 66 | 67 | transform.rotation = Quaternion.AngleAxis(-derivative * 25.0f, Vector3.forward); 68 | 69 | if ( m_invicibleTimer > 0.0f ) 70 | { 71 | m_invicibleTimer -= dt; 72 | if (m_invicibleTimer < 0.0f) 73 | m_invicibleTimer = 0.0f; 74 | 75 | Color updatedColor = Color.Lerp(m_originalColor, Color.red, m_invicibleTimer / kInvincibleDuration); 76 | if ( m_material != null ) 77 | { 78 | m_material.color = updatedColor; 79 | } 80 | } 81 | 82 | if (m_shakeTimer > 0.0f) 83 | { 84 | m_shakeTimer -= dt; 85 | if (m_shakeTimer < 0.0f) 86 | m_shakeTimer = 0.0f; 87 | 88 | m_shakePhase += dt * 10.0f; 89 | float shakeAmplitude = (m_shakeTimer / kShakeDuration) * 0.5f; 90 | m_mainCamera.transform.position = m_originalCameraPos + new Vector3(shakeAmplitude * math.sin(m_shakePhase), shakeAmplitude * math.sin(m_shakePhase * 1.37f), shakeAmplitude * math.sin(m_shakePhase * 2.17f)); 91 | } 92 | 93 | 94 | /* 95 | float xMov = Input.GetAxisRaw("Horizontal"); 96 | float yMov = Input.GetAxisRaw("Vertical"); 97 | */ 98 | 99 | bool fire = Input.GetKeyDown(KeyCode.Space); 100 | 101 | if ( Input.touchCount == 1 ) 102 | { 103 | if (Input.touches[0].phase == TouchPhase.Began) 104 | fire = true; 105 | } 106 | 107 | if (m_autoShootPeriod > 0.0f) 108 | { 109 | m_autoShootTimer += dt; 110 | if (m_autoShootTimer >= m_autoShootPeriod) 111 | { 112 | fire = true; 113 | m_autoShootTimer = 0.0f; 114 | } 115 | } 116 | 117 | 118 | if (fire) 119 | { 120 | var bulletInstance= Instantiate(bulletPrefab,shootingPoint.transform.position,shootingPoint.transform.rotation); 121 | } 122 | } 123 | 124 | // if enemy collides the player, explode! 125 | private void OnTriggerEnter(Collider other) 126 | { 127 | if (other.gameObject.tag == "Enemy") 128 | { 129 | EnemyMovement enemy = other.gameObject.GetComponent(); 130 | if (enemy != null) 131 | { 132 | if ( m_shakeTimer <= 0.0f ) 133 | m_shakeTimer = kShakeDuration; 134 | 135 | m_invicibleTimer = kInvincibleDuration; 136 | 137 | enemy.Explode(); 138 | } 139 | Destroy(other.gameObject); 140 | } 141 | } 142 | 143 | } 144 | -------------------------------------------------------------------------------- /Assets/Prefabs/Enemy.prefab: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1 &1715771093688195641 4 | GameObject: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | serializedVersion: 6 10 | m_Component: 11 | - component: {fileID: 7653733442817906431} 12 | - component: {fileID: 3652633932094631304} 13 | - component: {fileID: 2835150331284150158} 14 | - component: {fileID: 262797624035620622} 15 | - component: {fileID: 731548360513887752} 16 | - component: {fileID: 8500961070717189020} 17 | m_Layer: 0 18 | m_Name: Enemy 19 | m_TagString: Enemy 20 | m_Icon: {fileID: 0} 21 | m_NavMeshLayer: 0 22 | m_StaticEditorFlags: 0 23 | m_IsActive: 1 24 | --- !u!4 &7653733442817906431 25 | Transform: 26 | m_ObjectHideFlags: 0 27 | m_CorrespondingSourceObject: {fileID: 0} 28 | m_PrefabInstance: {fileID: 0} 29 | m_PrefabAsset: {fileID: 0} 30 | m_GameObject: {fileID: 1715771093688195641} 31 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 32 | m_LocalPosition: {x: -1.04, y: 1.91, z: 27.479} 33 | m_LocalScale: {x: 1.221, y: 1.221, z: 1.221} 34 | m_ConstrainProportionsScale: 0 35 | m_Children: [] 36 | m_Father: {fileID: 0} 37 | m_RootOrder: 0 38 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 39 | --- !u!33 &3652633932094631304 40 | MeshFilter: 41 | m_ObjectHideFlags: 0 42 | m_CorrespondingSourceObject: {fileID: 0} 43 | m_PrefabInstance: {fileID: 0} 44 | m_PrefabAsset: {fileID: 0} 45 | m_GameObject: {fileID: 1715771093688195641} 46 | m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} 47 | --- !u!23 &2835150331284150158 48 | MeshRenderer: 49 | m_ObjectHideFlags: 0 50 | m_CorrespondingSourceObject: {fileID: 0} 51 | m_PrefabInstance: {fileID: 0} 52 | m_PrefabAsset: {fileID: 0} 53 | m_GameObject: {fileID: 1715771093688195641} 54 | m_Enabled: 1 55 | m_CastShadows: 1 56 | m_ReceiveShadows: 1 57 | m_DynamicOccludee: 1 58 | m_StaticShadowCaster: 0 59 | m_MotionVectors: 1 60 | m_LightProbeUsage: 1 61 | m_ReflectionProbeUsage: 1 62 | m_RayTracingMode: 2 63 | m_RayTraceProcedural: 0 64 | m_RenderingLayerMask: 1 65 | m_RendererPriority: 0 66 | m_Materials: 67 | - {fileID: 2100000, guid: 0d9631960905a0b4091d0287b1d097b8, type: 2} 68 | m_StaticBatchInfo: 69 | firstSubMesh: 0 70 | subMeshCount: 0 71 | m_StaticBatchRoot: {fileID: 0} 72 | m_ProbeAnchor: {fileID: 0} 73 | m_LightProbeVolumeOverride: {fileID: 0} 74 | m_ScaleInLightmap: 1 75 | m_ReceiveGI: 1 76 | m_PreserveUVs: 0 77 | m_IgnoreNormalsForChartDetection: 0 78 | m_ImportantGI: 0 79 | m_StitchLightmapSeams: 1 80 | m_SelectedEditorRenderState: 3 81 | m_MinimumChartSize: 4 82 | m_AutoUVMaxDistance: 0.5 83 | m_AutoUVMaxAngle: 89 84 | m_LightmapParameters: {fileID: 0} 85 | m_SortingLayerID: 0 86 | m_SortingLayer: 0 87 | m_SortingOrder: 0 88 | m_AdditionalVertexStreams: {fileID: 0} 89 | --- !u!114 &262797624035620622 90 | MonoBehaviour: 91 | m_ObjectHideFlags: 0 92 | m_CorrespondingSourceObject: {fileID: 0} 93 | m_PrefabInstance: {fileID: 0} 94 | m_PrefabAsset: {fileID: 0} 95 | m_GameObject: {fileID: 1715771093688195641} 96 | m_Enabled: 1 97 | m_EditorHideFlags: 0 98 | m_Script: {fileID: 11500000, guid: b825dedc6d9b3984db3e243a63276ee5, type: 3} 99 | m_Name: 100 | m_EditorClassIdentifier: 101 | m_rndHueColor: 0 102 | --- !u!135 &731548360513887752 103 | SphereCollider: 104 | m_ObjectHideFlags: 0 105 | m_CorrespondingSourceObject: {fileID: 0} 106 | m_PrefabInstance: {fileID: 0} 107 | m_PrefabAsset: {fileID: 0} 108 | m_GameObject: {fileID: 1715771093688195641} 109 | m_Material: {fileID: 0} 110 | m_IncludeLayers: 111 | serializedVersion: 2 112 | m_Bits: 0 113 | m_ExcludeLayers: 114 | serializedVersion: 2 115 | m_Bits: 0 116 | m_LayerOverridePriority: 0 117 | m_IsTrigger: 1 118 | m_ProvidesContacts: 0 119 | m_Enabled: 1 120 | serializedVersion: 3 121 | m_Radius: 0.6 122 | m_Center: {x: 0, y: 0, z: 0} 123 | --- !u!54 &8500961070717189020 124 | Rigidbody: 125 | m_ObjectHideFlags: 0 126 | m_CorrespondingSourceObject: {fileID: 0} 127 | m_PrefabInstance: {fileID: 0} 128 | m_PrefabAsset: {fileID: 0} 129 | m_GameObject: {fileID: 1715771093688195641} 130 | serializedVersion: 4 131 | m_Mass: 1 132 | m_Drag: 0 133 | m_AngularDrag: 0.05 134 | m_CenterOfMass: {x: 0, y: 0, z: 0} 135 | m_InertiaTensor: {x: 1, y: 1, z: 1} 136 | m_InertiaRotation: {x: 0, y: 0, z: 0, w: 1} 137 | m_IncludeLayers: 138 | serializedVersion: 2 139 | m_Bits: 0 140 | m_ExcludeLayers: 141 | serializedVersion: 2 142 | m_Bits: 0 143 | m_ImplicitCom: 1 144 | m_ImplicitTensor: 1 145 | m_UseGravity: 0 146 | m_IsKinematic: 1 147 | m_Interpolate: 0 148 | m_Constraints: 0 149 | m_CollisionDetection: 0 150 | -------------------------------------------------------------------------------- /Assets/Presets/AudioStreaming.preset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!181963792 &2655988077585873504 4 | Preset: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_Name: AudioStreaming 9 | m_TargetType: 10 | m_NativeTypeID: 1020 11 | m_ManagedTypePPtr: {fileID: 0} 12 | m_ManagedTypeFallback: 13 | m_Properties: 14 | - target: {fileID: 0} 15 | propertyPath: m_ExternalObjects.Array.size 16 | value: 0 17 | objectReference: {fileID: 0} 18 | - target: {fileID: 0} 19 | propertyPath: m_DefaultSettings.loadType 20 | value: 2 21 | objectReference: {fileID: 0} 22 | - target: {fileID: 0} 23 | propertyPath: m_DefaultSettings.sampleRateSetting 24 | value: 0 25 | objectReference: {fileID: 0} 26 | - target: {fileID: 0} 27 | propertyPath: m_DefaultSettings.sampleRateOverride 28 | value: 44100 29 | objectReference: {fileID: 0} 30 | - target: {fileID: 0} 31 | propertyPath: m_DefaultSettings.compressionFormat 32 | value: 1 33 | objectReference: {fileID: 0} 34 | - target: {fileID: 0} 35 | propertyPath: m_DefaultSettings.quality 36 | value: 0.7 37 | objectReference: {fileID: 0} 38 | - target: {fileID: 0} 39 | propertyPath: m_DefaultSettings.conversionMode 40 | value: 0 41 | objectReference: {fileID: 0} 42 | - target: {fileID: 0} 43 | propertyPath: m_PlatformSettingOverrides.Array.size 44 | value: 2 45 | objectReference: {fileID: 0} 46 | - target: {fileID: 0} 47 | propertyPath: m_PlatformSettingOverrides.Array.data[0].first 48 | value: 4 49 | objectReference: {fileID: 0} 50 | - target: {fileID: 0} 51 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.loadType 52 | value: 2 53 | objectReference: {fileID: 0} 54 | - target: {fileID: 0} 55 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.sampleRateSetting 56 | value: 0 57 | objectReference: {fileID: 0} 58 | - target: {fileID: 0} 59 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.sampleRateOverride 60 | value: 44100 61 | objectReference: {fileID: 0} 62 | - target: {fileID: 0} 63 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.compressionFormat 64 | value: 3 65 | objectReference: {fileID: 0} 66 | - target: {fileID: 0} 67 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.quality 68 | value: 0.7 69 | objectReference: {fileID: 0} 70 | - target: {fileID: 0} 71 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.conversionMode 72 | value: 0 73 | objectReference: {fileID: 0} 74 | - target: {fileID: 0} 75 | propertyPath: m_PlatformSettingOverrides.Array.data[1].first 76 | value: 7 77 | objectReference: {fileID: 0} 78 | - target: {fileID: 0} 79 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.loadType 80 | value: 2 81 | objectReference: {fileID: 0} 82 | - target: {fileID: 0} 83 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.sampleRateSetting 84 | value: 0 85 | objectReference: {fileID: 0} 86 | - target: {fileID: 0} 87 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.sampleRateOverride 88 | value: 44100 89 | objectReference: {fileID: 0} 90 | - target: {fileID: 0} 91 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.compressionFormat 92 | value: 1 93 | objectReference: {fileID: 0} 94 | - target: {fileID: 0} 95 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.quality 96 | value: 0.7 97 | objectReference: {fileID: 0} 98 | - target: {fileID: 0} 99 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.conversionMode 100 | value: 0 101 | objectReference: {fileID: 0} 102 | - target: {fileID: 0} 103 | propertyPath: m_ForceToMono 104 | value: 0 105 | objectReference: {fileID: 0} 106 | - target: {fileID: 0} 107 | propertyPath: m_Normalize 108 | value: 1 109 | objectReference: {fileID: 0} 110 | - target: {fileID: 0} 111 | propertyPath: m_PreloadAudioData 112 | value: 1 113 | objectReference: {fileID: 0} 114 | - target: {fileID: 0} 115 | propertyPath: m_LoadInBackground 116 | value: 0 117 | objectReference: {fileID: 0} 118 | - target: {fileID: 0} 119 | propertyPath: m_Ambisonic 120 | value: 0 121 | objectReference: {fileID: 0} 122 | - target: {fileID: 0} 123 | propertyPath: m_3D 124 | value: 1 125 | objectReference: {fileID: 0} 126 | - target: {fileID: 0} 127 | propertyPath: m_UserData 128 | value: 129 | objectReference: {fileID: 0} 130 | - target: {fileID: 0} 131 | propertyPath: m_AssetBundleName 132 | value: 133 | objectReference: {fileID: 0} 134 | - target: {fileID: 0} 135 | propertyPath: m_AssetBundleVariant 136 | value: 137 | objectReference: {fileID: 0} 138 | -------------------------------------------------------------------------------- /Assets/Presets/AudioCompressedInMemory.preset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!181963792 &2655988077585873504 4 | Preset: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_Name: AudioCompressedInMemory 9 | m_TargetType: 10 | m_NativeTypeID: 1020 11 | m_ManagedTypePPtr: {fileID: 0} 12 | m_ManagedTypeFallback: 13 | m_Properties: 14 | - target: {fileID: 0} 15 | propertyPath: m_ExternalObjects.Array.size 16 | value: 0 17 | objectReference: {fileID: 0} 18 | - target: {fileID: 0} 19 | propertyPath: m_DefaultSettings.loadType 20 | value: 1 21 | objectReference: {fileID: 0} 22 | - target: {fileID: 0} 23 | propertyPath: m_DefaultSettings.sampleRateSetting 24 | value: 0 25 | objectReference: {fileID: 0} 26 | - target: {fileID: 0} 27 | propertyPath: m_DefaultSettings.sampleRateOverride 28 | value: 44100 29 | objectReference: {fileID: 0} 30 | - target: {fileID: 0} 31 | propertyPath: m_DefaultSettings.compressionFormat 32 | value: 2 33 | objectReference: {fileID: 0} 34 | - target: {fileID: 0} 35 | propertyPath: m_DefaultSettings.quality 36 | value: 0.7 37 | objectReference: {fileID: 0} 38 | - target: {fileID: 0} 39 | propertyPath: m_DefaultSettings.conversionMode 40 | value: 0 41 | objectReference: {fileID: 0} 42 | - target: {fileID: 0} 43 | propertyPath: m_PlatformSettingOverrides.Array.size 44 | value: 2 45 | objectReference: {fileID: 0} 46 | - target: {fileID: 0} 47 | propertyPath: m_PlatformSettingOverrides.Array.data[0].first 48 | value: 4 49 | objectReference: {fileID: 0} 50 | - target: {fileID: 0} 51 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.loadType 52 | value: 1 53 | objectReference: {fileID: 0} 54 | - target: {fileID: 0} 55 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.sampleRateSetting 56 | value: 0 57 | objectReference: {fileID: 0} 58 | - target: {fileID: 0} 59 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.sampleRateOverride 60 | value: 44100 61 | objectReference: {fileID: 0} 62 | - target: {fileID: 0} 63 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.compressionFormat 64 | value: 3 65 | objectReference: {fileID: 0} 66 | - target: {fileID: 0} 67 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.quality 68 | value: 0.7 69 | objectReference: {fileID: 0} 70 | - target: {fileID: 0} 71 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.conversionMode 72 | value: 0 73 | objectReference: {fileID: 0} 74 | - target: {fileID: 0} 75 | propertyPath: m_PlatformSettingOverrides.Array.data[1].first 76 | value: 7 77 | objectReference: {fileID: 0} 78 | - target: {fileID: 0} 79 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.loadType 80 | value: 1 81 | objectReference: {fileID: 0} 82 | - target: {fileID: 0} 83 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.sampleRateSetting 84 | value: 0 85 | objectReference: {fileID: 0} 86 | - target: {fileID: 0} 87 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.sampleRateOverride 88 | value: 44100 89 | objectReference: {fileID: 0} 90 | - target: {fileID: 0} 91 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.compressionFormat 92 | value: 1 93 | objectReference: {fileID: 0} 94 | - target: {fileID: 0} 95 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.quality 96 | value: 0.7 97 | objectReference: {fileID: 0} 98 | - target: {fileID: 0} 99 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.conversionMode 100 | value: 0 101 | objectReference: {fileID: 0} 102 | - target: {fileID: 0} 103 | propertyPath: m_ForceToMono 104 | value: 0 105 | objectReference: {fileID: 0} 106 | - target: {fileID: 0} 107 | propertyPath: m_Normalize 108 | value: 1 109 | objectReference: {fileID: 0} 110 | - target: {fileID: 0} 111 | propertyPath: m_PreloadAudioData 112 | value: 1 113 | objectReference: {fileID: 0} 114 | - target: {fileID: 0} 115 | propertyPath: m_LoadInBackground 116 | value: 0 117 | objectReference: {fileID: 0} 118 | - target: {fileID: 0} 119 | propertyPath: m_Ambisonic 120 | value: 0 121 | objectReference: {fileID: 0} 122 | - target: {fileID: 0} 123 | propertyPath: m_3D 124 | value: 1 125 | objectReference: {fileID: 0} 126 | - target: {fileID: 0} 127 | propertyPath: m_UserData 128 | value: 129 | objectReference: {fileID: 0} 130 | - target: {fileID: 0} 131 | propertyPath: m_AssetBundleName 132 | value: 133 | objectReference: {fileID: 0} 134 | - target: {fileID: 0} 135 | propertyPath: m_AssetBundleVariant 136 | value: 137 | objectReference: {fileID: 0} 138 | -------------------------------------------------------------------------------- /Assets/Presets/Defaults/AudioDecompressOnLoad.preset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!181963792 &2655988077585873504 4 | Preset: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInternal: {fileID: 0} 8 | m_Name: AudioDecompressOnLoad 9 | m_TargetType: 10 | m_NativeTypeID: 1020 11 | m_ManagedTypePPtr: {fileID: 0} 12 | m_ManagedTypeFallback: 13 | m_Properties: 14 | - target: {fileID: 0} 15 | propertyPath: m_ExternalObjects.Array.size 16 | value: 0 17 | objectReference: {fileID: 0} 18 | - target: {fileID: 0} 19 | propertyPath: m_DefaultSettings.loadType 20 | value: 0 21 | objectReference: {fileID: 0} 22 | - target: {fileID: 0} 23 | propertyPath: m_DefaultSettings.sampleRateSetting 24 | value: 0 25 | objectReference: {fileID: 0} 26 | - target: {fileID: 0} 27 | propertyPath: m_DefaultSettings.sampleRateOverride 28 | value: 44100 29 | objectReference: {fileID: 0} 30 | - target: {fileID: 0} 31 | propertyPath: m_DefaultSettings.compressionFormat 32 | value: 0 33 | objectReference: {fileID: 0} 34 | - target: {fileID: 0} 35 | propertyPath: m_DefaultSettings.quality 36 | value: 1 37 | objectReference: {fileID: 0} 38 | - target: {fileID: 0} 39 | propertyPath: m_DefaultSettings.conversionMode 40 | value: 0 41 | objectReference: {fileID: 0} 42 | - target: {fileID: 0} 43 | propertyPath: m_PlatformSettingOverrides.Array.size 44 | value: 2 45 | objectReference: {fileID: 0} 46 | - target: {fileID: 0} 47 | propertyPath: m_PlatformSettingOverrides.Array.data[0].first 48 | value: 4 49 | objectReference: {fileID: 0} 50 | - target: {fileID: 0} 51 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.loadType 52 | value: 0 53 | objectReference: {fileID: 0} 54 | - target: {fileID: 0} 55 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.sampleRateSetting 56 | value: 0 57 | objectReference: {fileID: 0} 58 | - target: {fileID: 0} 59 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.sampleRateOverride 60 | value: 44100 61 | objectReference: {fileID: 0} 62 | - target: {fileID: 0} 63 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.compressionFormat 64 | value: 3 65 | objectReference: {fileID: 0} 66 | - target: {fileID: 0} 67 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.quality 68 | value: 1 69 | objectReference: {fileID: 0} 70 | - target: {fileID: 0} 71 | propertyPath: m_PlatformSettingOverrides.Array.data[0].second.conversionMode 72 | value: 0 73 | objectReference: {fileID: 0} 74 | - target: {fileID: 0} 75 | propertyPath: m_PlatformSettingOverrides.Array.data[1].first 76 | value: 7 77 | objectReference: {fileID: 0} 78 | - target: {fileID: 0} 79 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.loadType 80 | value: 0 81 | objectReference: {fileID: 0} 82 | - target: {fileID: 0} 83 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.sampleRateSetting 84 | value: 0 85 | objectReference: {fileID: 0} 86 | - target: {fileID: 0} 87 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.sampleRateOverride 88 | value: 44100 89 | objectReference: {fileID: 0} 90 | - target: {fileID: 0} 91 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.compressionFormat 92 | value: 1 93 | objectReference: {fileID: 0} 94 | - target: {fileID: 0} 95 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.quality 96 | value: 1 97 | objectReference: {fileID: 0} 98 | - target: {fileID: 0} 99 | propertyPath: m_PlatformSettingOverrides.Array.data[1].second.conversionMode 100 | value: 0 101 | objectReference: {fileID: 0} 102 | - target: {fileID: 0} 103 | propertyPath: m_ForceToMono 104 | value: 0 105 | objectReference: {fileID: 0} 106 | - target: {fileID: 0} 107 | propertyPath: m_Normalize 108 | value: 1 109 | objectReference: {fileID: 0} 110 | - target: {fileID: 0} 111 | propertyPath: m_PreloadAudioData 112 | value: 1 113 | objectReference: {fileID: 0} 114 | - target: {fileID: 0} 115 | propertyPath: m_LoadInBackground 116 | value: 0 117 | objectReference: {fileID: 0} 118 | - target: {fileID: 0} 119 | propertyPath: m_Ambisonic 120 | value: 0 121 | objectReference: {fileID: 0} 122 | - target: {fileID: 0} 123 | propertyPath: m_3D 124 | value: 1 125 | objectReference: {fileID: 0} 126 | - target: {fileID: 0} 127 | propertyPath: m_UserData 128 | value: 129 | objectReference: {fileID: 0} 130 | - target: {fileID: 0} 131 | propertyPath: m_AssetBundleName 132 | value: 133 | objectReference: {fileID: 0} 134 | - target: {fileID: 0} 135 | propertyPath: m_AssetBundleVariant 136 | value: 137 | objectReference: {fileID: 0} 138 | -------------------------------------------------------------------------------- /Assets/Prefabs/Bullet.prefab: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1 &169017366624862012 4 | GameObject: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | serializedVersion: 6 10 | m_Component: 11 | - component: {fileID: 2448713361782206177} 12 | - component: {fileID: -9179226117992093664} 13 | - component: {fileID: 6794409923011025843} 14 | m_Layer: 0 15 | m_Name: Bullet 16 | m_TagString: Untagged 17 | m_Icon: {fileID: 0} 18 | m_NavMeshLayer: 0 19 | m_StaticEditorFlags: 0 20 | m_IsActive: 1 21 | --- !u!4 &2448713361782206177 22 | Transform: 23 | m_ObjectHideFlags: 0 24 | m_CorrespondingSourceObject: {fileID: 0} 25 | m_PrefabInstance: {fileID: 0} 26 | m_PrefabAsset: {fileID: 0} 27 | m_GameObject: {fileID: 169017366624862012} 28 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 29 | m_LocalPosition: {x: 0, y: 0, z: 0} 30 | m_LocalScale: {x: 1, y: 1, z: 1} 31 | m_ConstrainProportionsScale: 0 32 | m_Children: 33 | - {fileID: 3561078156930224241} 34 | m_Father: {fileID: 0} 35 | m_RootOrder: 0 36 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 37 | --- !u!114 &-9179226117992093664 38 | MonoBehaviour: 39 | m_ObjectHideFlags: 0 40 | m_CorrespondingSourceObject: {fileID: 0} 41 | m_PrefabInstance: {fileID: 0} 42 | m_PrefabAsset: {fileID: 0} 43 | m_GameObject: {fileID: 169017366624862012} 44 | m_Enabled: 1 45 | m_EditorHideFlags: 0 46 | m_Script: {fileID: 11500000, guid: bd68be9d714d1f84e880c24fb8e12ffb, type: 3} 47 | m_Name: 48 | m_EditorClassIdentifier: 49 | --- !u!65 &6794409923011025843 50 | BoxCollider: 51 | m_ObjectHideFlags: 0 52 | m_CorrespondingSourceObject: {fileID: 0} 53 | m_PrefabInstance: {fileID: 0} 54 | m_PrefabAsset: {fileID: 0} 55 | m_GameObject: {fileID: 169017366624862012} 56 | m_Material: {fileID: 0} 57 | m_IncludeLayers: 58 | serializedVersion: 2 59 | m_Bits: 4294967295 60 | m_ExcludeLayers: 61 | serializedVersion: 2 62 | m_Bits: 0 63 | m_LayerOverridePriority: 0 64 | m_IsTrigger: 1 65 | m_ProvidesContacts: 0 66 | m_Enabled: 1 67 | serializedVersion: 3 68 | m_Size: {x: 0.26, y: 0.27, z: 1.99} 69 | m_Center: {x: 0, y: 0, z: 0} 70 | --- !u!1 &8976677098820278273 71 | GameObject: 72 | m_ObjectHideFlags: 0 73 | m_CorrespondingSourceObject: {fileID: 0} 74 | m_PrefabInstance: {fileID: 0} 75 | m_PrefabAsset: {fileID: 0} 76 | serializedVersion: 6 77 | m_Component: 78 | - component: {fileID: 3561078156930224241} 79 | - component: {fileID: 8976677098820278278} 80 | - component: {fileID: 8976677098820278279} 81 | m_Layer: 0 82 | m_Name: Cylinder 83 | m_TagString: Untagged 84 | m_Icon: {fileID: 0} 85 | m_NavMeshLayer: 0 86 | m_StaticEditorFlags: 0 87 | m_IsActive: 1 88 | --- !u!4 &3561078156930224241 89 | Transform: 90 | m_ObjectHideFlags: 0 91 | m_CorrespondingSourceObject: {fileID: 0} 92 | m_PrefabInstance: {fileID: 0} 93 | m_PrefabAsset: {fileID: 0} 94 | m_GameObject: {fileID: 8976677098820278273} 95 | m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} 96 | m_LocalPosition: {x: 0, y: 0, z: 0} 97 | m_LocalScale: {x: 0.3, y: 1, z: 0.3} 98 | m_ConstrainProportionsScale: 0 99 | m_Children: [] 100 | m_Father: {fileID: 2448713361782206177} 101 | m_RootOrder: -1 102 | m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} 103 | --- !u!33 &8976677098820278278 104 | MeshFilter: 105 | m_ObjectHideFlags: 0 106 | m_CorrespondingSourceObject: {fileID: 0} 107 | m_PrefabInstance: {fileID: 0} 108 | m_PrefabAsset: {fileID: 0} 109 | m_GameObject: {fileID: 8976677098820278273} 110 | m_Mesh: {fileID: 10206, guid: 0000000000000000e000000000000000, type: 0} 111 | --- !u!23 &8976677098820278279 112 | MeshRenderer: 113 | m_ObjectHideFlags: 0 114 | m_CorrespondingSourceObject: {fileID: 0} 115 | m_PrefabInstance: {fileID: 0} 116 | m_PrefabAsset: {fileID: 0} 117 | m_GameObject: {fileID: 8976677098820278273} 118 | m_Enabled: 1 119 | m_CastShadows: 1 120 | m_ReceiveShadows: 1 121 | m_DynamicOccludee: 1 122 | m_StaticShadowCaster: 0 123 | m_MotionVectors: 1 124 | m_LightProbeUsage: 1 125 | m_ReflectionProbeUsage: 1 126 | m_RayTracingMode: 2 127 | m_RayTraceProcedural: 0 128 | m_RenderingLayerMask: 1 129 | m_RendererPriority: 0 130 | m_Materials: 131 | - {fileID: 2100000, guid: 9d51b65aa0935484598903b7c9363ec9, type: 2} 132 | m_StaticBatchInfo: 133 | firstSubMesh: 0 134 | subMeshCount: 0 135 | m_StaticBatchRoot: {fileID: 0} 136 | m_ProbeAnchor: {fileID: 0} 137 | m_LightProbeVolumeOverride: {fileID: 0} 138 | m_ScaleInLightmap: 1 139 | m_ReceiveGI: 1 140 | m_PreserveUVs: 0 141 | m_IgnoreNormalsForChartDetection: 0 142 | m_ImportantGI: 0 143 | m_StitchLightmapSeams: 1 144 | m_SelectedEditorRenderState: 3 145 | m_MinimumChartSize: 4 146 | m_AutoUVMaxDistance: 0.5 147 | m_AutoUVMaxAngle: 89 148 | m_LightmapParameters: {fileID: 0} 149 | m_SortingLayerID: 0 150 | m_SortingLayer: 0 151 | m_SortingOrder: 0 152 | m_AdditionalVertexStreams: {fileID: 0} 153 | -------------------------------------------------------------------------------- /Assets/SampleInfo/Scripts/Editor/ReadmeEditor.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | using UnityEditor; 5 | using System; 6 | using System.IO; 7 | using System.Reflection; 8 | 9 | [CustomEditor(typeof(Readme))] 10 | [InitializeOnLoad] 11 | public class ReadmeEditor : Editor 12 | { 13 | static string kShowedReadmeSessionStateName = "ReadmeEditor.showedReadme"; 14 | 15 | static float kSpace = 16f; 16 | 17 | static ReadmeEditor() 18 | { 19 | EditorApplication.delayCall += SelectReadmeAutomatically; 20 | } 21 | 22 | static void SelectReadmeAutomatically() 23 | { 24 | if (!SessionState.GetBool(kShowedReadmeSessionStateName, false)) 25 | { 26 | var readme = SelectReadme(); 27 | SessionState.SetBool(kShowedReadmeSessionStateName, true); 28 | 29 | if (readme && !readme.loadedLayout) 30 | { 31 | LoadLayout(); 32 | readme.loadedLayout = true; 33 | } 34 | } 35 | } 36 | 37 | static void LoadLayout() 38 | { 39 | var assembly = typeof(EditorApplication).Assembly; 40 | var windowLayoutType = assembly.GetType("UnityEditor.WindowLayout", true); 41 | var method = windowLayoutType.GetMethod("LoadWindowLayout", BindingFlags.Public | BindingFlags.Static); 42 | method.Invoke(null, new object[] { Path.Combine(Application.dataPath, "TutorialInfo/Layout.wlt"), false }); 43 | } 44 | 45 | [MenuItem("Tutorial/Show Tutorial Instructions")] 46 | static Readme SelectReadme() 47 | { 48 | var ids = AssetDatabase.FindAssets("Readme t:Readme"); 49 | if (ids.Length == 1) 50 | { 51 | var readmeObject = AssetDatabase.LoadMainAssetAtPath(AssetDatabase.GUIDToAssetPath(ids[0])); 52 | 53 | Selection.objects = new UnityEngine.Object[] { readmeObject }; 54 | 55 | return (Readme)readmeObject; 56 | } 57 | else 58 | { 59 | Debug.Log("Couldn't find a readme"); 60 | return null; 61 | } 62 | } 63 | 64 | protected override void OnHeaderGUI() 65 | { 66 | var readme = (Readme)target; 67 | Init(); 68 | 69 | var iconWidth = Mathf.Min(EditorGUIUtility.currentViewWidth / 3f - 20f, 128f); 70 | 71 | GUILayout.BeginHorizontal("In BigTitle"); 72 | { 73 | GUILayout.Label(readme.icon, GUILayout.Width(iconWidth), GUILayout.Height(iconWidth)); 74 | GUILayout.Label(readme.title, TitleStyle); 75 | } 76 | GUILayout.EndHorizontal(); 77 | } 78 | 79 | public override void OnInspectorGUI() 80 | { 81 | var readme = (Readme)target; 82 | Init(); 83 | 84 | foreach (var section in readme.sections) 85 | { 86 | if (!string.IsNullOrEmpty(section.heading)) 87 | { 88 | GUILayout.Label(section.heading, HeadingStyle); 89 | } 90 | if (!string.IsNullOrEmpty(section.text)) 91 | { 92 | GUILayout.Label(section.text, BodyStyle); 93 | } 94 | if (!string.IsNullOrEmpty(section.linkText)) 95 | { 96 | if (LinkLabel(new GUIContent(section.linkText))) 97 | { 98 | Application.OpenURL(section.url); 99 | } 100 | } 101 | GUILayout.Space(kSpace); 102 | } 103 | } 104 | 105 | bool m_Initialized; 106 | 107 | GUIStyle LinkStyle { get { return m_LinkStyle; } } 108 | [SerializeField] GUIStyle m_LinkStyle; 109 | 110 | GUIStyle TitleStyle { get { return m_TitleStyle; } } 111 | [SerializeField] GUIStyle m_TitleStyle; 112 | 113 | GUIStyle HeadingStyle { get { return m_HeadingStyle; } } 114 | [SerializeField] GUIStyle m_HeadingStyle; 115 | 116 | GUIStyle BodyStyle { get { return m_BodyStyle; } } 117 | [SerializeField] GUIStyle m_BodyStyle; 118 | 119 | void Init() 120 | { 121 | if (m_Initialized) 122 | return; 123 | m_BodyStyle = new GUIStyle(EditorStyles.label); 124 | m_BodyStyle.wordWrap = true; 125 | m_BodyStyle.fontSize = 14; 126 | 127 | m_TitleStyle = new GUIStyle(m_BodyStyle); 128 | m_TitleStyle.fontSize = 26; 129 | 130 | m_HeadingStyle = new GUIStyle(m_BodyStyle); 131 | m_HeadingStyle.fontSize = 18; 132 | 133 | m_LinkStyle = new GUIStyle(m_BodyStyle); 134 | m_LinkStyle.wordWrap = false; 135 | // Match selection color which works nicely for both light and dark skins 136 | m_LinkStyle.normal.textColor = new Color(0x00 / 255f, 0x78 / 255f, 0xDA / 255f, 1f); 137 | m_LinkStyle.stretchWidth = false; 138 | 139 | m_Initialized = true; 140 | } 141 | 142 | bool LinkLabel(GUIContent label, params GUILayoutOption[] options) 143 | { 144 | var position = GUILayoutUtility.GetRect(label, LinkStyle, options); 145 | 146 | Handles.BeginGUI(); 147 | Handles.color = LinkStyle.normal.textColor; 148 | Handles.DrawLine(new Vector3(position.xMin, position.yMax), new Vector3(position.xMax, position.yMax)); 149 | Handles.color = Color.white; 150 | Handles.EndGUI(); 151 | 152 | EditorGUIUtility.AddCursorRect(position, MouseCursor.Link); 153 | 154 | return GUI.Button(position, label, LinkStyle); 155 | } 156 | } 157 | -------------------------------------------------------------------------------- /ProjectSettings/QualitySettings.asset: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!47 &1 4 | QualitySettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 5 7 | m_CurrentQuality: 1 8 | m_QualitySettings: 9 | - serializedVersion: 3 10 | name: Low 11 | pixelLightCount: 0 12 | shadows: 0 13 | shadowResolution: 0 14 | shadowProjection: 1 15 | shadowCascades: 1 16 | shadowDistance: 20 17 | shadowNearPlaneOffset: 3 18 | shadowCascade2Split: 0.33333334 19 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 20 | shadowmaskMode: 0 21 | skinWeights: 4 22 | globalTextureMipmapLimit: 0 23 | textureMipmapLimitSettings: [] 24 | anisotropicTextures: 0 25 | antiAliasing: 0 26 | softParticles: 0 27 | softVegetation: 0 28 | realtimeReflectionProbes: 0 29 | billboardsFaceCameraPosition: 0 30 | useLegacyDetailDistribution: 1 31 | vSyncCount: 0 32 | lodBias: 0.4 33 | maximumLODLevel: 0 34 | enableLODCrossFade: 1 35 | streamingMipmapsActive: 0 36 | streamingMipmapsAddAllCameras: 1 37 | streamingMipmapsMemoryBudget: 512 38 | streamingMipmapsRenderersPerFrame: 512 39 | streamingMipmapsMaxLevelReduction: 2 40 | streamingMipmapsMaxFileIORequests: 1024 41 | particleRaycastBudget: 16 42 | asyncUploadTimeSlice: 2 43 | asyncUploadBufferSize: 16 44 | asyncUploadPersistentBuffer: 1 45 | resolutionScalingFixedDPIFactor: 1 46 | customRenderPipeline: {fileID: 11400000, guid: a31e9f9f9c9d4b9429ed0d1234e22103, type: 2} 47 | terrainQualityOverrides: 0 48 | terrainPixelError: 1 49 | terrainDetailDensityScale: 1 50 | terrainBasemapDistance: 1000 51 | terrainDetailDistance: 80 52 | terrainTreeDistance: 5000 53 | terrainBillboardStart: 50 54 | terrainFadeLength: 5 55 | terrainMaxTrees: 50 56 | excludedTargetPlatforms: [] 57 | - serializedVersion: 3 58 | name: Medium 59 | pixelLightCount: 1 60 | shadows: 1 61 | shadowResolution: 0 62 | shadowProjection: 1 63 | shadowCascades: 1 64 | shadowDistance: 20 65 | shadowNearPlaneOffset: 3 66 | shadowCascade2Split: 0.33333334 67 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 68 | shadowmaskMode: 0 69 | skinWeights: 4 70 | globalTextureMipmapLimit: 0 71 | textureMipmapLimitSettings: [] 72 | anisotropicTextures: 1 73 | antiAliasing: 0 74 | softParticles: 0 75 | softVegetation: 0 76 | realtimeReflectionProbes: 0 77 | billboardsFaceCameraPosition: 0 78 | useLegacyDetailDistribution: 1 79 | vSyncCount: 1 80 | lodBias: 0.7 81 | maximumLODLevel: 0 82 | enableLODCrossFade: 1 83 | streamingMipmapsActive: 0 84 | streamingMipmapsAddAllCameras: 1 85 | streamingMipmapsMemoryBudget: 512 86 | streamingMipmapsRenderersPerFrame: 512 87 | streamingMipmapsMaxLevelReduction: 2 88 | streamingMipmapsMaxFileIORequests: 1024 89 | particleRaycastBudget: 64 90 | asyncUploadTimeSlice: 2 91 | asyncUploadBufferSize: 16 92 | asyncUploadPersistentBuffer: 1 93 | resolutionScalingFixedDPIFactor: 1 94 | customRenderPipeline: {fileID: 11400000, guid: d847b876476d3d6468f5dfcd34266f96, type: 2} 95 | terrainQualityOverrides: 0 96 | terrainPixelError: 1 97 | terrainDetailDensityScale: 1 98 | terrainBasemapDistance: 1000 99 | terrainDetailDistance: 80 100 | terrainTreeDistance: 5000 101 | terrainBillboardStart: 50 102 | terrainFadeLength: 5 103 | terrainMaxTrees: 50 104 | excludedTargetPlatforms: [] 105 | - serializedVersion: 3 106 | name: High 107 | pixelLightCount: 2 108 | shadows: 2 109 | shadowResolution: 1 110 | shadowProjection: 1 111 | shadowCascades: 2 112 | shadowDistance: 40 113 | shadowNearPlaneOffset: 3 114 | shadowCascade2Split: 0.33333334 115 | shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667} 116 | shadowmaskMode: 1 117 | skinWeights: 255 118 | globalTextureMipmapLimit: 0 119 | textureMipmapLimitSettings: [] 120 | anisotropicTextures: 1 121 | antiAliasing: 2 122 | softParticles: 0 123 | softVegetation: 1 124 | realtimeReflectionProbes: 1 125 | billboardsFaceCameraPosition: 1 126 | useLegacyDetailDistribution: 1 127 | vSyncCount: 1 128 | lodBias: 1 129 | maximumLODLevel: 0 130 | enableLODCrossFade: 1 131 | streamingMipmapsActive: 0 132 | streamingMipmapsAddAllCameras: 1 133 | streamingMipmapsMemoryBudget: 512 134 | streamingMipmapsRenderersPerFrame: 512 135 | streamingMipmapsMaxLevelReduction: 2 136 | streamingMipmapsMaxFileIORequests: 1024 137 | particleRaycastBudget: 256 138 | asyncUploadTimeSlice: 2 139 | asyncUploadBufferSize: 16 140 | asyncUploadPersistentBuffer: 1 141 | resolutionScalingFixedDPIFactor: 1 142 | customRenderPipeline: {fileID: 11400000, guid: 19ba41d7c0026c3459d37c2fe90c55a0, type: 2} 143 | terrainQualityOverrides: 0 144 | terrainPixelError: 1 145 | terrainDetailDensityScale: 1 146 | terrainBasemapDistance: 1000 147 | terrainDetailDistance: 80 148 | terrainTreeDistance: 5000 149 | terrainBillboardStart: 50 150 | terrainFadeLength: 5 151 | terrainMaxTrees: 50 152 | excludedTargetPlatforms: [] 153 | m_TextureMipmapLimitGroupNames: [] 154 | m_PerPlatformDefaultQuality: 155 | Android: 1 156 | GameCoreScarlett: 2 157 | GameCoreXboxOne: 2 158 | Lumin: 2 159 | Nintendo Switch: 2 160 | PS4: 2 161 | PS5: 2 162 | Server: 0 163 | Stadia: 2 164 | Standalone: 2 165 | WebGL: 1 166 | Windows Store Apps: 2 167 | XboxOne: 2 168 | iPhone: 1 169 | tvOS: 1 170 | -------------------------------------------------------------------------------- /ProjectSettings/SceneTemplateSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "templatePinStates": [], 3 | "dependencyTypeInfos": [ 4 | { 5 | "userAdded": false, 6 | "type": "UnityEngine.AnimationClip", 7 | "ignore": false, 8 | "defaultInstantiationMode": 0, 9 | "supportsModification": true 10 | }, 11 | { 12 | "userAdded": false, 13 | "type": "UnityEditor.Animations.AnimatorController", 14 | "ignore": false, 15 | "defaultInstantiationMode": 0, 16 | "supportsModification": true 17 | }, 18 | { 19 | "userAdded": false, 20 | "type": "UnityEngine.AnimatorOverrideController", 21 | "ignore": false, 22 | "defaultInstantiationMode": 0, 23 | "supportsModification": true 24 | }, 25 | { 26 | "userAdded": false, 27 | "type": "UnityEditor.Audio.AudioMixerController", 28 | "ignore": false, 29 | "defaultInstantiationMode": 0, 30 | "supportsModification": true 31 | }, 32 | { 33 | "userAdded": false, 34 | "type": "UnityEngine.ComputeShader", 35 | "ignore": true, 36 | "defaultInstantiationMode": 1, 37 | "supportsModification": true 38 | }, 39 | { 40 | "userAdded": false, 41 | "type": "UnityEngine.Cubemap", 42 | "ignore": false, 43 | "defaultInstantiationMode": 0, 44 | "supportsModification": true 45 | }, 46 | { 47 | "userAdded": false, 48 | "type": "UnityEngine.GameObject", 49 | "ignore": false, 50 | "defaultInstantiationMode": 0, 51 | "supportsModification": true 52 | }, 53 | { 54 | "userAdded": false, 55 | "type": "UnityEditor.LightingDataAsset", 56 | "ignore": false, 57 | "defaultInstantiationMode": 0, 58 | "supportsModification": false 59 | }, 60 | { 61 | "userAdded": false, 62 | "type": "UnityEngine.LightingSettings", 63 | "ignore": false, 64 | "defaultInstantiationMode": 0, 65 | "supportsModification": true 66 | }, 67 | { 68 | "userAdded": false, 69 | "type": "UnityEngine.Material", 70 | "ignore": false, 71 | "defaultInstantiationMode": 0, 72 | "supportsModification": true 73 | }, 74 | { 75 | "userAdded": false, 76 | "type": "UnityEditor.MonoScript", 77 | "ignore": true, 78 | "defaultInstantiationMode": 1, 79 | "supportsModification": true 80 | }, 81 | { 82 | "userAdded": false, 83 | "type": "UnityEngine.PhysicMaterial", 84 | "ignore": false, 85 | "defaultInstantiationMode": 0, 86 | "supportsModification": true 87 | }, 88 | { 89 | "userAdded": false, 90 | "type": "UnityEngine.PhysicsMaterial2D", 91 | "ignore": false, 92 | "defaultInstantiationMode": 0, 93 | "supportsModification": true 94 | }, 95 | { 96 | "userAdded": false, 97 | "type": "UnityEngine.Rendering.PostProcessing.PostProcessProfile", 98 | "ignore": false, 99 | "defaultInstantiationMode": 0, 100 | "supportsModification": true 101 | }, 102 | { 103 | "userAdded": false, 104 | "type": "UnityEngine.Rendering.PostProcessing.PostProcessResources", 105 | "ignore": false, 106 | "defaultInstantiationMode": 0, 107 | "supportsModification": true 108 | }, 109 | { 110 | "userAdded": false, 111 | "type": "UnityEngine.Rendering.VolumeProfile", 112 | "ignore": false, 113 | "defaultInstantiationMode": 0, 114 | "supportsModification": true 115 | }, 116 | { 117 | "userAdded": false, 118 | "type": "UnityEditor.SceneAsset", 119 | "ignore": false, 120 | "defaultInstantiationMode": 0, 121 | "supportsModification": false 122 | }, 123 | { 124 | "userAdded": false, 125 | "type": "UnityEngine.Shader", 126 | "ignore": true, 127 | "defaultInstantiationMode": 1, 128 | "supportsModification": true 129 | }, 130 | { 131 | "userAdded": false, 132 | "type": "UnityEngine.ShaderVariantCollection", 133 | "ignore": true, 134 | "defaultInstantiationMode": 1, 135 | "supportsModification": true 136 | }, 137 | { 138 | "userAdded": false, 139 | "type": "UnityEngine.Texture", 140 | "ignore": false, 141 | "defaultInstantiationMode": 0, 142 | "supportsModification": true 143 | }, 144 | { 145 | "userAdded": false, 146 | "type": "UnityEngine.Texture2D", 147 | "ignore": false, 148 | "defaultInstantiationMode": 0, 149 | "supportsModification": true 150 | }, 151 | { 152 | "userAdded": false, 153 | "type": "UnityEngine.Timeline.TimelineAsset", 154 | "ignore": false, 155 | "defaultInstantiationMode": 0, 156 | "supportsModification": true 157 | } 158 | ], 159 | "defaultDependencyTypeInfo": { 160 | "userAdded": false, 161 | "type": "", 162 | "ignore": false, 163 | "defaultInstantiationMode": 1, 164 | "supportsModification": true 165 | }, 166 | "newSceneOverride": 0 167 | } -------------------------------------------------------------------------------- /Assets/Prefabs/MainCharacter.prefab: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!1 &5552083214460460424 4 | GameObject: 5 | m_ObjectHideFlags: 0 6 | m_CorrespondingSourceObject: {fileID: 0} 7 | m_PrefabInstance: {fileID: 0} 8 | m_PrefabAsset: {fileID: 0} 9 | serializedVersion: 6 10 | m_Component: 11 | - component: {fileID: 5552083214460460428} 12 | m_Layer: 0 13 | m_Name: ShootingPoint 14 | m_TagString: Untagged 15 | m_Icon: {fileID: 0} 16 | m_NavMeshLayer: 0 17 | m_StaticEditorFlags: 0 18 | m_IsActive: 1 19 | --- !u!4 &5552083214460460428 20 | Transform: 21 | m_ObjectHideFlags: 0 22 | m_CorrespondingSourceObject: {fileID: 0} 23 | m_PrefabInstance: {fileID: 0} 24 | m_PrefabAsset: {fileID: 0} 25 | m_GameObject: {fileID: 5552083214460460424} 26 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 27 | m_LocalPosition: {x: -0.033, y: 0, z: 1.49} 28 | m_LocalScale: {x: 0.24874, y: 0.28893, z: 0.98595} 29 | m_ConstrainProportionsScale: 0 30 | m_Children: [] 31 | m_Father: {fileID: 6261924764078417727} 32 | m_RootOrder: -1 33 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 34 | --- !u!1 &6261924764078417723 35 | GameObject: 36 | m_ObjectHideFlags: 0 37 | m_CorrespondingSourceObject: {fileID: 0} 38 | m_PrefabInstance: {fileID: 0} 39 | m_PrefabAsset: {fileID: 0} 40 | serializedVersion: 6 41 | m_Component: 42 | - component: {fileID: 6261924764078417727} 43 | - component: {fileID: 6261924764078417726} 44 | - component: {fileID: 6334737532428049707} 45 | m_Layer: 0 46 | m_Name: MainCharacter 47 | m_TagString: Untagged 48 | m_Icon: {fileID: 0} 49 | m_NavMeshLayer: 0 50 | m_StaticEditorFlags: 0 51 | m_IsActive: 1 52 | --- !u!4 &6261924764078417727 53 | Transform: 54 | m_ObjectHideFlags: 0 55 | m_CorrespondingSourceObject: {fileID: 0} 56 | m_PrefabInstance: {fileID: 0} 57 | m_PrefabAsset: {fileID: 0} 58 | m_GameObject: {fileID: 6261924764078417723} 59 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 60 | m_LocalPosition: {x: 0, y: 0, z: 0} 61 | m_LocalScale: {x: 1, y: 1, z: 1} 62 | m_ConstrainProportionsScale: 1 63 | m_Children: 64 | - {fileID: 7152424518289616880} 65 | - {fileID: 5552083214460460428} 66 | m_Father: {fileID: 0} 67 | m_RootOrder: 0 68 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 69 | --- !u!114 &6261924764078417726 70 | MonoBehaviour: 71 | m_ObjectHideFlags: 0 72 | m_CorrespondingSourceObject: {fileID: 0} 73 | m_PrefabInstance: {fileID: 0} 74 | m_PrefabAsset: {fileID: 0} 75 | m_GameObject: {fileID: 6261924764078417723} 76 | m_Enabled: 1 77 | m_EditorHideFlags: 0 78 | m_Script: {fileID: 11500000, guid: e8cd07e59c84452409c83579637fdcc2, type: 3} 79 | m_Name: 80 | m_EditorClassIdentifier: 81 | m_autoShootPeriod: 1 82 | m_sinAmplitude: 8 83 | m_sinSpeed: 1 84 | bulletPrefab: {fileID: 169017366624862012, guid: a8fdc418aafc8fc46a3c60a4b3f32fb3, type: 3} 85 | shootingPoint: {fileID: 5552083214460460424} 86 | --- !u!65 &6334737532428049707 87 | BoxCollider: 88 | m_ObjectHideFlags: 0 89 | m_CorrespondingSourceObject: {fileID: 0} 90 | m_PrefabInstance: {fileID: 0} 91 | m_PrefabAsset: {fileID: 0} 92 | m_GameObject: {fileID: 6261924764078417723} 93 | m_Material: {fileID: 0} 94 | m_IncludeLayers: 95 | serializedVersion: 2 96 | m_Bits: 4294967295 97 | m_ExcludeLayers: 98 | serializedVersion: 2 99 | m_Bits: 0 100 | m_LayerOverridePriority: 0 101 | m_IsTrigger: 1 102 | m_ProvidesContacts: 0 103 | m_Enabled: 1 104 | serializedVersion: 3 105 | m_Size: {x: 1, y: 1, z: 1.9798567} 106 | m_Center: {x: 0, y: 0, z: 0.4899286} 107 | --- !u!1 &7719845974378532885 108 | GameObject: 109 | m_ObjectHideFlags: 0 110 | m_CorrespondingSourceObject: {fileID: 0} 111 | m_PrefabInstance: {fileID: 0} 112 | m_PrefabAsset: {fileID: 0} 113 | serializedVersion: 6 114 | m_Component: 115 | - component: {fileID: 7152424518289616880} 116 | - component: {fileID: 1744120720146041650} 117 | - component: {fileID: 3650470664695410240} 118 | m_Layer: 0 119 | m_Name: ship 120 | m_TagString: Untagged 121 | m_Icon: {fileID: 0} 122 | m_NavMeshLayer: 0 123 | m_StaticEditorFlags: 0 124 | m_IsActive: 1 125 | --- !u!4 &7152424518289616880 126 | Transform: 127 | m_ObjectHideFlags: 0 128 | m_CorrespondingSourceObject: {fileID: 0} 129 | m_PrefabInstance: {fileID: 0} 130 | m_PrefabAsset: {fileID: 0} 131 | m_GameObject: {fileID: 7719845974378532885} 132 | m_LocalRotation: {x: 0, y: 0.7071068, z: 0, w: 0.7071068} 133 | m_LocalPosition: {x: -0.052, y: 0.128, z: 0.515} 134 | m_LocalScale: {x: 0.35, y: 0.35, z: 0.35} 135 | m_ConstrainProportionsScale: 1 136 | m_Children: [] 137 | m_Father: {fileID: 6261924764078417727} 138 | m_RootOrder: -1 139 | m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0} 140 | --- !u!23 &1744120720146041650 141 | MeshRenderer: 142 | m_ObjectHideFlags: 0 143 | m_CorrespondingSourceObject: {fileID: 0} 144 | m_PrefabInstance: {fileID: 0} 145 | m_PrefabAsset: {fileID: 0} 146 | m_GameObject: {fileID: 7719845974378532885} 147 | m_Enabled: 1 148 | m_CastShadows: 1 149 | m_ReceiveShadows: 1 150 | m_DynamicOccludee: 1 151 | m_StaticShadowCaster: 0 152 | m_MotionVectors: 1 153 | m_LightProbeUsage: 1 154 | m_ReflectionProbeUsage: 1 155 | m_RayTracingMode: 2 156 | m_RayTraceProcedural: 0 157 | m_RenderingLayerMask: 1 158 | m_RendererPriority: 0 159 | m_Materials: 160 | - {fileID: 2100000, guid: 95865321b62321d4aa2a335d122f3c25, type: 2} 161 | m_StaticBatchInfo: 162 | firstSubMesh: 0 163 | subMeshCount: 0 164 | m_StaticBatchRoot: {fileID: 0} 165 | m_ProbeAnchor: {fileID: 0} 166 | m_LightProbeVolumeOverride: {fileID: 0} 167 | m_ScaleInLightmap: 1 168 | m_ReceiveGI: 1 169 | m_PreserveUVs: 0 170 | m_IgnoreNormalsForChartDetection: 0 171 | m_ImportantGI: 0 172 | m_StitchLightmapSeams: 1 173 | m_SelectedEditorRenderState: 3 174 | m_MinimumChartSize: 4 175 | m_AutoUVMaxDistance: 0.5 176 | m_AutoUVMaxAngle: 89 177 | m_LightmapParameters: {fileID: 0} 178 | m_SortingLayerID: 0 179 | m_SortingLayer: 0 180 | m_SortingOrder: 0 181 | m_AdditionalVertexStreams: {fileID: 0} 182 | --- !u!33 &3650470664695410240 183 | MeshFilter: 184 | m_ObjectHideFlags: 0 185 | m_CorrespondingSourceObject: {fileID: 0} 186 | m_PrefabInstance: {fileID: 0} 187 | m_PrefabAsset: {fileID: 0} 188 | m_GameObject: {fileID: 7719845974378532885} 189 | m_Mesh: {fileID: -462981019419857548, guid: 27e8c81c66b852f4b8a7544bc62dc04d, type: 3} 190 | -------------------------------------------------------------------------------- /Packages/packages-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | "com.unity.burst": { 4 | "version": "1.8.7", 5 | "depth": 1, 6 | "source": "registry", 7 | "dependencies": { 8 | "com.unity.mathematics": "1.2.1" 9 | }, 10 | "url": "https://packages.unity.com" 11 | }, 12 | "com.unity.editorcoroutines": { 13 | "version": "1.0.0", 14 | "depth": 1, 15 | "source": "registry", 16 | "dependencies": {}, 17 | "url": "https://packages.unity.com" 18 | }, 19 | "com.unity.ext.nunit": { 20 | "version": "1.0.6", 21 | "depth": 2, 22 | "source": "registry", 23 | "dependencies": {}, 24 | "url": "https://packages.unity.com" 25 | }, 26 | "com.unity.feature.development": { 27 | "version": "1.0.1", 28 | "depth": 0, 29 | "source": "builtin", 30 | "dependencies": { 31 | "com.unity.ide.visualstudio": "2.0.18", 32 | "com.unity.ide.rider": "3.0.24", 33 | "com.unity.ide.vscode": "1.2.5", 34 | "com.unity.editorcoroutines": "1.0.0", 35 | "com.unity.performance.profile-analyzer": "1.2.2", 36 | "com.unity.test-framework": "1.1.33", 37 | "com.unity.testtools.codecoverage": "1.2.4" 38 | } 39 | }, 40 | "com.unity.ide.rider": { 41 | "version": "3.0.24", 42 | "depth": 1, 43 | "source": "registry", 44 | "dependencies": { 45 | "com.unity.ext.nunit": "1.0.6" 46 | }, 47 | "url": "https://packages.unity.com" 48 | }, 49 | "com.unity.ide.visualstudio": { 50 | "version": "2.0.18", 51 | "depth": 1, 52 | "source": "registry", 53 | "dependencies": { 54 | "com.unity.test-framework": "1.1.9" 55 | }, 56 | "url": "https://packages.unity.com" 57 | }, 58 | "com.unity.ide.vscode": { 59 | "version": "1.2.5", 60 | "depth": 1, 61 | "source": "registry", 62 | "dependencies": {}, 63 | "url": "https://packages.unity.com" 64 | }, 65 | "com.unity.mathematics": { 66 | "version": "1.2.6", 67 | "depth": 1, 68 | "source": "registry", 69 | "dependencies": {}, 70 | "url": "https://packages.unity.com" 71 | }, 72 | "com.unity.performance.profile-analyzer": { 73 | "version": "1.2.2", 74 | "depth": 1, 75 | "source": "registry", 76 | "dependencies": {}, 77 | "url": "https://packages.unity.com" 78 | }, 79 | "com.unity.render-pipelines.core": { 80 | "version": "14.0.8", 81 | "depth": 1, 82 | "source": "builtin", 83 | "dependencies": { 84 | "com.unity.ugui": "1.0.0", 85 | "com.unity.modules.physics": "1.0.0", 86 | "com.unity.modules.terrain": "1.0.0", 87 | "com.unity.modules.jsonserialize": "1.0.0" 88 | } 89 | }, 90 | "com.unity.render-pipelines.universal": { 91 | "version": "14.0.8", 92 | "depth": 0, 93 | "source": "builtin", 94 | "dependencies": { 95 | "com.unity.mathematics": "1.2.1", 96 | "com.unity.burst": "1.8.4", 97 | "com.unity.render-pipelines.core": "14.0.8", 98 | "com.unity.shadergraph": "14.0.8" 99 | } 100 | }, 101 | "com.unity.searcher": { 102 | "version": "4.9.2", 103 | "depth": 2, 104 | "source": "registry", 105 | "dependencies": {}, 106 | "url": "https://packages.unity.com" 107 | }, 108 | "com.unity.settings-manager": { 109 | "version": "2.0.1", 110 | "depth": 2, 111 | "source": "registry", 112 | "dependencies": {}, 113 | "url": "https://packages.unity.com" 114 | }, 115 | "com.unity.shadergraph": { 116 | "version": "14.0.8", 117 | "depth": 1, 118 | "source": "builtin", 119 | "dependencies": { 120 | "com.unity.render-pipelines.core": "14.0.8", 121 | "com.unity.searcher": "4.9.2" 122 | } 123 | }, 124 | "com.unity.test-framework": { 125 | "version": "1.1.33", 126 | "depth": 1, 127 | "source": "registry", 128 | "dependencies": { 129 | "com.unity.ext.nunit": "1.0.6", 130 | "com.unity.modules.imgui": "1.0.0", 131 | "com.unity.modules.jsonserialize": "1.0.0" 132 | }, 133 | "url": "https://packages.unity.com" 134 | }, 135 | "com.unity.testtools.codecoverage": { 136 | "version": "1.2.4", 137 | "depth": 1, 138 | "source": "registry", 139 | "dependencies": { 140 | "com.unity.test-framework": "1.0.16", 141 | "com.unity.settings-manager": "1.0.1" 142 | }, 143 | "url": "https://packages.unity.com" 144 | }, 145 | "com.unity.ugui": { 146 | "version": "1.0.0", 147 | "depth": 0, 148 | "source": "builtin", 149 | "dependencies": { 150 | "com.unity.modules.ui": "1.0.0", 151 | "com.unity.modules.imgui": "1.0.0" 152 | } 153 | }, 154 | "com.unity.modules.ai": { 155 | "version": "1.0.0", 156 | "depth": 0, 157 | "source": "builtin", 158 | "dependencies": {} 159 | }, 160 | "com.unity.modules.androidjni": { 161 | "version": "1.0.0", 162 | "depth": 0, 163 | "source": "builtin", 164 | "dependencies": {} 165 | }, 166 | "com.unity.modules.animation": { 167 | "version": "1.0.0", 168 | "depth": 0, 169 | "source": "builtin", 170 | "dependencies": {} 171 | }, 172 | "com.unity.modules.assetbundle": { 173 | "version": "1.0.0", 174 | "depth": 0, 175 | "source": "builtin", 176 | "dependencies": {} 177 | }, 178 | "com.unity.modules.audio": { 179 | "version": "1.0.0", 180 | "depth": 0, 181 | "source": "builtin", 182 | "dependencies": {} 183 | }, 184 | "com.unity.modules.cloth": { 185 | "version": "1.0.0", 186 | "depth": 0, 187 | "source": "builtin", 188 | "dependencies": { 189 | "com.unity.modules.physics": "1.0.0" 190 | } 191 | }, 192 | "com.unity.modules.director": { 193 | "version": "1.0.0", 194 | "depth": 0, 195 | "source": "builtin", 196 | "dependencies": { 197 | "com.unity.modules.audio": "1.0.0", 198 | "com.unity.modules.animation": "1.0.0" 199 | } 200 | }, 201 | "com.unity.modules.imageconversion": { 202 | "version": "1.0.0", 203 | "depth": 0, 204 | "source": "builtin", 205 | "dependencies": {} 206 | }, 207 | "com.unity.modules.imgui": { 208 | "version": "1.0.0", 209 | "depth": 0, 210 | "source": "builtin", 211 | "dependencies": {} 212 | }, 213 | "com.unity.modules.jsonserialize": { 214 | "version": "1.0.0", 215 | "depth": 0, 216 | "source": "builtin", 217 | "dependencies": {} 218 | }, 219 | "com.unity.modules.physics": { 220 | "version": "1.0.0", 221 | "depth": 0, 222 | "source": "builtin", 223 | "dependencies": {} 224 | }, 225 | "com.unity.modules.physics2d": { 226 | "version": "1.0.0", 227 | "depth": 0, 228 | "source": "builtin", 229 | "dependencies": {} 230 | }, 231 | "com.unity.modules.screencapture": { 232 | "version": "1.0.0", 233 | "depth": 0, 234 | "source": "builtin", 235 | "dependencies": { 236 | "com.unity.modules.imageconversion": "1.0.0" 237 | } 238 | }, 239 | "com.unity.modules.subsystems": { 240 | "version": "1.0.0", 241 | "depth": 1, 242 | "source": "builtin", 243 | "dependencies": { 244 | "com.unity.modules.jsonserialize": "1.0.0" 245 | } 246 | }, 247 | "com.unity.modules.terrain": { 248 | "version": "1.0.0", 249 | "depth": 2, 250 | "source": "builtin", 251 | "dependencies": {} 252 | }, 253 | "com.unity.modules.ui": { 254 | "version": "1.0.0", 255 | "depth": 0, 256 | "source": "builtin", 257 | "dependencies": {} 258 | }, 259 | "com.unity.modules.uielements": { 260 | "version": "1.0.0", 261 | "depth": 0, 262 | "source": "builtin", 263 | "dependencies": { 264 | "com.unity.modules.ui": "1.0.0", 265 | "com.unity.modules.imgui": "1.0.0", 266 | "com.unity.modules.jsonserialize": "1.0.0" 267 | } 268 | }, 269 | "com.unity.modules.vehicles": { 270 | "version": "1.0.0", 271 | "depth": 0, 272 | "source": "builtin", 273 | "dependencies": { 274 | "com.unity.modules.physics": "1.0.0" 275 | } 276 | }, 277 | "com.unity.modules.vr": { 278 | "version": "1.0.0", 279 | "depth": 0, 280 | "source": "builtin", 281 | "dependencies": { 282 | "com.unity.modules.jsonserialize": "1.0.0", 283 | "com.unity.modules.physics": "1.0.0", 284 | "com.unity.modules.xr": "1.0.0" 285 | } 286 | }, 287 | "com.unity.modules.wind": { 288 | "version": "1.0.0", 289 | "depth": 0, 290 | "source": "builtin", 291 | "dependencies": {} 292 | }, 293 | "com.unity.modules.xr": { 294 | "version": "1.0.0", 295 | "depth": 0, 296 | "source": "builtin", 297 | "dependencies": { 298 | "com.unity.modules.physics": "1.0.0", 299 | "com.unity.modules.jsonserialize": "1.0.0", 300 | "com.unity.modules.subsystems": "1.0.0" 301 | } 302 | } 303 | } 304 | } 305 | -------------------------------------------------------------------------------- /Assets/Scripts/SRPBatcherProfiler.cs: -------------------------------------------------------------------------------- 1 | using System.Collections; 2 | using System.Collections.Generic; 3 | using UnityEngine; 4 | 5 | using UnityEngine.Profiling; 6 | using UnityEngine.Rendering; 7 | 8 | namespace UnityEngine.Experimental.Rendering 9 | { 10 | public class SRPBatcherProfiler : MonoBehaviour 11 | { 12 | public bool m_Enable = false; 13 | private const float kAverageStatDuration = 1.0f; // stats refresh each second 14 | private int m_frameCount; 15 | private float m_AccDeltaTime; 16 | private string m_statsLabel; 17 | private GUIStyle m_style; 18 | private bool m_oldBatcherEnable; 19 | 20 | internal class RecorderEntry 21 | { 22 | public string name; 23 | public string oldName; 24 | public int callCount; 25 | public float accTime; 26 | public UnityEngine.Profiling.Recorder recorder; 27 | }; 28 | 29 | enum SRPBMarkers 30 | { 31 | kStdRenderDraw, 32 | kStdShadowDraw, 33 | kSRPBRenderDraw, 34 | kSRPBShadowDraw, 35 | kRenderThreadIdle, 36 | kStdRenderApplyShader, 37 | kStdShadowApplyShader, 38 | kSRPBRenderApplyShader, 39 | kSRPBShadowApplyShader, 40 | BRG_DebrisGPUSetData, 41 | BRG_BackgroundGPUSetData, 42 | }; 43 | 44 | RecorderEntry[] recordersList = 45 | { 46 | // Warning: Keep that list in the exact same order than SRPBMarkers enum 47 | new RecorderEntry() { name="RenderLoop.Draw" }, 48 | new RecorderEntry() { name="Shadows.Draw" }, 49 | new RecorderEntry() { name="RenderLoop.DrawSRPBatcher" }, 50 | new RecorderEntry() { name="Shadows.DrawSRPBatcher" }, 51 | new RecorderEntry() { name="RenderLoopDevice.Idle" }, 52 | new RecorderEntry() { name="StdRender.ApplyShader" }, 53 | new RecorderEntry() { name="StdShadow.ApplyShader" }, 54 | new RecorderEntry() { name="SRPBRender.ApplyShader" }, 55 | new RecorderEntry() { name="SRPBShadow.ApplyShader" }, 56 | new RecorderEntry() { name="BRG_Debris.GPUSetData" }, 57 | new RecorderEntry() { name="BRG_Background.GPUSetData" }, 58 | }; 59 | 60 | void Awake() 61 | { 62 | for (int i = 0; i < recordersList.Length; i++) 63 | { 64 | var sampler = Sampler.Get(recordersList[i].name); 65 | if (sampler.isValid) 66 | recordersList[i].recorder = sampler.GetRecorder(); 67 | else if ( recordersList[i].oldName != null ) 68 | { 69 | sampler = Sampler.Get(recordersList[i].oldName); 70 | if (sampler.isValid) 71 | recordersList[i].recorder = sampler.GetRecorder(); 72 | } 73 | } 74 | 75 | m_style =new GUIStyle(); 76 | m_style.fontSize = 15; 77 | m_style.normal.textColor = Color.white; 78 | m_oldBatcherEnable = m_Enable; 79 | 80 | ResetStats(); 81 | } 82 | 83 | void RazCounters() 84 | { 85 | m_AccDeltaTime = 0.0f; 86 | m_frameCount = 0; 87 | for (int i = 0; i < recordersList.Length; i++) 88 | { 89 | recordersList[i].accTime = 0.0f; 90 | recordersList[i].callCount = 0; 91 | } 92 | } 93 | 94 | void ResetStats() 95 | { 96 | m_statsLabel = "Gathering data..."; 97 | RazCounters(); 98 | } 99 | 100 | void ToggleStats() 101 | { 102 | m_Enable = !m_Enable; 103 | ResetStats(); 104 | } 105 | 106 | void Update() 107 | { 108 | 109 | if (Input.GetKeyDown(KeyCode.F9)) 110 | { 111 | GraphicsSettings.useScriptableRenderPipelineBatching = !GraphicsSettings.useScriptableRenderPipelineBatching; 112 | } 113 | 114 | if (GraphicsSettings.useScriptableRenderPipelineBatching != m_oldBatcherEnable ) 115 | { 116 | ResetStats(); 117 | m_oldBatcherEnable = GraphicsSettings.useScriptableRenderPipelineBatching; 118 | } 119 | 120 | bool toggleStats = Input.GetKeyDown(KeyCode.F8); 121 | if (Input.touchCount == 2) 122 | { 123 | if ((Input.touches[0].phase == TouchPhase.Began) && 124 | (Input.touches[1].phase == TouchPhase.Began)) 125 | toggleStats = !toggleStats; 126 | } 127 | 128 | if (toggleStats) 129 | { 130 | ToggleStats(); 131 | } 132 | 133 | if (m_Enable) 134 | { 135 | 136 | bool SRPBatcher = GraphicsSettings.useScriptableRenderPipelineBatching; 137 | 138 | m_AccDeltaTime += Time.unscaledDeltaTime; 139 | m_frameCount++; 140 | 141 | // get timing & update average accumulators 142 | for (int i = 0; i < recordersList.Length; i++) 143 | { 144 | if ( recordersList[i].recorder != null ) 145 | { 146 | recordersList[i].accTime += recordersList[i].recorder.elapsedNanoseconds / 1000000.0f; // acc time in ms 147 | recordersList[i].callCount += recordersList[i].recorder.sampleBlockCount; 148 | } 149 | } 150 | 151 | if (m_AccDeltaTime >= kAverageStatDuration) 152 | { 153 | 154 | float ooFrameCount = 1.0f / (float)m_frameCount; 155 | 156 | float avgStdRender = recordersList[(int)SRPBMarkers.kStdRenderDraw].accTime * ooFrameCount; 157 | float avgStdShadow = recordersList[(int)SRPBMarkers.kStdShadowDraw].accTime * ooFrameCount; 158 | float avgSRPBRender = recordersList[(int)SRPBMarkers.kSRPBRenderDraw].accTime * ooFrameCount; 159 | float avgSRPBShadow = recordersList[(int)SRPBMarkers.kSRPBShadowDraw].accTime * ooFrameCount; 160 | float RTIdleTime = recordersList[(int)SRPBMarkers.kRenderThreadIdle].accTime * ooFrameCount; 161 | 162 | m_statsLabel = string.Format("Accumulated time for RenderLoop.Draw and ShadowLoop.Draw (all threads)\n{0:F2}ms CPU Rendering time ( incl {1:F2}ms RT idle )\n", avgStdRender + avgStdShadow + avgSRPBRender + avgSRPBShadow, RTIdleTime); 163 | if (SRPBatcher) 164 | { 165 | m_statsLabel += string.Format(" {0:F2}ms SRP Batcher code path\n", avgSRPBRender + avgSRPBShadow); 166 | m_statsLabel += string.Format(" {0:F2}ms All objects ( {1} ApplyShader calls )\n", avgSRPBRender, recordersList[(int)SRPBMarkers.kSRPBRenderApplyShader].callCount / m_frameCount); 167 | m_statsLabel += string.Format(" {0:F2}ms Shadows ( {1} ApplyShader calls )\n", avgSRPBShadow, recordersList[(int)SRPBMarkers.kSRPBShadowApplyShader].callCount / m_frameCount); 168 | } 169 | // m_statsLabel += string.Format(" {0:F2}ms Standard code path\n", avgStdRender + avgStdShadow); 170 | // m_statsLabel += string.Format(" {0:F2}ms All objects ( {1} ApplyShader calls )\n", avgStdRender, recordersList[(int)SRPBMarkers.kStdRenderApplyShader].callCount / m_frameCount); 171 | // m_statsLabel += string.Format(" {0:F2}ms Shadows ( {1} ApplyShader calls )\n", avgStdShadow, recordersList[(int)SRPBMarkers.kStdShadowApplyShader].callCount / m_frameCount); 172 | m_statsLabel += string.Format("Global Main Loop: {0:F2}ms ({1} FPS)\n", m_AccDeltaTime * 1000.0f * ooFrameCount, (int)(((float)m_frameCount) / m_AccDeltaTime)); 173 | 174 | m_statsLabel += string.Format("\n"); 175 | m_statsLabel += string.Format(" {0:F2}ms BRG_DebrisGPUSetData ( {1} calls )\n", recordersList[(int)SRPBMarkers.BRG_DebrisGPUSetData].accTime * ooFrameCount, recordersList[(int)SRPBMarkers.BRG_DebrisGPUSetData].callCount / m_frameCount); 176 | m_statsLabel += string.Format(" {0:F2}ms BRG_BackgroundGPUSetData ( {1} calls )\n", recordersList[(int)SRPBMarkers.BRG_BackgroundGPUSetData].accTime * ooFrameCount, recordersList[(int)SRPBMarkers.BRG_BackgroundGPUSetData].callCount / m_frameCount); 177 | 178 | RazCounters(); 179 | } 180 | 181 | } 182 | } 183 | 184 | void OnGUI() 185 | { 186 | float offset = 50; 187 | if (m_Enable) 188 | { 189 | bool SRPBatcher = GraphicsSettings.useScriptableRenderPipelineBatching; 190 | 191 | GUI.color = new Color(1, 1, 1, 1); 192 | float w = 700, h = 256; 193 | offset += h + 50; 194 | 195 | if ( SRPBatcher ) 196 | GUILayout.BeginArea(new Rect(32, 50, w, h), "SRP batcher ON (F9)", GUI.skin.window); 197 | else 198 | GUILayout.BeginArea(new Rect(32, 50, w, h), "SRP batcher OFF (F9)", GUI.skin.window); 199 | 200 | GUILayout.Label(m_statsLabel, m_style); 201 | 202 | GUILayout.EndArea(); 203 | } 204 | } 205 | } 206 | } 207 | --------------------------------------------------------------------------------