game engine export - transparency/opacity for Unity

Discuss issues pertaining to the Creature Animation Editor here.
Post Reply
joriooo
Posts: 11
Joined: Mon Sep 16, 2019 9:29 pm

game engine export - transparency/opacity for Unity

Post by joriooo » Mon Oct 21, 2019 8:30 pm

Hello,

I'm experiencing some transparency issues when exporting animations for a game engine.

If the animation is exported via video / movie export, everything looks perfect, but when the animation is exported for the game engine and opened in Unity, there's a complete lack of opacity changes, every region just stays at 100% opacity throughout animation.
Do you have any suggestions or idea what could be the reason for this to happen?

Thank you so much,
best!

ps: and I've already tired using shaders you advised in the similar topic from few years ago, but unfortunately without success.
"For Unity, if you pick the correct shaders it should work. I just exported out an animation with animated opacity ( fading in from transparent to opaque ). I picked the "Alpha-Blended" shader and the transparent mesh regions displayed correctly."

chong
Posts: 1178
Joined: Thu Feb 19, 2015 2:21 am

Re: game engine export - transparency/opacity for Unity

Post by chong » Wed Oct 23, 2019 12:12 pm

Hello,

You should be able to use Unity's various shaders to get the transparency you want; this has always worked and is specific to understanding Unity's material setup. I believe there should be a sprite shader that supports transparency by default and/or has various modes that support transparency. There are also particle shaders that do that.

Cheers

joriooo
Posts: 11
Joined: Mon Sep 16, 2019 9:29 pm

Re: game engine export - transparency/opacity for Unity

Post by joriooo » Wed Oct 23, 2019 5:34 pm

Thank you very much for your support Chong,
unfortunately I cant get it to work properly even with the sprite or particle shaders.

I've tried to do a similar test you did in that old topic I've mentioned before in my question (http://bit.ly/2MJrh9L)- one simple region with changing opacity, just to see how/if it works.
It resulted in no changes in opacity whatsoever, no matter which shader was used when trying with Creature pack (there was just 100% opacity throughout), but it worked just fine with .bytes & .json though.
I'm lost on how to get it to work inside Creature pack, do you have any idea what could be the issue?

On top of that, when trying to use my animations, the problem persists not only when Creature pack is used, but also with .bytes & .json.
In some cases it changes the region color to black when it should be at 0% , in other instances just ignores all opacity changes and sets the region at 100%. Any Ideas would be more then welcome :)

Thank you again,
best!

chong
Posts: 1178
Joined: Thu Feb 19, 2015 2:21 am

Re: game engine export - transparency/opacity for Unity

Post by chong » Wed Oct 23, 2019 10:40 pm

Hello,

I just loaded up Unity, made a simpler CreaturePack project and it works:
https://paste.pics/65a9f2cf3da0b0b6754712ec63df7b25


Check the screenshot out, it should also show you the shader it is using ( standard Sprites shader ).
I am not sure what is going on at your end but I am not doing anything special at all, just a normal Unity workflow, nothing fancy.
Hopefully the screenshot can be helpful. This is with CreaturePack.

Update: Oh you meant Opacity Change... for Opacity changes, maybe you can try to check the "Colors" option during export and see if it helps. This will export color changes out as well. Normal CreaturePack will not export animated Colors if the option is not checked. I just tried an opacity + animated color character for CreaturePack in Unity and it worked:
https://paste.pics/6317556889b375adb79753673844948c

Thanks

joriooo
Posts: 11
Joined: Mon Sep 16, 2019 9:29 pm

Re: game engine export - transparency/opacity for Unity

Post by joriooo » Thu Oct 24, 2019 9:46 pm

Thank you so much for all your efforts chong, really means a lot!
Of course, the "Colors" option during export did the trick :)
Thank you again and all the best!

Post Reply