Fade effect on a skeletal mesh?

Hi,

Basically I have an NPC character that will teleport after a certain animation plays. I have a blendspace for the idle animation transition to the magic cast animation, which will cause the NPC to teleport. I was just wondering if there was a way I could have the NPC fade out as the animation plays? I don’t want the NPC to abruptly disappear as it would look a bit odd, so I wanted to know if I could make her fade out instead. Because I have a dialogue system the NPC itself is a blueprint.

You mean Transition in material?

Doable by blending Material Instance Dynamic.

how would I go about this?

  • make 2 materials
  • one (A) is main character material
  • second (B) is Material Instance Dynamic made with blending between material A and some transparent material (100% A → 100% transparent)
  • make a paramater that will control blend strength in material B
  • make blueprint that would Set Material from A to B and trigger animation transition of parameter from B

Switching materials between A and B is made solely for performance.

Hi, do you think you’d be able to do a mini guide with screenshots? I’m pretty new to unreal so some stuff is still quite new to me! :slight_smile:

I’ve made You a Project!
Note, that noise transition is the simplest possible for Solid Shaders since solid can’t be semitransparent.

124124-transition.gif

[Material Blend][2]

Thanks so much!! This is for a uni project so I am going to try this tomorrow, I will post if I need any help! :slight_smile:

Hi! I had a look at your project and tried to give it a go but can’t seem to get it working - what am I doing wrong? This is what I have, obviously my blueprint is a bit different to yours as mine just needed to change material once and not be constant. I called the “dialogue exit” event (which is the custom event when dialogue ends with the NPC) and did everything else here but still can’t seem to get it working

I’ve initially didn’t set “Used with Skeletal Mesh” checkbox in shader, but besides that everything works fine.

124336-screenshot.1485888189.png

124340-puff.gif

Hi, I’m not too sure why it’s not working for me, I have that box ticked.
Below is how it looks.

Am I using the wrong nodes? I noticed some things in your BP were labelled a bit differently but everything seemed to fit :frowning:

Open a BP and make sure nodes are triggering.

I just had a look and the BP actually doesn’t seem to be simulating. I did this blueprint in the NPC BP itself, I was going to do it in the widget blueprint that holds the dialogue info but I can’t actually have a timeline in a widget blueprint so I couldn’t do it there, do you think it’s something to do with this?

Put a breakpoint on first event node.

Just tried it, i get a yellow exclamation mark in the corner instead of a red circle but the NPC is still the same :frowning:

Man, Exclamation sign means there’s error in blueprint!
Open Compiler Results window if it’s not opened (it should on error).

Nope there’s no error! It’s a clean blueprint

Shows fine here as you can see, really not sure what the issue is :frowning:

@Dirtsleeper from Discord just noticed, You’ve plugged “Dialogue Exit” Event Input instead of Output!

You could Join Us on Discord: http://join.unrealslackers.org/