local Admins = { --Add Identifiers In The Given Format For Admins
{“steam:76561198348402374”, “license:0000000000000000000000000000000000000000”, “Gibo_37”},
cant seem to get this properly, sorry for being such a pain…
Thats not the ID you need.
Follow the instructions in the server.lua
, beginning at Line 16 to get the ID. (Steam has to be running of course)
thanks for you help i might be very thick cause i can´t seem to work this one out lol.
– Registering Server Events
–[[ To get your Identifier:
Add the Trainer to your Server Resources, run FiveM and join YOUR Server. Once your Ped Spawned, press the following Buttoncombination:
GAMEPAD:
--->>> LB/ L1 + RB / R1 + DPAD Down + A/ X. <<<---
KEYBOARD:
--->>> Button for VEHICLE AIM + Button for VEHICLE SHOOT + Button for PHONE DOWN + Button for PHONE UP. <<<---
It Outputs the Identifier in your RCON Log. Edit this File afterward.
]]
local Admins = { --Add Identifiers In The Given Format For Admins
{“steam:000000000000000”, “license:0000000000000000000000000000000000000000”, “Gibo_37”},
{“steam:000000000000000”, “license:0000000000000000000000000000000000000000”, “Admin Name”},
{“steam:000000000000000”, “license:0000000000000000000000000000000000000000”, “Admin Name”},
{“steam:000000000000000”, “license:0000000000000000000000000000000000000000”, “Admin Name”},
{“steam:000000000000000”, “license:0000000000000000000000000000000000000000”, “Admin Name”},
}
– General Stuff
AddEventHandler(“ID”, function() --Grants Access To The Menu
local FirstID = GetPlayerIdentifiers(source)[1]
local count = 0
for k, AdminIDs in pairs(Admins) do
if AdminIDs[1] == FirstID or AdminIDs[2] == FirstID then
print(k … “. Admin (” … AdminIDs[3] … “) spawned. Access to CHEM!CAL T0?!N granted!”)
TriggerClientEvent(“AdminActivation”, source, 1)
break
else
count = count + 1
if count == tablelength(Admins) then
TriggerClientEvent(“AdminActivation”, source, 0)
end
end
end
end)
AddEventHandler(“IsUsingSteam”, function() --Checks If The Player Uses Steam
local PlayerIdentifiers = GetPlayerIdentifiers(source)
local ID
for k, PlayerID in pairs(PlayerIdentifiers) do
local split = stringsplit(PlayerID, ":")
if split[1] == "steam" then
TriggerClientEvent("UsesSteam", source)
end
end
end)
AddEventHandler(“GetID”, function() --Used To Get The Steam Identifier
local IDs = GetPlayerIdentifiers(source)
if IDs[1] then
local IDType = stringsplit(IDs[1], “:”)
if IDType[1] == “ip” then
print(“First ID: " … IDs[1] … " – !!USE NOT RECOMMENDED!!”)
else
print("First ID: " … IDs[1])
end
if IDs[2] then
local IDType = stringsplit(IDs[2], “:”)
if IDType[1] == “ip” then
print(“Second ID: " … IDs[2] … " – !!USE NOT RECOMMENDED!!”)
else
print("Second ID: " … IDs[2])
end
if IDs[3] then
local IDType = stringsplit(IDs[3], “:”)
if IDType[1] == “ip” then
print(“Thrid ID: " … IDs[3] … " – !!USE NOT RECOMMENDED!!”)
else
print("Thrid ID: " … IDs[3])
end
end
one more question, I’m super admin and I do not have access, how can I release access to superadmin?
can i ask you in the server once i did lb ect it said check recon log where can i find it to finish the config?
@Adiliti36
Thats the server log, the CMD or Powershell Console on Windows or the Terminal on Linux.
@RMORAES
You have to add the Identifiers of the admins one by one in the server.lua
.
another quick question i have a rented server via ZAP-Hosting would that be a problem?
@Flatracer How can I get the steam id and the license?
Follow this steps:
- Start Steam and wait until it is started completly if you want to use the steam identifier
- Start FiveM and join your Server where FMODT is already “installed”
- Press this Buttoncombination with the GAMEPAD:
LB/ L1 + RB / R1 + DPAD Down + A/ X
or this Buttoncombination with the KEYBOARD:
Button for VEHICLE AIM + Button for VEHICLE SHOOT + Button for PHONE DOWN + Button for PHONE UP
- Check your RCON Log (server log, the CMD or Powershell Console on Windows or the Terminal on Linux)
working perfectly fine thanks very much for your help.
can i change time and weather in the server for everyone connected ?¿
Yes, that is possible.
Open the config.lua
, find this WorldAndNoClipOnlyAdmins = false
and change false
to true
. Afterward you as an admin can change the weather and time for every client.
Thanks for the new realse
How can I diseable the Voice-chat from your script.
I mean we use the voice parameter from the game and we prefer to use it.
As the player can select whisper, normal, scream
thanks for helping!
It is not easy to completly remove it but I will do so in the next version of the trainer if you want me to do it.
Ok or can I just comment the line that will disable may be
But don’t forget All what you done is just perfect!! Thanks again for sharing
Yeah, that is possible, but there are several thing you have to do then…
Let us begin with the admin.lua
. Open it and find this Line:
admin.lua
Line 6
local VoiceChatChannel = 0
Line 279 - 305
TriggerEvent("FMODT:Bool", VoiceChatTitle, VoiceChat, function(cb)
VoiceChat = cb
if VoiceChat then
drawNotification("~g~" .. VoiceChatEnableMessage .. "!")
else
drawNotification("~r~" .. VoiceChatDisableMessage .. "!")
end
end)
TriggerEvent("FMODT:Float", VoiceChatProximityTitle, VoiceChatProximity, 0.00, 8000.00, 2.50, 10, function(cb)
VoiceChatProximity = cb
if VoiceChatProximity == 0.00 then
drawNotification("~g~" .. VoiceChatProximityChangeToDefaultMessage .. "!")
else
drawNotification("~g~" .. VoiceChatProximityChangeMessage .. "!")
end
end)
TriggerEvent("FMODT:Int", VoiceChatChannelTitle, VoiceChatChannel, 0, 5, function(cb)
VoiceChatChannel = cb
if VoiceChatChannel == 0 then
NetworkClearVoiceChannel()
drawNotification("~g~" .. VoiceChatChannelChangeToDefaultMessage .. "!")
else
NetworkSetVoiceChannel(VoiceChatChannel)
end
end)
Line 475 - 476
TriggerServerEvent("VoiceChat", VoiceChat)
TriggerServerEvent("VoiceChatProximity", VoiceChatProximity)
Line 593 - 599
AddEventHandler("VoiceChatClient", function(State) --Enables/ Disables the Voice Chat
VoiceChat = State
end)
AddEventHandler("VoiceChatProximityClient", function(Proximity) --Changes the Voice Chat Proximity
VoiceChatProximity = Proximity
end)
Next is the misc.lua.
misc.lua
Line 905 - 917
Citizen.CreateThread(function() --Voice Chat
while true do
Citizen.Wait(0)
NetworkSetVoiceActive(VoiceChat)
end
end)
Citizen.CreateThread(function() --Voice Chat Proximity
while true do
Citizen.Wait(0)
NetworkSetTalkerProximity(VoiceChatProximity)
end
end)
Now we take a look at the config.lua
config.lua
Line 53 - 57
--Change "true" to "false" to disable the Voice Chat
VoiceChat = true
--Change the Float Value to change the default Voice Chat Proximity
VoiceChatProximity = 0.00 --In Meters, 0.00 means the whole Lobby
Last but not least, the server.lua
server.lua
Line 263 - 269
AddEventHandler("VoiceChat", function(State) --Enables/ Disables the Voice Chat on every Client
TriggerClientEvent("VoiceChatClient", -1, State)
end)
AddEventHandler("VoiceChatProximity", function(Proximity) --Changes the Voice Chat Proximity on every Client
TriggerClientEvent("VoiceChatProximityClient", -1, Proximity)
end)
Line 878 - 879
RegisterServerEvent("VoiceChat") --Just Don't Edit!
RegisterServerEvent("VoiceChatProximity") --Just Don't Edit!
Outcomment or remove them.
Thanks for the time you take to put all this information!
It’s work perfectly!! thanks you!
Hello All!,
Can you explain why the option for “Godmode” for the player is missing? I see that “Godmode” is in the “Player.lua” file but it does not reflect in the menu on the game. Is there another location that needs to be modified to have it show up?
Let me know if you can
Updated to v2.0.1
- Fixed a problem with the Player Godmode and Visibility
Download in the First Post!
@MIKEG Thanks for telling me about this problem, I made a mistake in the last release. Please redownload the file.