Jump to content

[SHOW] Vehicle Reverse Light System


Dzsozi (h03)

Recommended Posts

  • 2 months later...
  • Other Languages Moderators

Hello, I have interest in your project and I have some questions:

  1. How do you get the texture element from the vehicle?
  2. Is there a way to get the other light textures to turn them on?
  3. In your preview, there's a fail when the vehicle is reversing, did you fix this? I can help you in this case.

Nice job.

-------------------------

By the way, I have a project with turn arrow lights and reverse lights, but only works on predefined vehicles because I need to set the light position manually.

Spoiler

SNwY0SD6SbGRV7J3HNFjQQ.pnggQGxdabkTyC0-Vv40W33Ng.png

Edited by Lord Henry
  • Thanks 1
Link to comment
  • Other Languages Moderators
59 minutes ago, CodyJ(L) said:

@Lord Henry

I'm one step ahead of you on that one

[image]

Did you set the texture position manually or you get it automatically? I can get this result using DxDrawImage3D, but it's client only and really hardworking to set the image position and image rotation.

Edited by Lord Henry
Link to comment
  • 2 months later...
  • Other Languages Moderators
On 20/01/2018 at 20:15, CodyJ(L) said:

Oh that uses a advanced as all hell system. I put a lot of research into this one and am not going to release the formula 'For now at-least' . But for a hint this uses alot of dummies of sort.

I was not asking your "formula", only if you use or not that function. Is it hard to answer yes or no?

By the way, I already know how to use the dummies, my system use them to get the light positions.

Link to comment
  • 6 months later...
On 12/11/2017 at 11:27, Dzsozi (h03) said:

WTolzJL.png

 Hello! 

Today I am bringing you a new part/update of the Advanced Vehicle System project I am currently working on. This part of the project contains a simple, yet nice and effective reverse light system. It is not fully finished yet, still need some improvements and features, but I managed to get it done "partially", so I can show it to you.

This is compatible with every vehicle that has the "vehiclelightson128" texture, which most of the time happens with modded vehicles. But it definitely does with default vehicles.

 [RED] = Unaffected lights 
 [GREEN] = Affected lights 

5EkVi02.png

In action:

reverse-light-preview.gif

 

 Currently this script has 3 custom functions and 2 custom events, these are: 

setVehicleLightsOn(vehicle, state) - This is a workaround for the default setVehicleOverrideLights function. [server]
setVehicleReverseTexture(vehicle, state) - With this function you can toggle the reverse light texture on/off. [shared]
isVehicleReversing(vehicle) - Returns true if the vehicle is reversing, false otherwise. [currently server only]

onVehicleStartReverse - Parameters: driver, lightState [server]
onVehicleStopReverse - Parameters: driver, lightState [server]

driver: The player who drives the vehicle
lightState: The light state of the vehicle (true/false). This returns the value set by setVehicleLightsOn function. Always returns something.

The source of these events is the vehicle that starts/stops reversing.
These events are triggered when a vehicle starts/stops reversing.

 

More updates coming soon!

I always like to read suggestions, so feel free to comment your thoughts and what should I add/remove!

Thank you for reading, hope you like it!

 

 Part of the Advanced Vehicle System project. 
advanced-vehicle-system.gif

link.?

 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...