Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GetVehicleNumberPlateText RPC not working. #2838

Open
Demigod916 opened this issue Oct 4, 2024 · 5 comments
Open

GetVehicleNumberPlateText RPC not working. #2838

Demigod916 opened this issue Oct 4, 2024 · 5 comments
Labels
bug triage Needs a preliminary assessment to determine the urgency and required action

Comments

@Demigod916
Copy link

Demigod916 commented Oct 4, 2024

What happened?

when calling the Native GetVehicleNumberPlateText on the server, it returns nothing. using the same native on the client returns the correct plate string value.

Expected result

the native should return the plate on both the client and server

Reproduction steps

  1. call GetVehicleNumberPlateText(entity) on a vehicle from the server
  2. print the result

Importancy

Slight inconvenience

Area(s)

FiveM, Natives

Specific version(s)

FiveM 10191, GTA 3095, Windows 11

Additional information

No response

@Demigod916 Demigod916 added bug triage Needs a preliminary assessment to determine the urgency and required action labels Oct 4, 2024
@AvarianKnight
Copy link
Contributor

AvarianKnight commented Oct 4, 2024

This isn't an RPC native, this was broken with this 02ea63f commit

There's already a PR open to fix this

See: #2834

Though it has a bunch of white space changes which is currently blocking the PR

@Demigod916
Copy link
Author

Demigod916 commented Oct 4, 2024

honestly i just assumed it as an RPC not sure why. Thanks for the info!

@AvarianKnight
Copy link
Contributor

Most (if not all) getters are read directly, setters like SET_PED_HEAD_BLEND_DATA are RPC natives.

@Demigod916
Copy link
Author

Right right. probably where my confusion was

@kasuganosoras
Copy link
Contributor

kasuganosoras commented Oct 5, 2024

I create a simple script to temporary fix this.

Install the getplate resource (Link in the end), and add a new line to your fxmanifest.lua for any resource that you want to use the GetVehicleNumberPlateText native.

For example:

server_scripts {
    '@getplate/server.lua', -- Add this line
    'server/main.lua'
}


Then you don't need to do any change of your resources, everything will work as before.

Just wait for FiveM to fix this issue, and then you can remove this line from your fxmanifest.lua.

Download: getplate.zip


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug triage Needs a preliminary assessment to determine the urgency and required action
Projects
None yet
Development

No branches or pull requests

3 participants