mirror of
https://github.com/Mr-X-GTA/YimMenu.git
synced 2025-06-17 23:07:26 +08:00
28 lines
646 B
C++
28 lines
646 B
C++
![]() |
#include "backend/looped/looped.hpp"
|
||
|
#include "core/enums.hpp"
|
||
|
#include "natives.hpp"
|
||
|
|
||
|
namespace big
|
||
|
{
|
||
|
void looped::vehicle_boost_behavior()
|
||
|
{
|
||
|
auto* const vehicle = g_local_player->m_vehicle;
|
||
|
|
||
|
if (vehicle && VEHICLE::GET_HAS_ROCKET_BOOST_(self::veh))
|
||
|
{
|
||
|
if (g->vehicle.boost_behavior == eBoostBehaviors::INSTANT_REFIL && vehicle->m_boost == 0.f) // No Boost Refil Time
|
||
|
{
|
||
|
vehicle->m_boost = 1.f;
|
||
|
}
|
||
|
else if (g->vehicle.boost_behavior == eBoostBehaviors::INFINITE_BOOST) // Infinite Boost
|
||
|
{
|
||
|
if (vehicle->m_boost_state)
|
||
|
{
|
||
|
vehicle->m_boost_allow_recharge = true;
|
||
|
vehicle->m_boost = 1.f;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|