Post by popiroshka on Apr 12, 2024 21:52:38 GMT
Before I will start explaining here, I want to say that this is more like part 2 for this guide.
This is where you actually change the duration of your WEM file with audio effects. He is a Child of the MusicSegment where's he will takes all rule.
PlayAT/BeginTrimOffset/EndTrimOffset
PlayAt - Can move a whole segment with his settings if this code will be as plus numbers. If this code as minus, then it will cut song from the beginning, but for that we should write same numbers, but as plus, inside the BeginTrimOffset.
BeginTrimOffset - If the value is plus, then it will allow the segment to play that second without allowing it cutting. If it minus, then the song will be cutting from the beginning.
EndTrimOffset - If the value is plus, then this is when the segment will be ended and also with not allowing cut it as well. If it minus, then the song will be cutting from the end.
Coding all of them shouldn't be the same! It will mute your whole segment or everything will play together if that happen. If you want to cut your song from the beginning, then use PlayAt(as minus) and BeginTrimOffset(as plus). EndTrimOffest doesn't conflict with others, even if it has a minus or a plus numbers. Only PlayAt and BeginTrimOffset might be uncorrected. If we are cutting our song with these codes, then SourceDuration should be cutted as well, but this duration needs to be written only inside the MusicMarker duration. If you want to use PlayAt function when he is as minus, then just plus numbers to BeginTrimOffset for it. For example, when PlayAt with -2000 and I want to play segments after 2000, then I will write inside the BeginTrimOffset 4000 (2000 for cutting part of the file and 2000 when segment should play). If we are talking about cutting two TrackPlaylist, then duration should be written only from the last one TrackItem for the marker's duration. It's like one of the TrackItem for the intro himself, and another one where's MusicMarkers actually will work.
AutomationItem/AutomationItems
This code can do some audio effects like FadeOut, FadeIn, HigPass and LowPass. We can turn this code off by deleting his list and set him as 0(check original code where's he as zero to make it correct). If its AutoType has a value of 3, then this is FadeIn. If its AutoType has a value of 4, then this is FadeOut. If its AutoType has a value of 1, then its HighPass/LowPass effect (here's official table with numbers how to code it). If its AutoType has a value of 0, then it's increasing the volume from beginning to end. The seconds format for this code should be written as it was in the original. To create this code, just copy it somewhere with that AutoType what you need. You can combine them together or create another GraphPoint. Of course, you also should change GraphPoints number after that.
NodeBase
This is what will happen with the MusicSegment depending on some action. It's still a question for me. I only have a theory about this code, and this may be the reason why sometimes this segment sounds louder and sometimes it doesn't.
Properties/Prop
This is the reason why one of the segment is louder than another. This code uses for increasing volume a whole segment according to some rules. For example, when we hear segment for the first time - then he is louder, and next time - lower. Of course, its always about random and logic for that segment. If you want to change volume for your segment, then work with this code inside the MusicSegment, where you can actually disable this code, and volume will be used from the MusicTrack(WEM file) and NodeBase. I still was not working more with this code, and that's why I will leave it to you.
AuxiliaryParameters
This is where you can work with your audio channel volume. I'm still not sure how, but if you need it, then there is.
RTPC/Real-TimeParamaterControls
This code works the same everywhere, and it lowers the sound from the action. In dynamic logic, it uses for A raising as increasing volume.
He has same logic with From and To as it was with AutomationItem. You can do a trick with volume or just turning off this effect for A. If we talk about dialog, then while the character is talking, the sound of other will be lowered.
MusicSegment
This is where we can see the ID for SeqPlaylistItem and ChildIDs what for MusicMarkers. In that case, all these rules will work for all ChildIDs. It might be any A segments or when plays more than two segments. BuryTheLight uses this logic when two and three segments working only for one MusicMarker. If you copy ChildIDs and search it up there, then you will see what exactly segment is. This might be very helpful for finding A segments and coding BuryTheLight.
What is that ID of the MusicSegment? First what we will find it's how many D or S have segments, and second one is where we can change rule for this segment inside SeqPlayListItem, where he as Child. We can turn random off or make him always looping. Use Loop and AvoidRepeatCount for this. If Loop is 0, then it will always be looping segment and if it more than 1, then this is how many times segment will looping before switching. If AvoidRepeatCount will be as 0, then segment won't be skipped and if it more than 1, then this is how many times segment will be skipped. Keep in mind that any dynamic has one line when player just doing hit and nothing after. Random will work after A and S rank. Also, when you take MusicSegment's ID and searching it down there, then you will see others MusicSegment that working for one variation or state.
ChildIDs
This is how many WEM files will work for this MusicSegment rule. In that case, his MusicMarkers will be affected for all of them.
AkMeterGridPeriod
This code allows one segment continue plays some seconds in another if he's not finished yet. For example, if I set inside the MusicMarker 10000 as the point of transition to the next segment, while duration MusicMarker was 11000, then this 1000 will play with the next segment. Segment will be ended without fade out effect, but you also can use AutomationItem for it.
MusicMarkers
Some of the MusicMarker can be for a moment when segment can be switched or continued. If you will set duration for the first one marker, then this is where another one segment will be ended after phase cut or lost rank. If marker have ID value as 0, then this is the moment to switch according by some of the action. Logic for it might be different, for example, is when can be cutting for the S lost rank segment or be jumped to the last one segment. Zero ID will cut song immediately without FadeIn or FadeOut effect, if the next one segment doesn't have duration inside the first one MusicMarker. If you need another one MusicMarker, then you can just copy and paste him. Of course, don't forget to change MusicMarkers number after that.
Just change seconds inside the MusicSegment code to 0: Duration and all MusicMarkers.
We are not cutting or deleting him, nope, we just change duration into 0, and that's why he will be skip immediately.
A CODING
A doesn't even have own MusicMarker code, and A duration is SourceDuration only what actually working with PlayAt/BeginTrimOffse/EndTrimOffset. For making custom duration just change SourceDuration. EndTrimOffset is that code what allows A looping when it's plus numbers, but if you will write minus numbers, then this code will cut A without loop. Using him as plus will ended A loop after those seconds. Your mission with A here will be to finding her duration that playing somewhere with one of the D segments. In that case, A loop duration should be from the start to the end of the D segment, where's A loop will be restarted. Another way for understanding A is using REF and checking loop beside the 666 and 999 stylish points numbers. What about another easier way with A, it's taking your one of the longest D segment duration seconds for A as file, and write it inside code, for example: I will write inside the SoursecDuration 30000 (because A is about 30 sec. as file) for any A code, but EndTrimOffset always be different with mines numbers, that will cut duration for A just by according one of the D segment duration. I mean, when you find A, scroll down until you will see the first MusicMarker and take its end duration. So, my segment has 6000 durations inside the MusicMarker, then EndTrimOfsset will be -24000 because I want to cut A here without allowing continue in another segment. This is the one of the ways for avoiding A overlaps just by having longer file. If you want to make perfect A loop, then you should work with PlayAt (if one A overlapping in another A) and plus numbers for EndTrimOffset. Plus numbers will allow A looping only seconds that you will set there. In that case, you should write perfect end loop timing for one of the D segment. You can also use AkMeterGridPeriod as 0 for avoiding A's overlapping.
REMOVING A
For making A silence, you should remove her duration inside her code or just make silence files and replace A segments. Next what you will do is taking SourceID of the segment where you want to remove A. After choosing segment, you should find a little down there code RTPC, which belongs to A. Now change number inside this code like "name=To value=-1", what is inside the any GraphPoint to 0. Another way is taking original example code where's RTPC as 0 and do the same for turning this code off.
FASTER FIND FOR MUSICMARKER
When you find your segment by SourceID, you will be able to see up there a MusicTrack, which will have a different ID (<field type="uint32" name="ID" value="715977523" />) for the MusicSegment. Take this ID and find it down there. To be very shortly about it, then this is another segment ID where's he would be as a Child. It's very helpful with BTL and any boss music coding.
WHY SOME OF THE SEGMENTS CAN BE FOUND MANY TIMES
It's because this segment has a lot of the variation to play. For example, BuryTheLight has three segments when battle just started, but they play randomly with four variations. If we are talking about boss fight, then it might be intro what will play once, and another is for repeating. Just take original segment song file and combine his seconds with the PlayAt/BeginTrimOffset/EndTrimOffset for understanding it simply.
BETTER PLACE FOR TESTING DYNAMIC
I perfume to use Mission 10 to test three variation of the dynamic. First, how much louder the dynamic would be when the game will up it. Yes, we have like 2 or 3 volume code, which allows be dynamic louder or not just by some of the place. First one that I know it when dynamic plays for the first time before S rank or any loop. It's always about +2/4dB or -2/4dB for D before player will up S for the first time, and then volume will be normally after losing this rank. Second one is testing how dynamic will be without A. This logic will be turning ON by the game, when cutscene is ended and dynamic will skip HIT PART. And the last one is how dynamic will play when we find fight that can be skipped. In that fight, dynamic logic will be changed with transition, where's no FadeIN and FadeOut what comes from the game (not the AutomationItem). BLOODY PALACE is where dynamic working normally and also test your outro for avoiding with annoying or bad transition. It's about when player ended combat and start new one real quick.
TROUBLE WITH WEM FILES
This might be a Wwise version and "sample rate" that better use 44100Hz if you are using fusiontool method. If your WEM file seconds was doubled after you input it inside the bnk - then it's sample rate for sure. If you will have, for example, a whole dynamic silence with only one of them - then it's Wwise version. Better version for DMC5 it's any 2017 and 2021.
CODING WITHOUT HIRC
Don't forget that you can coding segment inside the BNK while pressing the right mouse button on that segment what you want to change. Just choice after that "Edit Wev HIRC" and everything that you need will be sorted there, which means no need to copy SourceID.
Hope something from it was close to understand for you all! I'm pretty sure you will understand more after playing with all this stuff that I showed you where it is. I also open for collaboration if you prepare all files for coding. Message me for it.
OBJECT TYPE
MusicTrackThis is where you actually change the duration of your WEM file with audio effects. He is a Child of the MusicSegment where's he will takes all rule.
PlayAT/BeginTrimOffset/EndTrimOffset
PlayAt - Can move a whole segment with his settings if this code will be as plus numbers. If this code as minus, then it will cut song from the beginning, but for that we should write same numbers, but as plus, inside the BeginTrimOffset.
BeginTrimOffset - If the value is plus, then it will allow the segment to play that second without allowing it cutting. If it minus, then the song will be cutting from the beginning.
EndTrimOffset - If the value is plus, then this is when the segment will be ended and also with not allowing cut it as well. If it minus, then the song will be cutting from the end.
Coding all of them shouldn't be the same! It will mute your whole segment or everything will play together if that happen. If you want to cut your song from the beginning, then use PlayAt(as minus) and BeginTrimOffset(as plus). EndTrimOffest doesn't conflict with others, even if it has a minus or a plus numbers. Only PlayAt and BeginTrimOffset might be uncorrected. If we are cutting our song with these codes, then SourceDuration should be cutted as well, but this duration needs to be written only inside the MusicMarker duration. If you want to use PlayAt function when he is as minus, then just plus numbers to BeginTrimOffset for it. For example, when PlayAt with -2000 and I want to play segments after 2000, then I will write inside the BeginTrimOffset 4000 (2000 for cutting part of the file and 2000 when segment should play). If we are talking about cutting two TrackPlaylist, then duration should be written only from the last one TrackItem for the marker's duration. It's like one of the TrackItem for the intro himself, and another one where's MusicMarkers actually will work.
AutomationItem/AutomationItems
This code can do some audio effects like FadeOut, FadeIn, HigPass and LowPass. We can turn this code off by deleting his list and set him as 0(check original code where's he as zero to make it correct). If its AutoType has a value of 3, then this is FadeIn. If its AutoType has a value of 4, then this is FadeOut. If its AutoType has a value of 1, then its HighPass/LowPass effect (here's official table with numbers how to code it). If its AutoType has a value of 0, then it's increasing the volume from beginning to end. The seconds format for this code should be written as it was in the original. To create this code, just copy it somewhere with that AutoType what you need. You can combine them together or create another GraphPoint. Of course, you also should change GraphPoints number after that.
NodeBase
This is what will happen with the MusicSegment depending on some action. It's still a question for me. I only have a theory about this code, and this may be the reason why sometimes this segment sounds louder and sometimes it doesn't.
Properties/Prop
This is the reason why one of the segment is louder than another. This code uses for increasing volume a whole segment according to some rules. For example, when we hear segment for the first time - then he is louder, and next time - lower. Of course, its always about random and logic for that segment. If you want to change volume for your segment, then work with this code inside the MusicSegment, where you can actually disable this code, and volume will be used from the MusicTrack(WEM file) and NodeBase. I still was not working more with this code, and that's why I will leave it to you.
AuxiliaryParameters
This is where you can work with your audio channel volume. I'm still not sure how, but if you need it, then there is.
RTPC/Real-TimeParamaterControls
This code works the same everywhere, and it lowers the sound from the action. In dynamic logic, it uses for A raising as increasing volume.
He has same logic with From and To as it was with AutomationItem. You can do a trick with volume or just turning off this effect for A. If we talk about dialog, then while the character is talking, the sound of other will be lowered.
MusicSegment
This is where we can see the ID for SeqPlaylistItem and ChildIDs what for MusicMarkers. In that case, all these rules will work for all ChildIDs. It might be any A segments or when plays more than two segments. BuryTheLight uses this logic when two and three segments working only for one MusicMarker. If you copy ChildIDs and search it up there, then you will see what exactly segment is. This might be very helpful for finding A segments and coding BuryTheLight.
What is that ID of the MusicSegment? First what we will find it's how many D or S have segments, and second one is where we can change rule for this segment inside SeqPlayListItem, where he as Child. We can turn random off or make him always looping. Use Loop and AvoidRepeatCount for this. If Loop is 0, then it will always be looping segment and if it more than 1, then this is how many times segment will looping before switching. If AvoidRepeatCount will be as 0, then segment won't be skipped and if it more than 1, then this is how many times segment will be skipped. Keep in mind that any dynamic has one line when player just doing hit and nothing after. Random will work after A and S rank. Also, when you take MusicSegment's ID and searching it down there, then you will see others MusicSegment that working for one variation or state.
ChildIDs
This is how many WEM files will work for this MusicSegment rule. In that case, his MusicMarkers will be affected for all of them.
AkMeterGridPeriod
This code allows one segment continue plays some seconds in another if he's not finished yet. For example, if I set inside the MusicMarker 10000 as the point of transition to the next segment, while duration MusicMarker was 11000, then this 1000 will play with the next segment. Segment will be ended without fade out effect, but you also can use AutomationItem for it.
MusicMarkers
Some of the MusicMarker can be for a moment when segment can be switched or continued. If you will set duration for the first one marker, then this is where another one segment will be ended after phase cut or lost rank. If marker have ID value as 0, then this is the moment to switch according by some of the action. Logic for it might be different, for example, is when can be cutting for the S lost rank segment or be jumped to the last one segment. Zero ID will cut song immediately without FadeIn or FadeOut effect, if the next one segment doesn't have duration inside the first one MusicMarker. If you need another one MusicMarker, then you can just copy and paste him. Of course, don't forget to change MusicMarkers number after that.
ADVICE
TURNING OFF ONE OF THE SEGMENTWe are not cutting or deleting him, nope, we just change duration into 0, and that's why he will be skip immediately.
A CODING
A doesn't even have own MusicMarker code, and A duration is SourceDuration only what actually working with PlayAt/BeginTrimOffse/EndTrimOffset. For making custom duration just change SourceDuration. EndTrimOffset is that code what allows A looping when it's plus numbers, but if you will write minus numbers, then this code will cut A without loop. Using him as plus will ended A loop after those seconds. Your mission with A here will be to finding her duration that playing somewhere with one of the D segments. In that case, A loop duration should be from the start to the end of the D segment, where's A loop will be restarted. Another way for understanding A is using REF and checking loop beside the 666 and 999 stylish points numbers. What about another easier way with A, it's taking your one of the longest D segment duration seconds for A as file, and write it inside code, for example: I will write inside the SoursecDuration 30000 (because A is about 30 sec. as file) for any A code, but EndTrimOffset always be different with mines numbers, that will cut duration for A just by according one of the D segment duration. I mean, when you find A, scroll down until you will see the first MusicMarker and take its end duration. So, my segment has 6000 durations inside the MusicMarker, then EndTrimOfsset will be -24000 because I want to cut A here without allowing continue in another segment. This is the one of the ways for avoiding A overlaps just by having longer file. If you want to make perfect A loop, then you should work with PlayAt (if one A overlapping in another A) and plus numbers for EndTrimOffset. Plus numbers will allow A looping only seconds that you will set there. In that case, you should write perfect end loop timing for one of the D segment. You can also use AkMeterGridPeriod as 0 for avoiding A's overlapping.
REMOVING A
For making A silence, you should remove her duration inside her code or just make silence files and replace A segments. Next what you will do is taking SourceID of the segment where you want to remove A. After choosing segment, you should find a little down there code RTPC, which belongs to A. Now change number inside this code like "name=To value=-1", what is inside the any GraphPoint to 0. Another way is taking original example code where's RTPC as 0 and do the same for turning this code off.
FASTER FIND FOR MUSICMARKER
When you find your segment by SourceID, you will be able to see up there a MusicTrack, which will have a different ID (<field type="uint32" name="ID" value="715977523" />) for the MusicSegment. Take this ID and find it down there. To be very shortly about it, then this is another segment ID where's he would be as a Child. It's very helpful with BTL and any boss music coding.
WHY SOME OF THE SEGMENTS CAN BE FOUND MANY TIMES
It's because this segment has a lot of the variation to play. For example, BuryTheLight has three segments when battle just started, but they play randomly with four variations. If we are talking about boss fight, then it might be intro what will play once, and another is for repeating. Just take original segment song file and combine his seconds with the PlayAt/BeginTrimOffset/EndTrimOffset for understanding it simply.
BETTER PLACE FOR TESTING DYNAMIC
I perfume to use Mission 10 to test three variation of the dynamic. First, how much louder the dynamic would be when the game will up it. Yes, we have like 2 or 3 volume code, which allows be dynamic louder or not just by some of the place. First one that I know it when dynamic plays for the first time before S rank or any loop. It's always about +2/4dB or -2/4dB for D before player will up S for the first time, and then volume will be normally after losing this rank. Second one is testing how dynamic will be without A. This logic will be turning ON by the game, when cutscene is ended and dynamic will skip HIT PART. And the last one is how dynamic will play when we find fight that can be skipped. In that fight, dynamic logic will be changed with transition, where's no FadeIN and FadeOut what comes from the game (not the AutomationItem). BLOODY PALACE is where dynamic working normally and also test your outro for avoiding with annoying or bad transition. It's about when player ended combat and start new one real quick.
TROUBLE WITH WEM FILES
This might be a Wwise version and "sample rate" that better use 44100Hz if you are using fusiontool method. If your WEM file seconds was doubled after you input it inside the bnk - then it's sample rate for sure. If you will have, for example, a whole dynamic silence with only one of them - then it's Wwise version. Better version for DMC5 it's any 2017 and 2021.
CODING WITHOUT HIRC
Don't forget that you can coding segment inside the BNK while pressing the right mouse button on that segment what you want to change. Just choice after that "Edit Wev HIRC" and everything that you need will be sorted there, which means no need to copy SourceID.
Hope something from it was close to understand for you all! I'm pretty sure you will understand more after playing with all this stuff that I showed you where it is. I also open for collaboration if you prepare all files for coding. Message me for it.