plugin for unity 3D

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

Re: plugin for unity 3D

Postby Julio Jerez » Fri Jun 24, 2016 3:04 pm

This seem such a fundamental issue that I refuse to accept all the monbo jumbo work around that I read form many people.
I poste the question over the Unity forum.

http://forum.unity3d.com/threads/proble ... or.413207/
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: plugin for unity 3D

Postby Julio Jerez » Sun Jun 26, 2016 8:21 am

No one has replied in the unity forum, it seem the simple ignored it, because I see many question been replied since I poste that question.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: plugin for unity 3D

Postby Sweenie » Sun Jun 26, 2016 12:24 pm

I will check it out and see if I can figure it out.
In the meantime couldn't we just use the default editor? That is, just make the editable values public. We wont get fancy popups and stuff but we can at least edit the values.
Sweenie
 
Posts: 503
Joined: Mon Jan 24, 2005 7:59 am
Location: Sweden

Re: plugin for unity 3D

Postby Julio Jerez » Sun Jun 26, 2016 4:38 pm

we could use default editor, but that bring another problem.
It seem the there aren't events call that can be use to refresh the scene after it is edited.
The only way I found to do that is by calling EditorUtility.SetDirty(target); which is part of the editor.
Otherwise if you change fo example the size of a chape it remain the same until so how unity decide to do the update.

If this is a core issue with unity, this seems a very big deal to ignore, not large studio would accept a dev tool whith such severe limitation.
I heard people with so many different opinions and solution to that problem but none seems to work. and it appears Unity does not even aknoledge that it is a serius problem.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: plugin for unity 3D

Postby Sweenie » Mon Jun 27, 2016 4:41 am

Hmm, OnValidate should solve that.
You also have the method Reset which let you set default values.
Sweenie
 
Posts: 503
Joined: Mon Jan 24, 2005 7:59 am
Location: Sweden

Re: plugin for unity 3D

Postby Julio Jerez » Mon Jun 27, 2016 7:59 am

I see,
for now a commented out the editor, and impendent on validate the NetwonCollision Class.
It seems to work.

The only problem is that OnValidate does not tell what field changed so I guess will need to implement out own versions by keep a shadow copy if the variables that requires some actions when the change.

for example say we have a cylinder, if we change scale, position, rotation, or some other parameters, the change does not have to be recreated, but if we change the radios, the the change nee to be deleted and another one has to be created. similar for convex hull, if the mesh is changed the same thing has to be done.

This can be done by having a hidden copy of these variable and check when the change and do the appropriate action. OK let us do that way and go class by class before we move on.

It is a chame the editor does no works.
this is what is say is in the decryption.
This function is called when the script is loaded or a value is changed in the inspector (Called in the editor only).
Use this function to validate the data of your MonoBehaviours. This can be used to ensure that when you modify date in an editor that the data stays within a certain range.

you would think that if the function is called only in editor mode, that that would be a better place for the editor GUI if they only passed the reference to the editor object. It does not look as if Unity team thought out that editor very well, but I guess it is what it is. not nice looking editor GUI.

Plus this does not really address the problem. Imagine a component in one game object having a reference to some other component on another game objet, if you change the reference on the other object the object will not know about, say for example you delete the world.
anything in the editor will be left with a dangling NewtonWorld because those objects will not be notified before the object is destroyed, only after. you can't even scan the scene because the objet is already gone.
Using the editor, this is popsible because the editor is called before the action takes place and the callback is responsible for the change, so you get the object before and after the change.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: plugin for unity 3D

Postby Julio Jerez » Mon Jun 27, 2016 8:34 am

I checked again to see if anyone reply, and my question is already on a different page answered.
I can see several dozen other questions posted after that has been answered

Maybe that is no the right forum to ask, but I could not find any Technical forum, and since we are using a free version my guess Is that no one from Unity actually check the forum.
They most be getting thousand of question pes day, and it will be very expensive for them to have staff people answering the forum. This must be a user moderated forum.

It would * to have to get a license so that you can ask a question for which the answer is must likely that the features does not works.

It is not like this problem is not uncommon, there are many questions related to the same issue
http://stackoverflow.com/questions/3597 ... erializing
and all I here is other user providing their work around solutions by not a single answer from Unity.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Previous

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 5 guests

cron