Fix code for VS

This commit is contained in:
2015-12-12 04:14:19 +06:00
parent 7180f6f8db
commit 7c84319132
9 changed files with 149 additions and 119 deletions

View File

@@ -1,2 +1,3 @@
glob:obj/*
glob:Temp/*
glob:Library/*

View File

@@ -3,9 +3,8 @@
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>10.0.20506</ProductVersion>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<RootNamespace></RootNamespace>
<ProjectGuid>{BD090B74-59E6-B8B4-61B5-2814183903F0}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
@@ -34,76 +33,78 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.XML" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="UnityEngine">
<HintPath>/Applications/Unity/Unity.app/Contents/Frameworks/Managed/UnityEngine.dll</HintPath>
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\Frameworks\Managed\UnityEngine.dll</HintPath>
</Reference>
<Reference Include="UnityEditor">
<HintPath>/Applications/Unity/Unity.app/Contents/Frameworks/Managed/UnityEditor.dll</HintPath>
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\Frameworks\Managed\UnityEditor.dll</HintPath>
</Reference>
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Assets\IsoTools\Editor\IsoObjectEditor.cs" />
<Reference Include="UnityEditor.Advertisements">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\Advertisements\Editor\UnityEditor.Advertisements.dll</HintPath>
</Reference>
<Reference Include="nunit.framework">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\EditorTestsRunner\Editor\nunit.framework.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.EditorTestsRunner">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\EditorTestsRunner\Editor\UnityEditor.EditorTestsRunner.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\GUISystem\UnityEngine.UI.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.UI">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\GUISystem\Editor\UnityEditor.UI.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\Networking\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Networking">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\Networking\Editor\UnityEditor.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.TreeEditor">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\TreeEditor\Editor\UnityEditor.TreeEditor.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Graphs">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\Frameworks\Managed\UnityEditor.Graphs.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Android.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\AndroidPlayer\UnityEditor.Android.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.iOS.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\iOSSupport\UnityEditor.iOS.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Tizen.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\TizenPlayer\UnityEditor.Tizen.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.SamsungTV.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\STVPlayer\UnityEditor.SamsungTV.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.WebGL.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\WebGLSupport\UnityEditor.WebGL.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.LinuxStandalone.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\LinuxStandaloneSupport\UnityEditor.LinuxStandalone.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.WindowsStandalone.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\WindowsStandaloneSupport\UnityEditor.WindowsStandalone.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.OSXStandalone.Extensions">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\MacStandaloneSupport\UnityEditor.OSXStandalone.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.iOS.Extensions.Xcode">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\iOSSupport\UnityEditor.iOS.Extensions.Xcode.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Assets\IsoTools\Editor\IsoObjectEditor.cs" />
<Reference Include="UnityEditor.Advertisements">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/Advertisements/Editor/UnityEditor.Advertisements.dll</HintPath>
</Reference>
<Reference Include="nunit.framework">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/EditorTestsRunner/Editor/nunit.framework.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.EditorTestsRunner">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/EditorTestsRunner/Editor/UnityEditor.EditorTestsRunner.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.UI">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/GUISystem/UnityEngine.UI.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.UI">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/GUISystem/Editor/UnityEditor.UI.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/Networking/UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Networking">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/Networking/Editor/UnityEditor.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.TreeEditor">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/TreeEditor/Editor/UnityEditor.TreeEditor.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Graphs">
<HintPath>/Applications/Unity/Unity.app/Contents/Frameworks/Managed/UnityEditor.Graphs.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Android.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/AndroidPlayer/UnityEditor.Android.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.iOS.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/iOSSupport/UnityEditor.iOS.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.Tizen.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/TizenPlayer/UnityEditor.Tizen.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.SamsungTV.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/STVPlayer/UnityEditor.SamsungTV.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.WebGL.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/WebGLSupport/UnityEditor.WebGL.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.LinuxStandalone.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/LinuxStandaloneSupport/UnityEditor.LinuxStandalone.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.WindowsStandalone.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/WindowsStandaloneSupport/UnityEditor.WindowsStandalone.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.OSXStandalone.Extensions">
<HintPath>/Applications/Unity/PlaybackEngines/MacStandaloneSupport/UnityEditor.OSXStandalone.Extensions.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.iOS.Extensions.Xcode">
<HintPath>/Applications/Unity/PlaybackEngines/iOSSupport/UnityEditor.iOS.Extensions.Xcode.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="Assembly-CSharp.csproj">
<Project>{95166F85-0462-AC59-009C-63E7F7F767D5}</Project> <Name>Assembly-CSharp</Name> </ProjectReference>
<Project>{95166F85-0462-AC59-009C-63E7F7F767D5}</Project>
<Name>Assembly-CSharp</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
@@ -113,5 +114,4 @@
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -3,9 +3,8 @@
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>10.0.20506</ProductVersion>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<RootNamespace></RootNamespace>
<ProjectGuid>{95166F85-0462-AC59-009C-63E7F7F767D5}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
@@ -34,46 +33,46 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.XML" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="UnityEngine">
<HintPath>/Applications/Unity/Unity.app/Contents/Frameworks/Managed/UnityEngine.dll</HintPath>
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\Frameworks\Managed\UnityEngine.dll</HintPath>
</Reference>
<Reference Include="UnityEditor">
<HintPath>/Applications/Unity/Unity.app/Contents/Frameworks/Managed/UnityEditor.dll</HintPath>
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\Frameworks\Managed\UnityEditor.dll</HintPath>
</Reference>
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Assets\IsoTools\Examples\Scripts\AlienBallController.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\AlienBallSpawner.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\CircleFly.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\CubeAutoMovement.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\IsoEchoListener.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\PlayerController.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoBoxCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoCollision.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoContactPoint.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoFakeCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoFakeObject.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoFakeRigidbody.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoObject.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoPhysicHelper.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoRaycastHit.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoRigidbody.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoSphereCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoUtils.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoWorld.cs" />
<Reference Include="UnityEngine.UI">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/GUISystem/UnityEngine.UI.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>/Applications/Unity/Unity.app/Contents/UnityExtensions/Unity/Networking/UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.iOS.Extensions.Xcode">
<HintPath>/Applications/Unity/PlaybackEngines/iOSSupport/UnityEditor.iOS.Extensions.Xcode.dll</HintPath>
</Reference>
<Compile Include="Assets\IsoTools\Examples\Scripts\AlienBallController.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\AlienBallSpawner.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\CircleFly.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\CubeAutoMovement.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\IsoEchoListener.cs" />
<Compile Include="Assets\IsoTools\Examples\Scripts\PlayerController.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoBoxCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoCollision.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoContactPoint.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoFakeCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoFakeObject.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoFakeRigidbody.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoObject.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoPhysicHelper.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoRaycastHit.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoRigidbody.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoSphereCollider.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoUtils.cs" />
<Compile Include="Assets\IsoTools\Scripts\IsoWorld.cs" />
<Reference Include="UnityEngine.UI">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\GUISystem\UnityEngine.UI.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.Networking">
<HintPath>..\..\..\..\..\Applications\Unity\Unity.app\Contents\UnityExtensions\Unity\Networking\UnityEngine.Networking.dll</HintPath>
</Reference>
<Reference Include="UnityEditor.iOS.Extensions.Xcode">
<HintPath>..\..\..\..\..\Applications\Unity\PlaybackEngines\iOSSupport\UnityEditor.iOS.Extensions.Xcode.dll</HintPath>
</Reference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
@@ -83,5 +82,4 @@
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -68,7 +68,7 @@ namespace IsoTools {
}
public bool Raycast(Ray ray, out IsoRaycastHit iso_hit_info, float max_distance) {
RaycastHit hit_info;
var hit_info = new RaycastHit();
var result = realCollider
? realCollider.Raycast(ray, out hit_info, max_distance)
: false;

View File

@@ -8,7 +8,7 @@ namespace IsoTools {
public Vector3 point { get; private set; }
public IsoCollider thisCollider { get; private set; }
public IsoContactPoint(ContactPoint contact_point) {
public IsoContactPoint(ContactPoint contact_point) : this() {
normal = contact_point.normal;
otherCollider = IsoUtils.IsoConvertCollider(contact_point.otherCollider);
point = contact_point.point;

View File

@@ -9,7 +9,7 @@ namespace IsoTools {
public Vector3 point { get; private set; }
public IsoRigidbody rigidbody { get; private set; }
public IsoRaycastHit(RaycastHit hit_info) {
public IsoRaycastHit(RaycastHit hit_info) : this() {
collider = IsoUtils.IsoConvertCollider(hit_info.collider);
distance = hit_info.distance;
normal = hit_info.normal;

View File

@@ -235,7 +235,7 @@ namespace IsoTools {
}
public bool SweepTest(Vector3 direction, out IsoRaycastHit iso_hit_info, float max_distance) {
RaycastHit hit_info;
var hit_info = new RaycastHit();
var result = realRigidbody
? realRigidbody.SweepTest(direction, out hit_info, max_distance)
: false;

View File

@@ -1,9 +1,9 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2008
Project("{9D0FFEC9-0383-4C40-DA01-96F3C6394847}") = "unityiso", "Assembly-CSharp.csproj", "{95166F85-0462-AC59-009C-63E7F7F767D5}"
# Visual Studio 2010
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp", "Assembly-CSharp.csproj", "{95166F85-0462-AC59-009C-63E7F7F767D5}"
EndProject
Project("{9D0FFEC9-0383-4C40-DA01-96F3C6394847}") = "unityiso", "Assembly-CSharp-Editor.csproj", "{BD090B74-59E6-B8B4-61B5-2814183903F0}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp-Editor", "Assembly-CSharp-Editor.csproj", "{BD090B74-59E6-B8B4-61B5-2814183903F0}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -20,25 +20,54 @@ Global
{BD090B74-59E6-B8B4-61B5-2814183903F0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{BD090B74-59E6-B8B4-61B5-2814183903F0}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(MonoDevelopProperties) = preSolution
StartupItem = Assembly-CSharp.csproj
GlobalSection(MonoDevelopProperties) = preSolution
Policies = $0
$0.TextStylePolicy = $1
$1.inheritsSet = null
$1.TabsToSpaces = False
$1.NoTabsAfterNonTabs = True
$1.EolMarker = Unix
$1.inheritsSet = VisualStudio
$1.inheritsScope = text/plain
$1.scope = text/x-csharp
$0.CSharpFormattingPolicy = $2
$2.NamespaceBraceStyle = EndOfLine
$2.ClassBraceStyle = EndOfLine
$2.InterfaceBraceStyle = EndOfLine
$2.StructBraceStyle = EndOfLine
$2.EnumBraceStyle = EndOfLine
$2.MethodBraceStyle = EndOfLine
$2.ConstructorBraceStyle = EndOfLine
$2.DestructorBraceStyle = EndOfLine
$2.BeforeMethodDeclarationParentheses = False
$2.BeforeMethodCallParentheses = False
$2.BeforeConstructorDeclarationParentheses = False
$2.BeforeIndexerDeclarationBracket = False
$2.BeforeDelegateDeclarationParentheses = False
$2.NewParentheses = False
$2.WithinIfParentheses = True
$2.WithinWhileParentheses = True
$2.WithinForParentheses = True
$2.WithinForEachParentheses = True
$2.WithinCatchParentheses = True
$2.WithinSwitchParentheses = True
$2.WithinLockParentheses = True
$2.WithinUsingParentheses = True
$2.SpacesBeforeBrackets = False
$2.inheritsSet = Mono
$2.inheritsScope = text/x-csharp
$2.scope = text/x-csharp
$0.TextStylePolicy = $3
$3.FileWidth = 120
$3.TabWidth = 4
$3.TabsToSpaces = False
$3.NoTabsAfterNonTabs = True
$3.EolMarker = Unix
$3.inheritsSet = Mono
$3.inheritsSet = VisualStudio
$3.inheritsScope = text/plain
$3.scope = text/plain
$0.DotNetNamingPolicy = $4
$4.DirectoryNamespaceAssociation = None
$4.ResourceNamePolicy = FileFormatDefault
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

View File

@@ -1,8 +1,10 @@
<Properties>
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
<Properties StartupItem="Assembly-CSharp.csproj">
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" PreferredExecutionTarget="Unity.Instance.Unity Editor" />
<MonoDevelop.Ide.Workbench ActiveDocument="Assets/IsoTools/Scripts/IsoWorld.cs">
<Files>
<File FileName="Assets/IsoTools/Scripts/IsoWorld.cs" Line="575" Column="4" />
<File FileName="Assets/IsoTools/Scripts/IsoWorld.cs" Line="24" Column="24" />
<File FileName="Assets/IsoTools/Scripts/IsoUtils.cs" Line="8" Column="2" />
<File FileName="Assets/IsoTools/Scripts/IsoObject.cs" Line="278" Column="8" />
</Files>
</MonoDevelop.Ide.Workbench>
<MonoDevelop.Ide.DebuggingService.Breakpoints>