0
Fixed

Good tool but I have some problems.

Mariusz Kowalczyk 11 years ago updated by GameDraw 11 years ago 18

Hello. Very nice tool, much better than ProBuilder. I am only using it for like 15 minutes now and looks like there are some problems with UV Editing on Mac (didn't test on the Windows).


I will try to explain what the problem is. So I am creating a basic cube shape, making a copy by using Add To List option, then modifying it a bit and then adding a material. So far so good. Then I am going to Edit UVs option. Now, the options from the menu are not working. The only way to make them work is by switching back to Edit Vertices (or edges, or faces or elements), selecting the vertices I want to modify and then going back to Edit UVs. I don't know if this is how it should work, probably yes so it's not a problem at all.


The real problem is this: When I want to use the following options: Rotate UV, Translate UV, Scale UV it's not possible to write the value I want, the only way to change the value is by scrolling with the mouse click. But the worst part of this is that after changing the value with the mouse click, the value visible in the field is being reseted to the default value. So even though the real Scale UV on the model is 2, I see 1 in the GUI field all the time (only during the click scrolling I can see the real value, after I release the click it is reseted in the window, on the model I can see that the UV Scale is correct though).


I would like to be able to type for example: 2.5, press enter and change values that way. Is this a bug or maybe this is how it should work? If it's not a bug, please consider changing it to the way I described, because now it's really hard to work with how it is.


The other weird things I have noticed is this: when I go to the UV Editor (the one with the white grid), the grid is blinking all the time which is really annoying :D


If I will find more bugs I will let you know :)


Anyway nice tool :)

Answer

Answer
Fixed

Thanks for reporting these issues :) much appreciated and please keep us updated of any issues you encounter


Regarding the UV editing, just untoggle the Instant update checkbox and you will be able to set values :D

Hope this helps out

Answer
Fixed

Thanks for reporting these issues :) much appreciated and please keep us updated of any issues you encounter


Regarding the UV editing, just untoggle the Instant update checkbox and you will be able to set values :D

Hope this helps out

Wow :) I am going to check every single option one by one so I would hopefully figure this out eventually :D Thank you.


Here is some other bug:

Create a cube shape, save it as an exampleShape.asset. Remove from the Hierarchy. Then add that exampleShape.asset from the Project to the Hierarchy. That shape will be pink and without any material. If you will then go to the UV Edit window (the one with the white grid), then you will get an error spam in the console:


NullReferenceException
UnityEngine.Material.get_mainTexture ()
GDUVEditor.DrawMaterialSettings ()
GDUVEditor.DrawGUI (Int32 id)
GDUVEditor.OnGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)



Is there any documentation? I would for example want to know what are these options in the GameDrawManager. Max Object Count, Message Read and so on.

The easiest way to save a mesh with all its components including the materials is to drag it from the scene hierarchy to the project hierarchy, this will create a prefab with all associated references next to it in folders.

We are working on an updated documentation but you can watch the tutorial video on our channel here http://www.youtube.com/user/GameDrawMXD

Thanks I have watched but I haven't seen anything about GameDrawManager. Is there a video about it?


I am trying to figure out what will be the best way to work with Game Draw and I decided that saving as .asset may be the way to go, since I will be making a simple and unique level elements (no need to reuse it).

We will do a video regarding GameDrawManager :)

Another bug (I think so):

Go to the Edit UVs, uncheck Instant Update and change the Scale UV X to 5. Then press Make Cubic. Then try to translate the uv by some value. Now you should see that the texture scale has been changed to the value from just before the "Make Cubic" option has been pressed.


To work around this I need to press "Make Cubic" when the Instant Update is checked. Then I can uncheck it and it works as it should.

We will look into this :) thanks for reporting

Is there a way to use these UV transform operations only on some faces and not on the whole object?



The other bug I have found is that I am getting really frequently these set of warning + error being spam in the console (and the game is paused, the only way to fix this is by removing the objects from the Hierarchy or by restarting Unity, without the restart I can't use GameDraw anymore, because I get this error all the time):


null texture passed to GUI.DrawTexture
UnityEngine.GUI:DrawTexture(Rect, Texture)
GDUVEditor:DrawGUI(Int32)
GDUVEditor:OnGUI()
UnityEditor.DockArea:OnGUI()

MissingReferenceException: The object of type 'Material' has been destroyed but you are still trying to access it.
Your script should either check if it is null or you should not destroy the object.
UnityEngine.Material.SetColor (System.String propertyName, Color color)
GDUVEditor.DrawUV (Boolean uv2)
GDUVEditor.DrawGUI (Int32 id)
GDUVEditor.OnGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)


I am not sure when this occur. One time I have pressed CMD + Z to undo when I was in the infamous UV editor with the white grid, and this bug has been executed :)


Now after restarting the Unity I still can't use GameDraw. I am getting warning + error spam in the console even without pressing the Play Button:


null texture passed to GUI.DrawTexture
UnityEngine.GUI:DrawTexture(Rect, Texture)
GDUVEditor:DrawGUI(Int32)
GDUVEditor:OnGUI()
UnityEditor.DockArea:OnGUI()

ArgumentOutOfRangeException: Argument is out of range.
Parameter name: index
System.Collections.Generic.List`1[GameDrawEditor.MaterialSettings].get_Item (Int32 index) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Collections.Generic/List.cs:633)
GDUVEditor.HighlightVertex (Boolean uv2)
GDUVEditor.DrawGUI (Int32 id)
GDUVEditor.OnGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)



What should I do now? :D

you can modify them from the UV editor window not from the UV tab, the UV editor window will allow you to select faces, edges or vertices, move, rotate and scale them or unwrap them, the UV editor will be updated in the next iteration to make it more improved.

I had to remove GameDraw, restart Unity and import again. It's working again (for now :)).


Another bug I have found is this:

When I am saving the object to .asset it works. Then when I am saving it again using the same name and in the same place, then the object from the Hierarchy is not usable anymore (Missin Mesh in the inspector, after manually picking the mesh weird things are going on). I have to remove it and instead add the one I have just saved as an .asset, if I don't do this, I am getting this error all the time:


MissingReferenceException: The object of type 'Mesh' has been destroyed but you are still trying to access it.
Your script should either check if it is null or you should not destroy the object.
UnityEngine.Object.Instantiate (UnityEngine.Object original)
GameDraw.GDController.set_selectedMesh (Int32 value)
GameDrawEditor.GDEditor.DrawSceneGUI ()
MeshFilterEditor.OnSceneGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:232)
System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MethodBase.cs:115)
UnityEditor.SceneView.CallOnSceneGUI ()
UnityEditor.SceneView.HandleSelectionAndOnSceneGUI ()
UnityEditor.SceneView.OnGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)


I don't know if my explanation is entirely correct or maybe this error occur only sometimes, but something is not right one way or the other.

When you save a .asset you don't need to save it again, it will be automatically saved whenever you modify it, this is how unity handles things, once you save it with the same name the new saved file is considered a different mesh and because you saved it on top of the first one the first mesh got overwritten and lost for that you are getting a null reference exception, when you want to have a new object you should save in a different file other than that any changes you made to a saved .asset is always automatically reflected to the file and saved.

OK thanks, that will make things easier :)

It looks like I can work with meshes without saving them anywhere (I don't need to reuse them in other scenes). So after I am making a copy in GameDraw of a Unity cube, that copy is stored somewhere, probably in the project files, since it's available after the restart, it's not only in the memory. Is this correct?

OMG I am seriously frustrated now :D. I am getting these errors over and over again. Now I have removed the saved .asset files from the Project and even after restarting the Unity, I am getting this warning + error when I add a Cube and press Play:


null texture passed to GUI.DrawTexture
UnityEngine.GUI:DrawTexture(Rect, Texture)
GDUVEditor:DrawGUI(Int32)
GDUVEditor:OnGUI()
UnityEditor.DockArea:OnGUI()

MissingReferenceException: The object of type 'Material' has been destroyed but you are still trying to access it.
Your script should either check if it is null or you should not destroy the object.
UnityEngine.Material.SetColor (System.String propertyName, Color color)
GDUVEditor.DrawUV (Boolean uv2)
GDUVEditor.DrawGUI (Int32 id)
GDUVEditor.OnGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)


Now I have to reinstall GameDraw again I think.


if you add a .asset directly to your scene you will need to associated a material with it also try not to modify the original object

I know that but this is not the source of the errors. I am removing all the objects from the scene and then adding a simple cube which have material and the problem is still there.


it seems the UV editor window is open, try closing it, I prefer that you open it only when you have a model selected and you want to modify its UVs, will take a deeper look into it.

I am sometimes getting this error after pressing Play: PPtr cast failed when dereferencing! Casting from DefaultAsset to Shader!


It disappears after I press stop and play again.