fix(SuperSprint): Only sprint while ped is sprinting

This commit is contained in:
Yimura
2021-01-01 15:23:47 +01:00
parent 8db3827846
commit 5bd71c2c55

View File

@ -12,7 +12,7 @@ namespace big
{
QUEUE_JOB_BEGIN_CLAUSE(= )
{
if (PAD::IS_CONTROL_PRESSED(0, 32))
if (TASK::IS_PED_SPRINTING(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_playerId)))
{
Ped player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_playerId);
@ -22,6 +22,10 @@ namespace big
PLAYER::SET_PLAYER_SPRINT(g_playerId, 1);
PLAYER::SET_RUN_SPRINT_MULTIPLIER_FOR_PLAYER(g_playerId, 1.49);
}
else
{
PLAYER::SET_RUN_SPRINT_MULTIPLIER_FOR_PLAYER(g_playerId, 1.0);
}
}QUEUE_JOB_END_CLAUSE
}
else if (!bSuperSprint && bSuperSprint != bLastSuperSprint)