[Release] Quit Command /quit [1.2]

@zee Fixed bby

Your /quit command won’t work, you’re not passing a valid player parameter. Also, there’s no need for the client, just use server and drop the client on the server with DropPlayer, likewise with what you have done with /disconnect.

It somehow does need the client tho, for the quit command. Vespura and I discussed this above. It’s designed to fully close FiveM, not just disconnect.

But triggering a server event which only contains DropPlayer() will only do the same as what it would do if you’re solely using the server – yes, I have tried this.

this code was used

This only dropped the client and led them back to the FiveM server list.

-- server:
RegisterNetEvent("dropSource")
AddEventHandler("dropSource", function()
    DropPlayer(source, "omg")
end)

-- client:
RegisterCommand("dc", function()
   TriggerServerEvent("dropSource")
end)

results in https://w.wew.wtf/htfqyd.png

The other alternative (which is what I was referencing in previous posts) would be:

-- server:
RegisterCommand("dc", function(source)
   DropPlayer(source, "You have disconnected.")
end)

… which would have the same result as the aforementioned code.