Jump to content
PsychicParrot

Few issues with building for xbox one UWP

Recommended Posts

Ello! It's my first post to the forum! How exciting!

I'm trying to build from Unity 2017 1.2f1 to Xbox One Creators Club (UWP) and I'm hitting a few issues having ProBuilder in my project :(  .. I just downloaded ProBuilder 2 days ago - version 2.9.8f3. Oh, incase it matters I'm using Win10 Creator's Club Edition or whatever the heck they're calling it. The latest.

First up, I was getting errors that seemed to be coming from Poly2Tri.dll so I found my way here to the forums and found a post about a similar problem someone was having building a standard win10 UWP app .. so I followed the instructions posted as a reply to that..  http://procore3d.github.io/probuilder2/troubleshooting/faq/#error-building-player-windows-store-ios-android-webgl

First, following the instructions from that link, I tried just setting the main dlls to editor only. After doing that, it built OK and it ran on the xbox but gave me errors in the actual build (see screengrab attached) .. so I went back and did the rest of the instructions on that page (where it says to set theProBuilderCore-Unity5 and ProBuilderMeshOps-Unity5 dlls to editor and standalone only) and next I was back to these build errors:

Assets\ProCore\ProBuilder\API Examples\Vertex Colors\HighlightNearestFace.cs(3,19): error CS0234: The type or namespace name 'Common' does not exist in the namespace 'ProBuilder2' (are you missing an assembly reference?)

To solve the build error above, I added #if UNITY_EDITOR || UNITY_STANDALONE  to the entire HighlightNearestFace.cs script, which meant I was able to build again.

Sadly, after all that I'm still getting errors in the build running on the actual xbox (see the screengrab - its the same error I was getting before, so yes there's only one screengrab!)

Any suggestions on getting around this / fixing it would be really welcome! I understand that support isn't easy :)

I absolutely love using ProBuilder and I'm having a great time with it. If there's any more info you need from me to help solve this, let me know.

Thanks so much!

Jeff.

 

xboxgrab.jpg

Share this post


Link to post
Share on other sites

Thanks for the detailed report. pb_PolyShape is bundled in a DLL and does not have any def'ed out serialization properties, so I'm not sure why that error would be coming up. However an easy solution would be to just strip out the PolyShape components at build time and avoid the problem all together.  Something like this should do the trick:

 

using UnityEngine;
using UnityEditor;
using UnityEditor.Callbacks;
using ProBuilder2.Common;

static class RemovePolyShape
{
	[PostProcessScene]
	public static void OnPostprocessScene()
	{
		if(EditorApplication.isPlayingOrWillChangePlaymode)
			return;

		foreach(var polyShapeComponent in GameObject.FindObjectsOfType(typeof(pb_PolyShape)))
		{
			GameObject.DestroyImmediate(polyShapeComponent);
		}
	}
}

 

Share this post


Link to post
Share on other sites

The log is still upset about `pb_Polyshape`? That sounds like the post-processor may not have worked correctly. Can you try creating a new empty scene, adding a single poly shape, then removing the pb_PolyShape component, then building (making sure just that one scene is in the build target)?

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×