Porting from Xenko 1.10 to Xenko 2.0 : Invalid command line switch for "al.exe"


#1

Hello,
I’m porting my project from Xeno 1.10 to Xenko 2.0
When I open my project with Xenko 2, I get this warning which looks normal:
Dependency to Xenko must be upgraded from version 1.10.0-alpha01 to 2.0.4.1
Then in the console I get lots of warnings (which I can provide if necessary) but the project can be opened in Xenko studio.

Then I compile the problem and get following error:

[C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(3439,5)]: Error: Invalid command line switch for “al.exe”. .NET Framework version “9999” is not supported. Please specify a value from the enumeration Microsoft.Build.Utilities.TargetDotNetFrameworkVersion.

This errior is not shwoing when compiling with Xenko 1.10
What to do?

Mat


#2

This issue seems to be in one of Visual Studio files. Possible fix includes reinstalling Visual Studio (choose “repair” in Visual Studio Installer") and making sure you have all the dependencies (like .Net 4.6.2 SDK). I never encountered this issue to be honest.


#3

“Repairing” did not work, then did a complete reinstall of Windows 10 / Visual studio 2017 / Xenko on another computer. Still exactly same problem.
So as the problem is same on multiple environments I conclude the problem (or part of) is inside the project itself (.xkpkg formatting, …)
Note that my project is “old”, I am a early Xenko adopter, so my .xkpkg already suffered a dozen of upgrade. I wonder if it does contain very old tags that are too obsolet now… Just guessing…
Really don’t know how to get out this situation. What could I check now? Or could somebody @Xenko have a look at my project?

Thanks

More details : Here is loading console log. See also the warning “Could not deserialize” for each of my scripts.
Verbose: Loading Assets from Package [Xenko.xkpkg]
[C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(3503,5)]: Error: Invalid command line switch for “al.exe”. .NET Framework version “9999” is not supported. Please specify a value from the enumeration Microsoft.Build.Utilities.TargetDotNetFrameworkVersion.
Error: Unable to build assembly reference [C:\yds\Ocean7\Ocean7\Bin\Windows\Debug\Ocean7.Game.dll]
Verbose: Loading Assets from Package [Ocean7.xkpkg]
MainScene(33,55): Warning: Could not deserialize object of type !Ocean7.Scripts.PinLocationScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 32, Col: 54, Chr: 1386) - (Lin: 33, Col: 24, Chr: 1457): Unable to resolve tag [!Ocean7.Scripts.PinLocationScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(46,55): Warning: Could not deserialize object of type !Ocean7.Scripts.LegendScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 45, Col: 54, Chr: 2187) - (Lin: 46, Col: 24, Chr: 2253): Unable to resolve tag [!Ocean7.Scripts.LegendScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(62,55): Warning: Could not deserialize object of type !Ocean7.Scripts.BlackFaderScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 61, Col: 54, Chr: 3184) - (Lin: 62, Col: 24, Chr: 3254): Unable to resolve tag [!Ocean7.Scripts.BlackFaderScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(75,55): Warning: Could not deserialize object of type !Ocean7.Scripts.LandMapScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 74, Col: 54, Chr: 3981) - (Lin: 75, Col: 24, Chr: 4048): Unable to resolve tag [!Ocean7.Scripts.LandMapScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(87,55): Warning: Could not deserialize object of type !Ocean7.Scripts.LogScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 86, Col: 54, Chr: 4646) - (Lin: 87, Col: 24, Chr: 4709): Unable to resolve tag [!Ocean7.Scripts.LogScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(100,55): Warning: Could not deserialize object of type !Ocean7.Scripts.StormTrackScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 99, Col: 54, Chr: 5428) - (Lin: 100, Col: 24, Chr: 5498): Unable to resolve tag [!Ocean7.Scripts.StormTrackScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(123,55): Warning: Could not deserialize object of type !Ocean7.Scripts.WindScript2,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 122, Col: 54, Chr: 6971) - (Lin: 123, Col: 24, Chr: 7036): Unable to resolve tag [!Ocean7.Scripts.WindScript2,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(139,55): Warning: Could not deserialize object of type !Yadusurf.Maps.WavesScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 138, Col: 54, Chr: 8064) - (Lin: 139, Col: 24, Chr: 8128): Unable to resolve tag [!Yadusurf.Maps.WavesScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(160,55): Warning: Could not deserialize object of type !Ocean7.Scripts.DebugScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 159, Col: 54, Chr: 9348) - (Lin: 160, Col: 24, Chr: 9413): Unable to resolve tag [!Ocean7.Scripts.DebugScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(181,55): Warning: Could not deserialize object of type !Ocean7.Scripts.PlayPauseScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 180, Col: 54, Chr: 10689) - (Lin: 181, Col: 24, Chr: 10758): Unable to resolve tag [!Ocean7.Scripts.PlayPauseScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(200,55): Warning: Could not deserialize object of type !Yadusurf.Maps.Ui.SceneScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 199, Col: 54, Chr: 11895) - (Lin: 200, Col: 24, Chr: 11962): Unable to resolve tag [!Yadusurf.Maps.Ui.SceneScript,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(215,55): Warning: Could not deserialize object of type !Ocean7.Scripts.WavesToScreenScript2,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 214, Col: 54, Chr: 12881) - (Lin: 215, Col: 24, Chr: 12955): Unable to resolve tag [!Ocean7.Scripts.WavesToScreenScript2,Ocean7.Game] to type from tag resolution or registered assemblies
MainScene(236,55): Warning: Could not deserialize object of type !Yadusurf.Maps.Scripts.WaiterScript,Ocean7.Game; replacing it with an object implementing IUnloadable:
(Lin: 235, Col: 54, Chr: 14146) - (Lin: 236, Col: 24, Chr: 14219): Unable to resolve tag [!Yadusurf.Maps.Scripts.WaiterScript,Ocean7.Game] to type from tag resolution or registered assemblies

After that, project is opened in Xenko studio.
But when I select one of of my scripts in left panel, property grid panel indicates “Error : Unable to load this object” with this description:
!CopyPasteData
Data: !Ocean7.Scripts.WavesToScreenScript2,Ocean7.Game
GradientTexture: e78dc2fd-8f74-46e1-bb5e-b115acaf0dea/7c362989-3f1b-4a51-abfb-a06977a1e236:shadowedgradient_b80
_MapData: null
WhiteTexture: 29aa410c-5170-4cf5-830d-7e9989c9161e/122b4733-63f9-455f-94fe-086bdc78ee04:Pixel4x4
MergeOutput: null
ProjectionOutput: null
ShadowOutput: null
ProjectionShadowOutput: null
Imposter: null
WaveHeightConversionMapBGRA: null
Id: ee657cc6-91be-42e2-bc29-1c3bb0d245ec
SourceId: 81f9a1b7-9c3d-4d87-a413-438e856942f1
IsRootObjectReference: false


#4

One thing for sure is that some API changed between the version so some scripts not compiling is expected. I would start with that. Once all the scripts compile, reloading the assembly (or in the worst case reloading the whole project) should fix the entities with “unloadable” components.

The “al.exe” issue is weirder but as you said, maybe you are carrying some old parameters of configuration from previous versions of Xenko in the .csproj files (or else). I sent you a PM on this subject.

If we can’t fix your issue, how long do you think you would need to create a new project and copy over all files/scrips/assets?


#5

The strange thing is that, the projects compiles & runs with VS2017 under target Windows. But scripts using shaders (maybe more) don’t show.

OK