How to fade out & replicate destructibles?

Hi,

Is it possible to fade out the chunks of a destructible mesh X seconds after it has been destructed and also disable their collision?

Ideally I’d like to do this from a blueprint but I could do it in code if necessary.

I found that you can specify the debris size and have the debris chunks time out after a time period but they disappear instantly. To get them to fade out would I need to do that separately by changing the destructible mesh material?

Also, I have now tested the destruction in networked multiplayer and the destruction does not occur on the clients. I know that the ApplyDamage functions only run on the server which is what I’m doing, but I assumed that any destruction that happens on the server would be replicated on the clients. How would I get this to happen?

You can’t fade them out (well maybe by code I don’t know yet) but you can have them time out one by one (more or less) by playing with the “Damage cap”. The smaller the value, the harder chunks will break into “leaf” chunks resulting in not having lots of “leaf” chunks falling at once (and thus disappearing at once). This is a good compromise I think.

As for replication you can:

  • trigger hit event from client (remote authority)
  • trigger a reliable server call from the client asking it to apply damage at the hit location
  • let the server call a multicast function to tell all clients to handle damage on the destructible
  • in the multicast, call the “ApplyDamage” function from the destructible component (if I remember well)

Hope this helps.

Cheers