So I just spent the better part of 4 days chasing down compiler errors to build my project to windows (trying all three of these: Windows Phone 8.1, Universal 8.1 and Universal 10. After chasing down build error after error just to reveal a few more build time errors it FINALLY made it to the very end, even going so far as to open up the profiler when I tried to build and run (yes I’ve done both, just build and build/run to same results). So it finishes building and throws another 250 build errors all of which are referencing one dll or another:
Here is the main error:
Reference Rewriter found some errors while running with command --target="Temp\StagingArea\Turret 360.Windows\RAIN.dll" --additionalreferences="Temp\StagingArea\Turret 360.Windows" --platform="C:\Program Files (x86)\Windows Kits\8.1\References\CommonConfiguration\Neutral\Windows.winmd" --support="Temp\StagingArea\Turret 360.Windows\WinRTLegacy.dll" --supportpartialns=Unity.Partial --system=System --dbg=pdb --framework="C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETCore\v4.5.1" --alt=System.Xml.Serialization --ignore=System.IConvertible,mscorlib.
Error: method `System.Reflection.Assembly System.Type::get_Assembly()` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINAction RAIN.Action.RAINAction::LoadActionInstance(System.String,System.String,System.Reflection.Assembly).
Error: method `System.Reflection.Assembly System.Type::get_Assembly()` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINAction RAIN.Action.RAINAction::LoadActionInstance(System.String,System.String,System.Reflection.Assembly).
Error: method `System.Object System.Reflection.Assembly::CreateInstance(System.String)` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINAction RAIN.Action.RAINAction::LoadActionInstance(System.String,System.String,System.Reflection.Assembly).
Error: method `System.Object System.Reflection.Assembly::CreateInstance(System.String)` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINAction RAIN.Action.RAINAction::LoadActionInstance(System.Reflection.Assembly,System.String).
Error: method `System.Object System.Reflection.Assembly::CreateInstance(System.String)` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINAction RAIN.Action.RAINAction::LoadActionInstance(System.Reflection.Assembly,System.String).
Error: method `System.Reflection.Assembly System.Type::get_Assembly()` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINDecision RAIN.Action.RAINDecision::LoadDecisionInstance(System.String,System.String).
Error: method `System.Reflection.Assembly System.Type::get_Assembly()` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINDecision RAIN.Action.RAINDecision::LoadDecisionInstance(System.Reflection.Assembly,System.String).
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Animation.BasicAnimator/BasicAnimatorState>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Animation.BasicAnimator/BasicAnimatorState> RAIN.Animation.BasicAnimator::get_AnimationStates().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Animation.MecanimAnimator/MecanimAnimatorState>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Animation.MecanimAnimator/MecanimAnimatorState> RAIN.Animation.MecanimAnimator::get_AnimationStates().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Entities.Aspects.RAINAspect>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Entities.Aspects.RAINAspect> RAIN.Perception.Sensors.PhysicalSensor::get_Matches().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Core.CustomAIElement>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Core.CustomAIElement> RAIN.Core.AI::get_CustomElements().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Motion.MecanimMotor/MotorParameter>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Motion.MecanimMotor/MotorParameter> RAIN.Motion.MecanimMotor::get_ForwardedParameters().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Navigation.Targets.NavigationTarget>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Navigation.Targets.NavigationTarget> RAIN.Navigation.NavigationManager::get_NavigationTargets().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Navigation.Waypoints.WaypointSet>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Navigation.Waypoints.WaypointSet> RAIN.Navigation.NavigationManager::get_WaypointSets().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Navigation.Graph.RAINNavigationGraph>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Navigation.Graph.RAINNavigationGraph> RAIN.Navigation.NavigationManager::get_NavigationGraphs().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Navigation.NavMesh.NavMeshPathGraph>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Navigation.NavMesh.NavMeshPathGraph> RAIN.Navigation.NavigationManager::get_NavMeshGraphs().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<RAIN.Navigation.Graph.RAINNavigationGraph>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<RAIN.Navigation.Graph.RAINNavigationGraph> RAIN.Navigation.NavigationManager::get_CustomGraphs().
Error: method `System.Collections.ObjectModel.ReadOnlyCollection`1<!0> System.Collections.Generic.List`1<System.String>::AsReadOnly()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Collections.Generic.IList`1<System.String> RAIN.Navigation.NavMesh.NavMesh::get_GraphTags().
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.NavMesh::CreateAllContours().
Error: method `System.Void System.Threading.Thread::Sleep(System.Int32)` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.NavMesh::CreateAllContours().
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Navigation.NavMesh.RecastProcess.ContourCreator.
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Boolean RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::get_Asynchronous().
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Boolean RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::get_Asynchronous().
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.ThreadStart` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: method `System.Void System.Threading.ThreadStart::.ctor(System.Object,System.IntPtr)` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.ThreadStart` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: method `System.Void System.Threading.Thread::.ctor(System.Threading.ThreadStart)` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: method `System.Void System.Threading.Thread::Start()` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::.ctor(UnityEngine.Matrix4x4,UnityEngine.Vector3,UnityEngine.Vector3,UnityEngine.Transform,UnityEngine.LayerMask,System.Collections.Generic.List`1<System.String>,System.Collections.Generic.List`1<System.String>,System.Single,System.Single,System.Int32,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Single,System.Int32).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Boolean RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::CreateContours(System.Collections.Generic.List`1<RAIN.Navigation.NavMesh.RecastNodes.PolyMeshData>&).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Boolean RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::CreateContours(System.Collections.Generic.List`1<RAIN.Navigation.NavMesh.RecastNodes.PolyMeshData>&).
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void RAIN.Navigation.NavMesh.RecastProcess.ContourCreator::CancelCreatingContours().
Error: type `System.Threading.Thread` doesn't exist in target framework. It is referenced from RAIN.dll at System.Void
and one of the many similar errors
Reference rewriter: Error: method `System.Object System.Reflection.Assembly::CreateInstance(System.String)` doesn't exist in target framework. It is referenced from RAIN.dll at RAIN.Action.RAINAction RAIN.Action.RAINAction::LoadActionInstance(System.String,System.String,System.Reflection.Assembly).
UnityEngine.Debug:LogError(Object)
PostProcessWinRT:RunReferenceRewriter() (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:591)
PostProcessUniversal81:RunReferenceRewriter() (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/PostProcessUniversal81.cs:123)
PostProcessWinRT:Process() (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:126)
PostProcessUniversal81:Process() (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/PostProcessUniversal81.cs:42)
UnityEditor.HostView:OnGUI()
I updated my project from 5.1.4 a while ago and just got around to testing the windows builds. In 5.1.4 most of these dll’s were already present and built just fine on my test device (Windows phone 8.1) with MINIMAL effort. I’m now using Unity 5.3.6f1, with the Windows store module with both backends (.net and ilc2pp) and Visual Studio 2015 with all the SDK’s. ilc2pp doesn’t hardly start to compile without throwing errors. .net now finishes and then throws the Reference rewriter errors. What can I do? These are DLL’s from asset store purchases, many of which build fine in the older Windows Phone build…