mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-09 23:07:43 +00:00
CIntElement: Remove const_cast
CIESampleAndHold caches values internally for use later in a non-visible manner to the user of the class. This is a good place for mutable to be used. This improves the readability of the GetValue() implementation.
This commit is contained in:
@@ -134,10 +134,10 @@ public:
|
||||
|
||||
class CIESampleAndHold : public CIntElement {
|
||||
std::unique_ptr<CIntElement> x4_sampleSource;
|
||||
int x8_nextSampleFrame = 0;
|
||||
mutable int x8_nextSampleFrame = 0;
|
||||
std::unique_ptr<CIntElement> xc_waitFramesMin;
|
||||
std::unique_ptr<CIntElement> x10_waitFramesMax;
|
||||
int x14_holdVal;
|
||||
mutable int x14_holdVal;
|
||||
|
||||
public:
|
||||
CIESampleAndHold(std::unique_ptr<CIntElement>&& a, std::unique_ptr<CIntElement>&& b, std::unique_ptr<CIntElement>&& c)
|
||||
|
||||
Reference in New Issue
Block a user