Using server natives with C#

@magnesium sorry i’m new to dev, can you please give me an exemple on how to use the CitizenFX.Core.Native.API
(just in few lines )

Oooo, me me me…

“Just like any other C# library”

Oh… It’s just the one… My bad, you said you wanted a few lines :stuck_out_tongue:

1 Like

when i try to use is i have only 29 method, or in the screen shot i think he got more
image

That’s because you need to call the native function. I think it’s Function.Call and you pass it a hash for the native.

1 Like

image
they are givin the same result
but maybe I miss understanding the whole thing
My goal is to use those function in a structural way with C# (if possible)

https://runtime.fivem.net/doc/reference.html#_0x424D4687FA1E5652

That’s because there’s only that few on the server. Try making a client script, using the client’s CitizenFX.Core.dll.

1 Like

ok, they are all using a framework that masks the complexity.
yes, it will be easy but it limits your creativity
anyway thank you, if I figure out how to do it I will post back here.

Rude much kid?

Rude much kid???

You realize that was from 2017? And how was he rude lol

:joy::joy::joy::joy:
Oh god. Thanks for the necromancy. Gave me a right laugh. Going to close as it’s an extremely old thread.