[Release] Change Pause Menu Name

You must be doing something wrong, it works completely fine, the job changes based on SQL perms, Name and ID change on the player.

1 Like

What can i do wrong?

If it stops working after a certain amount there must be an error, show me your code.

1 Like

This works fine tested it with someone else in the server.

function SetData()
	local name = GetPlayerName(PlayerId())
	local id = GetPlayerServerId(PlayerId())
	Citizen.InvokeNative(GetHashKey("ADD_TEXT_ENTRY"), 'FE_THDR_GTAO', '~y~TGA Roleplay ~t~| ~g~Discord: x7u54NH~t~ | ~b~ID: ' .. id .. ' ~t~| ~b~Name: ~b~' .. name)
end

Citizen.CreateThread(function()
	while true do
		Citizen.Wait(100)
		SetData()
	end
end)
1 Like

So this is how the code is now but how can i add so it allso says how many online?

function SetData()
	local name = GetPlayerName(PlayerId())
	local id = GetPlayerServerId(PlayerId())
	Citizen.InvokeNative(GetHashKey("ADD_TEXT_ENTRY"), 'FE_THDR_GTAO', '~y~TGA Roleplay ~t~| ~g~Discord: x7u54NH~t~ | ~b~ID: ' .. id .. ' ~t~| ~b~Name: ~b~' .. name)
end

Citizen.CreateThread(function()
	while true do
		Citizen.Wait(100)
		SetData()
	end
end)

Here you go

function SetData()
	players = {}
	for i = 0, 31 do
		if NetworkIsPlayerActive( i ) then
			table.insert( players, i )
		end
	end
	
	local name = GetPlayerName(PlayerId())
	local id = GetPlayerServerId(PlayerId())
	Citizen.InvokeNative(GetHashKey("ADD_TEXT_ENTRY"), 'FE_THDR_GTAO', '~y~TGA Roleplay ~t~| ~g~Discord: x7u54NH~t~ | ~b~ID: ' .. id .. ' ~t~| ~b~Name: ~b~' .. name .. " ~r~Players: " .. #players .. "/32")
end

Citizen.CreateThread(function()
	while true do
		Citizen.Wait(100)
		SetData()
	end
end)

4 Likes

Ahh okay thanks man I was sitting here and was trying but im so bad with scripts lol


Edit:

Is there anny way to remove this

499594

2 Likes

can you tell me how to get the AOP code? Thanks :slight_smile:

Just reference your AOP variables and enter them in there e.g.

("Current AOP: " .. aop1 .. " " .. aop2)
1 Like

I haven’t messed with those, try this I am unsure if it disables your cash or removes an amount of MP cash from you https://runtime.fivem.net/doc/natives/#_0xC7C6789AA1CFEDD0

It is in the hud section so it should remove it.

Okay cool thanks


but where do I put this code I know im an idiot now

REMOVE_MULTIPLAYER_BANK_CASH

But i have never used that stuff before lol


Speaking of removing things in the pause menu, is it possible to edit where it says Mission? To make it say Rules and show the rules for example?

I know this is a stupid question but will this interfere with an ESX Framework?

1 Like

no it should not as ESX does not touch the pause menu afaik.

1 Like

Thanks. I knew it was a stupid question but had to make sure. How can I put total players on it? Is that possible?

I believe there is a resource on the forums already for just that. :slight_smile:

1 Like

Thanks.

I would to have the numbers of online players in Pause Menu ? How can i do knowing i already tested this

local onlinePlayers = NetworkGetNumConnectedPlayers()

1 Like

How do get the job to set up

Hello,

Does someone have an example, on how it can be working with OneSync Infinity

Thanks in advance

i too need help plz help me add job like this