OberSchutze 19 Posted December 14, 2015 Hello all, Having a small issue with the guerrilla classes. I cannot get the unit to appear in game or arsenal. class TF2031_OCP_lw_Soldier_F: I_G_resistanceLeader_F { _generalMacro = "I_G_resistanceLeader_F"; scope = 2; displayName = "Taskforce 2031 Light Weight Soldier"; nakedUniform = "U_BasicBody"; uniformClass = "TF2031_OCP_lw_Soldier_F"; hiddenSelections[] = {"Camo","Insignia"}; hiddenSelectionsTextures[] = {"\Projects\TF_2031_Mod\addons\TF_2031_Units\data\textures\uniforms\TF2031_c_lightweight.paa"}; linkedItems[] = {"TF2031_combatbelt_ocp","TF2031_hat_ocp","ItemMap","ItemCompass","ItemWatch","ItemRadio"}; respawnLinkedItems[] = {"TF2031_combatbelt_ocp","TF2031_hat_ocp","ItemMap","ItemCompass","ItemWatch","ItemRadio"}; }; class TF2031_OCP_lw_CombatUniform_mcam: Uniform_Base { scope = 2; displayName = "Taskforce 2031 Light Weight (OCP)"; picture = "\A3\characters_f\data\ui\icon_U_B_CombatUniform_mcam_ca.paa"; model = "\A3\characters_f_epb\Guerrilla\ig_guerrilla4_1"; class ItemInfo: UniformItem { uniformModel = "-"; uniformClass = "TF2031_OCP_lw_Soldier_F"; containerClass = "Supply200"; mass = 1; }; }; I have the required addons in the proper place, the class set for the cfg vehicles and the uniform has the uniform base in cfg weapons. Not too sure what I am missing never had this issue before. Share this post Link to post Share on other sites
Jackal326 1181 Posted December 15, 2015 Change uniformClass = "TF2031_OCP_lw_Soldier_F"; to actually use the uniform's classname: uniformClass = "TF2031_OCP_lw_CombatUniform_mcam"; Do that in both entries. Share this post Link to post Share on other sites
Locklear 214 Posted December 17, 2015 Not in both, just in the soldier's config. In short, the uniformClass proeprty in soldier's class points to a uniform class, and the uniformClass property in the ItemInfo subclass of a uniform's class points to a soldier's class. Also, the model property in a uniform class is actually not a uniform, but a "suitpack" which appears on the ground when a uniform is placed from editor or inventory and such. So the model should be, for example, something like "\A3\Characters_F\Common\Suitpacks\suitpack_original_F.p3d". For more information, you can check my guide. Good luck. :) Share this post Link to post Share on other sites
OberSchutze 19 Posted December 30, 2015 I got it the show up in game now, t hank you, however it seems the texture is getting overridden to the default one for some reason. Can you think of a reason this would happen? It is setup like my other 10 or so items. Below is the code I am using. class TF2031_OCP_gur_Soldier_F: I_G_Soldier_base_F { _generalMacro = " I_G_Soldier_base_F"; scope = 2; displayName = "Taskforce 2031 Light Weight"; nakedUniform = "U_BasicBody"; uniformClass = "TF2031_OCP_gur_CombatUniform_mcam"; hiddenSelections[] = {"Camo","Insignia"}; hiddenSelectionsTextures[] = {"\Projects\TF_2031_Mod\addons\TF_2031_Units\data\textures\uniforms\TF2031_c_lightweight.paa"}; linkedItems[] = {"TF2031_OCP_PlateCarrier1_rgr","TF2031_fast_ocp","NVGoggles","ItemMap","ItemCompass","ItemWatch","ItemRadio"}; respawnLinkedItems[] = {"TF2031_OCP_PlateCarrier1_rgr","TF2031_fast_ocp","NVGoggles","ItemMap","ItemCompass","ItemWatch","ItemRadio"}; }; class TF2031_OCP_gur_CombatUniform_mcam: Uniform_Base { scope = 2; displayName = "Taskforce 2031 Light Weight"; picture = "\A3\characters_f\data\ui\icon_U_B_CombatUniform_mcam_ca.paa"; model = "\A3\Characters_F\Common\Suitpacks\suitpack_original_F"; class ItemInfo: UniformItem { uniformModel = "-"; uniformClass = "TF2031_OCP_gur_Soldier_F"; containerClass = "Supply200"; mass = 1; }; }; Share this post Link to post Share on other sites
Jackal326 1181 Posted December 30, 2015 Your texture path is bad: hiddenSelectionsTextures[] = {"\Projects\TF_2031_Mod\addons\TF_2031_Units\data\textures\uniforms\TF2031_c_lightweight.paa"}; Should be like: hiddenSelectionsTextures[] = {"\TF_2031_Units\data\textures\uniforms\TF2031_c_lightweight.paa"}; If it works like the first example for your other units, I've lost all faith in modding... As a side note, it also pains me to see people not using the texture naming rules. Share this post Link to post Share on other sites
OberSchutze 19 Posted December 30, 2015 It has worked like that, as a matter of fact it was the only way it seemed to work I was getting path errors before I did that. Share this post Link to post Share on other sites
Jackal326 1181 Posted December 30, 2015 I suppose it may do if your PBO packing tool is correctly setup to Bianrize the absolute P:\Projects... path out of the files, but shouldn't need to be setup that way. Share this post Link to post Share on other sites
OberSchutze 19 Posted December 30, 2015 It started happening when I got the latest mikero tools. Share this post Link to post Share on other sites
OberSchutze 19 Posted December 30, 2015 Just tested it by taking out the \projects\... part and it gives errors while packing so I have to keep the projects part in i guess. Still not sure why my texture is being overridden. Share this post Link to post Share on other sites
Jackal326 1181 Posted December 30, 2015 Just tested it by taking out the \projects\... part and it gives errors while packing so I have to keep the projects part in i guess. Still not sure why my texture is being overridden. Presumably because its not being found by the game (check your RPT). In Mikero's PBO Project, check your 'Setup' options and look under the 'Workspace' setting. Mine is just set to P:\ - chances are yours is set to P:\Projects\ or similar (assuming of course you even use the P:\ drive setup). This would explain the error whilst you attempt to pack it. I have no idea whether Mikero's (or BI's) tools are built in such a way to account for parent directories to be included - the only way to be sure would be to unpack your pbo and check the config.bin (after un-RAPing it) to see if it retains the 'Projects\TF2031_whatever' path. If it does, thats why your addon is broken and doesn't work. If on the other-hand the tools have removed this from the files during packing/Binarizing etc I'm at a loss. All I know is I've used that exact uniform model with setobjecttextures/hiddenselections with no issue. The rest of your config seems sound, the texture path is the only thing that stands out as off. Share this post Link to post Share on other sites
OberSchutze 19 Posted December 31, 2015 Well that is just it, the mod isnt broken. I have about 50 different head objects like berets, helmets, and hats that work fine, about 15 plate carriers that work fine, 8 other uniforms that work fine, 4 back packs and so on, it is just this one object that doesn't display the correct texture. Share this post Link to post Share on other sites
Jackal326 1181 Posted December 31, 2015 I just opened the model in a hex-editor and saw there is also a named selection called "camo2". Try using that in the HiddenSelections array instead of "camo". Its only referenced once in the entire model, so it probably wont work. I've just checked my previously mentioned addon where I thought I had used this exact model with setobjecttexture, but unfortunately it was a different model. Share this post Link to post Share on other sites
OberSchutze 19 Posted December 31, 2015 It still didn't work. I looked at the RPT file and found this entry, not sure what it means: Warning Message: Error: creating weapon TF2031_OCP_gur_Soldier_F with scope=private Share this post Link to post Share on other sites
Jackal326 1181 Posted December 31, 2015 It would imply that your unit has scope=0; somewhere in its config entry, but it clearly doesn't (it has scope=2 i.e. public), so not sure why its throwing that error. Perhaps Locklear (or someone else) can shed further light on the situation and hopefully see something we're missing Share this post Link to post Share on other sites
OberSchutze 19 Posted January 1, 2016 In the mean time, I just wanted to say I appreciate your help. Share this post Link to post Share on other sites
Artenis 7 Posted January 4, 2016 Hello, After looking a bit in the A3 config, it seems the class "I_G_Soldier_base_F" has either a wrong model path or a wrong hiddenSelections config. Anyway the model in this class points to this one but the texture linked is applied to that one. So the Guerilla1_1 config should be class soldier_classname : I_G_Soldier_base_F { [...] uniformClass = "suitpack_classname"; hiddenSelections[] = {"Camo1", "Camo2"}; hiddenSelectionsTextures[] = {"\path_to_tshirt_texture.paa","\path_to_pants_texture.paa"}; }; And the Guerilla2_1 should be class soldier_classname : I_G_Soldier_base_F { [...] model = "\A3\characters_F_gamma\Guerrilla\ig_guerrilla2_1.p3d"; uniformClass = "suitpack_classname"; hiddenSelections[] = {"Camo", "insignia"}; hiddenSelectionsTextures[] = {"\path_to_texture.paa"}; }; Don't know if that helps, as I'm not sure what uniform model you want to retexture Share this post Link to post Share on other sites
OberSchutze 19 Posted January 4, 2016 I got it sorted out now. Thank for your help. Share this post Link to post Share on other sites