Mafia 3 Modding (Mega Thread)

Download Mods for the Mafia Games Forums Mod Creation Mafia 3 Modding (Mega Thread)

This topic contains 184 replies, has 65 voices, and was last updated by  jehodonjohn 1 year, 2 months ago.

Viewing 15 posts - 151 through 165 (of 185 total)
  • Author
    Posts
  • #164442
    Josh
    Josh
    Participant

    </noscript><noscript><noscript>
    First texture mod test! I retextured the coat from green to black.

    • This reply was modified 1 year, 8 months ago by Josh Josh.
    1 user thanked author for this post.
    #164445

    vob775
    Participant

    EDIT: OK I solved by myself. I’ll upload weather change script mod later.
     
    Anyone tried to change weather in scripthook? I tried it “game.gfx:SetWeatherSet” like this;
    game.gfx:SetWeatherSet("_default_game")
    but it occurs error below;
    Error loading Lua code into buffer. Error -100
    Missing adaptor arguments.
    stack traceback:
    [C]: in function 'SetWeatherSet'
    test:2: in function '(main chunk)'
    I can’t identify what is “missing adaptor arguments”.
    I hope that someone help me thanks.

    • This reply was modified 1 year, 8 months ago by  vob775.
    #164453
    y.u.s.i.k
    y.u.s.i.k
    Participant
    164437 wrote:

    SDS Tools have arrived, I better see some real mods now! https://drive.google.com/file/d/0B5pcr1AnCX0LbVJJM0ZOM1d2Ukk/view

    https://drive.google.com/file/d/0B5pcr1AnCX0LRUxwWjItbWI4ajA/view?usp=sharing

    3 users thanked author for this post.
    #164485

    KrakTankkill
    Participant

    Nice SDS Tool, but how can i tune cars 4 example, lets say tweak the accelerating or so?
    I don#t get the point how to search in the hex?

    #164492

    vob775
    Participant

    I found a way to use cheat/debug commands in post #163017.
    For example if you want use “carpls” command, make lua script like this.
     
    SpawnVeh =[[
    package.loaded.common.base.game_structure_console.carpls()]]
    unbindKey("o");
    bindKey("o", SpawnVeh);
     
    You can spawn random vehicles by press O key when you’re on-foot.
    If you want to spawn spicific vehicle,
    change carpls() to carpls("smith_mainline_p")
     
    But spawning vehicle is always full customized and painted with unsuitable livery.
    What a terrible scripting game… 🙁
    Anyway anybody knows how to remove upgrade items from current vehicle?

    1 user thanked author for this post.
    #164493
    Josh
    Josh
    Participant
    164492 wrote:

    I found a way to use cheat/debug commands in post #163017.
    For example if you want use “carpls” command, make lua script like this.

    SpawnVeh =[[
    package.loaded.common.base.game_structure_console.carpls()]]
    unbindKey("o");
    bindKey("o", SpawnVeh);

    You can spawn random vehicles by press O key when you’re on-foot.
    If you want to spawn spicific vehicle,
    change carpls() to carpls("smith_mainline_p")

    But spawning vehicle is always full customized and painted with unsuitable livery.
    What a terrible scripting game… ?<noscript>?</noscript><noscript>?<noscript>?</noscript></noscript><noscript>?<noscript>?</noscript><noscript>?<noscript>?</noscript></noscript></noscript><noscript>?<noscript>?</noscript><noscript>?<noscript>?</noscript></noscript><noscript>?<noscript>?</noscript><noscript>?<noscript>?</noscript></noscript></noscript></noscript>
    Anyway anybody knows how to remove upgrade items from current vehicle?

    Very nice find! How did you that function out? I’m trying to find if there is a way to decompile these 5.2.1 .lua files and edit them, would give us more control and see how some functions are used. And to answer your question, you can get the current vehicle you are in by using “game.game:GetActivePlayer():GetOwner()” and then you can use “game.hud:OpenCustomizeCarMenu(true)” to customize it and remove those upgrades.
    Also interesting, reading that script shows carpls() command uses this:
    SpawnCar……….GetPos……….GetDir……….UserData……….IsSuccess……….GetSpawnedEntity……….obtain_id……….DespawnEntity……….AddTag……….design……………MakeCarOwnership……….LockControls……….GetOnVehicle….€?………WALK……….DBGVehicleUpgrade…………all……….SetColor….€@………InstallTuningItems…€–D..–D..À»D..€ÎD..ÀÔD..áD………SetPainting……….paint_curves02—d……….SetDelivered
    Would be preferable decompiled but you can sorta read how it is used.
    SpawnCar uses game.traffic:SpawnCar(pos, dir, modelName?)
    Then those upgrades are added using SetPainting, DBGVehicleUpgrade, InstallTuningItems.
    So in theory, you can just use the game.traffic:SpawnCar function to spawn a default car because the carpls() command adds those upgrades that you don’t like.
    Most functions can be found here: http://mafia3scripting.wikia.com/wiki/Welcome
    Hopefully more Mafia 3 modding ensues!

    #164494
    vrock_wave
    vrock_wave
    Participant

    M3ScriptHook 1.2 does not work for me anymore I decided after a long break to try to run it with the latest version of the game with all DLC (WIN7)
    I tried to change the compatibility as they write here in the answers but still get the game broke after running M3ScriptHookLauncher . Is there a more recent version of M3ScriptHook than 1.2?
    by the way the new tool Mafia III ResourceExplorer_1.1 is very good for editing textures. I replaced a couple for the sake of curiosity

     

    • This reply was modified 1 year, 8 months ago by vrock_wave vrock_wave.
    • This reply was modified 1 year, 8 months ago by vrock_wave vrock_wave.
    • This reply was modified 1 year, 8 months ago by vrock_wave vrock_wave.
    #164497

    vob775
    Participant

    Thanks for info. I found how to execute function here;
    Also I tried to game.traffic:SpawnCar but not works even with any arguments.
    But I found a way to remove unsuitable livery;
    game.game:GetActivePlayer():GetOwner():SetPainting("")
     
    I think some scripts are disabled or protected by devs from user-executing such as RepairAndClear Repair SetCarDamege
    I hope more skilled people will take interest in Mafia3 modding.

    #164498
    Modded Games
    Modded Games
    Participant

    After hours of tweaking/messing around, I present Vampire Lincoln Clay. His head and body are pale white, he’s also pretty thirsty for blood.
     



    • This reply was modified 1 year, 8 months ago by Modded Games Modded Games.
    • This reply was modified 1 year, 8 months ago by Modded Games Modded Games.
    • This reply was modified 1 year, 8 months ago by Modded Games Modded Games.
    • This reply was modified 1 year, 8 months ago by Modded Games Modded Games.
    • This reply was modified 1 year, 8 months ago by Modded Games Modded Games.
    2 users thanked author for this post.
    #164507

    vob775
    Participant
    164494 wrote:

    M3ScriptHook 1.2 does not work for me anymore I decided after a long break to try to run it with the latest version of the game with all DLC (WIN7) I tried to change the compatibility as they write here in the answers but still get the game broke after running M3ScriptHookLauncher . Is there a more recent version of M3ScriptHook than 1.2? by the way the new tool Mafia III ResourceExplorer_1.1 is very good for editing textures. I replaced a couple for the sake of curiosity

    I downloaded and using latest version ScriptHook from here (Win7-64bit)
    https://mega.nz/#F!VscigCQQ!yl3PBpGpZ075v6K5x6PICA

    #164509
    vrock_wave
    vrock_wave
    Participant
    164507 wrote:

    M3ScriptHook 1.2 does not work for me anymore I decided after a long break to try to run it with the latest version of the game with all DLC (WIN7) I tried to change the compatibility as they write here in the answers but still get the game broke after running M3ScriptHookLauncher . Is there a more recent version of M3ScriptHook than 1.2? by the way the new tool Mafia III ResourceExplorer_1.1 is very good for editing textures. I replaced a couple for the sake of curiosity

    I downloaded and using latest version ScriptHook from here (Win7-64bit) https://mega.nz/#F!VscigCQQ!yl3PBpGpZ075v6K5x6PICA

    Thank you. I still got the work of my M3ScriptHook 1.2 running it on (win10 with compatibility under win8)

    #164510

    vob775
    Participant

    game.game:GetActivePlayer():GetOwner():InstallTuningItems(1601, 1501, 1903, 1701, 1801)
    --ItemIds are written in "sds_retail/tables.sds/car_customization.xml"
     
    Found way to install upgrades to current vehicle, but it causes crash immediately just like RepairAndClear.
    It’s soooooooo frustrating and I gave up today.

    #164516
    Luke Stud
    Luke Stud
    Participant

    Hi there, is there a way to change The Experience outfit shirt to shirtless model but with dog tags? I tried with the tool but the game will not load..
    Also would be nice to change Lincoln’s hair back to his basic hair instead of those hipster hair 😛
    Thanks in advance.

    • This reply was modified 1 year, 8 months ago by Luke Stud Luke Stud.
    #164518
    Josh
    Josh
    Participant
    164516 wrote:

    Hi there, is there a way to change The Experience outfit shirt to shirtless model but with dog tags? I tried with the tool but the game will not load..
    Also would be nice to change Lincoln’s hair back to his basic hair instead of those hipster hair ?
    Thanks in advance.

    I’ve been messing around with the sds files and it seems the only legit way to change your player model is through spawnprofiles.sds but the files instead are still encrypted and unknown to the current sds tools. Player and NPC models are defined in there and they tell the game what “combinables” in “sds_retail\combinables\auto” and “sds_retail\combinables\auto_unique” to combine and use.
    The prefix names:
    he_ = hero aka player charcter
    ma_ = male
    fe_ = female
    You can swap textures easily but not models I’m pretty sure yet. The head models contain the skeleton.
    I was making a Vito mod with sdaddy345 aka Modded Games and this is how far we’ve gotten:

    We swapped he_basebody with ma_basebody and it made Lincoln white. Still more research needs to be done.

    2 users thanked author for this post.
    #164520

    vob775
    Participant

    Finally I did it that spawning vehicles without awful upgrades and painting.
    Currently the biggest problem is we can’t spawn all vehicles by “bindkey” command because this game has over 70 vehicles.
    Hopefully if someone tell me the way to store two digits number by pressing two numeric keys in lua script.

    • This reply was modified 1 year, 8 months ago by  vob775.
    • This reply was modified 1 year, 8 months ago by  vob775.
    4 users thanked author for this post.
Viewing 15 posts - 151 through 165 (of 185 total)

You must be logged in to reply to this topic.