16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-19 03:09:18 +02:00

button audio positioning fix

This commit is contained in:
tmj-fstate
2019-01-20 15:12:59 +01:00
parent 330e52d4fc
commit 0ad2a142c1
3 changed files with 34 additions and 21 deletions

View File

@@ -18,11 +18,10 @@ http://mozilla.org/MPL/2.0/.
void TButton::Clear(int i)
{
pModelOn = nullptr;
pModelOff = nullptr;
m_state = false;
if (i >= 0)
FeedbackBitSet(i);
*this = TButton();
if( i >= 0 ) {
FeedbackBitSet( i );
}
Update(); // kasowanie bitu Feedback, o ile jakiś ustawiony
};
@@ -63,7 +62,7 @@ void TButton::Load( cParser &Parser, TDynamicObject const *Owner ) {
std::array<TModel3d *, 3> sources { Owner->mdKabina, Owner->mdLowPolyInt, Owner->mdModel };
for( auto const *source : sources ) {
if( true == Init( submodelname, source, false ) ) {
// got what we wanted, bail out
// got what we wanted, don't need to search further
break;
}
}