Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cruise Control #1

Open
ArduousDev opened this issue Mar 3, 2021 · 12 comments · Fixed by #4
Open

Cruise Control #1

ArduousDev opened this issue Mar 3, 2021 · 12 comments · Fixed by #4
Assignees
Labels
enhancement New feature or request

Comments

@ArduousDev
Copy link

Cruise Control is not working for me or others.

@l3lackMegas
Copy link
Contributor

l3lackMegas commented Mar 4, 2021

Hi, @ArduousDev! Thank for open this issues.

The Cruise control function will be setEntityMaxSpeed at the current speed of vehicle. (This line)
I think your project may have some resources is trying to setEntityMaxSpeed.

Anyway, please give me more information to figure out what causes the problem.

  • When you enable Cruise Control (Default CAPSLOCK key), is Cruise status icon active on HUD?

@ArduousDev
Copy link
Author

The HUD works fine. There is no other scripts I have a empty test server.

@FlukRocker
Copy link
Member

@ArduousDev Hi i just test on my own local server.
it seem fine for me please provide more detail about your server setup.

Video: https://streamable.com/eksskb

@l3lackMegas
Copy link
Contributor

l3lackMegas commented Mar 5, 2021

The HUD works fine. There is no other scripts I have a empty test server.

I have no idea what is the causes.

Can you give me some screen record to see the problem?

Recording and follow this steps below to help me check it out.

  1. Drive the vehicle at a speed 40 M/H.
  2. Reduce the speed to 20 M/H and press the CAPSLOCK key to toggle cruise.
  3. Continue driving for a few seconds and press CAPSLOCK key again to disable cruise.

@ArduousDev
Copy link
Author

@l3lackMegas
Copy link
Contributor

https://streamable.com/nnomvd

Thank you!

I tried to analyze the problem from your video.
But I still can't figure out the cause of this. Sorry. :(

I want more information.

  • Is it all vehicles that have such a problem?
  • Did you installed any mods on your game?
  • Before use this script, did you use any script that have cruise controls?

@ArduousDev
Copy link
Author

Fresh server install, nothing but this script was running. Tried with and without OneSync still the same result. At this point i'll just have to make my own cruise control.

@l3lackMegas
Copy link
Contributor

I tried to figure out the cause with my fresh server install too, but It's fine for me.
So I think the problem might be from vehData['cruiseSpd'] is 0 in this line.

vehData['cruiseSpd'] = vehData['currSpd'];

But it should not a problem by get the current speed from GetEntitySpeed(currVeh).
vehData['currSpd'] = GetEntitySpeed(currVeh);

I really have no idea about it. But if you can make your own cruise control. could you please contribute to this project too? ;-;

@ArduousDev
Copy link
Author

It's now setting the speed, however once I let go of the accelerator the speed drops.

@l3lackMegas l3lackMegas added the bug Something isn't working label Mar 12, 2021
@xerenon
Copy link
Contributor

xerenon commented Mar 13, 2021

i have new pull request i think it might help
#4

@l3lackMegas l3lackMegas added enhancement New feature or request and removed bug Something isn't working labels Mar 15, 2021
@l3lackMegas l3lackMegas linked a pull request Mar 15, 2021 that will close this issue
@ArduousDev
Copy link
Author

Cruise Control is now working. Excellent!

@l3lackMegas
Copy link
Contributor

There are some bug report from forum about this feature of #4.

Thank you, Ken_Janelle_Jr

Okay so this is really buggy with the cruise control. While enabled, it doesn’t disabled if you slow down or wreck, it’ll keep going. If the car is badly damaged and cruise control is on the car will go crazy. There needs to be checks for this, I don’t know why these functions aren’t already in as that is how cruise control actually works in real life & for every other resource out there with cruise control.

Engine health isn’t working either but that is the least of my worries.

I'll open the issue again and try to fix it later when i'm free.

@l3lackMegas l3lackMegas reopened this Jun 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants