mirror of
https://github.com/OpenMW/openmw.git
synced 2025-10-18 05:16:40 +00:00
more similar to vanilla
This commit is contained in:
parent
abbbeefdbd
commit
77c30a68c9
5 changed files with 7 additions and 8 deletions
|
@ -23,7 +23,7 @@ namespace MWGui
|
||||||
: WindowBase("openmw_jail_screen.layout")
|
: WindowBase("openmw_jail_screen.layout")
|
||||||
, mDays(1)
|
, mDays(1)
|
||||||
, mFadeTimeRemaining(0)
|
, mFadeTimeRemaining(0)
|
||||||
, mTimeAdvancer(0.01f)
|
, mTimeAdvancer()
|
||||||
{
|
{
|
||||||
getWidget(mProgressBar, "ProgressBar");
|
getWidget(mProgressBar, "ProgressBar");
|
||||||
|
|
||||||
|
|
|
@ -2,13 +2,12 @@
|
||||||
|
|
||||||
namespace MWGui
|
namespace MWGui
|
||||||
{
|
{
|
||||||
TimeAdvancer::TimeAdvancer(float delay)
|
TimeAdvancer::TimeAdvancer()
|
||||||
: mRunning(false)
|
: mRunning(false)
|
||||||
, mCurHour(0)
|
, mCurHour(0)
|
||||||
, mHours(1)
|
, mHours(1)
|
||||||
, mInterruptAt(-1)
|
, mInterruptAt(-1)
|
||||||
, mDelay(delay)
|
, mRemainingTime(mDelay)
|
||||||
, mRemainingTime(delay)
|
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ namespace MWGui
|
||||||
class TimeAdvancer
|
class TimeAdvancer
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
TimeAdvancer(float delay);
|
TimeAdvancer();
|
||||||
|
|
||||||
void run(int hours, int interruptAt = -1);
|
void run(int hours, int interruptAt = -1);
|
||||||
void stop();
|
void stop();
|
||||||
|
@ -32,7 +32,7 @@ namespace MWGui
|
||||||
int mHours;
|
int mHours;
|
||||||
int mInterruptAt;
|
int mInterruptAt;
|
||||||
|
|
||||||
float mDelay;
|
static constexpr float mDelay = 1.0f / 60.0f;
|
||||||
float mRemainingTime;
|
float mRemainingTime;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,7 +27,7 @@ namespace MWGui
|
||||||
|
|
||||||
TrainingWindow::TrainingWindow()
|
TrainingWindow::TrainingWindow()
|
||||||
: WindowBase("openmw_trainingwindow.layout")
|
: WindowBase("openmw_trainingwindow.layout")
|
||||||
, mTimeAdvancer(0.05f)
|
, mTimeAdvancer()
|
||||||
{
|
{
|
||||||
getWidget(mTrainingOptions, "TrainingOptions");
|
getWidget(mTrainingOptions, "TrainingOptions");
|
||||||
getWidget(mCancelButton, "CancelButton");
|
getWidget(mCancelButton, "CancelButton");
|
||||||
|
|
|
@ -52,7 +52,7 @@ namespace MWGui
|
||||||
|
|
||||||
WaitDialog::WaitDialog()
|
WaitDialog::WaitDialog()
|
||||||
: WindowBase("openmw_wait_dialog.layout")
|
: WindowBase("openmw_wait_dialog.layout")
|
||||||
, mTimeAdvancer(0.05f)
|
, mTimeAdvancer()
|
||||||
, mSleeping(false)
|
, mSleeping(false)
|
||||||
, mHours(1)
|
, mHours(1)
|
||||||
, mManualHours(1)
|
, mManualHours(1)
|
||||||
|
|
Loading…
Reference in a new issue