Jump to content

How do I access the methods inside LSPDFR?


Antares

Recommended Posts

Hello everyone. 

I am new to the modding scene for GTAV, but not C#.

I am trying to write a script. It doesn't add anything, just makes it more realistic for those of us who likes realism.

I am trying to figure out how to access the methods inside LSPDFR. Mainly those those that the B and N default buttons call to.

For example... When you walk up to a suspect and press E and select "Ask for ID"

I do only need a way to see the methods. Not necessarily the code inside of the methods themselves though. Mainly for the Vanilla LSPDFR but maybe later for mods which I will ask directly before coming here.

Thank you and have a good day.

 

(if any more explanation is needed. ask but please be specific. :) )

regards,

Antares.

Link to comment
Share on other sites

You can only access the methods available in the API namespace (and a few outside of it, however these are likely to be removed from public access).

If it isn't inside the API namespace then you can't access it. You can use the object viewer in visual studio to see what you have access to.

Live Streaming daily from 8pm GMT (UK) at https://twitch.tv/OfficialLukeD - I play a variety of things 😄

Join my official discord server for support, general chat and my stream schedule! https://discord.gg/Mddj7PQ

Link to comment
Share on other sites

LukeD, Thanks for the quick response.

For example. EBackupResponseType shows Code2, Code3, Pursuit, and SuspectTransporter which I am sure calls the appropriate method to make things happen. but I need to by pass those, or send the correct code to the class/method that is called by these. I really can't find it for the life of me... I haven't done this for a little while. 

Link to comment
Share on other sites

4 minutes ago, Antares said:

LukeD, Thanks for the quick response.

For example. EBackupResponseType shows Code2, Code3, Pursuit, and SuspectTransporter which I am sure calls the appropriate method to make things happen. but I need to by pass those, or send the correct code to the class/method that is called by these. I really can't find it for the life of me... I haven't done this for a little while. 

I don't think what you're trying to do is possible without using code which has the potential to be hidden from public access. Have a serious browse through the object viewer, as this is the best form of documentation the API has at the moment, aside of course from the various guides and such members have put in this forum section.

Live Streaming daily from 8pm GMT (UK) at https://twitch.tv/OfficialLukeD - I play a variety of things 😄

Join my official discord server for support, general chat and my stream schedule! https://discord.gg/Mddj7PQ

Link to comment
Share on other sites

Suggest you check this out for an appendix of valid LSPDFR API Functions:

What you want to do is not possible (yet).

My YouTube: Click here. 

My Discord Server - https://discord.gg/0taiZvBSiw5qGAXU

Useful post? Let me and others know by clicking the Like button.
Check out my many script modifications! 
Having issues? LSPDFR Troubleshooter by Albo1125.

Link to comment
Share on other sites

I was actually watching your video on call outs (which isn't what I am looking for, just looking to see if you do it) as I got your response. I will look at the Functions in a bit. The only thing about those is that they aren't in the object viewer, so I will have to sort through them one by one.

but I appreciate the help.

Link to comment
Share on other sites

On 9/19/2016 at 7:58 AM, Antares said:

The only thing about those is that they aren't in the object viewer, so I will have to sort through them one by one.

Um yes they are? Add a reference to LSPD_First_Response.dll and they'll all show up in the object browser.

[REL] Coastal Callouts: An action-packed mod with new vehicles, maps, capabilities, and callouts in and around the waters of Los Santos

[REL] Police Tape: Make your scenes more realistic while stopping peds and traffic

[REL] Better EMS: Realistic and dynamic EMS response

Join the Parks Benefactor Program to support my work and get early beta access!

Link to comment
Share on other sites

and just to clarify. I'm not making a callout or anything like that really.

ok, so I have been looking through the documentation. And I have found the 4 videos by Albo1125 on YouTube (which is helping immensely. But the question now is....

As an example...

 

I wanted to show a notification only while the enter key is pressed and when the enter key is released, I want to stop that notification and show a different notification. sudo ex.

If(enterkey is down)

{

show notification1

}

if(enterkey is released)

{

stop notification1, show notifcation2

}

I'm not sure if I should be using an if statement or a while loop. And if I break the original while loop, it breaks the entire thing.  

I have done this before in regular codes but never using anyone else's .dll...

So it is throwing me.

Edited by Antares
added clarification at top.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...