help me please

Runbu73

Участник
Автор темы
75
2
Is this used to restore the car? how could I implement an Imgui.Button? if imgui.Button(fa.ICON_FA_AIR_FRESHENER .. u8' Test', imgui.ImVec2(130, 25)) then clearCarLastWeaponDamage (car vehicle) end
 

MLycoris

Режим чтения
Проверенный
1,826
1,868
do I understand correctly, you want to restore the HP of the car by pressing the button?
Lua:
if imgui.Button('Repair car') then
    if isCharInAnyCar(1) then
        lua_thread.create(function()
            setCarRoll(storeCarCharIsInNoSave(1), 0)
            wait(100)
            setCarHealth(storeCarCharIsInNoSave(1), 1500)
            wait(100)
            fixCar(storeCarCharIsInNoSave(1))
        end)
    else sampAddChatMessage('Error',-1)
    end
end
 
  • Нравится
Реакции: Runbu73