Krazyguy75 Posted March 1, 2016 Share Posted March 1, 2016 Basically, what the title says. I'm trying to add a new enemy to the game, but I can't seem to get the appearance to change. I've created a new package, changed the texture, changed the material, and updated a lot of references, but it just loads in with the old textures from the original muton (which is what this enemy is based on). Can someone help me figure out what I didn't change correctly? Link to comment Share on other sites More sharing options...
davidlallen Posted March 1, 2016 Share Posted March 1, 2016 There are a few published mods that do this, including the day 0 dlc for muton centurion. I recommend to download one or more of these and pick apart the files they added. Probably you will find something. Link to comment Share on other sites More sharing options...
Amineri Posted March 1, 2016 Share Posted March 1, 2016 The chain goes : code => archetype => skeletal mesh => material instance/material => texture. Code is set in the Character template, and looks like : CharTemplate.strPawnArchetypes.AddItem("LWMutonM2.ARC_GameUnit_MutonM2"); The reason it's a dynamic array of PawnArchetypes is to support multiple model types per unit. This is currently used to support the male/female ADVENT variants. Each instance randomly gets one of the configured archetypes (so if there's only one, that's it 100%). In the Archetype, the Skeletal Mesh is in Pawn/Mesh/SkeletalMeshComponent/SkeletalMesh. Within the Skeletal Mesh, the material is set in the Properties-Mesh tab, in SkeletalMesh/Materials/[#] -- skeletal mesh can be a "composite" of multiple submeshes, each with its own UVmap and material definition. Within a material instance, textures are typically in the Parameter Groups/Textures. Rarely, a material is used directly instead of a material instance, in which case the texture is basically hard-coded into the material. Link to comment Share on other sites More sharing options...
Krazyguy75 Posted March 1, 2016 Author Share Posted March 1, 2016 (edited) Whelp. Everything seems to be set correctly. I guess I'll delete the built files and rebuild and hope that fixes it. EDIT: Nope, no luck. Every reference Amineri mentioned is set correctly, and the Skeletal Mesh is displaying with the correct textures, but when I load it it looks like a normal muton... I'm so confused... Also, not as important, but how did you add the Centurion helmet? I'm just kinda curious. Edited March 1, 2016 by Krazyguy75 Link to comment Share on other sites More sharing options...
Amineri Posted March 1, 2016 Share Posted March 1, 2016 Whelp. Everything seems to be set correctly. I guess I'll delete the built files and rebuild and hope that fixes it. EDIT: Nope, no luck. Every reference Amineri mentioned is set correctly, and the Skeletal Mesh is displaying with the correct textures, but when I load it it looks like a normal muton... I'm so confused... Also, not as important, but how did you add the Centurion helmet? I'm just kinda curious. Sorry you're having trouble getting it to work. I guess I'm not quite sure how a new enemy is displaying as a Muton. Would probably have to see the code to have a chance to figure it out. One thought that occurs to me is to double-check that you've added your art package to your ModBuddy project. Adding it is necessary to get it to copy over to the game/SDK mod folders, as well as to run the precompileshaders commandlet, which builds the ModShaderCache. ------------------------- As for the Centurion, the process worked like this :Exported Muton Skeletal Mesh from UnrealEd to fbx file Imported fbx into Blender (JC Lewis did all the Blender stuff) Created new mesh for helmet, with separate UV mapping to a separate UV space Baked hi-poly helmet mesh to low-poly, generating normal map (NRM) Rigged helmet to a new bone attached to the Muton skeleton in the head Added detailing to DIF and MSK textures Imported skeletal mesh into UnrealEd Imported DIF, NRM, MSK textures into UnrealEd Created new material instance using Firaxis-created material (Alien_SD_SSS I think?) Configured material instance settings, including textures Applied new material to Material[1] of skeletal mesh Set new Centurion archetype to use new skeletal mesh Set Character template to use new archetype Link to comment Share on other sites More sharing options...
Krazyguy75 Posted March 3, 2016 Author Share Posted March 3, 2016 Problem solved, but I still don't know what it was. I redid all the references, and it fixed it. Link to comment Share on other sites More sharing options...
Recommended Posts