GT4 AI/Hybrid Tools

Discussion in 'Gran Turismo 4' started by TheAdmiester, Oct 31, 2019.

  1. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    Note to mods/admins: Wasn't sure who to contact to check if this is okay, however, I've seen some threads with emulation discussion fly just fine, provided that we don't discuss how to obtain the game/BIOS. Let me know if anything is infringing.

    GT4 AI/Hybrid Tools

    After a while of researching and tweaking GT4, and realising how fun it is to set custom AI grids in arcade, and hybrid cars on the fly in memory, I realised two things:
    1) I'm lazy, and thinking of which cars I want to race against or take parts from is hard with 700+ cars
    2) Other people may want to hybrid cars and force their own custom grids, but don't actually know how.

    That's where this tool comes in.

    Features
    Event Synthesizer
    upload_2019-10-31_0-39-9.png

    Exactly as it says on the tin, and mostly how it works in GT2. This tool allows the user to separately roll a random grid of AI cars (truly random, mind you - expect stuff like an Escudo and a Subaru 360 in the same grid), the player's own car, and track. These are separate which allows some freedom of control - for instance, if you want a random AI grid but to select your own car, or a default AI grid with a manually selected track - it's all possible.

    I plan on eventually categorising cars to be used in the rolls, for example being able to select a random grid of JGTC cars, race cars, rally cars, road cars, etc. But this will take some time and is simply on the to-do list.

    Custom Event
    upload_2019-10-31_0-39-36.png

    Same controls as Event Synthesizer, except you control this one, including your own car and track. Why might you want to override those when you can already select them, you may ask? Good question, here's why:
    • Forcing a track that typically restricts you to one AI opponent (e.g. Tsukuba wet, rally courses), then loading a track that allows a 6 car grid, will force that 2-car track to have 6 cars.
    • Forcing your own car allows for restricted cars such as the Model T or Benz Wagons to be used against AI opponents (who can also use them if you so desire)

    Hybrids
    upload_2019-10-31_0-39-58.png

    This is the part I'm pleased with. We can hybrid cars in our save files and save states, but this one allows you to hybrid your selected GT Mode car on the fly. Currently it allows swapping of Drivetrains, Engines, Exhausts, NA Tunes, Superchargers, and Turbos. Every part for every car is listed, and the dirty byte-swapping bits are done in the background, so if you want an AWD NSX with an FGT engine, all you have to do is pick a car with AWD for Drivetrain, the FGT for engine, and apply each.

    Misc (Camera Tools)
    upload_2019-10-31_0-40-56.png


    One thing that always irked me about GT4 was how the car is placed on the screen, and how stiff the camera's attachment to the car is. Using this tool you can adjust the FOV on the fly without even reloading the race (no more car overlapping the G Meter!) and set the camera to be more loosely attached, GT3-style. The tool remembers which settings you applied here so you don't have to keep setting them, just start up, apply and go.

    Default FOV (90):
    upload_2019-10-31_0-44-10.png

    100 FOV:
    upload_2019-10-31_0-43-48.png


    Disclaimers
    Now here are the less exciting parts:
    • Right now it only supports the NTSC (SCUS-97328) version of GT4. PAL support is planned but will take a while.
    • Some situations can cause the game to freeze or quit, such as (potentially) when idling on the main menu and a demo starts to play.
    • The tool is still in development, so please only use this with a save you have properly backed up. It's possible that in some rare cases, values or saves may be corrupted. By using this tool you accept responsibility for any damaged or lost saves. Please back up any saves before using this tool!
    • The tool must be run as administrator as it patches memory. I understand this is iffy for some people, so the source code can be viewed HERE
    DOWNLOAD
     
    Last edited: Feb 23, 2020
  2. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    Created a new release, version 1.1, and moved to Github for hosting.

    New features:

    Body Swapping:
    Certain regional cars can now be swapped to their PAL equivalents!
    upload_2019-11-4_20-6-2.png

    And a bonus:
    upload_2019-11-4_20-6-53.png

    The following swaps are available:
    • Marcos Mini Marcos GT '70 -> Mini Cooper 1.3i '98
    • Peugeot 206 Rally Car -> Esso equivalent
    • Opel Calibra Touring Car '94 -> Vauxhall equivalent
    • Opel Corsa Comfort 1.4 '01 -> Vauxhall equivalent
    • Opel Speedster '00 -> Vauxhall eqiuvalent
    • Opel Speedster Turbo '00 -> Vauxhall equivalent
    • Opel Tigra '99 -> Vauxhall equivalent
    • Opel Vectra 3.2 V6 '03 -> Vauxhall equivalent
    • Toyota GT-One Race Car -> Esso equivalent
    • Toyota Castrol Tom's Supra -> Toyota Esso Ultraflo Supra '01 (2001 Tom's was chosen as it's the closest spec and engine match to the Ultraflo)
    The interface for doing so is simple:
    upload_2019-11-4_20-12-14.png

    Unfortunately there is no Esso body for the 905 present, and no Vauxhall body for the Astra Touring car, so those can't be swapped.

    The Infinitis/Altezzas are planned at some point.
     
    Last edited: Feb 23, 2020
    jontikis, Apprentice and spsajewski like this.
  3. RacerGT4

    RacerGT4

    Messages:
    4
    the program is stuck cant back hybrids options cant back default what can i do?
     
  4. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    Restore from a backup of your save.
     
  5. RacerGT4

    RacerGT4

    Messages:
    4
    thanks i made it can u do the same for PAL VERSION ?
     
  6. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    Maybe at some point in the future.
     
  7. CozmicDragon

    CozmicDragon

    Messages:
    63
    Location:
    Brazil
    Doesn't even run. Instead, I get this error message:

    upload_2020-1-11_20-48-54.png

    But they are in the same directory because I never moved them. Running as administrator does nothing, I get the same error.
     
    Gorgeous_L likes this.
  8. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    Did you extract the files or run the program directly from the zip?
     
  9. CozmicDragon

    CozmicDragon

    Messages:
    63
    Location:
    Brazil
    I extracted it, to its own folder. Everything is there.

    upload_2020-1-12_11-24-56.png
     
  10. wolop953

    wolop953

    Messages:
    5
    This tool is incredible, thanks a ton for this!
     
    TheAdmiester likes this.
  11. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    The only thing I can think of is that your OS or antivirus might be preventing it from accessing the files somehow, as some users I tested with had some odd issues with those, but we resolved them so I'm not too sure, sorry.
     
  12. Apprentice

    Apprentice

    Messages:
    168
    Can someone else does this tool on Gran turismo 3 a-spec pal or ntsc.
     
  13. Apprentice

    Apprentice

    Messages:
    168
    Is this works on driving missions? or only on arcade mode? tnx.
     
  14. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    I've released a small update that improves the way it detects if you're in a race, now it no longer crashes on the Sony Computer Entertainment screen if the camera hack is already applied, and the random occasional crashes when loading a race seem to be gone too. Link is in the Github releases page linked in the first post. I've removed all attachments from this thread so you can't download an older version.

    Should work everywhere, feel free to report to me anywhere it doesn't work. I think I have everything covered but still may be missing something.
     
    Apprentice likes this.
  15. Apprentice

    Apprentice

    Messages:
    168
    Not works on Driving Missions, and No other bugs found.
     
  16. Anonanon

    Anonanon

    Messages:
    142
    Thank you for making this. I've always wanted a FOV fix and a camera spring fix for as long as I can remember, as it's just one of those little things that put GT3 above GT4 for me. Do you think there could be a GS/AR code equivalent so I can play with these enhancements on a real PS2?
     
  17. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    The FOV I don't know for myself, but the loose cam was actually taken from a PS2 code list: https://gamehacking.org/game/103851

    Search for "GT3-Like" on that page and you'll get it.
     
  18. gtracer6000

    gtracer6000

    Messages:
    7
    Sorry if this is the wrong place to ask but does anyone have like a body swap code for action replay MAX?
     
  19. Cowboy

    Cowboy Premium

    Messages:
    5,560
    Location:
    United States
    When I go to rescan the game version, I'm always getting this error:

    Screenshot (153).png

    I'm running on the correct version (SCUS_97328).
     
  20. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    The scan feature didn't work as well as I intended and should/will eventually be removed, just ignore it. As long as the Hybrids tab detects the car you're in in GT Mode, you're good to go.
     
  21. Cowboy

    Cowboy Premium

    Messages:
    5,560
    Location:
    United States
    It doesn't recognize it sadly.

    Screenshot (154).png

    Edit: It appears to be working now I believe.
     
    Last edited: Mar 21, 2020
  22. Friccin

    Friccin

    Messages:
    1
    The program doesn't seem to be working for me. I want to use the event synthesizer for arcade mode, but when I start it up it never gives me the right car or track.
     
  23. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    Would you mind posting which version of GT4 you're playing, and run through how you're trying to use the tool?
     
  24. Gorgeous_L

    Gorgeous_L

    Messages:
    2
    Location:
    Russian Federation
    I have the same problem. Perhaps this issue will be fixed in the next release?
     
  25. IceLancer

    IceLancer

    Messages:
    2
    Hey there. I am also heaving problem. Using NTSC-U
    ELF (cdrom0:\SCUS_973.28;1) Game CRC = 0x77E61C8A
    car is recognized in hybrid. So i try to change track ->custom event, (any track) press apply. Start race. Nothing happens. I still drive original game track. Same is with cars. No car change , no ai change either. Nothing seems to affect anything
    2 old pcsx2 builds
    pcsx2-v1.5.0-dev-1660 and another even older.

    Maybe i am doing it wrong?
    exe builds points that it is made in 2016. What pcsx2 builds does this tool require?
     
    Last edited: Dec 21, 2020
  26. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    If the hybrids are detected then the courses should just work. Are you trying to swap courses and cars in GT Mode or Arcade? Only Arcade is supported for course swapping.

    Also, there seem to be too many issues related to PCSX2's memory management for me to reliably maintain this tool, so unfortunately for now I'm going to have to label it deprecated and unsupported.
     
  27. IceLancer

    IceLancer

    Messages:
    2
    Is that tool resctriction ?
    because i watched videos where guy replaced GT mod map but he isnt responding to comments.

    he entered midfield raceway (original courses in gt mod) and map ended up as nurburgrin and even had event points. Unless he faked the video.. But its still weird. It was Deutsche Touring Car event with toyota

    P.S yeah i also tried Arcade mod. It didn't affect the track
     
    Last edited: Dec 21, 2020
  28. TheAdmiester

    TheAdmiester

    Messages:
    1,277
    Location:
    United Kingdom
    It's a tool restriction, yes. Swapping cars and tracks in GT Mode is possible but works differently to Arcade, and I didn't put too much effort into researching how it works. I'm focusing on PS3 GT for a while now so I won't be working on anything for GT4 until further notice.
     
    IceLancer likes this.
  29. RacerGT4

    RacerGT4

    Messages:
    4
     
  30. RacerGT4

    RacerGT4

    Messages:
    4
    IM WAITING FOR PAL VERSION OF THIS TOOL