esx:getSharesObject will come to EOL

Hello, I’m looking for a way to fix this situation.
Unfortunately, I’m somewhat new to the field. And what I’ve read doesn’t make me smart. Anyone know a way?

Hello @Deathliner,

you have to add this line shared_script '@es_extended/imports.lua' to the fxmanifest.lua of the outdated scripts.

Stay young and hungry
ZerX

1 Like

Unfortunately it did not work or I did something wrong

image

If you want the message to disappear, you have to remove every TriggerEvent with esx:getSharedObject.
The script will nevertheless work fine, when esx:getSharesObject will come to EOL

I understand the message also comes when the problem is fixed ? Very sad .
Thanks anyway for the tip

But have I inserted it correctly ?

1 Like

Yes, you have inserted it correctly.

1 Like

Hi, go to server.lua and find ESX = nil and

TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end)

and replace to ESX = exports["es_extended"]:getSharedObject()

Go client.lua find ESX = nil and replace ESX = exports["es_extended"]:getSharedObject()

go to fxmanifest.lua and add dependencies { 'es_extended' } and shared_script { '@es_extended/imports.lua' }

1 Like

thank you , I will try it today right away

what exactly is my mistake ?


if have this in server.lua just delete and add === ESX = exports["es_extended"]:getSharedObject()

image
If have this in server.lua change to ESX = exports["es_extended"]:getSharedObject()

fxmanifest.lua
image

an example

old server:
image

new server:
image


old client:
image

new client:
image

new fx:
image

image

here it works very well .
it seems to be a problem with the single script.
thank you very much

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.