Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: PolyMad on May 11, 2016, 05:12:39 PM

Title: Another weird behaviour
Post by: PolyMad on May 11, 2016, 05:12:39 PM
So, I have a prefab that is the classic Unity Character, updated with stuff and PlayMaker FSM.
I checked it: I clicked APPLY on the character in a map where this works perfectly, so the prefab is updated.
I made a new map, there's very few elements in it, dragged the Character prefab in it, and voilà: says there's no cameras rendering in the scene.
This modification I did to the character is that its cam renders to a texture, and the FSM creates the camera that reders the final view to the player.

OK I solved this while I had this post open, but still here there's something wrong, don't know if in Unity or PlayMaker, I think more in Unity though.
I solved by dragging the good Character on the prefab, replacing it effectively.
I can't understand how this is possible though, this means that APPLY doesn't completely replace the prefab, and at this point I don't know what is that button for really, I thought that when I clicked APPLY I made the prefab in the project the exact same of the one I had in the scene when I clicked APPLY. Useless button?
Title: Re: Another weird behaviour
Post by: jeanfabre on May 12, 2016, 02:33:00 AM
Hi,

 you are likely mistaken by the difference between an Fbx asset and a Prefab Asset.

 your fbx asset if dropped ontot the scene looks like a prefab, but it's not...

so make sure you drop back from the scene into a prefab the fbx ( so that you have the Fbx asset and next to it or somewhere else the prefab referencing that fbx character).

 Unity doesn't really show that difference, but I had issues with this too.

Bye,

 Jean
Title: Re: Another weird behaviour
Post by: PolyMad on May 12, 2016, 06:30:20 AM
Man, I'm talking about the Unity Character here, not about any FBX!
Title: Re: Another weird behaviour
Post by: jeanfabre on May 23, 2016, 11:26:53 AM
Hi,

Ok :) then where do you take the skinned mesh and animation for this character? Apart from an fbx, I am not sure where you can get it.

Maybe you could do a screencast showing this issue, we may spot something during the process that's overlooked.

Bye,

 Jean


Bye

 Jean
Title: Re: Another weird behaviour
Post by: PolyMad on May 24, 2016, 12:04:39 AM
Man... I have no problem with any FBX, my problem is with "reliableness" of Unity.

This is the part: "OK I solved this while I had this post open, but still here there's something wrong, don't know if in Unity or PlayMaker, I think more in Unity though.
I solved by dragging the good Character on the prefab, replacing it effectively.

I can't understand how this is possible though, this means that APPLY doesn't completely replace the prefab, and at this point I don't know what is that button for really, I thought that when I clicked APPLY I made the prefab in the project the exact same of the one I had in the scene when I clicked APPLY. Useless button?"
Title: Re: Another weird behaviour
Post by: 600 on May 24, 2016, 01:10:53 AM
Man... I have no problem with any FBX, my problem is with "reliableness" of Unity.

This is the part: "OK I solved this while I had this post open, but still here there's something wrong, don't know if in Unity or PlayMaker, I think more in Unity though.
I solved by dragging the good Character on the prefab, replacing it effectively.

I can't understand how this is possible though, this means that APPLY doesn't completely replace the prefab, and at this point I don't know what is that button for really, I thought that when I clicked APPLY I made the prefab in the project the exact same of the one I had in the scene when I clicked APPLY. Useless button?"
Hello,

About the APPLY, I have broken my prefabs a couple of times by editing it in the scene and while not applying go to project file and edit it there too, then later if you apply messy things happens as the scene reference was not saved and now the project file is different.

This way you can lose game object or FSM edits on the prefab. I believe it is a Unity thing, you should always hit apply on the prefab in the scene if you edit it and only then can click and go to the same prefab in the project folders.

Another finding, if there are many prefabs placed in the scene you want to edit, I usually open a empty scene to edit it and then go back so all of them got properly updated, had issue after a while if you do in the same scene (This might have been fixed/updated… I use Unity 5.2 mainly).
Title: Re: Another weird behaviour
Post by: PolyMad on May 24, 2016, 01:35:23 AM
Ye I suspected some crap like that... one must make things the most obvious and simple possible or the system won't recognize what's happening. I think also that it's more a Unity thing, as this happened to me in the past as well not with PlayMaker but with other simple prefabs. The APPLY button simply doesn't work sometimes and the prefab remains blue like connected. They should definitely add another colour when a prefab is not completely connected or whatever, if this is not an unknown bug to them.
Title: Re: Another weird behaviour
Post by: 600 on May 24, 2016, 01:42:24 AM
APPLY will apply the changes, if you want to disconnect you can go upper menu Game Object>Brake Prefab Instance
Title: Re: Another weird behaviour
Post by: PolyMad on May 24, 2016, 02:25:22 AM
No that's the problem. I hade this prefab, made changes, all is working but suddenly I find that no matter what, APPLY doesn't work anymore, but if I click SELECT, it selects THAT prefab, so clearly there is something wrong in the management of this thing.
Title: Re: Another weird behaviour
Post by: 600 on May 24, 2016, 03:09:33 AM
Yes encountered this too, in that case I usually create a new prefab by dropping from the scene to prefabs folder and delete the broken one, this wont be a solution if you use many of them in a scene.
Title: Re: Another weird behaviour
Post by: PolyMad on May 24, 2016, 03:25:02 AM
Eh that's pretty easy and I did it too, but try to imagine if this happens with a prefab that you used THOUSANDS of times in your project... you will have to replace all those prefabs by hand.