Merge branch 'master' of github.com:supertuxkart/stk-code

This commit is contained in:
hiker 2018-11-13 22:22:20 +11:00
commit 463301091b
8 changed files with 30 additions and 18 deletions

View File

@ -3,7 +3,7 @@
<unlock_list list="false"/>
<track id="fortmagma" laps="3" reverse="false"/>
<mode major="single" minor="quickrace"/>
<requirements trophies="190" challenges="25"/>
<requirements trophies="190" challenges="24"/>
<best>
<karts number="2" aiIdent="nolok" superPower="nolokBoss"/>

View File

@ -5,8 +5,10 @@
<model id="model" width="100%" layout="horizontal-row" height="100%">
</model>
</div>
<div width="40%" height="fit" text-align="left" layout="horizontal-row" >
<spinner id="toggle-slider" width="100%" min_value="0" max_value="1" wrap_around="true"/>
<div width="100%" height="fit" text-align="left" layout="horizontal-row" >
<spacer height="30" width="15%"/>
<spinner id="toggle-slider" width="70%" min_value="0" max_value="1" wrap_around="true"/>
<spacer height="30" width="15%"/>
</div>
<spacer height="30" width="10"/>
<div height="fit" width="100%" layout="horizontal-row">

View File

@ -548,7 +548,12 @@
-->
<network-ports server-discovery-port="2757" client-port="2758" server-port="2759"/>
<!-- Configurable values used in SmoothNetworkBody class.
<!-- Configurable values used in SmoothNetworkBody class:
min-adjust-length and max-adjust-length: Error in length smaller or larger
than this value will be ignored (ie show the real position).
min-adjust-speed: Minimum linear velocity required by a body to have smoothing.
max-adjust-time: Maximum time spent in each smoothing stage.
adjust-length-threshold: The higher this value, the larger the correction curve.
-->
<network-smoothing min-adjust-length="0.1"
max-adjust-length="4.0"

View File

@ -291,7 +291,7 @@ public:
return m_id < a.m_id;
break;
case SO_DATE:
return m_date > a.m_date;
return m_date < a.m_date;
break;
} // switch
// Fix compiler warning.

View File

@ -1738,10 +1738,10 @@ void Skin::drawListHeader(const irr::core::rect< irr::s32 > &rect,
ITexture* img;
if (((ListWidget*)widget->m_event_handler)->m_sort_desc)
img =
SkinConfig::m_render_params["list_sort_up::neutral"].getImage();
SkinConfig::m_render_params["list_sort_down::neutral"].getImage();
else
img =
SkinConfig::m_render_params["list_sort_down::neutral"].getImage();
SkinConfig::m_render_params["list_sort_up::neutral"].getImage();
core::recti destRect(rect.UpperLeftCorner,
core::dimension2di(rect.getHeight(),

View File

@ -307,7 +307,7 @@ void LocalPlayerController::displayPenaltyWarning()
m->addMessage(_("Penalty time!!"), m_kart, 2.0f,
GUIEngine::getSkin()->getColor("font::top"), true /* important */,
false /* big font */, true /* outline */);
m->addMessage(_("Don't accelerate before go"), m_kart, 2.0f,
m->addMessage(_("Don't accelerate before 'Set!'"), m_kart, 2.0f,
GUIEngine::getSkin()->getColor("font::normal"), true /* important */,
false /* big font */, true /* outline */);
}

View File

@ -77,10 +77,6 @@ void SmoothNetworkBody::checkSmoothing(const btTransform& current_transform,
if (adjust_time > m_max_adjust_time)
return;
m_smoothing = SS_TO_ADJUST;
m_adjust_time_dt = 0.0f;
m_adjust_time = adjust_time;
m_start_smoothing_postion.first = m_smoothing == SS_NONE ?
m_prev_position_data.first.getOrigin() :
m_smoothed_transform.getOrigin();
@ -89,6 +85,10 @@ void SmoothNetworkBody::checkSmoothing(const btTransform& current_transform,
m_smoothed_transform.getRotation();
m_start_smoothing_postion.second.normalize();
m_smoothing = SS_TO_ADJUST;
m_adjust_time_dt = 0.0f;
m_adjust_time = adjust_time;
m_adjust_control_point = m_start_smoothing_postion.first +
m_prev_position_data.second * m_adjust_time;
Vec3 p2 = current_transform.getOrigin() + current_velocity * m_adjust_time;

View File

@ -1645,12 +1645,17 @@ void RaceResultGUI::displayCTFResults()
if (race_manager->modeHasLaps())
{
float best_lap_time = static_cast<LinearWorld*>(World::getWorld())->getFastestLap();
core::stringw best_lap_string = _("Best lap time: %s",
StringUtils::timeToString(best_lap_time, time_precision).c_str());
current_y += int(m_distance_between_rows * 0.8f);
GUIEngine::getFont()->draw(best_lap_string,
core::recti(x, current_y, 0, 0), white_color, false, false,
nullptr, true);
// The fastest lap ticks is set to INT_MAX, so the best_lap_time will be
// very high when none has been set yet.
if (best_lap_time <= 3600.0)
{
core::stringw best_lap_string = _("Best lap time: %s",
StringUtils::timeToString(best_lap_time, time_precision).c_str());
current_y += int(m_distance_between_rows * 0.8f);
GUIEngine::getFont()->draw(best_lap_string,
core::recti(x, current_y, 0, 0), white_color, false, false,
nullptr, true);
}
} // if mode has laps
} // if not soccer mode
#endif