Ignore:
Timestamp:
Feb 18, 2011, 5:59:39 PM (14 years ago)
Author:
Torben Dannhauer
Message:

typo fix, clean up

File:
1 edited

Legend:

Unmodified
Added
Removed
  • osgVisual/trunk/src/sky_Silverlining/visual_skySilverLining.cpp

    r221 r247  
    9595       
    9696        SilverLining::LocalTime t = atmosphere->GetConditions()->GetTime();
    97         t.SetHour( hour_ );
    98         t.SetMinutes( minute_ );
    99         t.SetSeconds( second_ );
     97        if(hour_) t.SetHour( hour_ );
     98        if(minute_) t.SetMinutes( minute_ );
     99        if(second_) t.SetSeconds( second_ );
    100100        atmosphere->GetConditions()->SetTime( t );
    101101}
     
    108108
    109109        SilverLining::LocalTime t = atmosphere->GetConditions()->GetTime();
    110         t.SetYear( year_ );
    111         t.SetMonth( month_ );
    112         t.SetDay( day_ );
     110        if(year_) t.SetYear( year_ );
     111        if(month_) t.SetMonth( month_ );
     112        if(day_) t.SetDay( day_ );
    113113}
    114114
Note: See TracChangeset for help on using the changeset viewer.