Since the introduction of player licenses those options donât do a anything when it comes to (non-)steam users trying to join.
If you only want players to join with steam enabled, youâd have to create a resource for it yourself.
A very simple example of such script would be something like this:
server.lua
AddEventHandler('playerConnecting', function(name, setCallback, deferrals)
-- mark this connection as deferred, this is to prevent problems while checking player identifiers.
deferrals.defer()
-- letting the user know what's going on.
deferrals.update("Checking for steam identifier...")
-- save source
local s = source
-- check for steam identifier
local allowed = false
for id in ipairs(GetPlayerIdentifiers(s)) do
if string.find(id, "steam:") then allowed = true end -- if the identifier is a steam identifier, allow the player.
end
if allowed then
deferrals.done()
else
deferrals.done("Sorry, you need to be running steam before you can join.")
end
end)
Iâve tried joining with those settings above, with Steam killed via Taskmanager, and cannot join. Steam is not a required element to play FiveM. My GTA V is Social Club only. I have steam and do not like it. I would like to be able to join without Steam. How can I do this?
FiveM stock allows you to connect without steam. Check your resources, if you are assembling from releases, you might have something on your server you donât know about.
AddEventHandler( âplayerConnectingâ, function( name, cb )
if ( Config.settings.steamOnly ) then
local id = DATASAVE:GetIdentifier( source, âsteamâ )
if ( id == nil ) then
cb( "This server requires you to be logged into the Steam client." )
CancelEvent()
end
end
I have similar problem. Just build a FXServer and cannot join to it, because I have the Rockstar Shop version, not bought from Steam Games.
Server says that I am a âbad guyâ (= I am the pirate version user).
So, legal Rockstar version users can not play FiveM?
I think the piracy protection By Rockstar is the Social Club. And I think that Steam protection is this logging-in-Steam kind of⌠Is there coming fix/ upgrade to FiveM that legal Rockstar players can join this FXServers too?
Thank you for the help, the code works as intended but conflicts with vrp for some reason. This is the error that I get when using this script. I tested it on three seperate occasions. I moved it to start before vrp and after vrp but the result is the same everytime. The server runs fine without the script loaded and a clear cache
Thank you for answering but it was more or less just showing that it didnât work for vrp. Hopefully it will help people that try to use it that have vrp