Back to Main Page


A second page about the development of the Driver Information System, a feature filled vehicle system that adds many real-life car features and functions to GTAV.

 

Driver Information System - The rise of the Bro-Tec DIS


So what's the story with Bro-Tec I hear nobody ask?

Well the unofficial story is that a gang of seedy characters, with some il-gotten gains, set up in a seedy part of Los-Santos making in-car systems. Reportedly, their "offices" were nothing more than a disused warehose, where immigrant workers were tied to their deks in an atmosphere of "inspiration and creativity". It was suspected that the atmosphere was more likely to be hallucination-inducing and mind-numbing... but hey, what gets the job done right?

So the company name... apparently the conversation went like this.

Owner: (to visitor) "Whassup Bro? What brings you around these parts?"
Visitor: "Hey bro, just thought I would drop by and see how the local "entrepreneur" is doing... know what I'm sayin'?"
Owner: "Sure thing bro... wanna do the tour?"
Visitor: "Sure thing, lead on... so what you do in here anyway?"
Owner: "We be making in-car tech... you know... for the Bros, something they gonna enjoy."
Visitor: "So you be making like... Bro-Tech, amirite?"
Owner: "Hey... I like that... Bro-Tech, or maybe Bro-Tec, cos that's kinda cool right if you leave silent letters off?"

Not sure how much of that I believe though. :D

The name origin was actually an old game dev trick that we used to get our names into games where the publisher didn't want us to have a credits screen (lookin' at you Sega!). So we used to use high-score tables or name anagrams to hide our names in there as products.

So the person who started this idea rolling: Tobsi Cred
The name of this revolutionary tech system: Bro-Tec DIS

Do you see what I did there? Anyway... back to the mod development.

So we have all these settings, some that affected everything, like whether the door markers should be displayed, or whether the alarm should play the sound or flash the lights, that kind of thing... or simply held the default states for all the car functions. Then we had the per-car settings, like autolock speed, ambilight colours and like a real car, it needed an interface.

Welcome, to the Bro-Tec Driver Information System.

 

As you can see from the video, the GUI makes accessing all the features of the DIS easy, like using an information system in your own car. The colour scheme of the GUI can be changed on every level, from text colour, button colours, even the colours of the animating shapes in the background.

Every car is fitted with its own DIS computer and for as long as the vehicle is in your collection, it is tracked and updated in the DIS. At any time you can see the details of all of your cars, what they are and where they are.

And if you need some repairs doing, or you fancy some new custom parts, the integration with the World Guide System means finding a garage or custom shop, is just a button press away (if the satellites are working that is).

I had to modfy the WGS search functions so that external search requests could suppress the WGS location details (the text that appeared at the bottom of the screen). UI.DrawTexture() always draws on top of everything, so the DIS overlay was drawn over the text. But a search request returns every detail about the location, so it was easy to display that info in the DIS.

I was lucky with the GUI code, because the core of the GUI functionality already existed in the WGS. It just needed some tweaking for the new button types and screen size/functions but it went together really quickly. And as an artist, it's always nice to have something that lets me exercise different parts of my creative thinking.

As a creator, this mod has provided two weeks of very rewarding modding... it's kind of a shame that only two people will ever get to use it but that's just how it is. The one feature that I still want to add, is persistence across game sessions... I think that will be the proverbial icing on the cake. I have classes in Pick Your Ride that can store a vehicle configuration, I even have a vehicle configuration collection manager in that mod. It just needs to have all the additional data from this mod integrated into the classes when I add them to this mod. It's not complicated, just tedius.

Update: Now with cross-game-session persistence.

Well it turns out persistence was more complicated than I thought, purely down to my underestimation of how much data was going to be involved. There are approximately 120 individual components to a vehicle configuraiton that are now persistent. As well as the standard vehicle properties, like colour, dirt, radio station etc... there are also the properties in this mod, like the ambient lights settings, walk away alarm time etc... And then there's all the data in the vehicle information screen, that's also carried over too. So you really can start to clock up the miles on your car and it's all carried over from session to session. If you have the auto-steering patch installed, even the front wheel angle is persistent. Deformation cannot be persistent as that is inflicted through physical contact, also tyre burst state isn't stored, simply because I can't see the point in storing that info.

The way it works is each vehicle config is an individual file on disk. When the mod loads, it pre-loads all those configs and puts them into a holding list. Each config is then assigned a "Persistent Spawn Point" on the map, which is shown by a white key blip. Each frame, one item from that list is distance checked to the player and if you are within a pre-determined distance (200f by default), the config is pulled from the list and a HackedCar is assigned to that config and the vehicle is spawned into the world in its persistent state. They key blip is then switched to blue so that you know the vehicle exists in the world. If the vehicle isn't within the required distance, the index is moved on and another vehicle is checked next frame. That means that no matter how many vehicles you have, you're never distance checking more than a single vehicle per frame.

To also help with stability problems, once a vehicle is spawned, a cooldown timer is set to 500ms before the next vehicle is spawned. Everything is managed to try and lessen the impact of any event that occurs in this mod. The less you notice, the more seamless things become.

Final Update: Fuel level persistance has also been added to this mod today (23-07-2018). The fuel consumption is a pseudo-horsepower related consumption, that increases as power increases. It also varies slightly based on wheel size and if you're going up or downhill. It has also allowed me to add gas station functionality to the Car Services mod. So that's pretty much everything finished with this mod.

Update: (yeah, so the final update wasn't quite so final after all) I added another feature to this last night (26-07-2018) and that's if you travel further away from a spawned car than twice the spawn distance, the car is removed and added back into the loaded configs dictionary. That way, cars you are nowhere near, aren't left to suck resources from the game. Because all the distances are checked with the much faster distance-squared process, this has almost zero impact on game performance.

Functionality Info Update:

DIS now accepts vehicles marked with the "VIDVehicle" decorator on an "excluded" basis. This means the cars inherit the functionality while they are in use but no persistent config file is saved to disk.

A Quick-Exit function has also been added, which allows you to remove the vehicle from the system by pressing RB + Vehicle Exit when you get out of the car.

Again, these two features are driven by compatibility requirements with other mods, in particular, Vehicles in Demand.

Indicator functionality has been added as an optional feature. They are controlled by the left-stick, to replicate indicator controls on most cars (on the ones I have had anyway). Up = turn right, Down = turn left. Indicators can be cancelled by pushing the opposite direction and will auto-cancel after making a turn. They are purely there to satisfy my habitual desire to indicate when I turn. It works nicely with the "swear at people when you're pressing the horn" feature I added to Players Extended... something else I do in the car.

Further Functionality Info Update:

Navigation sounds changed to use the hacking sounds from the DLC_IE_SVM_Voltic2_Hacking_Sounds sound set as well as the MP_5_SECOND_TIMER sound on the touch screen keyboard interface and for standard up, down, left & right navigation sounds on other menu screens.

Performance Update:

It's always bugged me with the slight pause when cars spawn into the world. It was actually caused, like most things, by my bad coding. I wrote the Vehicle Spawn Factory to help with this and the problem was purely down to how I was waiting for the model to be loaded. Having changed that, models spawn into the world with no pauses or stuttering. Sadly, the game runs like crap on my system, so this just fixes one stutter out of many.

Compatibility Fix: Electric Vehicles

Finally got round to fixing the bug with electric vehicles. Because they have a fuel tank capacity of 0, they registered as being out of fuel immediately. They're now excluded from the fuel system and show as electric in the fuel display on the Vehicle Information screen. If there were charge points in the game, I could use them but like so many other half-assed things in this game, there isn't.

Update: GUI Overview Image

This is a single image showing all of the screens used in the DIS at a reduced size. You can see that the Airbag functionality has been integrated into this now.