Quantcast
Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
    1. Welcome to GTAForums!

    1. Red Dead Redemption 2

      1. Gameplay
      2. Missions
      3. Help & Support
    2. Red Dead Online

      1. Gameplay
      2. Find Lobbies & Outlaws
      3. Help & Support
    1. Crews & Posses

      1. Recruitment
    2. Events

    1. GTA Online

      1. Arena War
      2. After Hours
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Grand Theft Auto Series

    3. GTA Next

    4. GTA V

      1. PC
      2. Guides & Strategies
      3. Help & Support
    5. GTA IV

      1. Episodes from Liberty City
      2. Multiplayer
      3. Guides & Strategies
      4. Help & Support
      5. GTA Mods
    6. GTA Chinatown Wars

    7. GTA Vice City Stories

    8. GTA Liberty City Stories

    9. GTA San Andreas

      1. Guides & Strategies
      2. Help & Support
      3. GTA Mods
    10. GTA Vice City

      1. Guides & Strategies
      2. Help & Support
      3. GTA Mods
    11. GTA III

      1. Guides & Strategies
      2. Help & Support
      3. GTA Mods
    12. Top Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    13. Wiki

      1. Merchandising
    1. GTA Modding

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    3. Featured Mods

      1. DYOM
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Red Dead Redemption

    2. Rockstar Games

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Programming
      5. Movies & TV
      6. Music
      7. Sports
      8. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. News

    2. Forum Support

    3. Site Suggestions

spaceeinstein

Brokenfish's Speedometer

Recommended Posts

spaceeinstein

CONVERTED FOR SAN ANDREAS!

 

Created by Brokenfish for Vice City. Converted by spaceeinstein for San Andreas. This is a script mod that displays the speed of any vehicles in about miles per hour.

 

Please download Barton's mission builder using Craig's link. You have to download Hammer89's GXT editor. Find the GXT string "HOSP_1". Edit the text to "MPH". Save the GXT. It should display the speed in numbers next to the MPH.

 

 

004F: create_thread ££SPEED------------:SPEED0001: wait  50 ms00D6: if  000DF:   actor $PLAYER_ACTOR driving004D: jump_if_false ££SPEEDLAST03C0: @0 = actor $PLAYER_ACTOR car00D6: if  000DB:   actor $PLAYER_ACTOR in_car @0004D: jump_if_false ££SPEED02E3: @1 = car @0 speed0011: @1 *=  2.25;; floating-point values008C: @1 = float_to_integer @10086: $SPED =  @1;; floating-point values only04F7: status_text $SPED  0 line  4 'HOSP_1';; MPH0002: jump ££SPEED:SPEEDLAST0001: wait  250 ms0151: remove_status_text $SPED0002: jump ££SPEED

 

Edited by spaceeinstein

Share this post


Link to post
Share on other sites
ThAtSgOtTaHuRt

sweet, just what I was looking for. good work. rah.gif

 

although the NRG tops out at 80MPH on your speedo and the HYREA tops out at 120MPH. can ya boost the number up a bit to make it more realistic? - like multiply it by 2.25 then NRG will top out at 180 (sounds about right)

 

but then again after I did that I end up going 40MPH when the bike is rolling at a jogging pace.

 

what to do what to do?

 

Edited by ThAtSgOtTaHuRt

Share this post


Link to post
Share on other sites
spaceeinstein
It's like that, somehow. It does that in Vice City for the Skimmer only but somehow in San An, it does that in almost any vehicles. I changed the value to 2.0 (original one). Edited by spaceeinstein

Share this post


Link to post
Share on other sites
sighko

works PERFECT been waiting for a digital speedo to put in my script...BIG UPS!

Share this post


Link to post
Share on other sites
RainingAcid

Is locks up when I try to add it to SA-Back to reality.

Share this post


Link to post
Share on other sites
spaceeinstein
The size limit for the first four segments is 2MB (or 200,00 something), so if you go over that, the game crashes.

Share this post


Link to post
Share on other sites
yfbcjw

It worked when i added it to SA - back to reality, although it doesnt always show because of the petrol bar and when it does the petrol bar doesnt

Share this post


Link to post
Share on other sites
The_Grudge

Any way to make this display KPH?

Share this post


Link to post
Share on other sites
spaceeinstein

Change 0011: $SPED2 *= 2.0;; floating-point values.

to this 0011: $SPED2 *= 4.0 ;; floating-point values

 

O yea, I will update the code to include local instead of global variables later on.

Edited by spaceeinstein

Share this post


Link to post
Share on other sites
The_Grudge
Change 0011: $SPED2 *= 2.0;; floating-point values.

to this 0011: $SPED2 *= 4.0 ;; floating-point values

 

O yea, I will update the code to include local instead of global variables later on.

Thanks, but I already figured that out.

Share this post


Link to post
Share on other sites
spaceeinstein
The speedometer is updated so it can have the same speed as the other speedometer.

Share this post


Link to post
Share on other sites
Alick

cool looks great in game

Share this post


Link to post
Share on other sites
ripple

Trouble shooting needed smile.gif

 

I tried to combine this with Greg's SA Opened Up mod. The speedometer works, but.....when I start a new game, I get that big text message on screen which says "When your health reaches 0 you will be sent to the hospital" (or something like that), but the text message does not dissappear--it just stays there. Any ideas?

Share this post


Link to post
Share on other sites
spaceeinstein

So terribly sorry about ignoring this. You have to download a GXT Editor and find "HOSP_1". Edit the text to "MPH". I will update first post later today.

 

