Mettre les notifications dans ESX

Allez dans votre es_extended/client/functions.lua et remplacer cela

function ESX.ShowAdvancedNotification(title, img, subtitle, description, duration)
    AddTextEntry("esxAdvancedNotification", msg)
    BeginTextCommandThefeedPost("esxAdvancedNotification")
    if hudColorIndex then
        ThefeedSetNextPostBackgroundColor(hudColorIndex)
    end
    EndTextCommandThefeedPostMessagetext(textureDict, textureDict, false, iconType, sender, subject)
    EndTextCommandThefeedPostTicker(flash, saveToBrief == nil or saveToBrief)
end

function ESX.ShowNotification(message, duration)
	return IsResourceFound('esx_notify') and exports['esx_notify']:Notify(notifyType, length, message),
end

Par ceci

function ESX.ShowNotification(message, notifyType, length)
	exports["mNotification"]:ShowSimpleNotification(message, length or 5000 )
end

function ESX.ShowAdvancedNotification(sender, subject, msg, textureDict, iconType, flash, saveToBrief, hudColorIndex, duration)
    exports["mNotification"]:ShowAdvancedNotification(subject, textureDict, sender, msg, duration or 5000)
end

Pour ajoute les notifications simple avec progress voici une function à ajouté a ESX

function ESX.ShowNotificationMaro(text, duration)
    exports["mNotification"]:ShowSimpleNotificationProgress(text, duration or 7500)
end

Dernière mise à jour