Notifications
Clear all

[Sticky] Support – Classic Survival Horror Framework

276 Posts
16 Users
90 Reactions
24.5 K Views
Ben4886
(@ben4886)
Patreon Survivor Registered
Joined: 3 months ago
Posts: 56
 

Hi guys. I am adding some things to the Oil Barrels, like sound effects etc. How do i despawn them after leaving a room? So i have everything working when the barrel explodes, but when i leave the room through a door with a cutscene, i want the barrels and fire etc to despawn. I have tried various options in the Barrel BP, but nothing seems to work



   
ReplyQuote
Farshad
(@farshad)
DEVELOPER Admin
Joined: 4 months ago
Posts: 224
Topic starter  

@ben4886 Hey Ben, If I understood correctly, you want the barrel's exploded fire effects to be removed from the level after it explodes. In that case, open BP_OilBarrel and go to the ForceExplosion custom event. After the DestroyedChunksTemp loop, you can add a delay for example 5 seconds, then destroy the fire and smoke emitters and finally destroy the actor itself. Or, if you want the barrel to be removed after a specific event rather than a timer, you can connect the barrel to the actor that triggers the event and call the destroy logic at the exact moment you want it to disappear.


This post was modified 22 hours ago 2 times by Farshad

   
ReplyQuote
Ben4886
(@ben4886)
Patreon Survivor Registered
Joined: 3 months ago
Posts: 56
 

@farshad I have added the sound of fire to the barrel, activated once it explodes. If I leave the room (with door opening cutscene) you can still hear the fire sound. I want to deactivate the sound (and fire) once we leave the room



   
ReplyQuote
Farshad
(@farshad)
DEVELOPER Admin
Joined: 4 months ago
Posts: 224
Topic starter  

@ben4886 There are a few ways to handle soundspart. The simplest solution is to use Unreal's sound attenuation, so the sound gradually fades out as the player moves away from the area.

Another option tha help the effect as well is to link the barrel to door(s) or another event actor. Then, when a specific door is interacted with (or a cutscene starts), you can disable or destroy the assigned barrel, along with any fire or effects it spawned.



   
ReplyQuote
Ben4886
(@ben4886)
Patreon Survivor Registered
Joined: 3 months ago
Posts: 56
 

@farshad I’m away at the moment, so can’t check it. But in the door BP is there logic for something like “cutscene triggered”, or “interacted with”?



   
ReplyQuote
8012fdcbb87d8ed510cdcbc1895309a43739ecd978a24bf0c190e9d56fc94e30?s=80&d=mm&r=g
(@mr_spookies)
Patreon Survivor Registered
Joined: 2 months ago
Posts: 10
 

@hosna Hi! I tried going through the video with your spline/camera setup and ran into a snag. I've triple checked my project to the video you made and everything looks correct but when I play and overlap the switcher, my camera stays static. I noticed you had set up some variables for CameraSlineSpeed and SplineDistance, but I didn't see where they were used or if they were used at all, and then the in editor set up was not very clear. I really love this idea and would love to implement it in my game, so any help would be super appreciated!

 

P.S. Not sure how the forum works, but this is in response to your exchange with @the_javawockee regarding moving the cameras!



   
ReplyQuote
Page 19 / 19
Share: