Reputation Activity
-
AnneJordan75 reacted to Straysify in [WIP] BaitCarVIts about time I break my silence on this mod. If you enjoyed the vdH Bait Car mod, you'll enjoy this too. Development of this has been ongoing for about a week now, and some versions have been sent out for testing. Select a bait car from a list of models(changeable), wait for it to be driven to you, park it where you like, then sit back and wait.
Current Features
Fully editable list of vehicle models Neat, clean interface for selecting the vehicle Simple to use, only one keybind(open the selection menu) Fleeing suspects are recognized by LSPDFR, so backup will assist you. Kill switch to toggle the bait car's engine. Planned Features
None Issues to overcome
A few minor conflicts with MoreControlV Video Preview: https://youtu.be/1pbZU-p3Kdc
I will post more updates in this thread when the time comes. I'm currently having a few people play with the mod to ensure that there are as few bugs as possible in the initial public release.
-
AnneJordan75 reacted to MichaelV in Code 4 Roleplay Now OpenThis topic has been closed by LCPDFR.com staff because it is a website, clan, or group ad. Our site isn't an advertising service - please do not use it as one. If you want to share your website, group, or clan, please keep that limited to your profile and signature.
If you feel that this topic has been closed in error, please report this post.
-
AnneJordan75 reacted to Stealth22 in Tips for DevelopersSo being that I am a software developer for a living, I thought I would create this thread to share some tips with fellow developers...especially those who are new.
Anyone can contribute to this topic...I myself am a newbie when it comes to RAGE Plugin Hook and LSPDFR. So anything useful that you come across, feel free to post it!
Some of what I have written below may not make sense to a new programmer, so if you have questions, or it seems like I am speaking Martian, feel free to ask questions!!
I'll start off by saying...
ORGANIZE YOUR CODE!! This means folders and namespaces for just about everything. Don't keep all your classes at the root level, and do not, for god's sake, do every part of your code in the Main class. Feel free to ask questions about this if you are confused, but LukeD's example API is a great way to start with namespaces.
Take advantage of inheritance and polymorphism! Use base classes and interfaces for everything! (Callouts, pedestrians, vehicles, etc) For example, I have started on the framework for my callout plugin. I have a CalloutBase class, which inherits the LSPDFR Callout class, and it has all of my method overrides. The overridden methods in CalloutBase perform any actions which are common to all of my callouts. Each callout type will have its own class, which would, you guessed it: inherit the CalloutBase class. My CalloutBase class implements my "ICalloutBase" interface. The interface is for declaring methods or properties that CalloutBase may not be able to do anything with, but if you use the abstract keyword in C# (or MustOverride in VB.NET), then each callout class/type you create would have it's own set of actions for that function. For example, my ICalloutBase interface declares a method called "OnArrivalAtScene()". The CalloutBase class implements this as an abstract method, meaning, any class that inherits CalloutBase (say, ShotsFiredCall, for example) has to have a method called "OnArrivalAtScene", which would be a set of actions for the program to take when the officer arrives on scene OF THE SHOTS FIRED CALL ONLY. The abstract method I just created would be called in the Process() method of the CalloutBase class. Remember, Process() is an LSPDFR method that is called continuously. CalloutBase performs actions which are common to ALL callouts, including calling the OnArrivalAtScene() method. In CalloutBase.Process(), I check to see if the player's location is getting close to my callout location. If so, and if the callout state is still "Unit Responding", then OnArrivalAtScene() is called, and the state is changed to "At Scene". Now, when you create a ShotsFiredCall class, there is no need to call OnArrivalAtScene() from ShotsFiredCall.Process(), because CalloutBase.Process() has already done it for you! The example I stated above requires you to track the state of the callout (i.e. Dispatched, Unit Responding, At Scene, Call Completed, Call Cancelled, etc), but it just gives you an idea on how efficient you can make your code. Its a bit of legwork in the beginning, but it pays off BIG TIME as your plugin grows and matures. Using base classes and interfaces is not only useful for Callout classes. You can use them to track which Peds are suspects, and which are civilians, or what role a certain vehicle plays in your callout. You can add properties to Peds that don't exist in the Rage Plugin, like "MyPlugin.MySuspect.IsBankRobber", for a simple example.
ERROR HANDLING!! Always, always, ALWAYS use proper error handling. One bad block of code can crash a user's entire game. Use Try...Catch blocks, and use the Catch block to log exceptions, so that when a user says "Your plugin is shit!!", then their log file will tell you what is wrong. Always use Ped.Exists or Vehicle.Exists (I think its called Exists for cars) to make sure that GTA V has not disposed of your object. GTA V does not mess around in terms of garbage collection and memory management. Always check if an object is null, and then if it has an Exists property, check that as well.
ANYONE CAN CODE!! VB.NET and C# are both very easy to learn. It does take years to master programming, and a university education in Computer Science or Software Engineering definitely helps. But if you're a newbie, and want to learn, jump in with both feet! Search Google for tutorials, or buy a book at your local book store. I guarantee that you can write a Hello World! program in less than 5 minutes!
VISUAL STUDIO IS FREE!! That's right! Visual Studio Community Edition 2013 is completely free. It doesn't have all the features that the pros use, but who cares? You aren't a software company!
USE A CODE REPO AND SOURCE CONTROL!! When you download Visual Studio Community, you get the option of creating a Visual Studio Online account. DO IT! Visual Studio Online gives you free and unlimited access to code repositories where you can store and back up your code. If any programmers are reading this, they provide both TFS and Git based repos. Source Control allows you to keep track of each change you make to your code. Last update crashed everyone's GTA? No problem, just roll back your changes! Computer hard drive crash? Laptop stolen? No problem! Once you're up and running, install Visual Studio again, connect to your code repo, and all your code is back! For those that use TFS, you can create work items for yourself to track all changes that you need to make to your plugin. Each time you check in code, you can tie a set of changes (called a changeset) to a specific work item.
BRANCH YOUR CODE!! This, at an elementary level, means to maintain two copies of your code. Your main branch (also referred to as your 'master' or 'trunk' branch) contains the most stable version of your code. Your second branch is called your 'dev', or development branch. All of your code changes and testing should be made on the dev branch. When you're ready to release, you merge all of the relevant changes from your dev branch to the trunk. This allows you to make different code changes to your project, all in parallel. This allowed me to recently release a LSPDFR 0.3 compatibility patch for Code 3 Callouts (I made those code changes in my trunk branch), while still working on the next update in my dev branch. See this MSDN link for more details: https://msdn.microsoft.com/en-us/library/ee782536.aspx
CHECK ALL DEPENDENCIES ON STARTUP!! Check file versions on EVERY DLL or assembly referenced by your project. You don't need to check the Microsoft .NET ones, but you should be checking file versions on RagePluginHook.exe, the LSPDFR DLL, and any other DLL (including RageNative UI, a Common DLL you've written yourself, etc) that is used by your project and needs to be installed in the GTA V folder. And NO, do NOT, I repeat, NOT use the Assembly class to load the DLL's into memory. That is just a waste of resources. Use the GetVersionInfo function of the System.Diagnostics.FileVersionInfo class instead.
More to come... -
AnneJordan75 reacted to LMS in Tips for DevelopersThanks for that, I'm sure it will help people.
A few things I'd like to add...
Don't sleep in your main thread!If you do, I will pay you a visit and it won't be nice! No, but seriously, the Process function is called every tick from LSPDFR's CalloutManager and if you decide to sleep there, you will block other callouts from working correctly. If you need to await something, do it in a separate GameFiber (if it requires game logic) or System.Threading.Thread if not. Use logging!Not only as a beginner, you should use logging extensively. You can create overloads of your logging function so that it only happens in debug build (like most LSPDFR logging) or under certain circumstances (such as logging levels), but use it. It will help you to better understand what went wrong on a user's end. Especially since as a beginner you probably have no real experience with debugging or checking crashes via crash offsets. Note that debugging V is unfortunately not really possible right now, as the DRM doesn't really like it. I didn't test on 393 yet, but earlier versions didn't work well. Keep an eye on performanceEvery now and then it might be a good idea to measure the time the main loop (your Process function) takes to run. 1-2 ms? Good! 20ms? Not so good... Don't be afraid to add a lot of general logic, your CPU can handle it. Game calls and poor code (such as unnecessary loops) will most likely be the cause of performance issues. Use commentsI'm not an idiot, I know what I'm doing here. Sure, now you do. But will you remember why you passed that 0x2 value to the native call in 2 weeks? Chances are you will not. And why did you apply the Wait task to the passenger again? Use comments to describe why you are doing such actions. It will help you later on, trust me. -
There's a very fine line I can apply for this.
The first is keep it the way it is, in which "avoid traffic" is on. However if you have avoid traffic on they ignore the minimum distance check, this is well out of my control because its built into the native function. There's no point in my checking the distance myself and applying brakes because that's just going to complicate things and cause more problems,
The alternative is I set it to not avoid traffic, allowing the minimum distance check to be possible and thus gets stuck at every possible opportunity where another car exists.
I'll do everything I can to improve the AI over time.
-
AnneJordan75 reacted to Will in Change key of police computerI believe this is correct. Most controls for LSPDFR use GTA V keybindings.
-
AnneJordan75 reacted to Will in can someone create me a car?But you posted in the GTA V section. Moved to GTA IV Suggestions & Requests.
This topic has been moved to the appropriate forum. Please post in the correct location in the future.
-
AnneJordan75 reacted to Sam in LSPD First Response 0.2 BetaWe're proud to present the second major public release of LSPDFR, and by far the most epic version yet, LSPDFR 0.2.
LSPDFR Version 0.2 follows on from the groundbreaking success of our first release for GTA V, implementing a large number of features specifically asked for by our community.
You can find LSPDFR 0.2 on the brand new LSPDFR page, including a whole set of online resources and documentation, at http://www.lspdfr.com
-
AnneJordan75 reacted to Cyan in LSPD First Response 0.2 Betaya think?
-
Downtown LS.
-
AnneJordan75 reacted to Will in LSPDFR Not able to go on dutyTry loading the plugin manually then going on duty.
-
AnneJordan75 reacted to ineseri in What's the significance of the API? What exactly will it introduce?Oh yes, I'm sure many developers will be pleased with the API :)
-
AnneJordan75 reacted to ineseri in What's the significance of the API? What exactly will it introduce?It allows developers to create LSPDFR plugins, hooking directly into the code of LSPDFR. It allows for a more seamless interaction.
-
It aims to expose LSPDFR functionality, such as pursuits, to developers so they can make use of our features and the experience will be exactly the same. We also provide functions to retrieve data from LSPDFR, such as whether a callout is in progress. The 0.2 API is very very basic as we focus on features and stability more at the moment and hence lacks a lot of internal features, but this will improve over time. Another reason why we didn't implement so many functions is that LSPDFR is a very early version and many things are subject to change or hacky solutions, so exposing them is not always a good idea. The most important feature of the current implementation is the ability to hook into the callback dispatcher so that user-created callouts are dispatched by LSPDFR as well as the ability to create pursuits (though no custimization yet). I plan to bring back the V API dev forum soon so I can get in touch with developers and their needs/ideas/problems.
-
AnneJordan75 reacted to LMS in About G17 Media/LSPDFR.This is because RAGEPluginHook and LSPDFR are technically very different. One exposes V's scripting functions and one actually uses them. This is the same setup for almost all script-based mods: You have a "script hook" and a mod. It also was the same in GTA IV and we didn't really provide support for the .NET ScriptHook either, at least not actively. Because of the limits we experienced with SHDN on IV (at least until Hazard added me to the repo so we could change some stuff we desperately needed) we decided to in fact have our own implementation, which is RAGEPluginHook. But a) since I'm the only team member of LSPDFR developing it (together with a non-team member) and b) because it's a completely different product with completely different support needs, there is also a separate website/forum. With V we are more close to the "full package" than we were with V. Most people just don't understand that LCPDFR on GTA IV had undergone six years of development, while LSPDFR and RAGEPluginHook is about three months. It just can't be perfect.
How not? Does Rockstar help you when the game doesn't work because of hardware/driver issues? I think we already provide a very good support considering the amount of time we have.
-
AnneJordan75 reacted to Sam in The Magic "E" KeyWe'll see what we can do about this. Personally, I use G as the siren key anyway in keeping with GTA IV.
-
AnneJordan75 reacted to Sam in LSPDFR 0.2 Crash on requesting backupDoes the game freeze at all before it crashes?
-
AnneJordan75 reacted to LMS in Stuck on loading screen..This is the advice I'd recommend as well.
-
AnneJordan75 reacted to Sam in Game crash when pulling over a vehicleThis is a weird error. I'll look into it.
-
AnneJordan75 reacted to MichaelV in Cannot Download LSPD Version EMoving to Website Problems, Feedback & Suggestions.
This topic has been moved to the appropriate forum. Please post in the correct location in the future.
-
AnneJordan75 reacted to ineseri in LSPD:FR SuggestionsIt's LSPDFR and LSPDFR respectively. There's no ":" in either name at all.
More on topic, we have more in store regarding callouts in the future and the possible return of the API. Most of these should be possible to make with the API and of course, our ambition is to have an LCPDFR 1.1 for GTA V, but at the moment, it's not just possible with time constraints and Rockstar being Rockstar.
-
AnneJordan75 reacted to LukeD in LSPD:FR SuggestionsThis topic has been moved to the appropriate forum. Please post in the correct location in the future.
-
AnneJordan75 reacted to Will in "First car mod"I'm guessing this is made by someone that just wanted to be able to say that he made the first car model for GTA V. This isn't the "start of vehicle modding" at all, vehicle modding for GTA is a hell of a lot more complicated than importing a random mesh into the game.
-
AnneJordan75 reacted to ineseri in LSPDFR 0.2 Delay Update - 13 JulyMost likely a news post this time, to avoid any debacle. The below text is unrelated to your post :)
MODERATOR NOTICE: Further off-topic, abusive or otherwise disrespectful posts in this topic will result in sanctions not limited to suspensions. Enough is enough.
-
AnneJordan75 reacted to Will in LSPDFR 0.2 Delay Update - 13 JulyAs said multiple times before, LSPDFR does not do anything to stop you from playing on a cracked version of the game. It's RagePluginHook that does, and you would need to speak to them about it.