FIX - harden inventory contracts and resolve phone interaction issues (#20)

* FIX - repair inventory metadata and ESX contracts

Use the stable core_inventory metadata setter and validate the complete inventory adapter contract after provider bridges load. Preserve the real ESX configuration error instead of cascading into a missing RegisterUsableItem failure.

* FIX - clarify phone opening without SIM

* FIX - harden inventory and device contracts

Validate SIM number configuration before item handling, preserve QB metadata mutation contracts, and propagate phone-open failures to callers. Extend regression coverage for inventory bridges and device bootstrap errors.

* FIX - resolve reported phone interaction issues

Stop game-input passthrough while NUI text fields are focused and add an independent hold-to-look option. Propagate SIM number formatting to the frontend, migrate configured currency symbols to utf8mb4, and clarify SkyRide, VaultX, and DarkChat behavior with focused contract coverage.

* FIX - detect missing packaged phone UI

Validate the generated NUI entrypoint, its referenced assets, and required static media when the resource starts. Print an actionable server-console warning for incomplete source archives, package phone sounds through the manifest, and cover the detection contract with Lua regressions.
This commit is contained in:
DerEchteAlec
2026-08-21 17:19:27 +02:00
committed by GitHub
parent 698420584d
commit 97db163cd0
34 changed files with 912 additions and 79 deletions
+12
View File
@@ -2,6 +2,14 @@ Bridge.Database.AfterMigration("sky_phone", function()
SkyPhoneSim = {}
local valid_number_configuration, number_configuration_error = SkyPhoneSimNumber.ValidateConfiguration(
Config.Sim.NumberLength,
Config.Sim.NumberPrefix
)
if not valid_number_configuration then
error(("[sky_phone] Invalid SIM number configuration: %s."):format(number_configuration_error))
end
local unique_phones = Config.Phone.Unique ~= false
local sim_cards_enabled = Config.Sim.Enabled ~= false
local pending_insertions = {}
@@ -393,6 +401,10 @@ local function use_sim(source, used_item)
TriggerClientEvent("sky_phone:sim:picker", source, {
choices = choices,
number = sim.phone_number,
phoneNumberFormat = {
length = Config.Sim.NumberLength,
groups = Config.Sim.NumberGroups,
},
})
return true
end