playMaker

Author Topic: Build Error Windows Store 10 IL2CPP  (Read 10509 times)

bslayerw

  • Playmaker Newbie
  • *
  • Posts: 1
Build Error Windows Store 10 IL2CPP
« on: May 19, 2017, 08:58:16 PM »
Unity 5.6.1
PlayMaker 1.8.6
UnityException: Failed to run reference rewriter with command --target="Temp\StagingArea\Data\Managed\PlayMaker.dll" --additionalreferences="Temp\StagingArea\Data\Managed","Temp\StagingArea\Data\Managed\Plugins\X86","Temp\StagingArea\Data\Managed\Plugins\ARM","Temp\StagingArea\Data\Managed\Plugins\X64" --platform="C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.15063.0\Facade\Windows.winmd" --dbg=pdb --framework="Temp\StagingArea\Data\Managed" --alt=Microsoft.Win32.SafeHandles,mscorlib;System,mscorlib;System,System;System,System.Core;System.CodeDom.Compiler,System;System.Collections,mscorlib;System.Collections.Generic,mscorlib;System.Collections.Generic,System;System.Collections.Generic,System.Core;System.Collections.ObjectModel,mscorlib;System.Collections.Specialized,System;System.ComponentModel,System;System.Data,System.Data;System.Data.Common,System.Data;System.Diagnostics,mscorlib;System.Diagnostics,System;System.Diagnostics.CodeAnalysis,mscorlib;System.Globalization,mscorlib;System.IO,mscorlib;System.IO.Compression,System;System.IO.IsolatedStorage,mscorlib;System.Linq,System.Core;System.Linq.Expressions,System.Core;System.Net,System;System.Net.NetworkInformation,System;System.Net.Security,System;System.Net.Sockets,System;System.Reflection,mscorlib;System.Reflection.Emit,mscorlib;System.Resources,mscorlib;System.Runtime,mscorlib;System.Runtime.CompilerServices,mscorlib;System.Runtime.CompilerServices,System.Core;System.Runtime.InteropServices,mscorlib;System.Runtime.InteropServices.ComTypes,mscorlib;System.Runtime.Serialization,mscorlib;System.Runtime.Serialization,System.Runtime.Serialization;System.Runtime.Serialization.Json,System.ServiceModel.Web;System.Security,mscorlib;System.Security.Authentication,System;System.Security.Principal,mscorlib;System.ServiceModel,System.ServiceModel;System.ServiceModel.Channels,System.ServiceModel;System.ServiceModel.Description,System.ServiceModel;System.ServiceModel.Dispatcher,System.ServiceModel;System.ServiceModel.Security,System.ServiceModel;System.Text,mscorlib;System.Text.RegularExpressions,System;System.Threading,mscorlib;System.Threading,System;System.Threading,System.Core;System.Xml,System.Runtime.Serialization;System.Xml,System.Xml;System.Xml.Linq,System.Xml.Linq;System.Xml.Schema,System.Xml;System.Xml.Serialization,System.Xml --ignore=System.IConvertible,mscorlib.
Error: type `System.Reflection.TypeInfo` doesn't exist in target framework. It is referenced from PlayMaker.dll at System.Void HutongGames.PlayMaker.ActionData::LoadActionField(HutongGames.PlayMaker.Fsm,System.Object,System.Reflection.FieldInfo,System.Int32).

Error: type `System.Reflection.TypeInfo` doesn't exist in target framework. It is referenced from PlayMaker.dll at System.Void HutongGames.PlayMaker.ActionData::LoadActionField(HutongGames.PlayMaker.Fsm,System.Object,System.Reflection.FieldInfo,System.Int32).

Error: type `System.Reflection.TypeInfo` doesn't exist in target framework. It is referenced from PlayMaker.dll at System.Void HutongGames.PlayMaker.ActionData::LoadActionField(HutongGames.PlayMaker.Fsm,System.Object,System.Reflection.FieldInfo,System.Int32).

