Glenstorm Posted October 19, 2009 Share Posted October 19, 2009 Hi. I would like to change the handling of a particular car temporarily, how do I do it? For example, I want to code in such that the car I'm currently in is very light (low mass). How do I code it? Please reply. This is the only factor left for me to complete a great mod im working on. Cheers Glenstorm Link to comment https://gtaforums.com/topic/429194-changing-car-handling/ Share on other sites More sharing options...
ZAZ Posted October 19, 2009 Share Posted October 19, 2009 look here: click Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059570880 Share on other sites More sharing options...
Glenstorm Posted October 20, 2009 Author Share Posted October 20, 2009 I don't get it. How do I know what to look for editing the mass of a car? Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059572703 Share on other sites More sharing options...
ZAZ Posted October 20, 2009 Share Posted October 20, 2009 I don't get it. How do I know what to look for editing the mass of a car? I don't know. I got a script which manipulates the handling of cheetah, don't know which handling part I have tested and recognized a better handling then the original one The script is made by Kotton, Big, ATP and Mindf*ck Kottons_Chop_Shop It modifies memadresses and works only if the car is created as new get a cheetah, press M and choose Turing mode {$CLEO}0000::TINO_2while truewait 100ifPlayer.Defined($PLAYER_CHAR)thenif00DD: actor $PLAYER_ACTOR driving_car_with_model #CHEETAHthenif0AB0: key_pressed 77//-key = Mthenbreakendendendend03C0: 0@ = actor $PLAYER_ACTOR car0247: load_model 415038B: load_requested_modelsgosub @Read20@ -= @Text0gosub @Create:TINO_3wait 150if00DD: actor $PLAYER_ACTOR driving_car_with_model #CHEETAH004D: jump_if_false @TINO_8if and0248: model 415 available0AB0: key_pressed 77004D: jump_if_false @TINO_303F3: get_car 0@ primary_color_to 24@ secondary_color_to 25@051E: 11@ = get_current_radio_station0085: 12@ = 11@02E3: 26@ = car 0@ speed0013: 26@ *= 1.20174: 19@ = car 0@ z_angle1@ = 0xC2B9DC1@ += 3360 //224x151@ += 0xBC0A8D: 2@ = read_memory 1@ size 4 virtual_protect 00A8C: write_memory 1@ size 4 value -0.16 virtual_protect 03@ = 0xC2B9DC3@ += 3360 //224x153@ += 0xA40A8D: 4@ = read_memory 3@ size 4 virtual_protect 00A8C: write_memory 3@ size 4 value 1.00 virtual_protect 05@ = 0xC2B9DC5@ += 3360 //224x155@ += 0x100A8D: 6@ = read_memory 5@ size 4 virtual_protect 00A8C: write_memory 5@ size 4 value 1.1 virtual_protect 07@ = 0xC2B9DC7@ += 3360 //224x157@ += 0xB00A8D: 8@ = read_memory 7@ size 4 virtual_protect 00A8C: write_memory 7@ size 4 value 0.16 virtual_protect 09@ = 0xC2B9DC9@ += 3360 //224x159@ += 0x1C0A8D: 10@ = read_memory 9@ size 4 virtual_protect 00A8C: write_memory 9@ size 4 value -0.40 virtual_protect 00792: disembark_instantly_actor $PLAYER_ACTOR0407: create_coordinate 15@ 16@ 17@ from_car 0@ offset 0.0 0.0 0.000A6: destroy_car 0@00A5: 0@ = create_car 415 at 15@ 16@ 17@0175: set_car 0@ z_angle_to 19@036A: put_actor $PLAYER_ACTOR in_car 0@04BA: set_car 0@ speed_to 26@0229: set_car 0@ primary_color_to 24@ secondary_color_to 25@041E: set_radio_station 12@0249: release_model 41501C3: remove_references_to_car 0@03E6: remove_text_boxgosub @Read20@ -= @Text1gosub @Create:TINO_4wait 150if00DD: actor $PLAYER_ACTOR driving_car_with_model #CHEETAH004D: jump_if_false @TINO_8if and0248: model 415 available0AB0: key_pressed 77004D: jump_if_false @TINO_403F3: get_car 0@ primary_color_to 24@ secondary_color_to 25@051E: 11@ = get_current_radio_station0085: 12@ = 11@02E3: 26@ = car 0@ speed0013: 26@ *= 1.20174: 19@ = car 0@ z_angle0A8C: write_memory 1@ size 4 value -0.10 virtual_protect 00A8C: write_memory 3@ size 4 value 0.90 virtual_protect 00A8C: write_memory 5@ size 4 value 0.9 virtual_protect 00A8C: write_memory 7@ size 4 value 0.12 virtual_protect 00A8C: write_memory 9@ size 4 value -0.44 virtual_protect 00792: disembark_instantly_actor $PLAYER_ACTOR0407: create_coordinate 15@ 16@ 17@ from_car 0@ offset 0.0 0.0 0.000A6: destroy_car 0@00A5: 0@ = create_car 415 at 15@ 16@ 17@0175: set_car 0@ z_angle_to 19@036A: put_actor $PLAYER_ACTOR in_car 0@04BA: set_car 0@ speed_to 26@0229: set_car 0@ primary_color_to 24@ secondary_color_to 25@041E: set_radio_station 12@0249: release_model 41501C3: remove_references_to_car 0@03E6: remove_text_boxgosub @Read20@ -= @Text2gosub @Create:TINO_5wait 150if00DD: actor $PLAYER_ACTOR driving_car_with_model #CHEETAH004D: jump_if_false @TINO_8if and0248: model 415 available0AB0: key_pressed 77004D: jump_if_false @TINO_503F3: get_car 0@ primary_color_to 24@ secondary_color_to 25@051E: 11@ = get_current_radio_station0085: 12@ = 11@02E3: 26@ = car 0@ speed0013: 26@ *= 1.20174: 19@ = car 0@ z_angle0A8C: write_memory 1@ size 4 value -0.05 virtual_protect 00A8C: write_memory 3@ size 4 value 0.85 virtual_protect 00A8C: write_memory 5@ size 4 value 0.8 virtual_protect 00A8C: write_memory 7@ size 4 value 0.08 virtual_protect 00A8C: write_memory 9@ size 4 value -0.48 virtual_protect 00792: disembark_instantly_actor $PLAYER_ACTOR0407: create_coordinate 15@ 16@ 17@ from_car 0@ offset 0.0 0.0 0.000A6: destroy_car 0@00A5: 0@ = create_car 415 at 15@ 16@ 17@0175: set_car 0@ z_angle_to 19@036A: put_actor $PLAYER_ACTOR in_car 0@04BA: set_car 0@ speed_to 26@0229: set_car 0@ primary_color_to 24@ secondary_color_to 25@041E: set_radio_station 12@0249: release_model 41501C3: remove_references_to_car 0@03E6: remove_text_boxgosub @Read20@ -= @Text3gosub @Create:TINO_6wait 150if00DD: actor $PLAYER_ACTOR driving_car_with_model #CHEETAH004D: jump_if_false @TINO_8if and0248: model 415 available0AB0: key_pressed 77004D: jump_if_false @TINO_603F3: get_car 0@ primary_color_to 24@ secondary_color_to 25@051E: 11@ = get_current_radio_station0085: 12@ = 11@02E3: 26@ = car 0@ speed0013: 26@ *= 1.20174: 19@ = car 0@ z_angle0A8C: write_memory 1@ size 4 value -0.02 virtual_protect 00A8C: write_memory 3@ size 4 value 0.80 virtual_protect 00A8C: write_memory 5@ size 4 value 0.7 virtual_protect 00A8C: write_memory 7@ size 4 value 0.04 virtual_protect 00A8C: write_memory 9@ size 4 value -0.52 virtual_protect 00792: disembark_instantly_actor $PLAYER_ACTOR0407: create_coordinate 15@ 16@ 17@ from_car 0@ offset 0.0 0.0 0.000A6: destroy_car 0@00A5: 0@ = create_car 415 at 15@ 16@ 17@0175: set_car 0@ z_angle_to 19@036A: put_actor $PLAYER_ACTOR in_car 0@04BA: set_car 0@ speed_to 26@0229: set_car 0@ primary_color_to 24@ secondary_color_to 25@041E: set_radio_station 12@0249: release_model 41501C3: remove_references_to_car 0@03E6: remove_text_boxgosub @Read20@ -= @Text4gosub @Create:TINO_7wait 150if or0AB0: key_pressed 7780DD: NOT actor $PLAYER_ACTOR driving_car_with_model #CHEETAH004D: jump_if_false @TINO_7:TINO_801C3: remove_references_to_car 0@gosub @Read20@ -= @Textgosub @Create:TINO_90002: jump @TINO_2:Read0A9F: 20@ = current_thread_pointer20@ += 0x100A8D: 20@ = read_memory 20@ size 4 virtual_protect 0return:Createif0AA9: is_game_version_originalthen0AA5: call 0x588BE0 num_params 4 pop 4 0 0 0 20@else0AA5: call 0x5893B0 num_params 4 pop 4 0 0 0 20@endreturn:Text0hex"Manettino:_ Active" 00end:Texthex"Manettino:_ Deactivated" 00end:Text1hex"Suspension:_ Touring" 00end:Text2hex"Suspension:_ Sport" 00end:Text3hex"Suspension:_ Novitec" 00end:Text4hex"Suspension:_ Racing" 00end:Text5hex"Script_by_Kotton" 00end Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059572821 Share on other sites More sharing options...
Deji Posted October 20, 2009 Share Posted October 20, 2009 Memory is pretty simple when you get used to it. First get the car pointer (there's an opcode for that, search "car pointer"). I think then you do 0xB6F980 + your cars pointer. Then + a number that can be found in this list: http://www.gtamodding.com/index.php?title=...esses_(SA)#Cars Then you can use that variable to set the memory address with write_address. Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059573702 Share on other sites More sharing options...
ZAZ Posted October 21, 2009 Share Posted October 21, 2009 (edited) Memory is pretty simple when you get used to it. First get the car pointer (there's an opcode for that, search "car pointer"). I think then you do 0xB6F980 + your cars pointer. Then + a number that can be found in this list: http://www.gtamodding.com/index.php?title=...esses_(SA)#Cars Then you can use that variable to set the memory address with write_address. Thanks Deji, I never spend effort to find it out Handling0xC2B9DC - Handling Block Start. Each slot has 224 bytes of data. * +0x0 = [dword] Index/Identifier * +0x4 = fMass * +0x8 = 1.0 / fMass * +0xC = fTurnMass * +0x10 = fDragMult * +0x14 = CentreOfMass.x * +0x18 = CentreOfMass.y * +0x1C = CentreOfMass.z * +0x20 = [byte] nPercentSubmerged * +0x24 = fMass * 8.0000001e-1 / nPercentSubmerged * +0x28 = fTractionMultiplier * +0x74 = [byte] TransmissionData.nDriveType * +0x75 = [byte] TransmissionData.nEngineType * +0x76 = [byte] TransmissionData.nNumberOfGears * +0x7C = TransmissionData.fEngineAcceleration (Multiplied by 3.9999999e-4) * +0x80 = TransmissionData.fEngineInertia * +0x84 = TransmissionData.fMaxVelocity (Multiplied by 5.5555599e-3) * +0x94 = fBrakeDeceleration (Multiplied by 3.9999999e-4) * +0x98 = fBrakeBias * +0x9C = [byte] bABS * +0xA0 = fSteeringLock * +0xA4 = fTractionLoss * +0xA8 = fTractionBias * +0xAC = fSuspensionForceLevel * +0xB0 = fSuspensionDampingLevel * +0xB4 = fSuspensionHighSpdComDamp * +0xB8 = Suspension upper limit * +0xBC= Suspension lower limit * +0xC0 = Suspension bias between front and rear * +0xC4 = Suspension anti-dive multiplier * +0xC8 = fCollisionDamageMultiplier (multiplier not yet found) * +0xCC = [hex] modelFlags * +0xD0 = [hex] handlingFlags * +0xD4 = fSeatOffsetDistance * +0xD8 = [dword] nMonetaryValue * +0xDC = [byte] Front lights * +0xDD = [byte] Rear lights * +0xDE = [byte] Vehicle anim group In addition I got answers from Kotton QUOTE (Kotton@) 1@ = 0xC2B9DC 1@ += 3360 //224x15 1@ += 0xBC 0A8D: 2@ = read_memory 1@ size 4 virtual_protect 0 0A8C: write_memory 1@ size 4 value -0.16 virtual_protect 0 as you can see, 0xC2B9DC is the beginning of the handling block- each slot is 224 bytes (1 slot per vehicle) ..so being that the cheetah is the 15th vehicle in the handling.cfg (LANDSTAL being #0) -we get 224x15 = 3360 then we refer to what exact address we want to modify, +0xBC= Suspension lower limit so after reading that specific address, we write the new value easy eh? lol so again looking at the script, you can see that we've modified the following with each keypress.. +0xBC= Suspension lower limit +0xA4 = fTractionLoss +0x10 = fDragMult +0xB0 = fSuspensionDampingLevel +0x1C = CentreOfMass.z ______________________________________________ if I wanted to modify the drag I would access 0x10 1@ = 0xC2B9DC 1@ += 3360 //224x15 (cheetah) 1@ += 0x10 //fdrag multiplier 0A8D: 2@ = read_memory 1@ size 4 virtual_protect 0 0A8C: write_memory 1@ size 4 value 2.5 virtual_protect 0 //2.5 would be the new value Ok, now the praxis I want to make cheetah much more faster but keeps stable It's possible if I change 3 parameter of cheetahs original handling.cfg line Topspeed to 850.0, Acceleration to 50.0 and Drag to 1.0 HANDLING.CFGchange fDragMult to 1.0 and transmission to 850.0 50.0 (fMaxVelocity/fEngineAcceleration)name mass turnmass drag centreofmass boy traction transmissionorig.CHEETAH 1200.0 3000.0 2.0 0.0 -0.2 -0.2 70 0.80 0.9 0.50 5 230.0 30.0mod.CHEETAH 1200.0 3000.0 1.0 0.0 -0.2 -0.2 70 0.80 0.9 0.50 5 850.0 50.0 I tried it with the memory codes but any manipulation of accelaeration let the cheetah slide like a soap Drag seems to work but can not prevent the sliding speed was possible to increase but caused crashs by driving very fast, by any bump: freeze the script below: go in groovestreet into red marker to get cheetah and manipulate handling memory {$CLEO .cs}:Handlg_103A4: name_thread 'Handlg':Handlg_20001: wait 0 ms00D6: if 00256: player $PLAYER_CHAR defined004D: jump_if_false @Handlg_200D6: if 000FF: actor $PLAYER_ACTOR 1 (in-sphere)near_point_on_foot 2491.5 -1667.5 13.35 radius 1.0 1.0 1.0004D: jump_if_false @Handlg_20247: request_model #CHEETAH:Handlg_30001: wait 0 ms00D6: if 00248: model #CHEETAH available004D: jump_if_false @Handlg_300A5: 0@ = create_car #CHEETAH at 2487.5 -1660.5 13.350175: set_car 0@ z_angle_to 90.01@ = 0xC2B9DC1@ += 3360 //224x15 (cheetah)1@ += 0x84 //TransmissionData.fMaxVelocity0A8D: 2@ = read_memory 1@ size 4 virtual_protect 00A8C: write_memory 1@ size 4 value 2.5 virtual_protect 0 //2.5 would be the new value //3@ = 0xC2B9DC//3@ += 3360 //224x15 (cheetah)//3@ += 0x7C //TransmissionData.fEngineAcceleration//0A8D: 4@ = read_memory 3@ size 4 virtual_protect 0//0A8C: write_memory 3@ size 4 value 0.1 virtual_protect 0 //2.5 would be the new value 5@ = 0xC2B9DC5@ += 3360 //224x155@ += 0x10//fDragMult multiplier0A8D: 6@ = read_memory 5@ size 4 virtual_protect 00A8C: write_memory 5@ size 4 value 0.1 virtual_protect 00249: release_model #CHEETAH0001: wait 1000 ms0013: 2@ *= 100.0 // floating-point values 0013: 4@ *= 100.0 // floating-point values 0013: 6@ *= 100.0 // floating-point values 0092: 11@ = float_to_integer 2@ 0092: 12@ = float_to_integer 4@ 0092: 13@ = float_to_integer 6@:Handlg_40001: wait 0 ms00D6: if 00256: player $PLAYER_CHAR defined004D: jump_if_false @Handlg_403F0: enable_text_draw 1045A: text_draw_1number 50.0 42.0 'NUMBER' 11@ // value045A: text_draw_1number 200.0 45.0 'NUMBER' 12@ // value045A: text_draw_1number 350.0 45.0 'NUMBER' 13@ // value00D6: if 080FF: NOT actor $PLAYER_ACTOR 0 ()near_point_on_foot 2491.5 -1667.5 13.35 radius 2.0 2.0 2.0004D: jump_if_false @Handlg_401C3: remove_references_to_car 0@ // Like turning a car into any random car03F0: enable_text_draw 00002: jump @Handlg_2 i tried first 850.0 and 50.0 but cheetah was sliding a lot itried 350.0 a d 35.0 and i tried hexcode and tried 35.0 and 5.0 cheetah was allways sliding look for the textmessages it shows the real value of the memadress At the first going into read marker and keep standing there it shows the original handling memvalues by the next going into red marker it shows the new values of the memadress it was neccesary to multiplicate the values with 100 to show floats (exemple: if the value would be 0.53 it will be displayed as 53) the original value of velocitymemadress of cheetah is allways 1.04 and displayed as 104 the original value of drag of cheetah is allways 2.0 and displayed as 200 the original value of acceleration can't remember, i believe ciro with 2.5 as write_memory of velocity can i drive 250.0 with 0.01 as write_memory of fEngineAcceleration can i drive also 250.0 and accelerate normal I believe, this is not acceleration: 0x7C = TransmissionData.fEngineAcceleration furthermore i'm wondering what (Multiplied by 5.5555599e-3) means * +0x7C = TransmissionData.fEngineAcceleration (Multiplied by 3.9999999e-4) * +0x80 = TransmissionData.fEngineInertia * +0x84 = TransmissionData.fMaxVelocity (Multiplied by 5.5555599e-3) Edited October 22, 2009 by ZAZ Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059575259 Share on other sites More sharing options...
Glenstorm Posted October 26, 2009 Author Share Posted October 26, 2009 What if I need to change the handling of the car I'm currently in? meaning, it can be anything, not just Cheetah. Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059584958 Share on other sites More sharing options...
Wesser Posted October 26, 2009 Share Posted October 26, 2009 Is this more clear and easier than kotton's script? 0xC2B9DC : Base Memory Address + 0xE0 : Block Size (for each vehicle defined in vehicles.dat) + 0x.. : Related things There are 212 vehicles ID which start from 400. To get our vehicle number (400 = 0, 401 = 1, ...), we have to do this (untested). 0xE0 * ModelID-400 + 0x..0@ = 415 // vehicle ID (cheetah)0@ -= 400 // vehicle ID - first vehicle ID = vehicle number0@ *= 0xE0 // vehicle number * bytes for each slot = vehicle block0@ += 0xC2B9DC // vehicle block + handling block = vehicle handling block0@ += 0x.. // vehicle handling block + some things0A8D: 1@ = read_memory 0@ size 4 virtual_protect 0 Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059585734 Share on other sites More sharing options...
Revolution-Designes Posted October 26, 2009 Share Posted October 26, 2009 I'm currently creating a CLEO3 mod and want to increase the acceleration of the car i'm currently driving in. I gave the vehicle i'm currently driving the variable 1@. And i also found this memory adress on the internet: +0x7C = TransmissionData.fEngineAcceleration (Multiplied by 3.9999999e-4) But how can i put it into my script? Can i just use one code and add the memory adress to increase the acceleration or something else? I've never done this before so it's a little difficult for me... Grtz RD Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059585965 Share on other sites More sharing options...
Wesser Posted October 26, 2009 Share Posted October 26, 2009 (edited) Here it is what you need. {$CLEO}0000: NOPwhile true wait 0 if 00DF: actor $PLAYER_ACTOR driving then 03C0: 1@ = actor $PLAYER_ACTOR car 0441: 0@ = car 1@ model 000E: 0@ -= 400 0012: 0@ *= 0xE0 000A: 0@ += 0xC2B9DC 000A: 0@ += 0x7C 0A8C: write_memory 0@ size 4 value 0.1 virtual_protect 0 endend EDIT: I suppose it doesn't work since it can do it only for vehicles created as new, like ZAZ said. So ZAZ, what do you mean with this? Does it work only for created cars by .scm? EDIT 2: I tried and it works with all vehicles too. Edited October 26, 2009 by Wesser Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059586134 Share on other sites More sharing options...
Revolution-Designes Posted October 26, 2009 Share Posted October 26, 2009 Here it is what you need. {$CLEO}0000: NOPwhile true wait 0 if 00DF: actor $PLAYER_ACTOR driving then 03C0: 1@ = actor $PLAYER_ACTOR car 0441: 0@ = car 1@ model 000E: 0@ -= 400 0012: 0@ *= 0xE0 000A: 0@ += 0xC2B9DC 000A: 0@ += 0x7C 0A8C: write_memory 0@ size 4 value 0.1 virtual_protect 0 endend I suppose it doesn't work since it can do it only for vehicles created as new, like ZAZ said. So ZAZ, what do you mean with this? Does it work only for created cars by .scm? Don't i have to add a value to the code? Like 10 or 20. So the car will accelerate with 10 or 20 km/h more? Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059586190 Share on other sites More sharing options...
Wesser Posted October 26, 2009 Share Posted October 26, 2009 It's weird but I can't get it to work with vehicles which have more than 16 as their ID. Anyone know why? Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059586355 Share on other sites More sharing options...
ZAZ Posted October 27, 2009 Share Posted October 27, 2009 It's weird but I can't get it to work with vehicles which have more than 16 as their ID. Anyone know why? I confirm. I tried with taxi and had no effect. Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059589259 Share on other sites More sharing options...
Wesser Posted November 13, 2009 Share Posted November 13, 2009 (edited) Finally, I found a way to solve that. Handling lines are read in groups which can be respectively divided into: cars -> bikes -> boats -> planes. Unfortunally, the lines aren't ordered like vehicles ID (handling.cfg - vehicles.ide). Since we can't know what's the real line position, I wrote an external file where I put all positions per ID, picked from vehicles.ide. Here is the code: {$CLEO}0000: NOP4@ = 0while true wait 0 if 00DF: actor $PLAYER_ACTOR driving then 03C0: 1@ = actor $PLAYER_ACTOR car 0441: 0@ = car 1@ model gosub @ReadFromFile 0@ -= 400 0@ *= 0xE0 0@ += 0xC2B9DC 0@ += 0x7C 0A8D: 2@ = read_memory 0@ size 4 virtual_protect 0 0A8C: write_memory 0@ size 4 value 0.1 virtual_protect 0 4@ = 1 repeat wait 0 until 80DF: not actor $PLAYER_ACTOR driving else if 4@ <> 0 then 0A8C: write_memory 0@ size 4 value 2@ virtual_protect 0 4@ = 0 end endend:ReadFromFile0A99: chdir 0 if 0A9A: 1@ = openfile "./cleo/handlingId.dat" mode 0x6272 then for 2@ = 400 to 0@ 0A9D: readfile 1@ size 2 to 3@ end 0085: 0@ = 3@ 0A9B: closefile 1@ endreturn Before trying it, you need the file I was talking about downloadable from here. It's not 100% tested, so please report any bugs. I hope this should be useful. Edited December 11, 2009 by Wesser -Anti- 1 Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1059632226 Share on other sites More sharing options...
Wesser Posted July 26, 2010 Share Posted July 26, 2010 Sorry for bumping an old topic but it's necessary cause I've just found an alternative and simplest way: {$CLEO}0000: NOP3@ = 0while true wait 0 if 00DF: actor $PLAYER_ACTOR driving then 03C0: 0@ = actor $PLAYER_ACTOR car 0AB1: @getVehHandlingOffset 1 from_car 0@ store_to 1@ 1@ += 0x7C 0A8D: 2@ = read_memory 1@ size 4 virtual_protect 0 0A8C: write_memory 1@ size 4 value 0.1 virtual_protect 0 3@ = 1 repeat wait 0 until 80DF: not actor $PLAYER_ACTOR driving else if 3@ <> 0 then 0A8C: write_memory 1@ size 4 value 2@ virtual_protect 0 3@ = 0 end endend:getVehicleNum{ Parameters: Passed: 0@ - vehicle handle Result: 1@ - vehicle number Example: 0AB1: @getVehicleNum 1 from_car 0@ store_to 1@ }0441: 1@ = car 0@ model1@ -= 400 0AB2: ret 1 1@ :getVehHandlingOffset{ Parameters: Passed: 0@ - vehicle handle Result: 3@ - vehicle handling offset Example: 0AB1: @getVehHandlingOffset 1 from_car 0@ store_to 1@ }0AB1: @getVehicleNum 1 from_car 0@ store_to 1@ 0085: 2@ = 1@ 2@ *= 0x308 2@ += 0xB1F650 2@ += 0x4E 0A8D: 3@ = read_memory 2@ size 2 virtual_protect 0 // get handling ID3@ *= 0xE0 3@ += 0xC2B9DC 0AB2: ret 1 3@ bjeremii and -Anti- 2 Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1060045026 Share on other sites More sharing options...
carljrbrass Posted March 25, 2011 Share Posted March 25, 2011 Hey guys, sorry for bringing this up after so long, but ive been a fan of ZAZ's is scripts since pimpmycar frst came out. that got me hooked to cleo scripting, but ive tried hard for a good 2 years but im still at a very beginner level. ive made a mod for the Hotring racer (hotrina) and its sorta a dragster mod, and i was wondering if ter was some way to edit that handling while i was in game.....and google led me here anyway's i tried my hand at that stuff but failed, the moment i started gta sa up the game would just crash after loading a savegame. so ive been overthese scripts for a while, but ive had no luck wat-so-ever . ive also tried to make a mod that when a car shifts down a flame bursts out the eshuast...but ive done smtn wrong and the flame just stays there and after a few seconds starts lagging me like a b*tch anyway's i was wondering if u guys could give me a few pointers or a little help. anyting would be fine thanx for just takin a look at this too in short im just tryin to get the hotring to load a diffrent handling in game, like type 'DRAG' and it changes xD Thanx in advance! Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1060396276 Share on other sites More sharing options...
carljrbrass Posted March 25, 2011 Share Posted March 25, 2011 O, and i frgt...if i have to download another file or smtn like that it would be no problem at all. this mod isnt like, public. its just for me and a few buddies and whoeverelse wants it xD Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1060396279 Share on other sites More sharing options...
ZAZ Posted March 25, 2011 Share Posted March 25, 2011 (edited) O, and i frgt...if i have to download another file or smtn like that it would be no problem at all. this mod isnt like, public. its just for me and a few buddies and whoeverelse wants it xD There are script examples in this topic, so you can do it yourself. I wrote a report of my tests, you should read it. If you don't understand it, her's the fazit: There are problems problem1 it was not possible for every car but Wesser found a way to fix it and showed the method in his last script which he posted at Jul 26 2010 problem2 the game becomes unstablty if you increase the acceleration problem3 it don't makes fun to write a hanglingmodscript because of problem2 Edited March 25, 2011 by ZAZ Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1060396494 Share on other sites More sharing options...
carljrbrass Posted March 26, 2011 Share Posted March 26, 2011 Thanx for the reply and advice, ive tried it using wesser's methood agn after reading the previous post, but still the same result, i can get it to read, but it only reads vehicle mass and top speed, i think, not shure, but think..it also is reading engine inertia...it seems like that a bit but im not shure. but if i raise the top speed just a tiny bit the game crashes when the car changes gears at a high speed, it does like a small bump like *\ and come back down - and then it goes half way up and the game freezez for a little while and then crashes. so right now im just experamenting with things but i hope i can make it work. if i increase the acceleration of any car by +6 it crashes. ive tested on the infernus hotringracer and nrg...yea...nrg crashed when i accelerated lol so it was a fail. right now im trying to see if its crashing be cause of something else or cause of the speed bieng +6...cause +6 isnt really much . anyways thanx for the help really appriceate it. and btw ive got a little progress of the gear shift flame, i had the timer wrong xD Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1060397875 Share on other sites More sharing options...
unknown1419 Posted March 20, 2015 Share Posted March 20, 2015 I'm very sorry to bump this old post but then I think that whenever you change the top speed, gta sa still uses old values of gear ratio. Is it possible to force the game to recalculate all the gears in order to cater for the new top speed? Link to comment https://gtaforums.com/topic/429194-changing-car-handling/#findComment-1067163145 Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now