CRumbleVoice: Resize vectors within constructor initializer list

Same behavior, but constructs in place with the size, rather than
constructing and then resizing.

x20_handleIds cannot be done the same way unfortunately, as
reserved_vector doesn't have a constructor accepting a size argument
like std::vector does.
This commit is contained in:
Lioncash 2020-03-18 00:28:42 -04:00
parent 6ddbd15cfc
commit 2701f060ee
1 changed files with 1 additions and 3 deletions

View File

@ -2,9 +2,7 @@
namespace urde {
CRumbleVoice::CRumbleVoice() {
x0_datas.resize(4);
x10_deltas.resize(4, SAdsrDelta::Stopped());
CRumbleVoice::CRumbleVoice() : x0_datas(4), x10_deltas(4, SAdsrDelta::Stopped()) {
x20_handleIds.resize(4);
}