Ok post updated. Anyone who installed this mod should install it again since I updated the code also.

Edited by spaceeinstein

Share this post


Link to post
Share on other sites
ripple

No problem Space. Thanks for the update. I edited it to reflect KPH

 

 

0011: @1 *=  3.621024;; floating-point values

008C: @1 = float_to_integer @1

0086: $SPED =  @1 ;; floating-point values only

04F7: status_text $SPED  0 line  4 'HOSP_1';; KPH

 

Is this right?

Share this post


Link to post
Share on other sites
spaceeinstein
Change to 4.0 Edited by spaceeinstein

Share this post


Link to post
Share on other sites
ripple

Thanks Space. The reason I was asking was because intially I changed it to 4 as per your previous instructions and....well, CJ was riding on the bicycle and doing 80 kph just cruising, which I thought was fast because I never went that fast on my bike tounge.gif

Share this post


Link to post
Share on other sites
spaceeinstein
Yea, I know. GTA is a whacky place. It's normal for the bike to go that fast.

Share this post


Link to post
Share on other sites
akboy

Note: 1 kph = 1,61 mph.

 

But if your multiplier for mile is 2.0, the multiplier for kph is 3.22 (2.0 * 1.61).

 

In the handling.cfg, Hydra max speed is 200 kph (I take the hydra because he can take this max speed). Without multiplier, the game draws 75.

 

-> 200/75 = 2.67 (kph multiplier)

-> 2.67/1.61 = 1.66 (mph multiplier)

 

 

What do you think about that?

Share this post


Link to post
Share on other sites
spaceeinstein
The speed I have now is based on Spooky's speedometer. Its max speed for the Hydra is 168MPH so I synced it with it.

Share this post


Link to post
Share on other sites
bear052303

i got this error message:

ERROR: Parameter 1 not set.

Command: 004D: JUMP_IF_FALSE ’’SPEEDLAST

please help, thanks

Share this post


Link to post
Share on other sites
Private_Paula

it seems to work, but i can´t find anything even close to "HOPS_1" in the GXT file. (or the text it shows in game)

 

can you please tell me where to find it (is it a table, entry or value)? i´m using sagxtedit if this is helping.

 

EDIT: forget it, i found it.

 

 

Edited by Private_Paula

Share this post


Link to post
Share on other sites
Kremit

 

Note: 1 kph = 1,61 mph.

 

I think ya got that backwards... 1 kph = 0.621371192 mph...

or... 1 mph = 1.609344 kph

 

So, here's a chart of conversion multipliers to one's disposal..

 

 

 

     MPH     ||      KPH     1.0    ||   1.609344    1.25    ||    2.01168     1.5    ||   2.414016    1.75    ||   2.816352     2.0    ||   3.218688    2.25    ||   3.621024     2.5    ||    4.02336    2.75    ||   4.425696     3.0    ||   4.828032     3.25    ||   5.230368     3.5    ||   5.632704    3.75    ||    6.03504     4.0    ||   6.437376    4.25    ||   6.839712     4.5    ||   7.242048    4.75    ||   7.644384     5.0    ||    8.04672

 

 

No more guesstimation or approximations... rah.gif

Edited by Kremit

Share this post


Link to post
Share on other sites
Kremit
i got this error message:

ERROR: Parameter 1 not set.

Command: 004D: JUMP_IF_FALSE ’’SPEEDLAST

please help, thanks

can only take a couple guesses here as this isn't my code of knowledge...

 

However, I would have to guess one of the following may be your issue...

 

A) You do not have a Speedlast section.

 

 

:SPEEDLAST0001: wait  250 ms0151: remove_status_text $SPED0002: jump ££SPEED

 

 

B) You do not have a valid if statement, or perhaps no action after the if statement.

 

 

00D6: if  000DF:   actor $PLAYER_ACTOR driving

 

 

C) You do not have 0 defined.

 

 

03C0: @0 = actor $PLAYER_ACTOR car

 

 

 

Basically, it's saying: "If the player character is in a car, then the character's action is driving.. Otherwise, he's on foot." Now if he's driving, it continues downward to calculate his speed. If not, it kicks over to Speedlast section and removes the mph block.

 

Wish I could help you more, but I'm not sure what your code looks like and as I've said, this isn't one of my stronger languages.... confused.gif

Share this post


Link to post
Share on other sites
the_king

If this mod was converted from vc to san andreas, does anyone happen to know where I can find the VC version?

 

Kremit, I dont think bear052303 is pursuing that error question any more, it's been a few months since this topic has had any replies. confused.gif

Share this post


Link to post
Share on other sites
stan101

Does this work for Vice City?

Share this post


Link to post
Share on other sites
Martin12345678910

any pics for it?

Share this post


Link to post
Share on other sites
stan101

Ok, i just got GTA SA and i'm modding, it works, but i need to know the default speed multi-plier in mph... in numbers like:

2.24? this is just an example in gta vc, still working on sa.......

 

user posted image

 

see the the speedometer is differet than the main.scm code.. so how do we get the main.scm to work in the speedometer.. i want to convert it myself.

Edited by stan101

Share this post


Link to post
Share on other sites
Martin12345678910

looks cool can some one post a file for it so you dont have to do this to get it to work as i tried to get it to work and i cant open the main.scm file

 

and if someone posts it can they make it in KPH and MPH please

 

Thanks

Share this post


Link to post
Share on other sites
ms.cooldude

I can see why this speedometer is much better than the ones you add to the SA directory cos they slow my pc down by a bit

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.