qbcore-framework / qb-cityhall Goto Github PK
View Code? Open in Web Editor NEWCity Hall Script For QB-Core
License: GNU General Public License v3.0
City Hall Script For QB-Core
License: GNU General Public License v3.0
Is it normal that i can buy unlimited IDs and Driver Licenses, even when i already have them in my inventory ?
Describe the bug
the peds used in city hall float no matter how many vectors ive tried is there a fix or something that can be done to bring them back to ground lvl?
Expected behavior
looking for them to be on ground level
Questions (please complete the following information):
qb-
to something custom? [no]Additional context
Add any other context about the problem here.
Make a tutorial how to make the license card so it shows what kind of license you have instead off class c license
for when i show my license its only saying Class c license when i have N and AM
This appears after receiving the weapons license - https://i.imgur.com/UYzSeD6.png
Weapons licenses are not showing in the city services
Describe the bug
A clear and concise description of what the bug is. A stranger to qbcore should be able to read your bug report and understand how to reproduce it themselves and understand how the feature should work normally.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
Questions (please complete the following information):
qb-
to something custom? [e.g. yes/no]Additional context
Add any other context about the problem here.
Seems as this is in the code but doesn't work.
I don't really understand scripts, but I'm learning, I added four jobs, everything was duplicated in the menu, I rummaged through the entire server, looked for where I did what wrong myself... I didn't find anything, finally replaced the html /app.js on the old one, everything worked fine
Please help me, I do not understand how to get a "weaponlicense", the weapons store requires a license, I got a job as a policeman but I did not understand how to give it to the player or myself, I got a "weaponlicense" in the inventory with the "giveitem" command, but the store still asks for a license
Can buy a driver license without driving test And theory. Set a notification that you are not allowed to buy a driver license without permission from the driving school boss.
Describe the bug
The CityHall ped disappears if you use /logout
and then respawn.
To Reproduce
Steps to reproduce the behavior:
/logout
Expected behavior
Ped should spawn on player connected
Questions (please complete the following information):
qb-
to something custom? NoAdditional context
Add any other context about the problem here.
How to set up newqb to prohibit giving a driver's license when entering the server for the first time. I looked at the old method and it seems that there is no such thing in line 42.
I have new idea for make it better about job cooldown
When I go to apply for a job via the NPC at city hall, like taxi for example, no notification comes up and I don't get the job. There are no errors in F8 and console. The jobs do exist. Not sure what else to do. Thank you for your help in advance!
Script works all good for me until I relog, when I come back and talk to the NPC, the licenses page works but the jobs page is empty (more like it's hidden) and I can only see the back button.
We are able to get the business license to show up in the list of Identification available , but players get kicked when trying to buy it. How do we fix this?
Describe the bug
I'm having the problem of when you issue the Weapon lic thru ps mdt or the /grantlic. command you go to the city hall and is does not show at all now i can go restart just city hall and it shows up then but i if i revoke the weapon lic and reissue it the lic it won't show up unless you restart the script then it shows up just fine.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Give Weapon Lic..
Screenshots
If applicable, add screenshots to help explain your problem.
Questions (please complete the following information):
qb-
to something custom? [NO]Additional context
Here is the Code for Grant Lic.
QBCore.Commands.Add("grantlicense", Lang:t("commands.license_grant"), {{name = "id", help = Lang:t('info.player_id')}, {name = "license", help = Lang:t('info.license_type')}}, true, function(source, args)
local src = source
local Player = QBCore.Functions.GetPlayer(src)
if Player.PlayerData.job.name == "police" and Player.PlayerData.job.grade.level >= Config.LicenseRank then
if args[2] == "driver" or args[2] == "weapon" then
local SearchedPlayer = QBCore.Functions.GetPlayer(tonumber(args[1]))
if not SearchedPlayer then return end
local licenseTable = SearchedPlayer.PlayerData.metadata["licences"]
if licenseTable[args[2]] then
TriggerClientEvent('QBCore:Notify', src, Lang:t("error.license_already"), "error")
return
end
licenseTable[args[2]] = true
SearchedPlayer.Functions.SetMetaData("licences", licenseTable)
TriggerClientEvent('QBCore:Notify', SearchedPlayer.PlayerData.source, Lang:t("success.granted_license"), "success")
TriggerClientEvent('QBCore:Notify', src, Lang:t("success.grant_license"), "success")
else
TriggerClientEvent('QBCore:Notify', src, Lang:t("error.error_license_type"), "error")
end
else
TriggerClientEvent('QBCore:Notify', src, Lang:t("error.rank_license"), "error")
end
end)
QBCore.Commands.Add("revokelicense", Lang:t("commands.license_revoke"), {{name = "id", help = Lang:t('info.player_id')}, {name = "license", help = Lang:t('info.license_type')}}, true, function(source, args)
local src = source
local Player = QBCore.Functions.GetPlayer(src)
if Player.PlayerData.job.name == "police" and Player.PlayerData.job.grade.level >= Config.LicenseRank then
if args[2] == "driver" or args[2] == "weapon" then
local SearchedPlayer = QBCore.Functions.GetPlayer(tonumber(args[1]))
if not SearchedPlayer then return end
local licenseTable = SearchedPlayer.PlayerData.metadata["licences"]
if not licenseTable[args[2]] then
TriggerClientEvent('QBCore:Notify', src, Lang:t("error.error_license"), "error")
return
end
licenseTable[args[2]] = false
SearchedPlayer.Functions.SetMetaData("licences", licenseTable)
TriggerClientEvent('QBCore:Notify', SearchedPlayer.PlayerData.source, Lang:t("error.revoked_license"), "error")
TriggerClientEvent('QBCore:Notify', src, Lang:t("success.revoke_license"), "success")
else
TriggerClientEvent('QBCore:Notify', src, Lang:t("error.error_license"), "error")
end
else
TriggerClientEvent('QBCore:Notify', src, Lang:t("error.rank_revoke"), "error")
end
end)
I have tried going to a discord support call but no one was wanting too help out on this any help will be helpful. THANK YOU!!!
if you have 0 cash on you , you can buy as much free licenses as you want and it doesn't even check for the bank .
The menu after it closes freezes your character, as if the menu is still open.
Describe the bug
Using /tpm
to tp to the cityhall puts you on the roof of the building and the menu is still accessible up there. If you select a job while still on the roof, you get kicked for "Attempted exploit abuse"
To Reproduce
Steps to reproduce the behavior:
setr UseTarget false
in server.cfg
/tpm
Expected behavior
I would expect to not be TP'd to the roof, and also while on the roof, the menu should not be accessible.
Questions (please complete the following information):
qb-
to something custom? NoAdditional context
N/A
I can't get firearm licenses, I don't know why
Is there a way to remove the default driving license and have the ability to give the license based on a dmv test? So basically a whitelist for a driving license given by the instructor?
Hi,
I have found an issue with when you have had your license revoked and attempt to buy another then the attached is thrown.
Also when you go to the town hall there are no prompts to allow you to request to take a driving test.
If a license is revoked how do you ask for this back and should the police actually remove this from you?
Thanks in advance.
Angie
Hi,
I noticed on pictures provided in this script that there has to be an option to buy the drivers license in the cityhall. Only on the latest version you can only buy an id card.
My fault. Didnt noticed another admin took my driverlicense with the /revoke option as a cop
I updated cityhall and towjob and was going through configurating other jobs, come to get the towjob via city hall and when I click on the job I get instantly banned:
Connection rejected by server: You have been banned from the server: Abuse localhost:13172 For POST Requests Your ban expires 22/8/2021 21:12 Abuse localhost:13172 For POST Requests
I see it's this thread:
RegisterServerEvent('qb-cityhall:server:banPlayer') AddEventHandler('qb-cityhall:server:banPlayer', function() local src = source TriggerClientEvent('chatMessage', -1, "QB Anti-Cheat", "error", GetPlayerName(src).." has been banned for sending POST Request's ") exports.ghmattimysql:execute('INSERT INTO bans (name, license, discord, ip, reason, expire, bannedby) VALUES (@name, @license, @discord, @ip, @reason, @expire, @bannedby)', { ['@name'] = GetPlayerName(src), ['@license'] = QBCore.Functions.GetIdentifier(src, 'license'), ['@discord'] = QBCore.Functions.GetIdentifier(src, 'discord'), ['@ip'] = QBCore.Functions.GetIdentifier(src, 'ip'), ['@reason'] = 'Abuse localhost:13172 For POST Requests', ['@expire'] = 2145913200, ['@bannedby'] = GetPlayerName(src) }) DropPlayer(src, 'Attempting To Exploit') end)
I have no idea what is causing it?
I also removed the newsreporter job from the resources and the button was still in the HTML and it did the same thing.
Describe the bug
As the title reads, for some reason players cannot purchase a physical copy of their weapons license from City Hall. If they try, FiveM somehow sees this as an attempted exploit and boots them from the server.
To Reproduce
Steps to reproduce the behavior:
Coordinates to DrivingSchool and DriveTest on config.lua lead to inside of some buildings without map.
With the updated hotdog job, it's no longer a open job, so I ended up putting, this into server main of city hall. Line9.
["hotdog"] = "Hot Dog",
I have a qbcore server and I have Changed the qb-police to wasabi-police but when I Issue a weapon licence and they go to city hall they Weapon licence is not there.
Is there something I need to change in thidescript and if so can someone please help me and where I need to change it?
The error we get:
[ script:qb-cityhall] SCRIPT ERROR: @qb-cityhall/server/main.lua:114: attempt to index a nil value (field 'Jobs')
The block of Code its referencing:
RegisterNetEvent('qb-cityhall:server:ApplyJob', function(job, cityhallCoords)
local src = source
local Player = QBCore.Functions.GetPlayer(src)
if not Player then return end
local ped = GetPlayerPed(src)
local pedCoords = GetEntityCoords(ped)
local JobInfo = QBCore.Shared.Jobs[job]
if #(pedCoords - cityhallCoords) >= 20.0 or not availableJobs[job] then
return DropPlayer(source, "Attempted exploit abuse")
We go to the guy in City Hall apply for the job doesnt matter which one. This is what happens
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.