Skip to content

Commit 3856ea5

Browse files
committed
Changes MGFSM to PCL
Updates README.md Updates Test game
1 parent 16a00a4 commit 3856ea5

File tree

10 files changed

+50
-71
lines changed

10 files changed

+50
-71
lines changed

MonoGameStateMachine/MonoGameStateMachine.csproj

Lines changed: 24 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,68 +1,44 @@
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">
3+
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
34
<PropertyGroup>
5+
<MinimumVisualStudioVersion>10.0</MinimumVisualStudioVersion>
46
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
5-
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
6-
<ProductVersion>8.0.30703</ProductVersion>
7-
<SchemaVersion>2.0</SchemaVersion>
8-
<ProjectGuid>{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}</ProjectGuid>
7+
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
8+
9+
10+
<ProjectGuid>{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}</ProjectGuid>
911
<OutputType>Library</OutputType>
1012
<AppDesignerFolder>Properties</AppDesignerFolder>
1113
<RootNamespace>MonoGameStateMachine</RootNamespace>
1214
<AssemblyName>MonoGameStateMachine</AssemblyName>
15+
<DefaultLanguage>en-US</DefaultLanguage>
1316
<FileAlignment>512</FileAlignment>
14-
<MonoGamePlatform>Windows</MonoGamePlatform>
15-
<TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
16-
<TargetFrameworkProfile />
17+
<ProjectTypeGuids>{786C830F-07A1-408B-BD7F-6EE04809D6DB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
18+
<TargetFrameworkProfile>Profile111</TargetFrameworkProfile>
19+
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
20+
1721
</PropertyGroup>
18-
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
22+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
1923
<PlatformTarget>AnyCPU</PlatformTarget>
2024
<DebugSymbols>true</DebugSymbols>
2125
<DebugType>full</DebugType>
2226
<Optimize>false</Optimize>
23-
<OutputPath>bin\$(MonoGamePlatform)\$(Platform)\$(Configuration)\</OutputPath>
24-
<DefineConstants>DEBUG;TRACE;WINDOWS</DefineConstants>
27+
<OutputPath>bin\Debug\</OutputPath>
28+
<DefineConstants>DEBUG;TRACE</DefineConstants>
2529
<ErrorReport>prompt</ErrorReport>
2630
<WarningLevel>4</WarningLevel>
2731
</PropertyGroup>
28-
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
29-
<PlatformTarget>x86</PlatformTarget>
32+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
3033
<DebugType>pdbonly</DebugType>
3134
<Optimize>true</Optimize>
32-
<OutputPath>bin\$(MonoGamePlatform)\$(Platform)\$(Configuration)\</OutputPath>
33-
<DefineConstants>TRACE;WINDOWS</DefineConstants>
34-
<ErrorReport>prompt</ErrorReport>
35-
<WarningLevel>4</WarningLevel>
36-
</PropertyGroup>
37-
<PropertyGroup>
38-
<ApplicationIcon>
39-
</ApplicationIcon>
40-
</PropertyGroup>
41-
<PropertyGroup />
42-
<PropertyGroup>
43-
<StartupObject>
44-
</StartupObject>
45-
</PropertyGroup>
46-
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'">
47-
<DebugSymbols>true</DebugSymbols>
48-
<OutputPath>bin\Windows\x86\Debug\</OutputPath>
49-
<DefineConstants>DEBUG;TRACE;WINDOWS</DefineConstants>
50-
<DebugType>full</DebugType>
51-
<PlatformTarget>AnyCPU</PlatformTarget>
52-
<ErrorReport>prompt</ErrorReport>
53-
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
54-
<Prefer32Bit>false</Prefer32Bit>
55-
</PropertyGroup>
56-
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|AnyCPU'">
5735
<OutputPath>bin\Release\</OutputPath>
58-
<DefineConstants>TRACE;WINDOWS</DefineConstants>
59-
<Optimize>true</Optimize>
60-
<DebugType>pdbonly</DebugType>
61-
<PlatformTarget>AnyCPU</PlatformTarget>
36+
37+
<DefineConstants>TRACE</DefineConstants>
6238
<ErrorReport>prompt</ErrorReport>
63-
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
64-
<Prefer32Bit>true</Prefer32Bit>
39+
<WarningLevel>4</WarningLevel>
6540
</PropertyGroup>
41+
6642
<ItemGroup>
6743
<Compile Include="Api\BuilderFluent.cs" />
6844
<Compile Include="Api\FluentImplementation.cs" />
@@ -79,8 +55,9 @@
7955
<Compile Include="Api\TransitionFluent.cs" />
8056
</ItemGroup>
8157
<ItemGroup>
82-
<Reference Include="JetBrains.Annotations">
83-
<HintPath>..\packages\JetBrains.Annotations.11.0.0\lib\net20\JetBrains.Annotations.dll</HintPath>
58+
<Reference Include="JetBrains.Annotations, Version=11.1.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325, processorArchitecture=MSIL">
59+
<HintPath>..\packages\JetBrains.Annotations.11.1.0\lib\net20\JetBrains.Annotations.dll</HintPath>
60+
<Private>True</Private>
8461
</Reference>
8562
<Reference Include="MonoGame.Framework">
8663
<HintPath>$(MonoGameInstallDirectory)\MonoGame\v3.0\Assemblies\Windows\MonoGame.Framework.dll</HintPath>
@@ -93,8 +70,6 @@
9370
<HintPath>..\packages\StateMachine.1.1.1.3\lib\net451\StateMachine.dll</HintPath>
9471
<Private>True</Private>
9572
</Reference>
96-
<Reference Include="System" />
97-
<Reference Include="System.Xml" />
9873
</ItemGroup>
9974
<ItemGroup>
10075
<None Include="app.config" />
@@ -103,7 +78,7 @@
10378
<ItemGroup>
10479
<Service Include="{82A7F48D-3B50-4B1E-B82E-3ADA8210C358}" />
10580
</ItemGroup>
106-
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
81+
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\Portable\$(TargetFrameworkVersion)\Microsoft.Portable.CSharp.targets" />
10782
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
10883
Other similar extension points exist, see Microsoft.Common.targets.
10984
<Target Name="BeforeBuild">

MonoGameStateMachine/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.8.3")]
36-
[assembly: AssemblyFileVersion("1.0.8.3")]
35+
[assembly: AssemblyVersion("1.0.9.0")]
36+
[assembly: AssemblyFileVersion("1.0.9.0")]
Lines changed: 2 additions & 1 deletion
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="11.0.0" targetFramework="net451" />
3+
<package id="JetBrains.Annotations" version="11.1.0" targetFramework="net451" />
4+
<package id="MonoGame.Framework.Portable" version="3.6.0.1625" targetFramework="net451" />
45
<package id="NUnit" version="3.8.1" targetFramework="net451" />
56
<package id="StateMachine" version="1.1.1.3" targetFramework="net451" />
67
</packages>

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
# Finite-State-Machine
1010

11-
This project implements a Finite-State-Machine (FSM) designed to be used in games.
11+
This project provides a Finite-State-Machine (FSM) designed to be used in games.
1212

1313
Furthermore it implements even a Stack-Based-FSM (SBFSM). So you may tell it to 'continue with the last state before the active one'.
1414

@@ -25,7 +25,9 @@ Nice if you want to use it outside of MonoGame.
2525

2626
#### ![Icon](https://github.com/UnterrainerInformatik/FiniteStateMachine/raw/master/MonoGameStateMachine/icon.png)MonoGameStateMachine
2727

28-
Includes a reference to MonoGame so that it can use MonoGame's `GameTime` structure.It is a mandatory parameter when calling `Update` in this implementation and so it can add the `After()` feature to transitions like so:
28+
This is a PCL (portable code library) so you should be able to use it in any MG project.
29+
30+
Includes a reference to MonoGame so that it can use MonoGame's `GameTime` structure. It is a mandatory parameter when calling `Update` in this implementation and so it can add the `After()` feature to transitions like so:
2931

3032
````c#
3133
Fsm<State, Trigger>.Builder(State.STANDING)

StateMachine.sln

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,12 @@ Global
3434
{B44CDDAE-3BA6-4BE2-8A42-12576CB4EFCE}.Release|x86.Build.0 = Release|Any CPU
3535
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
3636
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Debug|Any CPU.Build.0 = Debug|Any CPU
37-
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Debug|x86.ActiveCfg = Debug|x86
38-
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Debug|x86.Build.0 = Debug|x86
39-
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Release|Any CPU.ActiveCfg = Release|x86
40-
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Release|x86.ActiveCfg = Release|x86
41-
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Release|x86.Build.0 = Release|x86
37+
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Debug|x86.ActiveCfg = Debug|Any CPU
38+
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Debug|x86.Build.0 = Debug|Any CPU
39+
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Release|Any CPU.ActiveCfg = Release|Any CPU
40+
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Release|Any CPU.Build.0 = Release|Any CPU
41+
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Release|x86.ActiveCfg = Release|Any CPU
42+
{A1AD3096-CCDB-4B43-9104-295B7F59F3D3}.Release|x86.Build.0 = Release|Any CPU
4243
EndGlobalSection
4344
GlobalSection(SolutionProperties) = preSolution
4445
HideSolutionNode = FALSE

StateMachine/StateMachine.csproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
<WarningLevel>4</WarningLevel>
3131
</PropertyGroup>
3232
<ItemGroup>
33-
<Reference Include="JetBrains.Annotations, Version=11.0.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325, processorArchitecture=MSIL">
34-
<SpecificVersion>False</SpecificVersion>
35-
<HintPath>..\packages\JetBrains.Annotations.11.0.0\lib\net20\JetBrains.Annotations.dll</HintPath>
33+
<Reference Include="JetBrains.Annotations, Version=11.1.0.0, Culture=neutral, PublicKeyToken=1010a0d8d6380325, processorArchitecture=MSIL">
34+
<HintPath>..\packages\JetBrains.Annotations.11.1.0\lib\net20\JetBrains.Annotations.dll</HintPath>
35+
<Private>True</Private>
3636
</Reference>
3737
<Reference Include="nunit.framework, Version=3.8.1.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
3838
<HintPath>..\packages\NUnit.3.8.1\lib\net45\nunit.framework.dll</HintPath>

StateMachine/packages.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="JetBrains.Annotations" version="11.0.0" targetFramework="net451" />
3+
<package id="JetBrains.Annotations" version="11.1.0" targetFramework="net451" />
44
<package id="NUnit" version="3.8.1" targetFramework="net451" />
55
</packages>

TestGame/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.8.3")]
36-
[assembly: AssemblyFileVersion("1.0.8.3")]
35+
[assembly: AssemblyVersion("1.0.9.0")]
36+
[assembly: AssemblyFileVersion("1.0.9.0")]

TestGame/TestGame.csproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@
4747
<Compile Include="Properties\AssemblyInfo.cs" />
4848
</ItemGroup>
4949
<ItemGroup>
50-
<Reference Include="MonoGame.Extended, Version=0.6.568.0, Culture=neutral, processorArchitecture=MSIL">
51-
<HintPath>..\packages\MonoGame.Extended.0.6.568\lib\portable-net45+win8+wpa81\MonoGame.Extended.dll</HintPath>
50+
<Reference Include="MonoGame.Extended, Version=0.6.602.0, Culture=neutral, processorArchitecture=MSIL">
51+
<HintPath>..\packages\MonoGame.Extended.0.6.602\lib\portable-net45+win8+wpa81\MonoGame.Extended.dll</HintPath>
5252
<Private>True</Private>
5353
</Reference>
54-
<Reference Include="MonoGame.Extended.Animations, Version=0.6.568.0, Culture=neutral, processorArchitecture=MSIL">
55-
<HintPath>..\packages\MonoGame.Extended.Animations.0.6.568\lib\portable-net45+win8+wpa81\MonoGame.Extended.Animations.dll</HintPath>
54+
<Reference Include="MonoGame.Extended.Animations, Version=0.6.602.0, Culture=neutral, processorArchitecture=MSIL">
55+
<HintPath>..\packages\MonoGame.Extended.Animations.0.6.602\lib\portable-net45+win8+wpa81\MonoGame.Extended.Animations.dll</HintPath>
5656
<Private>True</Private>
5757
</Reference>
5858
<Reference Include="MonoGame.Framework">

TestGame/packages.config

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="MonoGame.Extended" version="0.6.568" targetFramework="net45" />
4-
<package id="MonoGame.Extended.Animations" version="0.6.568" targetFramework="net45" />
3+
<package id="MonoGame.Extended" version="0.6.602" targetFramework="net451" />
4+
<package id="MonoGame.Extended.Animations" version="0.6.602" targetFramework="net451" />
55
<package id="Newtonsoft.Json" version="10.0.3" targetFramework="net45" />
66
</packages>

0 commit comments

Comments
 (0)