Error: type `System.Reflection.TypeInfo` doesn't exist in target framework. It is referenced from PlayMaker.dll at System.Void HutongGames.PlayMaker.ActionData::LoadActionField(HutongGames.PlayMaker.Fsm,System.Object,System.Reflection.FieldInfo,System.Int32).

Catastrophic failure while running rrw: Mono.Cecil.AssemblyResolutionException: Failed to resolve assembly: 'System.Reflection, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

   at Unity.SearchPathAssemblyResolver.Resolve(AssemblyNameReference name, ReaderParameters parameters)

   at Unity.SearchPathAssemblyResolver.Resolve(AssemblyNameReference name)

   at Mono.Cecil.MetadataResolver.Resolve(TypeReference type) in C:\buildslave\cecil\build\Mono.Cecil\MetadataResolver.cs:line 106

   at Mono.Cecil.MetadataResolver.Resolve(MethodReference method) in C:\buildslave\cecil\build\Mono.Cecil\MetadataResolver.cs:line 216

   at Mono.Cecil.MethodReference.Resolve() in C:\buildslave\cecil\build\Mono.Cecil\MethodReference.cs:line 170

   at Unity.ReferenceRewriter.RewriteTypeReferences.Visit(MethodReference method, String referencingEntityName)

   at Unity.ReferenceRewriter.ReferenceDispatcher.Visit(MethodReference method, String referencingEntityName)

   at Unity.ReferenceRewriter.ReferenceDispatcher.DispatchMethodBody(MethodBody body)

   at Unity.ReferenceRewriter.ReferenceDispatcher.DispatchMethod(MethodDefinition method)

   at Unity.ReferenceRewriter.ReferenceDispatcher.DispatchMethods(TypeDefinition type)

   at Unity.ReferenceRewriter.ReferenceDispatcher.Dispatch()

   at Unity.ReferenceRewriter.RewriteTypeReferences.Run()

   at Unity.ReferenceRewriter.RewriteOperation.Execute(RewriteContext context)

   at Unity.ReferenceRewriter.Program.Main(String[] args)

PostProcessWinRT.RunReferenceRewriter () (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:615)
PostProcessWinRT.Process () (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:170)
UnityEditor.WSA.BuildPostprocessor.DoPostProcess (BuildPostProcessArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:155)
UnityEditor.WSA.BuildPostprocessor.PostProcess (BuildPostProcessArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:162)
UnityEditor.HostView:OnGUI()

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 4005
  • Official Playmaker Support
    • LinkedIn
Re: Build Error Windows Store 10 IL2CPP
« Reply #1 on: May 19, 2017, 09:40:50 PM »
The currently released version of Playmaker is 1.8.4 (not 1.8.6)
Please submit a bug report so we can get more system info.

christougher

  • Playmaker Newbie
  • *
  • Posts: 36
Re: Build Error Windows Store 10 IL2CPP
« Reply #2 on: June 04, 2017, 12:32:41 PM »
Exact same error, built on Unity 5.6.1 and Playmaker 1.8.4.  Recreated it by simply making a new project, importing playmaker and building with an empty scene.  IL2CPP backend on the Windows Universal 10 SDK. Bug report submitted.

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 4005
  • Official Playmaker Support
    • LinkedIn
Re: Build Error Windows Store 10 IL2CPP
« Reply #3 on: June 04, 2017, 03:56:32 PM »
Sorry about that, it seems the standard Windows Store dll is not compatible with IL2CPP. Instead you can use the WebGL dll which is IL2CPP compatible.

I've attached a couple of screen captures that show how to setup the plugin settings.
  • Remove the IL2CPP scripting backend from Plugins\PlayMaker\Metro\Playmaker
  • Add the WSA IL2CPP scripting backend to Playins\PlayMaker\WebGL\Playmaker
Make sure you hit Apply after making changes. I also find it a good idea to reload the project after changing plugin settings.

Let me know if you run into any problems!
« Last Edit: June 04, 2017, 04:03:45 PM by Alex Chouls »