mirror of
https://github.com/jimathy/jim-consumables.git
synced 2026-08-17 06:26:03 +01:00
Change the "Stop Consuming" popup
It was originally using `drawText` to use framework ui to display `[BACKSPACE] Stop Consuming` Changed to display an instructional native ui popup on the bottom right of the screen
This commit is contained in:
@@ -218,18 +218,20 @@ RegisterNetEvent(getScript()..':Consume', function(itemName)
|
|||||||
end)
|
end)
|
||||||
|
|
||||||
while consuming do
|
while consuming do
|
||||||
local drawTable = debugMode and
|
if debugMode then
|
||||||
{ "[BackSpace] Stop Consuming",
|
drawText(nil, {
|
||||||
"Time: "..tostring(time),
|
"Time: "..tostring(time),
|
||||||
"Type: "..(type or ""),
|
"Type: "..(type or ""),
|
||||||
"Hunger: "..(needStats.hunger or 0).."%",
|
"Hunger: "..(needStats.hunger or 0).."%",
|
||||||
"Thirst: "..(needStats.thirst or 0).."%",
|
"Thirst: "..(needStats.thirst or 0).."%",
|
||||||
"Stress: "..(stress or 0).."%",
|
"Stress: "..(stress or 0).."%",
|
||||||
"Heal: "..(heal or 0).."%",
|
"Heal: "..(heal or 0).."%",
|
||||||
"Armour: "..(armor or 0).."%",
|
"Armour: "..(armor or 0).."%",
|
||||||
} or
|
}, nil, nil)
|
||||||
{ "[BackSpace] Stop Consuming", }
|
end
|
||||||
drawText(nil, drawTable, nil, nil)
|
makeInstructionalButtons({
|
||||||
|
{ keys = { 194 }, text = "Stop Consuming" },
|
||||||
|
})
|
||||||
if time <= 0 then
|
if time <= 0 then
|
||||||
consuming = false
|
consuming = false
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user