diff --git a/.gitignore b/.gitignore index e45e4ce..89c3f95 100644 --- a/.gitignore +++ b/.gitignore @@ -29,4 +29,6 @@ sysinfo.txt .vscode/ Bolt_DebugStart_Build/ +.vsconfig +UpgradeLog.htm diff --git a/Assets/GWConquest/Scripts/Formation.cs b/Assets/GWConquest/Scripts/Formation.cs index 51ac8ae..a1aa0d7 100644 --- a/Assets/GWConquest/Scripts/Formation.cs +++ b/Assets/GWConquest/Scripts/Formation.cs @@ -37,7 +37,6 @@ namespace GWConquest private NetworkVariable player = new NetworkVariable(); private GWNetworkList units = new GWNetworkList(); private GWNetworkList pathQueue = new GWNetworkList(); - private NetworkVariable currentBattle = new NetworkVariable(); private NetworkVariable heroUnit = new NetworkVariable(); private GWNetworkList subFormations = new GWNetworkList(); private NetworkVariable formationName = new NetworkVariable(); diff --git a/Assets/GWConquest/Scripts/GWNullable.cs b/Assets/GWConquest/Scripts/GWNullable.cs index 482aece..93330be 100644 --- a/Assets/GWConquest/Scripts/GWNullable.cs +++ b/Assets/GWConquest/Scripts/GWNullable.cs @@ -17,7 +17,7 @@ namespace GWConquest { } } - public bool HasValue => hasValue; + public readonly bool HasValue => hasValue; public NetworkBehaviour Behaviour { diff --git a/Assets/GWConquest/Scripts/Planet.cs b/Assets/GWConquest/Scripts/Planet.cs index b3ac720..d91ed40 100644 --- a/Assets/GWConquest/Scripts/Planet.cs +++ b/Assets/GWConquest/Scripts/Planet.cs @@ -228,6 +228,7 @@ namespace GWConquest } else { planetName = PlanetName; + gameObject.name = planetName; GetMainZone(ZoneType.Space).SetZoneId(spaceZoneID.Value); GetAttackZones(ZoneType.Ground)[0].SetZoneId(attackZoneID.Value); @@ -539,6 +540,22 @@ namespace GWConquest prefabScale.Value = scale; } + public override string ToString() + { + if(IsSpawned) + { + return PlanetName; + } + else if(planetName != null && planetName != "") + { + return planetName; + } + else + { + return ""; + } + } + #if UNITY_EDITOR [ContextMenu("Setup Zones From Database")] diff --git a/Assets/GWConquest/Scripts/PlanetConnection.cs b/Assets/GWConquest/Scripts/PlanetConnection.cs index 6ea4f4a..26c54bf 100644 --- a/Assets/GWConquest/Scripts/PlanetConnection.cs +++ b/Assets/GWConquest/Scripts/PlanetConnection.cs @@ -241,7 +241,7 @@ namespace GWConquest } else { - Debug.LogFormat("Connecting planets {0} and {1}", planet1, planet2); + Debug.LogFormat("[PlanetPlacement] Connecting planets {0} and {1}", planet1, planet2); if (!planet1.connections.Contains(this)) { planet1.connections.Add(this); @@ -256,5 +256,10 @@ namespace GWConquest } } + public override string ToString() + { + return "PlanetConnection(" + planet1?.ToString() + ", " + planet2?.ToString() + ")"; + } + } } \ No newline at end of file diff --git a/Assets/GWConquest/Scripts/PlanetPlacement.cs b/Assets/GWConquest/Scripts/PlanetPlacement.cs index f1cc022..0678023 100644 --- a/Assets/GWConquest/Scripts/PlanetPlacement.cs +++ b/Assets/GWConquest/Scripts/PlanetPlacement.cs @@ -202,7 +202,7 @@ namespace GWConquest type = DistrictType.Civil; } - Debug.LogFormat("Spawning district of type {0} on planet {1}", type, planet.name); + Debug.LogFormat("[PlanetPlacement] Spawning district of type {0} on planet {1}", type, planet.name); var point2D = Random.insideUnitCircle * districtSettings.MaxDistrictRadius; @@ -396,13 +396,13 @@ namespace GWConquest List allPlanets = new List(FindObjectsOfType()); int origPlanetCount = allPlanets.Count; - Debug.LogFormat("Static planets: {0}", origPlanetCount); + Debug.LogFormat("[PlanetPlacement] Static planets: {0}", origPlanetCount); foreach(var conn in PreConnections) { float connLength = conn.GetLength(); int planetCount = Mathf.RoundToInt( Random.Range(connLength / MaxPlanetDistance, connLength / MinPlanetDistance) ) - 1; - Debug.LogFormat("Spawning {0} planets between {1} and {2}", planetCount, conn.planet1.PlanetName, conn.planet2.PlanetName); + Debug.LogFormat("[PlanetPlacement] Spawning {0} planets between {1} and {2}", planetCount, conn.planet1.PlanetName, conn.planet2.PlanetName); Vector3 start = conn.planet1.transform.position; Vector3 dir = conn.planet2.transform.position - start; @@ -435,7 +435,7 @@ namespace GWConquest PlacePlanetsSecondPassNew(allPlanets, spawnedConnections, ref nextZoneId); int finalPlanetCount = allPlanets.Count; - Debug.LogFormat("Additional planets: {0}", finalPlanetCount-origPlanetCount); + Debug.LogFormat("[PlanetPlacement] Additional planets: {0}", finalPlanetCount-origPlanetCount); } private void PlacePlanetsSecondPass(List allPlanets, List spawnedConnections, ref int nextZoneId) @@ -489,7 +489,7 @@ namespace GWConquest private void PlacePlanetsSecondPassNew(List allPlanets, List spawnedConnections, ref int nextZoneId) { int planetsToSpawn = Random.Range(Pass2New_MinPlanets, Pass2New_MaxPlanets); - Debug.LogFormat("Spawning {0} planets in second pass.", planetsToSpawn); + Debug.LogFormat("[PlanetPlacement] Spawning {0} planets in second pass.", planetsToSpawn); Vector3 galaxyCenter = transform.position; diff --git a/Assets/GWConquest/Scripts/Player.cs b/Assets/GWConquest/Scripts/Player.cs index 5b14241..0e75150 100644 --- a/Assets/GWConquest/Scripts/Player.cs +++ b/Assets/GWConquest/Scripts/Player.cs @@ -72,7 +72,7 @@ namespace GWConquest knownPlanetsList.OnListChanged += OnPlanetsUpdated; visiblePlanetsList.OnListChanged += OnPlanetsUpdated; - if(!IsServer) + if(!IsServer && IsOwner) { CurrentPlayer = this; Debug.LogFormat("Current player is {0} with connection ID {1}", this, OwnerClientId); diff --git a/Packages/manifest.json b/Packages/manifest.json index 8beb60e..2c9aaeb 100644 --- a/Packages/manifest.json +++ b/Packages/manifest.json @@ -1,16 +1,17 @@ { "dependencies": { - "com.unity.2d.common": "8.0.1", + "com.unity.2d.common": "9.0.1", "com.unity.2d.sprite": "1.0.0", "com.unity.ai.navigation": "1.1.4", "com.unity.collab-proxy": "2.0.5", "com.unity.ide.rider": "3.0.24", "com.unity.ide.visualstudio": "2.0.18", - "com.unity.ide.vscode": "1.2.5", - "com.unity.netcode.gameobjects": "1.5.1", - "com.unity.postprocessing": "3.2.2", - "com.unity.test-framework": "1.1.33", - "com.unity.timeline": "1.7.4", + "com.unity.multiplayer.playmode": "0.1.1", + "com.unity.multiplayer.tools": "1.1.0", + "com.unity.netcode.gameobjects": "1.5.2", + "com.unity.postprocessing": "3.3.0", + "com.unity.test-framework": "1.3.7", + "com.unity.timeline": "1.8.2", "com.unity.ugui": "1.0.0", "com.unity.modules.ai": "1.0.0", "com.unity.modules.androidjni": "1.0.0", diff --git a/Packages/packages-lock.json b/Packages/packages-lock.json index d6f21cb..c0715ba 100644 --- a/Packages/packages-lock.json +++ b/Packages/packages-lock.json @@ -1,7 +1,7 @@ { "dependencies": { "com.unity.2d.common": { - "version": "8.0.1", + "version": "9.0.1", "depth": 0, "source": "registry", "dependencies": { @@ -9,7 +9,7 @@ "com.unity.mathematics": "1.1.0", "com.unity.modules.uielements": "1.0.0", "com.unity.modules.animation": "1.0.0", - "com.unity.burst": "1.7.3" + "com.unity.burst": "1.8.3" }, "url": "https://packages.unity.com" }, @@ -46,7 +46,7 @@ }, "com.unity.collections": { "version": "1.2.4", - "depth": 2, + "depth": 1, "source": "registry", "dependencies": { "com.unity.burst": "1.6.6", @@ -55,7 +55,7 @@ "url": "https://packages.unity.com" }, "com.unity.ext.nunit": { - "version": "1.0.6", + "version": "2.0.3", "depth": 1, "source": "registry", "dependencies": {}, @@ -79,13 +79,6 @@ }, "url": "https://packages.unity.com" }, - "com.unity.ide.vscode": { - "version": "1.2.5", - "depth": 0, - "source": "registry", - "dependencies": {}, - "url": "https://packages.unity.com" - }, "com.unity.mathematics": { "version": "1.2.6", "depth": 1, @@ -93,8 +86,31 @@ "dependencies": {}, "url": "https://packages.unity.com" }, + "com.unity.multiplayer.playmode": { + "version": "0.1.1", + "depth": 0, + "source": "registry", + "dependencies": { + "nuget.moq": "1.0.0", + "com.unity.nuget.newtonsoft-json": "2.0.2" + }, + "url": "https://packages.unity.com" + }, + "com.unity.multiplayer.tools": { + "version": "1.1.0", + "depth": 0, + "source": "registry", + "dependencies": { + "com.unity.profiling.core": "1.0.0-pre.1", + "com.unity.nuget.newtonsoft-json": "2.0.0", + "com.unity.nuget.mono-cecil": "1.10.1", + "com.unity.collections": "1.1.0", + "com.unity.modules.uielements": "1.0.0" + }, + "url": "https://packages.unity.com" + }, "com.unity.netcode.gameobjects": { - "version": "1.5.1", + "version": "1.5.2", "depth": 0, "source": "registry", "dependencies": { @@ -110,8 +126,15 @@ "dependencies": {}, "url": "https://packages.unity.com" }, + "com.unity.nuget.newtonsoft-json": { + "version": "3.2.1", + "depth": 1, + "source": "registry", + "dependencies": {}, + "url": "https://packages.unity.com" + }, "com.unity.postprocessing": { - "version": "3.2.2", + "version": "3.3.0", "depth": 0, "source": "registry", "dependencies": { @@ -119,19 +142,26 @@ }, "url": "https://packages.unity.com" }, + "com.unity.profiling.core": { + "version": "1.0.2", + "depth": 1, + "source": "registry", + "dependencies": {}, + "url": "https://packages.unity.com" + }, "com.unity.test-framework": { - "version": "1.1.33", + "version": "1.3.7", "depth": 0, "source": "registry", "dependencies": { - "com.unity.ext.nunit": "1.0.6", + "com.unity.ext.nunit": "2.0.3", "com.unity.modules.imgui": "1.0.0", "com.unity.modules.jsonserialize": "1.0.0" }, "url": "https://packages.unity.com" }, "com.unity.timeline": { - "version": "1.7.4", + "version": "1.8.2", "depth": 0, "source": "registry", "dependencies": { @@ -143,7 +173,7 @@ "url": "https://packages.unity.com" }, "com.unity.transport": { - "version": "1.3.4", + "version": "1.4.0", "depth": 1, "source": "registry", "dependencies": { @@ -162,6 +192,22 @@ "com.unity.modules.imgui": "1.0.0" } }, + "nuget.castle-core": { + "version": "1.0.1", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://packages.unity.com" + }, + "nuget.moq": { + "version": "1.0.0", + "depth": 1, + "source": "registry", + "dependencies": { + "nuget.castle-core": "1.0.1" + }, + "url": "https://packages.unity.com" + }, "com.unity.modules.ai": { "version": "1.0.0", "depth": 0, diff --git a/ProjectSettings/ProjectSettings.asset b/ProjectSettings/ProjectSettings.asset index a704c81..4b5af06 100644 --- a/ProjectSettings/ProjectSettings.asset +++ b/ProjectSettings/ProjectSettings.asset @@ -3,7 +3,7 @@ --- !u!129 &1 PlayerSettings: m_ObjectHideFlags: 0 - serializedVersion: 26 + serializedVersion: 27 productGUID: a96b1b09381e83e45b36ba1f7b6e33d5 AndroidProfiler: 0 AndroidFilterTouchesWhenObscured: 0 @@ -75,6 +75,7 @@ PlayerSettings: androidMinimumWindowWidth: 400 androidMinimumWindowHeight: 300 androidFullscreenMode: 1 + androidApplicationEntry: 1 defaultIsNativeResolution: 1 macRetinaSupport: 1 runInBackground: 1 @@ -93,6 +94,7 @@ PlayerSettings: useMacAppStoreValidation: 0 macAppStoreCategory: public.app-category.games gpuSkinning: 1 + meshDeformation: 2 xboxPIXTextureCapture: 0 xboxEnableAvatar: 0 xboxEnableKinect: 0 @@ -125,8 +127,6 @@ PlayerSettings: switchNVNMaxPublicTextureIDCount: 0 switchNVNMaxPublicSamplerIDCount: 0 switchNVNGraphicsFirmwareMemory: 32 - stadiaPresentMode: 0 - stadiaTargetFramerate: 0 vulkanNumSwapchainBuffers: 3 vulkanEnableSetSRGBWrite: 0 vulkanEnablePreTransform: 0 @@ -172,18 +172,16 @@ PlayerSettings: ForceInternetPermission: 0 ForceSDCardPermission: 0 CreateWallpaper: 0 - APKExpansionFiles: 0 + androidSplitApplicationBinary: 0 keepLoadedShadersAlive: 0 StripUnusedMeshComponents: 1 strictShaderVariantMatching: 0 VertexChannelCompressionMask: 4054 iPhoneSdkVersion: 988 - iOSTargetOSVersionString: 12.0 + iOSTargetOSVersionString: 13.0 tvOSSdkVersion: 0 tvOSRequireExtendedGameController: 0 - tvOSTargetOSVersionString: 12.0 - bratwurstSdkVersion: 0 - bratwurstTargetOSVersionString: 16.4 + tvOSTargetOSVersionString: 13.0 uIPrerenderedIcon: 0 uIRequiresPersistentWiFi: 0 uIRequiresFullScreen: 1 @@ -231,10 +229,8 @@ PlayerSettings: appleDeveloperTeamID: iOSManualSigningProvisioningProfileID: tvOSManualSigningProvisioningProfileID: - bratwurstManualSigningProvisioningProfileID: iOSManualSigningProvisioningProfileType: 0 tvOSManualSigningProvisioningProfileType: 0 - bratwurstManualSigningProvisioningProfileType: 0 appleEnableAutomaticSigning: 0 iOSRequireARKit: 0 iOSAutomaticallyDetectAndAddCapabilities: 1 @@ -275,6 +271,7 @@ PlayerSettings: AndroidMinifyDebug: 0 AndroidValidateAppBundleSize: 1 AndroidAppBundleSizeToValidate: 150 + AndroidReportGooglePlayAppDependencies: 1 m_BuildTargetIcons: - m_BuildTarget: m_Icons: @@ -345,7 +342,7 @@ PlayerSettings: m_Automatic: 1 - m_BuildTarget: WebGLSupport m_APIs: 0b000000 - m_Automatic: 0 + m_Automatic: 1 - m_BuildTarget: MetroSupport m_APIs: 02000000 m_Automatic: 1 @@ -635,7 +632,9 @@ PlayerSettings: Bratwurst: UNITY_POST_PROCESSING_STACK_V2 CloudRendering: UNITY_POST_PROCESSING_STACK_V2 EmbeddedLinux: UNITY_POST_PROCESSING_STACK_V2 + GameCoreScarlett: UNITY_POST_PROCESSING_STACK_V2 GameCoreXboxOne: UNITY_POST_PROCESSING_STACK_V2 + LinuxHeadlessSimulation: UNITY_POST_PROCESSING_STACK_V2 Lumin: UNITY_POST_PROCESSING_STACK_V2 Nintendo Switch: UNITY_POST_PROCESSING_STACK_V2 PS4: UNITY_POST_PROCESSING_STACK_V2 @@ -654,6 +653,7 @@ PlayerSettings: Standalone: 1 il2cppCompilerConfiguration: {} il2cppCodeGeneration: {} + il2cppStacktraceInformation: {} managedStrippingLevel: Bratwurst: 1 EmbeddedLinux: 1 @@ -680,6 +680,7 @@ PlayerSettings: gcWBarrierValidation: 0 apiCompatibilityLevelPerPlatform: Standalone: 3 + editorAssembliesCompatibilityLevel: 1 m_RenderingPath: 1 m_MobileRenderingPath: 1 metroPackageName: Template_3D @@ -767,6 +768,5 @@ PlayerSettings: cloudEnabled: 0 legacyClampBlendShapeWeights: 0 hmiLoadingImage: {fileID: 0} - platformRequiresReadableAssets: 0 virtualTexturingSupportEnabled: 0 insecureHttpOption: 0 diff --git a/ProjectSettings/ProjectVersion.txt b/ProjectSettings/ProjectVersion.txt index e7e2f19..b0d9690 100644 --- a/ProjectSettings/ProjectVersion.txt +++ b/ProjectSettings/ProjectVersion.txt @@ -1,2 +1,2 @@ -m_EditorVersion: 2022.3.4f1 -m_EditorVersionWithRevision: 2022.3.4f1 (35713cd46cd7) +m_EditorVersion: 2023.1.6f1 +m_EditorVersionWithRevision: 2023.1.6f1 (964b2488c462)