Hunters Run 57 Posted April 6, 2022 43 minutes ago, AmanoJyaku said: A degenerate has no ethics or morals. 😁 It means there's a problem with the geometry: Edges with no length. Faces with no areas (faces on a point or thin faces). Face corners with no area. https://docs.blender.org/manual/en/latest/modeling/meshes/editing/mesh/cleanup.html I suspected as much. Either 610dan_31.wok (a tsl walkmesh) was shipped with a degenerate walkmesh, or I am experiencing a bug. Maybe both. Quote Share this post Link to post Share on other sites
DarthDrija 16 Posted June 5, 2022 I think I'm doing something wrong, I would appreciate some help. Whenever I create a model from scratch or import one and I edit the position of a single vertex on "Edit" mode, I get an error saying "bpy_prop_collection[index]: index 0 out of range, size 0" when exporting to an .mdl file. I've looked on the blender forums this issue and it says that there's a vertex outside any group, does it change anything other than position when moving? Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 14, 2022 It is okay to use this with older versions of Blender? i.e., 2.79a Quote Share this post Link to post Share on other sites
LoneWanderer 103 Posted June 14, 2022 Last time I checked, the plugin loaded with an error and didn't work on 2.79 and 2.80 Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 15, 2022 On 6/14/2022 at 11:53 AM, LoneWanderer said: Last time I checked, the plugin loaded with an error and didn't work on 2.79 and 2.80 Got it, thanks for info! Another question for anyone: I'd like to do some work on a model that has animation attached to it. Is it possible to just Import Geometry, remodel as needed, and then add the animation back in later? Or is it best to keep everything together? Quote Share this post Link to post Share on other sites
seedhartha 116 Posted June 16, 2022 Quote Is it possible to just Import Geometry, remodel as needed, and then add the animation back in later That should work, yes. I just checked. Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 16, 2022 12 hours ago, seedhartha said: That should work, yes. I just checked. Nice! Let me just say, hell of a job with this. No more breaking out to ascii and recompiling into binary. Love it! Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 17, 2022 Just me again, being a pain in the ass. I imported my model with Geometry, Animations, and Walkmeshes selected. I then made some edits to the model. However upon exporting (Animations, Walkmeshes, and Custom Normals selected), I'm thrown a list index out of range error. Any ideas as to what might be causing this error? Thanks for your time (and patience). Quote Share this post Link to post Share on other sites
seedhartha 116 Posted June 18, 2022 Quote list index out of range Hard to say. Can you send me the .blend file so that I could investigate? Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 18, 2022 2 hours ago, seedhartha said: Hard to say. Can you send me the .blend file so that I could investigate? You got it. plc_starmap.blend Quote Share this post Link to post Share on other sites
seedhartha 116 Posted June 18, 2022 You have loose vertices in Cylinder01. Select that object and do Mesh -> Clean Up -> Delete Loose. Meanwhile, I will have to think how to handle it properly. Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 18, 2022 16 minutes ago, seedhartha said: You have loose vertices in Cylinder01. Select that object and do Mesh -> Clean Up -> Delete Loose. Meanwhile, I will have to think how to handle it properly. Thanks for taking a look, I'll give it a go. Thank you! Quote Share this post Link to post Share on other sites
JediArchivist 70 Posted June 24, 2022 KotorBlender won't export my .mdl file. When i click on Export/Kotor Model (.mdl) and click Export KotOR MDL nothing happens, no .mdl file is created in the source folder. I can import files just fine, but cannot export new files... Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 24, 2022 This is likely a setting I'm overlooking, but my models in game are much smoother than they are in Blender. I have Object set to Shade Flat on all my pieces and Export Custom Normals seems to have no affect either. Any advice is appreciated, thanks for your time. 1 Quote Share this post Link to post Share on other sites
seedhartha 116 Posted June 25, 2022 13 hours ago, JediArchivist said: KotorBlender won't export my .mdl file. When i click on Export/Kotor Model (.mdl) and click Export KotOR MDL nothing happens, no .mdl file is created in the source folder. I can import files just fine, but cannot export new files... Can't help without seeing your .blend file. 6 hours ago, CarthOnasty said: This is likely a setting I'm overlooking, but my models in game are much smoother than they are in Blender. I have Object set to Shade Flat on all my pieces and Export Custom Normals seems to have no affect either. Any advice is appreciated, thanks for your time. Long story short, you need to duplicate vertices to emulate flat shading. This is a limitation of MDL file format. It's normals are per vertex, but in Blender normals are per triangle. Here's how you can workaround that: Mark edges connecting your flat triangles as sharp Add Edge Split modifier to the object (ensure that Sharp Edges flag is set) On export, this will duplicate vertices on sharp edges, creating a flat shaded look. 1 Quote Share this post Link to post Share on other sites
JediArchivist 70 Posted June 25, 2022 12 hours ago, seedhartha said: Can't help without seeing your .blend file. cat.blend Quote Share this post Link to post Share on other sites
CarthOnasty 214 Posted June 25, 2022 13 hours ago, seedhartha said: Long story short, you need to duplicate vertices to emulate flat shading. This is a limitation of MDL file format. It's normals are per vertex, but in Blender normals are per triangle. Here's how you can workaround that: Mark edges connecting your flat triangles as sharp Add Edge Split modifier to the object (ensure that Sharp Edges flag is set) On export, this will duplicate vertices on sharp edges, creating a flat shaded look. Awesome, thank you so much for the detailed explanation. Quote Share this post Link to post Share on other sites
seedhartha 116 Posted June 25, 2022 10 hours ago, JediArchivist said: cat.blend 6.24 MB · 0 downloads Fully custom models are possible, but it's not going to be that easy. At a minimum, to be able to export this, you need to: Create Empty object Under KotOR Model Node set Type to MDL Root Rename to match exported filename or it could crash Reparent your Mesh object to a newly created Empty object 2 Quote Share this post Link to post Share on other sites
JediArchivist 70 Posted June 26, 2022 11 hours ago, seedhartha said: Fully custom models are possible, but it's not going to be that easy. At a minimum, to be able to export this, you need to: Create Empty object Under KotOR Model Node set Type to MDL Root Rename to match exported filename or it could crash Reparent your Mesh object to a newly created Empty object Thank You very much for making it clear! Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted June 27, 2022 Is there a way to batch lightmap an entire level in one go? The described process of doing each individual mesh one at a time is not particularly practical given the sheer volume of meshes in an average level. Quote Share this post Link to post Share on other sites
seedhartha 116 Posted June 27, 2022 3 hours ago, DarthParametric said: The described process of doing each individual mesh one at a time is not particularly practical given the sheer volume of meshes in an average level. True that. Described process is the only way, as far as I'm concerned. It can be automated, but I will probably never find time to do that. Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted June 27, 2022 Is that a limitation of Blender or just because of dealing with Odyssey models? I stumbled across this - https://github.com/Naxela/The_Lightmapper - although it seems heavily focused on creating lightmap UVs, which isn't my primary concern. As terrible as the vanilla lightmap UVs are, I'd prefer not to have to replace hundreds of room models. Quote Share this post Link to post Share on other sites
seedhartha 116 Posted June 27, 2022 1 hour ago, DarthParametric said: Is that a limitation of Blender or just because of dealing with Odyssey models? I stumbled across this - https://github.com/Naxela/The_Lightmapper - although it seems heavily focused on creating lightmap UVs, which isn't my primary concern. As terrible as the vanilla lightmap UVs are, I'd prefer not to have to replace hundreds of room models. You don't necessarily have to use a separate plugin. Blender can lightmap pack multiple objects out-of-the-box. It's just that these objects need to share the lightmap texture. As for limitations, I don't see any, but it is not obvious how to connect these things in code. Quote Share this post Link to post Share on other sites
Marius Fett 196 Posted June 27, 2022 4 hours ago, DarthParametric said: Is there a way to batch lightmap an entire level in one go? The described process of doing each individual mesh one at a time is not particularly practical given the sheer volume of meshes in an average level. Just out of curiosity DP, is there a reason you’re not using Max for your lightmaps instead? I’ve always found it really straightforward in Max. Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted June 27, 2022 It's a gazillion times easier than Blender's approach to things certainly, but the results aren't exactly stellar. I've discussed the issues with KMax's OdysseyLight implementation with seedhartha previously and I was lead to believe that KBlender deals with them differently. I figured there was no harm (except loss of sanity points) in seeing what sort of lightmaps Blender could spit out. Quote Share this post Link to post Share on other sites