[How-to] [Updated] Discord rich presence Custom Image šŸž

Or no? I have changed it to the right one but still does not work? lol

1 Like
Citizen.CreateThread(function()
	while true do
		Citizen.Wait(10000) -- in MS
		SetDiscordAppId(123456789101112) -- This is the bot client ID
		SetDiscordRichPresenceAsset('large_asset_name_here')
		SetDiscordRichPresenceAssetText('whatever_you_want_large_hover_to_say')
		SetDiscordRichPresenceAssetSmall('small_asset_name_here')
		SetDiscordRichPresenceAssetSmallText('whatever_you_want_small_hover_to_say')
		SetRichPresence('words_here')
	end
end)

Sadly does not work

Well I donā€™t know what to tell you. Not sure why youā€™re blocking the Client ID as the general public canā€™t do anything with that number.

Escape the 's if itā€™s inside the string, or use "s for the string.

1 Like

Arrh maybe will try thanks. Will comment if it worked

Hey Can some One help me how i make it so that you See the id from the Player in the Text Where the pictures are too?

Hey! I need help with pulling the players ID and showing it in the text as well, along with maybe their character names - would be super nice for RP servers. Unfortunately the codes that youā€™ve written above doesnā€™t work. Iā€™m running vRP. Let me know if you can help, always willing to provide something back as well. :smile:

ID - GetPlayerServerId(PlayerId()) For character names that would depend on whatever you are using to store the player names.

1 Like

Hey! Yeps, Iā€™ve tried that, but it pulls the ID depending on who joined the server first - an example would be me owning the server and being ID 1. However, if I join second (when thereā€™s already someone on the server), Rich Presence would show Iā€™m ID 2, and the person who joined first would be ID 1. https://gyazo.com/f0ca17e514a0f6689cb19b44b78fd12d

But that is normal behaviour.

Hm, not exactly what I was looking for. How would I go about pulling their actual in-game assigned ID from the database to Rich Presence then? This also goes for the PlayerName thing, Iā€™d like to pull their first name from the database to rich presence, etc.

Do the query server side then pass it to the client.

1 Like

I know Iā€™m being a total blimbo now, but how would I go about doing that? Iā€™m just starting out trying to do some coding work, so Iā€™m mainly just editing files right now - starting off with this one. :smiley:

I canā€™t think right now, Iā€™m tired. Iā€™m sure somebody else will reply when Iā€™m :zzz:-ing. Probably best if I donā€™t reply right now anyway, otherwise Iā€™d probably give some false information.

For an RP environment, - unless youā€™re using it for Discord moderation - Iā€™d suggest keeping semi-sensitive information out of it. People can get quite creative about what they do with IDs, so on and so forth.

2 Likes

Appreciate the help nonetheless, sleep tight! :sleeping:

1 Like

Eyyyy friendo! Yeah, itā€™d be both for moderation, but also so we can easily track people through rcon and rich presence. :slight_smile:

Hey, nobody ever came to my rescue :smiley:

How you do the 2/64?