Virtual Car Dealer

Virtual Car Dealer

Very basic framework which allows modders to add any vehicle to a simple virtual shop using TweakXL.

[color=#93c47d][size=5][b]Info[/b][/size][/color][size=3]
Virtual Car Dealer adds a new in-game store which you can access from PC in any of your appartments [/size][size=3](the same way like Virtual Atelier does). It checks if any supported vehicle mods installed and just displays all detected records as purchasable cars.[/size]


[color=#93c47d][size=5][b]For modders - Adding a new car[/b][/size][/color][size=3]
The only requirement here is that you have your car defined with TweakXL. Virtual Car Dealer searches for a few flats defined for vehicle record and adds a new purchasable item if records were found:[/size]
[list]
[][size=3][size=3][color=#00ff00]dealerPrice[/color] - vehicle selling price - [b][color=#00ff00]Int[/color][/b][/size][/size][/]
[][size=3][size=3][color=#00ff00]dealerCred[/color] - required Street Cred to unlock purchase - [b][color=#00ff00]Int[/color][/b][/size][/size][/]
[][size=3][size=3][color=#00ff00]dealerAtlasPath[/color] - path to [/size][size=3]inkatlas resource for full vehicle preview image - [b][color=#00ff00]String[/color][/b][/size][/size][/]
[][size=3][size=3][color=#00ff00]dealerPartName[/color] - texture part name inside inkatlas - [b][color=#00ff00]String[/color][/b][/size][/size][/]
[][size=3][size=3][color=#00ff00]dealerVariants[/color] - additional color variations for base vehicle record - [b][color=#00ff00]array of Strings[/color][/b][/size][/size][/]
[/list][size=3]For example if you made a new vehicle with id [/size][size=3][color=#00ff00]Vehicle.my.custom_vehicle[/color] (and appended it to [/size][size=3]Vehicle.vehicle_list.list) then new lines might look like this:[/size]

[code]Vehicle.my.custom_vehicle.dealerPrice: 123000
Vehicle.my.custom_vehicle.dealerCred: 20
Vehicle.my.custom_vehicle.dealerAtlasPath: "base/gameplay/gui/common/icons/codex/assets_fullscreen25.inkatlas"
Vehicle.my.custom_vehicle.dealerPartName: "v_makigai_maimai_basic_suburban_05_full"[/code][size=3]
And if you are making color variations then declare [color=#00ff00]dealerPrice[/color], [color=#00ff00]dealerCred [/color]and [color=#00ff00]dealerVariants [/color]for base record and separate [color=#00ff00]dealerAtlasPath[/color] and [color=#00ff00]dealerPartName[/color] for each color variant and then append color variations records to Vehicle.vehicle_list (but not the base record). Example:[/size]

[code]Vehicle.my.custom_vehicle.blue.dealerAtlasPath: "your/path/to/inkatlas.inkatlas"
Vehicle.my.custom_vehicle.blue.dealerPartName: "your_blue_preview_icon"

Vehicle.my.custom_vehicle.green.dealerAtlasPath: "your/path/to/inkatlas.inkatlas"
Vehicle.my.custom_vehicle.green.dealerPartName: "your_green_preview_icon"

Vehicle.my.custom_vehicle.dealerPrice: 123000
Vehicle.my.custom_vehicle.dealerCred: 20
Vehicle.my.custom_vehicle.dealerVariants:
  - "Vehicle.my.custom_vehicle.blue"
  - "Vehicle.my.custom_vehicle.green"

# And somewhere in your tweak file
Vehicle.vehicle_list.list:
  - !append t"Vehicle.my.custom_vehicle.blue"
  - !append t"Vehicle.my.custom_vehicle.green"[/code][size=3]

For my sample cars pack I used previews from codex which have size [color=#00ff00]1860x609[/color] so it is better to make something similar (or you can reuse codex images as well). Previews for vehicle summoning widget should have [color=#00ff00]470 px[/color] width.[/size]


[color=#93c47d][size=5][b]How to install[/b][/size][/color]
[list]
[][size=3]Download and install all required files[/size][/]
[][size=3]Download the mod archives and unpack both to the game folder[/size][/]
[/list]
[color=#93c47d][size=5][b]How to uninstall [/b][/size][/color]
[list]
[][size=3]Open CET console and do this command: [color=#ffff00]ClearSoldVehicles()[/color][/size][/]
[][size=3]Delete Cyberpunk 2077\r6\scripts\VirtualCarDealer folder[/size][/]
[][size=3]Delete Cyberpunk 2077\r6\tweaks\VirtualCarDealer folder[/size][/]
[][size=3]Delete VirtualCarDealer.archive and VirtualCarDealer.archive.xl from your Cyberpunk 2077\archive\pc\mod folder.[/size][/]
[/list]
[color=#93c47d][size=5][b]Translation[/b][/size][/color]
[size=3]If you want to translate the mod to your own language, then download Translation sources archive, open vdealer.json with any text editor (I would recommend Notepad++) and translate only lines with "femaleVariant" key ([url=https://i.imgur.com/47NwXlp.png]sample screenshot[/url] from other mod, text which you should change marked with yellow). After that check the code for your language [url=https://github.com/psiberx/cp2077-archive-xl]here[/url] at the table below and send translated file back to me.[/size]
[b]
[color=#93c47d][size=3]Currently supported languages:[/size][/color][/b]
[list]
[][size=3]English[/size][/]
[][size=3]Russian[/size][/]
[][size=3]French (credits to Unseen Unit)[/size][/]
[][size=3]Traditional Chinese (credits to hansdofer)[/size][/]
[][size=3]Polish (credits to george173)[/size][/]
[][size=3]Spanish (credits to iguruspain)[/size][/]
[][size=3]Italian (credits to NarakuITA)[/size][/]
[][size=3]Turkish (credits to CalvinQuantine)[/size][/]
[][size=3]Brazilian Portuguese (credits to F4xUu)[/size][/]
[][size=3]Japanese (credits to onepkvn1)[/size][/]
[][size=3]Simplified Chinese (credits to HarryGu)[/size][/]
[][size=3]Czech (credits to Starfis)[/size][/]
[][size=3]German (credits to Somerov)[/size][/]
[][size=3]Korean (credits to MoookGwak)[/size][/]
[/list]
[color=#93c47d][size=5][b]Credits[/b][/size][/color]
[list]
[][size=3]jekky for the redscript compiler[/size][/]
[][size=3]WopsS for RED4ext[/size][/]
[][size=3]psiberx for codeware and stuff[/size][/]
[][size=3]e256 for a huge help with textures, testing and support[/size][/]
[][size=3]Alien for inkatlas-utils photoshop plugin[/size][/]
[/list]

[b][color=#93c47d][size=5]My other mods[/size][/color][/b]
[list]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/21482]Virtual Atelier Delivery[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/20743]Cutscene Weapon Swapper[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/17642]Revised Backpack[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/15036]Deus Ex Themed Palette[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/14935]HUD Painter[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/14264]Stash and Backpack Search[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/11882]Metro Pocket Guide[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/7238]Quickhack Hotkeys[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/5646]Wannabe Edgerunner[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/5298]Stash Filters[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/5115]Immersive Timeskip[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/5112]Faster Iguana Hatch[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4941]Real Vendor Names[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4725]Mark To Sell[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4714]Stand Still Please[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4625]Vehicle Pack - Basic[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4539]Vehicle Pack - Corpo[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4530]Vehicle Pack - Utility[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4509]Vehicle Pack - Gangs[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4476]Mizutani Shion Targa MZT[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4521]Named Saves[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4454]Virtual Car Dealer[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2987]Virtual Atelier[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4378]Enhanced Craft[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/4217]No Scanner Time Dilation[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/3819]Custom Map Markers[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/3309]Sleeves[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/3290]Toggle Quest Tags[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2959]Improved Minimap Zoom[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2820]Hide Read Shards[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2687]Smarter Scrapper[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2678]Reduced Loot[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2592]Limited HUD[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/3315]HUDitor[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2557]Always First Equip[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/2169]No Camera Auto Centering[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/1904]Holster By Hotkey[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/1889]Limited Fast Travel[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/870]Game Time Tweaks[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/1727]Muted Markers[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/1226]Yet Another UI Recolor[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/870]Game Time Tweaks[/url][/size][/]
[][size=3][url=https://www.nexusmods.com/cyberpunk2077/mods/533]No Intro Videos[/url][/size][/]
[/list]