Trying to use this with Hololens [solved]

Hi

Ok. Hm… It’s hard for me to debug this.
Would one of you be willing to join me in a Skype session to try to sort this out?

Sorry i wasn’t Clear enough. I actually get this errors while building to Universal 10 from Unity. So the errors occur in the build process.

Steps to reproduce.
In Build settings
Choose Platform - Windows Store
SDK - Universal 10
Target Device - Hololens ( Mobile will get the same errors)
Build and Run on - Local Machine
Debugging
Unity C# Projects - True

And then Build. This will generate the errors above in the Console in Unity.

i use Version 5.5.0p1

If you still are not able to reproduce i could show you.

Jørn

I’m getting the same issue with building to just plain Universal 10 on a normal Windows 10 desktop. (Non Hololens and Non Mobile) I really hope this is something that can get fixed. Thanks

Hi

For some reason Unity does not want to build a full build for me (still trying to figure out why), but I make a number of fixes (most of them untested however since I cannot do a full build). I have sent a PM to each of you with a download link to a preview version. This is based on the latest beta which also has a number of other changes (some of them breaking). The fixes should be pretty easy to back-port however so if the breaking changes (especially RVO) make it hard for you to test this I can upload a version based on the current release instead.

1 Like

This change should also make it unnecessary to use the ASTAR_NO_ZIP directive. On UWP it should now use System.IO.Compression.ZipArchive. Hopefully it is compatible with the zip spec that DotNetZip uses (I haven’t been able to test).

I tried it real quick and it did build in Unity but threw some warning errors in Unity. "Reference Rewriter found some errors while running with command --target=“Temp\StagingArea\Pathfinding.Ionic.Zip.Reduced.dll” --additionalreferences=“Temp\StagingArea” and a bunch of these “Reference rewriter: Error: method System.Void System.ComponentModel.DescriptionAttribute::.ctor(System.String) doesn’t exist in target framework. It is referenced from Pathfinding.Ionic.Zip.Reduced.dll at Pathfinding.Ionic.ComparisonOperator.
UnityEngine.Debug:LogError(Object)
PostProcessWinRT:RunReferenceRewriter() (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:583)
PostProcessWinRT:Process() (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:126)
UnityEditor.HostView:OnGUI()”

But the Visual Studio project doesn’t build at all. it has an error “The command Unity\Tools\AssemblyConverter.exe” -platform=uap -lock=" and a bunch more dlls exited with code 1.

I only imported the package and tried building. It built and ran fine for the normal Windows build but still getting hung up with the UWP. I could do a skype session with you sometime if you want to send me an email and we could probably figure out a time. Thanks for your help!

Hi

Hm, might be some meta file that wasn’t updated when you imported. That dll should be marked as excluded from all UWP builds. You can select it and mark it as such.

1 Like

That did the trick. Unchecked “Any Platform” on the Pathfinding.Ionic.Zip.Reduced. Thanks so much!

Edit:
Yep. That version exported and worked great as UWP and as Windows Standalone

I did not try the ASTAR_NO_ZIP. It was unchecked when i built everything last night. I’ve only been using it for about a week to see if it would fit my needs so I’m only building Grid Graphs dynamically right now but that all functioned perfectly.

So it works fine in a standalone player now?

Awesome :slight_smile: Were you using the ASTAR_NO_ZIP compiler directive?

I’m running into the same issue. Can you please PM the link with the fix?

me as well, it would be appreciated :wink:

Hi

I have just uploaded a new release (3.8.8) which contains these fixes. It is not the exact same build as was sent in a PM to some users (that was based on the beta branch).

1 Like

Ah you are creating graphs dynamically. Ok then the zip part of the code might still be untested. Hopefully it works.

FYI, there is some unfinished task code, that prevents compile in uwp.
in RecastGenerator.ScanAllTiles - I commented them out on my side.

@twlomega Huh, that code compiled just fine for me. What errors does it give you? And what build settings are you using exactly?

@aron_granberg I tested the new version and it works. Thank you!

1 Like

just building project for hololens.

Specifically the stuff is this:
#if NETFX_CORE
// Need to make a copy here, otherwise it may refer to some other index when the task actually runs
var threadIndex = i;
System.Threading.Tasks.Task.Run(() => BuildTiles(tileQueue, buckets, waitEvents[threadIndex], threadIndex));
#else
#endif

and:
#if NETFX_CORE
var waitEvent = waitEvents[i];
System.Threading.Tasks.Task.Run(() => ConnectTiles(tileQueue, waitEvent, direction == 0, direction == 1));
#else
#endif

the first block is sitting on line 1187, right after “vox.maxEdgeLength = maxEdgeLength;”
which can’t compile because ‘i’ doesn’t even exist there. and secondly, there is only two mentions of “tileQueue” anywhere in the entire code, and it’s just in those two blocks.

maybe there is a mistake between the free and pro version? I haven’t looked at the Free one.

Ah. Found the issue. I had cherry picked a commit from another branch and it didn’t apply cleanly. I have uploaded a new version now which I think should fix the issue (and indeed it only applied to the pro version).