Description:
Downgrade to slightly earlier .NET to fix macOS issue.
Commit status:
[Not Reviewed]
References:
Comments:
0 Commit comments 0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
Add another comment

r30:0855cc158466 -

1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
@@ -18,4 +18,3
18 /Users/alys/repos/isometric-park-fna/FNA/obj/Debug/FNA.csproj.CoreCompileInputs.cache
18 /Users/alys/repos/isometric-park-fna/FNA/obj/Debug/FNA.csproj.CoreCompileInputs.cache
19 /Users/alys/repos/isometric-park-fna/FNA/obj/Debug/FNA.dll
19 /Users/alys/repos/isometric-park-fna/FNA/obj/Debug/FNA.dll
20 /Users/alys/repos/isometric-park-fna/FNA/obj/Debug/FNA.pdb
20 /Users/alys/repos/isometric-park-fna/FNA/obj/Debug/FNA.pdb
21 /Users/alys/repos/isometric-park-fna/FNA/obj/Debug/FNA.csprojAssemblyReference.cache
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
@@ -1,9 +1,9
1 <Project ToolsVersion="15.0" Sdk="Microsoft.NET.Sdk">
1 <Project Sdk="Microsoft.NET.Sdk">
2 <PropertyGroup>
2 <PropertyGroup>
3 <Description>A .NET wrapper for the Dear ImGui library.</Description>
3 <Description>A .NET wrapper for the Dear ImGui library.</Description>
4 <AssemblyVersion>1.78.0</AssemblyVersion>
4 <AssemblyVersion>1.78.0</AssemblyVersion>
5 <Authors>Eric Mellino</Authors>
5 <Authors>Eric Mellino</Authors>
6 <TargetFramework>net472</TargetFramework>
6 <TargetFramework>netstandard2.0</TargetFramework>
7 <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
7 <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
8 <DebugType>portable</DebugType>
8 <DebugType>portable</DebugType>
9 <AssemblyName>ImGui.NET</AssemblyName>
9 <AssemblyName>ImGui.NET</AssemblyName>
@@ -20,8 +20,8
20 <DocumentationFile></DocumentationFile>
20 <DocumentationFile></DocumentationFile>
21 </PropertyGroup>
21 </PropertyGroup>
22 <ItemGroup>
22 <ItemGroup>
23 <PackageReference Include="System.Numerics.Vectors" Version="4.4.0"/>
23 <PackageReference Include="System.Numerics.Vectors" Version="4.4.0" />
24 <PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="4.4.0"/>
24 <PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="4.4.0" />
25 <PackageReference Include="System.Buffers" Version="4.4.0" />
25 <PackageReference Include="System.Buffers" Version="4.4.0" />
26 </ItemGroup>
26 </ItemGroup>
27 <ItemGroup>
27 <ItemGroup>
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
@@ -9,7 +9,7
9 EndProject
9 EndProject
10 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFontPlus.FNA", "SpriteFontPlus\src\SpriteFontPlus.FNA.csproj", "{206E88C3-9D3D-4684-80E4-4AE0CD626D2F}"
10 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpriteFontPlus.FNA", "SpriteFontPlus\src\SpriteFontPlus.FNA.csproj", "{206E88C3-9D3D-4684-80E4-4AE0CD626D2F}"
11 EndProject
11 EndProject
12 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImGui.NET", "ImGui.NET\ImGui.NET.csproj", "{22ACD385-A146-448C-B82D-0FDB449FB7AD}"
12 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImGui.NET", "ImGui.NET\ImGui.NET.csproj", "{0023328E-2EFD-448B-BD85-A76769CD106A}"
13 EndProject
13 EndProject
14 Global
14 Global
15 GlobalSection(SolutionConfigurationPlatforms) = preSolution
15 GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -57,18 +57,18
57 {206E88C3-9D3D-4684-80E4-4AE0CD626D2F}.Debug|x64.Build.0 = Debug|Any CPU
57 {206E88C3-9D3D-4684-80E4-4AE0CD626D2F}.Debug|x64.Build.0 = Debug|Any CPU
58 {206E88C3-9D3D-4684-80E4-4AE0CD626D2F}.Release|x64.ActiveCfg = Release|Any CPU
58 {206E88C3-9D3D-4684-80E4-4AE0CD626D2F}.Release|x64.ActiveCfg = Release|Any CPU
59 {206E88C3-9D3D-4684-80E4-4AE0CD626D2F}.Release|x64.Build.0 = Release|Any CPU
59 {206E88C3-9D3D-4684-80E4-4AE0CD626D2F}.Release|x64.Build.0 = Release|Any CPU
60 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Debug|anycpu.ActiveCfg = Debug|Any CPU
60 {0023328E-2EFD-448B-BD85-A76769CD106A}.Debug|anycpu.ActiveCfg = Debug|Any CPU
61 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Debug|anycpu.Build.0 = Debug|Any CPU
61 {0023328E-2EFD-448B-BD85-A76769CD106A}.Debug|anycpu.Build.0 = Debug|Any CPU
62 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Release|anycpu.ActiveCfg = Release|Any CPU
62 {0023328E-2EFD-448B-BD85-A76769CD106A}.Release|anycpu.ActiveCfg = Release|Any CPU
63 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Release|anycpu.Build.0 = Release|Any CPU
63 {0023328E-2EFD-448B-BD85-A76769CD106A}.Release|anycpu.Build.0 = Release|Any CPU
64 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Debug|x86.ActiveCfg = Debug|Any CPU
64 {0023328E-2EFD-448B-BD85-A76769CD106A}.Debug|x86.ActiveCfg = Debug|Any CPU
65 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Debug|x86.Build.0 = Debug|Any CPU
65 {0023328E-2EFD-448B-BD85-A76769CD106A}.Debug|x86.Build.0 = Debug|Any CPU
66 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Release|x86.ActiveCfg = Release|Any CPU
66 {0023328E-2EFD-448B-BD85-A76769CD106A}.Release|x86.ActiveCfg = Release|Any CPU
67 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Release|x86.Build.0 = Release|Any CPU
67 {0023328E-2EFD-448B-BD85-A76769CD106A}.Release|x86.Build.0 = Release|Any CPU
68 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Debug|x64.ActiveCfg = Debug|Any CPU
68 {0023328E-2EFD-448B-BD85-A76769CD106A}.Debug|x64.ActiveCfg = Debug|Any CPU
69 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Debug|x64.Build.0 = Debug|Any CPU
69 {0023328E-2EFD-448B-BD85-A76769CD106A}.Debug|x64.Build.0 = Debug|Any CPU
70 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Release|x64.ActiveCfg = Release|Any CPU
70 {0023328E-2EFD-448B-BD85-A76769CD106A}.Release|x64.ActiveCfg = Release|Any CPU
71 {22ACD385-A146-448C-B82D-0FDB449FB7AD}.Release|x64.Build.0 = Release|Any CPU
71 {0023328E-2EFD-448B-BD85-A76769CD106A}.Release|x64.Build.0 = Release|Any CPU
72 EndGlobalSection
72 EndGlobalSection
73 GlobalSection(SolutionProperties) = preSolution
73 GlobalSection(SolutionProperties) = preSolution
74 HideSolutionNode = FALSE
74 HideSolutionNode = FALSE
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
@@ -12,10 +12,9
12 using System.Diagnostics;
12 using System.Diagnostics;
13 using static isometricparkfna.TileMap;
13 using static isometricparkfna.TileMap;
14
14
15 #if DEBUG
15
16 using ImGuiNET.SampleProgram.XNA;
16 using ImGuiNET.SampleProgram.XNA;
17 using ImGuiNET;
17 using ImGuiNET;
18 #endif
19
18
20 class FNAGame : Game
19 class FNAGame : Game
21 {
20 {
@@ -55,10 +54,10
55 Vector2 mouseGrid;
54 Vector2 mouseGrid;
56 Vector2 original_point;
55 Vector2 original_point;
57 Vector2 mousePos;
56 Vector2 mousePos;
58 #if DEBUG
57
59 private ImGuiRenderer _imGuiRenderer;
58 private ImGuiRenderer _imGuiRenderer;
60 private DebugWindow debugWindow;
59 private DebugWindow debugWindow;
61 #endif
60
62 bool show_another_window;
61 bool show_another_window;
63 private bool showInitial;
62 private bool showInitial;
64 int messageIndex;
63 int messageIndex;
@@ -81,6 +80,14
81 {
80 {
82 //this.device = new GraphicsDevice(GraphicsAdapter.DefaultAdapter, GraphicsProfile.)
81 //this.device = new GraphicsDevice(GraphicsAdapter.DefaultAdapter, GraphicsProfile.)
83
82
83 Console.Out.Write("TEST?");
84 #if DEBUG
85 foreach (System.Reflection.Assembly assembly in AppDomain.CurrentDomain.GetAssemblies())
86 {
87 Console.Out.Write(assembly.ToString() + "\n");
88 }
89 ;
90 #endif
84 GraphicsDeviceManager gdm = new GraphicsDeviceManager(this)
91 GraphicsDeviceManager gdm = new GraphicsDeviceManager(this)
85 {
92 {
86
93
@@ -109,8 +116,11
109 showInitial = true;
116 showInitial = true;
110 messageIndex = 0;
117 messageIndex = 0;
111
118
119 this.Window.Title = "Isometric Park";
120
112 Content.RootDirectory = "Content";
121 Content.RootDirectory = "Content";
113
122
123
114 }
124 }
115
125
116 protected override void Initialize()
126 protected override void Initialize()
@@ -737,7 +747,7
737 hasTree = has_tree,
747 hasTree = has_tree,
738 tilesDrawn = this.tilesDrawn
748 tilesDrawn = this.tilesDrawn
739 };
749 };
740 #if DEBUG
750
741 //Finally, draw the debug window
751 //Finally, draw the debug window
742 _imGuiRenderer.BeforeLayout(gameTime);
752 _imGuiRenderer.BeforeLayout(gameTime);
743 debugWindow.Layout(debugInfo, new Dictionary<string, string>(),ref show_another_window);
753 debugWindow.Layout(debugInfo, new Dictionary<string, string>(),ref show_another_window);
@@ -758,7 +768,7
758 }
768 }
759
769
760 _imGuiRenderer.AfterLayout();
770 _imGuiRenderer.AfterLayout();
761 #endif
771
762
772
763 stopWatch.Stop();
773 stopWatch.Stop();
764 this.drawTime = stopWatch.Elapsed;
774 this.drawTime = stopWatch.Elapsed;
@@ -9,6 +9,11
9 public const int START_MONTH = 1;
9 public const int START_MONTH = 1;
10 public const int START_DAY = 1;
10 public const int START_DAY = 1;
11
11
12
13 private const float SPONTANEOUS_NEW_TREE_CHANCE = 0.9995f;
14 private const float NEIGHBOR_NEW_TREE_CHANCE = 0.995f;
15 private const float NEIGHBOR_CROWDS_TREE_CHANCE = 0.995f;
16
12 public int Tick
17 public int Tick
13 {
18 {
14 get;
19 get;
@@ -39,9 +44,12
39 public int ticksPerAdvance;
44 public int ticksPerAdvance;
40
45
41 private float lastAdvance;
46 private float lastAdvance;
47 private Random random;
42
48
43 public Simulation(int width, int height, float millisecondsPerAdvance)
49 public Simulation(int width, int height, float millisecondsPerAdvance)
44 {
50 {
51 this.random = new Random();
52
45 this.DateTime = new DateTime(START_YEAR, START_MONTH, START_DAY);
53 this.DateTime = new DateTime(START_YEAR, START_MONTH, START_DAY);
46
54
47 this.map = new TileMap(width, height);
55 this.map = new TileMap(width, height);
@@ -51,12 +59,12
51
59
52 private void advanceSimulation()
60 private void advanceSimulation()
53 {
61 {
54 Random random = new Random();
62
55 this.DateTime = this.DateTime.AddMonths(1);
63 this.DateTime = this.DateTime.AddMonths(1);
56
64
57 foreach (Cell cell in this.map.iterate_cells())
65 foreach (Cell cell in this.map.iterate_cells())
58 {
66 {
59 if (random.NextDouble() > 0.9995f)
67 if (random.NextDouble() > SPONTANEOUS_NEW_TREE_CHANCE)
60 {
68 {
61 cell.hasTree = true;
69 cell.hasTree = true;
62 }
70 }
@@ -64,7 +72,7
64
72
65 foreach (Cell cell in this.map.iterate_cells_with_neighbors(4))
73 foreach (Cell cell in this.map.iterate_cells_with_neighbors(4))
66 {
74 {
67 if (random.NextDouble() > 0.995f)
75 if (random.NextDouble() > NEIGHBOR_NEW_TREE_CHANCE)
68 {
76 {
69 cell.hasTree = true;
77 cell.hasTree = true;
70 }
78 }
@@ -72,7 +80,7
72
80
73 foreach (Cell cell in this.map.iterate_cells_with_neighbors(7))
81 foreach (Cell cell in this.map.iterate_cells_with_neighbors(7))
74 {
82 {
75 if (random.NextDouble() > 0.995f)
83 if (random.NextDouble() > NEIGHBOR_CROWDS_TREE_CHANCE)
76 {
84 {
77 cell.hasTree = false;
85 cell.hasTree = false;
78 }
86 }
@@ -95,7 +103,7
95 //Example:
103 //Example:
96 //We start at t=100 and simulate every 10 t. If we miss enough updates that
104 //We start at t=100 and simulate every 10 t. If we miss enough updates that
97 //it's t=125, we have 2.5 steps to simulate. However, we only want to simulate
105 //it's t=125, we have 2.5 steps to simulate. However, we only want to simulate
98 //whole steps, so that means we'll simulate 2. But that means we've only simulated
106 //whole steps for simplicity's sake, so that means we'll simulate 2. But that means we've only simulated
99 //through t=120, so that's what we want to track in lastAdvance.
107 //through t=120, so that's what we want to track in lastAdvance.
100 this.lastAdvance += advancesToSimulate * this.millisecondsPerAdvance;
108 this.lastAdvance += advancesToSimulate * this.millisecondsPerAdvance;
101 }
109 }
@@ -7,7 +7,7
7 <OutputType>WinExe</OutputType>
7 <OutputType>WinExe</OutputType>
8 <RootNamespace>isometricparkfna</RootNamespace>
8 <RootNamespace>isometricparkfna</RootNamespace>
9 <AssemblyName>isometric-park-fna</AssemblyName>
9 <AssemblyName>isometric-park-fna</AssemblyName>
10 <TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
10 <TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
11 </PropertyGroup>
11 </PropertyGroup>
12 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|anycpu' ">
12 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|anycpu' ">
13 <DebugSymbols>true</DebugSymbols>
13 <DebugSymbols>true</DebugSymbols>
@@ -53,7 +53,7
53 <Name>SpriteFontPlus.FNA</Name>
53 <Name>SpriteFontPlus.FNA</Name>
54 </ProjectReference>
54 </ProjectReference>
55 <ProjectReference Include="..\ImGui.NET\ImGui.NET.csproj">
55 <ProjectReference Include="..\ImGui.NET\ImGui.NET.csproj">
56 <Project>{22ACD385-A146-448C-B82D-0FDB449FB7AD}</Project>
56 <Project>{0023328E-2EFD-448B-BD85-A76769CD106A}</Project>
57 <Name>ImGui.NET</Name>
57 <Name>ImGui.NET</Name>
58 <HintPath>..\packages\ImGui.NET.1.78.0\lib\netstandard2.0\ImGui.NET.dll</HintPath>
58 <HintPath>..\packages\ImGui.NET.1.78.0\lib\netstandard2.0\ImGui.NET.dll</HintPath>
59 </ProjectReference>
59 </ProjectReference>
@@ -118,6 +118,7
118 </ItemGroup>
118 </ItemGroup>
119 <ItemGroup>
119 <ItemGroup>
120 <Reference Include="System" />
120 <Reference Include="System" />
121 <Reference Include="System.Runtime" />
121 <!-- <PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.0" PrivateAssets="All" /> -->
122 <!-- <PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.0" PrivateAssets="All" /> -->
122 <Reference Include="System.Buffers">
123 <Reference Include="System.Buffers">
123 <HintPath>..\packages\System.Buffers.4.4.0\lib\netstandard2.0\System.Buffers.dll</HintPath>
124 <HintPath>..\packages\System.Buffers.4.4.0\lib\netstandard2.0\System.Buffers.dll</HintPath>
@@ -88,7 +88,7
88
88
89 def make_macos(suffix="new"):
89 def make_macos(suffix="new"):
90
90
91 new_name = destination_directory / (macos_template.name[:-4] + "-" + suffix + ".app" + "/")
91 new_name = destination_directory / (macos_template.name[:-13] + "-" + suffix + ".app" + "/")
92
92
93 # shutil.rmtree(new_name)
93 # shutil.rmtree(new_name)
94 shutil.copytree(macos_template, new_name)
94 shutil.copytree(macos_template, new_name)
You need to be logged in to leave comments. Login now