📢 PSA: Custom mask mods - Changes required for Payday 2 Update 243

Originally posted by Rex on Steam Discussions

With update 243 we made adjustments to how masks can be customized, which required shader changes that now needs the "material_config" files to be updated.

Custom mod masks will not automatically support this new format so to make it work in the new system you will need to make the following changes!

Rename the render_template from "solid_mask" to "solid_mask:MATS_3" Add material_amounts vector3 parameter Add diffuse_layer0_texture parameter Add diffuse_layer1_texture parameter Add diffuse_layer2_texture parameter

If you are uncertain on how to add these parameters; See the below codeblocks for an old and new version of a mask material.

Old material code block for reference:

<material name="mat_template" unique="true" render_template="solid_mask" version="2"> <diffuse_texture file="units/payday2/masks/msk_template/template_df"/> <bump_normal_texture file="units/payday2/masks/msk_template/template_nm"/> <reflection_texture file="units/payday2/matcaps/matcap_plastic_df"/> <material_texture file="units/payday2/masks/shared_textures/patterns/pattern_no_color_no_material_df"/> <variable value="0 0 0" type="vector3" name="tint_color_a"/> <variable value="0 0 0" type="vector3" name="tint_color_b"/> <variable value="1" type="scalar" name="material_amount"/> </material>

Same material in the new format.

<material name="mat_template" unique="true" render_template="solid_mask:MATS_3" version="2"> <diffuse_texture file="units/payday2/masks/msk_template/template_df"/> <bump_normal_texture file="units/payday2/masks/msk_template/template_nm"/> <reflection_texture file="units/payday2/matcaps/matcap_plastic_df"/> <material_texture file="units/payday2/masks/shared_textures/patterns/pattern_no_color_no_material_df"/> <variable type="scalar" name="material_amount" value="1"/> <variable type="vector3" name="material_amounts" value="2 2 2"/> <diffuse_layer0_texture file="units/payday2/matcaps/matcap_plastic_df"/> <diffuse_layer1_texture file="units/payday2/matcaps/matcap_plastic_df"/> <diffuse_layer2_texture file="units/payday2/matcaps/matcap_plastic_df"/> </material>

I need help! It's not working!

Make sure you have not made changes to "diffuse_texture", "bump_normal_texture", "reflection_texture", "material_texture" or the parameter "material_amount". Check to see if you have the right variable type for your "material_amounts" parameter, it should be "vector3" and NOT "scalar". Make sure the parameters for "tint_color_a" and "tint_color_b" are not present in the material. If all else fails make a comment under this post and someone can point out any mistakes that may have been made.
Request: Mod to deduct cleaner costs for killing cop hostages?
Avatar

As the title says, I would like to request a mod that deducts cleaner costs from the player upon killing a cop hostage. This should, if possible, be reduced with Sixth Sense Aced(?)

Thanks in advance.

Feature RequestFun
Avatar

...Yeah, could probably do this.

Avatar

That would make for two times I owe you... Good luck! x3c

Avatar

You don't owe me anything besides maybe an unban for your Payday servers.

Any preferences for the mod? Higher/lower cleaner cost? Stealth only? Exclusion to gangsters?

Avatar

@insomnia I believe you were already unbanned a while ago after we chatted and cleared things up, so that's already said and done

As for preferences, I would say either the same cost as or slightly more than killing a civvie, not stealth or loud dependent, and...
I don't think gangsters can be taken hostage anyway, so that shouldn't matter, but in a case where they somehow could, don't deduct anything lol

Avatar

Okay, here you go.

The cleaner cost will not apply unless the enemy counts as a hostage and has their hands tied. If the enemy has their hands up or their weapon dropped, nothing will happen upon killing them.
I added a 1.5x cleaner cost multiplier for killing a police hostage. If you want to change it, you can do so in line 2 of moneymanager.lua.
Certain mods allow gangsters to surrender and become converts even. Killing a surrendered gangster won't activate the cleaner cost.
Killing a police hostage won't increase the time spent in custody.
I was not able to test if this works in multiplayer or not.

Avatar

@insomnia Seems good... 1.5 was the exact multiplier I was thinking of ironically. Nice work. I guess I'll see whether this works when somepony next plays the game with me. Thanks for now. :) b

Avatar

Oh! Wait! I messed up. I noticed too soon that the cleaner cost only applies on bullet damage and not melee damage. Let me fix it...

Avatar

@insomnia All good, take your time

Avatar

Okay, I fixed the download link. Should contain the updated mod. Cleaner costs should apply for melee, explosion and damage over time now.

Avatar

@insomnia Gotcha. Nice catch

Avatar

Thank you. Enjoy the mod. Feel free to upload it if you want to. If not, I'll probably upload it myself eventually since I'm pretty proud of this one.

Avatar

@insomnia You're welcome, I certainly will. You may upload this yourself. And I'd be proud of myself too if I were you, that was quick

30 1027