Skip to content

Commit 369f079

Browse files
committed
Changes project to PCL library
1 parent 8c10072 commit 369f079

39 files changed

+135
-413596
lines changed

CollisionGrid.sln

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio 2013
4-
VisualStudioVersion = 12.0.30110.0
3+
# Visual Studio 14
4+
VisualStudioVersion = 14.0.25420.1
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CollisionGrid", "CollisionGrid\CollisionGrid.csproj", "{B055EF56-7264-4723-8B3F-05D1550C331C}"
77
EndProject
@@ -10,17 +10,27 @@ EndProject
1010
Global
1111
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1212
Debug|Any CPU = Debug|Any CPU
13+
Debug|x86 = Debug|x86
1314
Release|Any CPU = Release|Any CPU
15+
Release|x86 = Release|x86
1416
EndGlobalSection
1517
GlobalSection(ProjectConfigurationPlatforms) = postSolution
1618
{B055EF56-7264-4723-8B3F-05D1550C331C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
1719
{B055EF56-7264-4723-8B3F-05D1550C331C}.Debug|Any CPU.Build.0 = Debug|Any CPU
20+
{B055EF56-7264-4723-8B3F-05D1550C331C}.Debug|x86.ActiveCfg = Debug|Any CPU
21+
{B055EF56-7264-4723-8B3F-05D1550C331C}.Debug|x86.Build.0 = Debug|Any CPU
1822
{B055EF56-7264-4723-8B3F-05D1550C331C}.Release|Any CPU.ActiveCfg = Release|Any CPU
1923
{B055EF56-7264-4723-8B3F-05D1550C331C}.Release|Any CPU.Build.0 = Release|Any CPU
24+
{B055EF56-7264-4723-8B3F-05D1550C331C}.Release|x86.ActiveCfg = Release|Any CPU
25+
{B055EF56-7264-4723-8B3F-05D1550C331C}.Release|x86.Build.0 = Release|Any CPU
2026
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
2127
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Debug|Any CPU.Build.0 = Debug|Any CPU
28+
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Debug|x86.ActiveCfg = Debug|Any CPU
29+
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Debug|x86.Build.0 = Debug|Any CPU
2230
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Release|Any CPU.ActiveCfg = Release|Any CPU
2331
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Release|Any CPU.Build.0 = Release|Any CPU
32+
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Release|x86.ActiveCfg = Release|Any CPU
33+
{37B14616-5CCE-4239-BE27-41D25E0718D4}.Release|x86.Build.0 = Release|Any CPU
2434
EndGlobalSection
2535
GlobalSection(SolutionProperties) = preSolution
2636
HideSolutionNode = FALSE

CollisionGrid/CollisionGrid.Rect.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
// For more information, please refer to <http://unlicense.org>
2626
// ***************************************************************************
2727

28+
using MonoGame.Extended;
2829
using MonoGame.Extended.Shapes;
2930

3031
namespace CollisionGrid

CollisionGrid/CollisionGrid.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
using System.Collections.Generic;
2929
using JetBrains.Annotations;
3030
using Microsoft.Xna.Framework;
31+
using MonoGame.Extended;
3132
using MonoGame.Extended.Shapes;
3233

3334
namespace CollisionGrid
@@ -132,8 +133,8 @@ private void RemoveFromGrid(T item, Point cell)
132133

133134
private Rectangle Rectangle(RectangleF rect)
134135
{
135-
Point tl = Cell(rect.Location);
136-
Point br = Cell(rect.Location + rect.Size);
136+
Point tl = Cell(rect.Position);
137+
Point br = Cell(rect.Position + rect.Size);
137138
Point s = br - tl + new Point(1, 1);
138139
return new Rectangle(tl, s);
139140
}

CollisionGrid/CollisionGrid.csproj

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,20 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2+
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
44
<PropertyGroup>
5+
<MinimumVisualStudioVersion>10.0</MinimumVisualStudioVersion>
56
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
67
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
78
<ProjectGuid>{B055EF56-7264-4723-8B3F-05D1550C331C}</ProjectGuid>
89
<OutputType>Library</OutputType>
910
<AppDesignerFolder>Properties</AppDesignerFolder>
1011
<RootNamespace>CollisionGrid</RootNamespace>
1112
<AssemblyName>CollisionGrid</AssemblyName>
12-
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
13+
<DefaultLanguage>en-US</DefaultLanguage>
1314
<FileAlignment>512</FileAlignment>
14-
<TargetFrameworkProfile />
15+
<ProjectTypeGuids>{786C830F-07A1-408B-BD7F-6EE04809D6DB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
16+
<TargetFrameworkProfile>Profile111</TargetFrameworkProfile>
17+
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
1518
</PropertyGroup>
1619
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
1720
<DebugSymbols>true</DebugSymbols>
@@ -21,7 +24,6 @@
2124
<DefineConstants>DEBUG;TRACE</DefineConstants>
2225
<ErrorReport>prompt</ErrorReport>
2326
<WarningLevel>4</WarningLevel>
24-
<Prefer32Bit>false</Prefer32Bit>
2527
</PropertyGroup>
2628
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
2729
<DebugType>pdbonly</DebugType>
@@ -30,28 +32,24 @@
3032
<DefineConstants>TRACE</DefineConstants>
3133
<ErrorReport>prompt</ErrorReport>
3234
<WarningLevel>4</WarningLevel>
33-
<Prefer32Bit>false</Prefer32Bit>
3435
</PropertyGroup>
3536
<ItemGroup>
36-
<Reference Include="JetBrains.Annotations, Version=10.1.4.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325, processorArchitecture=MSIL">
37-
<HintPath>..\packages\JetBrains.Annotations.10.1.4\lib\net20\JetBrains.Annotations.dll</HintPath>
37+
<Reference Include="JetBrains.Annotations, Version=11.1.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325, processorArchitecture=MSIL">
38+
<HintPath>..\packages\JetBrains.Annotations.11.1.0\lib\portable40-net40+sl5+win8+wp8+wpa81\JetBrains.Annotations.dll</HintPath>
3839
<Private>True</Private>
3940
</Reference>
40-
<Reference Include="MonoGame.Extended, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
41-
<HintPath>..\packages\MonoGame.Extended.0.5.149\lib\MonoGame.Extended.dll</HintPath>
41+
<Reference Include="MonoGame.Extended, Version=0.6.602.0, Culture=neutral, processorArchitecture=MSIL">
42+
<HintPath>..\packages\MonoGame.Extended.0.6.602\lib\portable-net45+win8+wpa81\MonoGame.Extended.dll</HintPath>
4243
<Private>True</Private>
4344
</Reference>
44-
<Reference Include="MonoGame.Framework, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
45-
<SpecificVersion>False</SpecificVersion>
46-
<HintPath>..\..\Throbax - MonoGame - 2014\ThrobaxTD\ThrobaxTD\_EXTERNAL_LIBRARIES\MonoGame\MonoGame.Framework.dll</HintPath>
45+
<Reference Include="MonoGame.Framework, Version=3.6.0.1625, Culture=neutral, processorArchitecture=MSIL">
46+
<HintPath>..\packages\MonoGame.Framework.Portable.3.6.0.1625\lib\portable-net45+win8+wpa81\MonoGame.Framework.dll</HintPath>
47+
<Private>True</Private>
48+
</Reference>
49+
<Reference Include="Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
50+
<HintPath>..\packages\Newtonsoft.Json.10.0.3\lib\portable-net45+win8+wp8+wpa81\Newtonsoft.Json.dll</HintPath>
51+
<Private>True</Private>
4752
</Reference>
48-
<Reference Include="System" />
49-
<Reference Include="System.Core" />
50-
<Reference Include="System.Xml.Linq" />
51-
<Reference Include="System.Data.DataSetExtensions" />
52-
<Reference Include="Microsoft.CSharp" />
53-
<Reference Include="System.Data" />
54-
<Reference Include="System.Xml" />
5553
</ItemGroup>
5654
<ItemGroup>
5755
<Compile Include="CollisionGrid.Rect.cs" />
@@ -62,10 +60,11 @@
6260
<Compile Include="Properties\AssemblyInfo.cs" />
6361
</ItemGroup>
6462
<ItemGroup>
63+
<None Include="app.config" />
6564
<None Include="CollisionGrid.nuspec" />
6665
<None Include="packages.config" />
6766
</ItemGroup>
68-
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
67+
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\Portable\$(TargetFrameworkVersion)\Microsoft.Portable.CSharp.targets" />
6968
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
7069
Other similar extension points exist, see Microsoft.Common.targets.
7170
<Target Name="BeforeBuild">

CollisionGrid/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,5 @@
3232
// You can specify all the values or you can default the Build and Revision Numbers
3333
// by using the '*' as shown below:
3434
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.0.0.2")]
36-
[assembly: AssemblyFileVersion("1.0.0.2")]
35+
[assembly: AssemblyVersion("1.1.0.0")]
36+
[assembly: AssemblyFileVersion("1.1.0.0")]

CollisionGrid/app.config

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<configuration>
3+
<runtime>
4+
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
5+
<dependentAssembly>
6+
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
7+
<bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0" />
8+
</dependentAssembly>
9+
</assemblyBinding>
10+
</runtime>
11+
</configuration>

CollisionGrid/packages.config

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="JetBrains.Annotations" version="10.1.4" targetFramework="net45" />
4-
<package id="MonoGame.Extended" version="0.5.149" targetFramework="net45" />
5-
<package id="System.Runtime" version="4.0.20" targetFramework="net461" />
3+
<package id="JetBrains.Annotations" version="11.1.0" targetFramework="portable45-net45+win8+wpa81" />
4+
<package id="MonoGame.Extended" version="0.6.602" targetFramework="portable45-net45+win8+wpa81" />
5+
<package id="Newtonsoft.Json" version="10.0.3" targetFramework="portable45-net45+win8+wpa81" />
6+
<package id="System.Runtime" version="4.3.0" targetFramework="portable45-net45+win8+wpa81" />
67
</packages>

Test/DrawableGrid.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
using CollisionGrid;
3131
using Microsoft.Xna.Framework;
3232
using Microsoft.Xna.Framework.Graphics;
33+
using MonoGame.Extended;
3334
using MonoGame.Extended.Shapes;
3435

3536
namespace Test

Test/Main.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@
2525
// For more information, please refer to <http://unlicense.org>
2626
// ***************************************************************************
2727

28-
using System;
29-
using System.Windows.Forms;
3028
using Microsoft.Xna.Framework;
3129
using Microsoft.Xna.Framework.Graphics;
3230

@@ -50,7 +48,6 @@ public Main()
5048
GraphicsDeviceManager.PreparingDeviceSettings += PrepareDeviceSettings;
5149

5250
Window.AllowUserResizing = true;
53-
Window.Position = Point.Zero;
5451
IsMouseVisible = true;
5552
}
5653

Test/MonoGame.Framework.dll.config

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<configuration>
3+
<dllmap dll="SDL2.dll" os="osx" target="libSDL2-2.0.0.dylib"/>
4+
<dllmap dll="soft_oal.dll" os="osx" target="libopenal.1.dylib" />
5+
<dllmap dll="SDL2.dll" os="linux" cpu="x86" target="./x86/libSDL2-2.0.so.0"/>
6+
<dllmap dll="soft_oal.dll" os="linux" cpu="x86" target="./x86/libopenal.so.1" />
7+
<dllmap dll="SDL2.dll" os="linux" cpu="x86-64" target="./x64/libSDL2-2.0.so.0"/>
8+
<dllmap dll="soft_oal.dll" os="linux" cpu="x86-64" target="./x64/libopenal.so.1" />
9+
</configuration>

0 commit comments

Comments
 (0)