DarthParametric 3,785 Posted December 21, 2019 Aside from a bone count limit on skinned meshes (the MDL format supports a maximum of 17 bones per mesh, hence why KOTOR models split off arms/hands and heads) and a maximum character count of 16 for any object name, there's no problem with custom rigs. Except of course said rigs would obviously require custom animations. The plan was indeed to use the TOR rig directly in KOTOR if we could have managed to retarget the KOTOR animations successfully. Quote Share this post Link to post Share on other sites
Alvar007 130 Posted December 21, 2019 6 minutes ago, DarthParametric said: Aside from a bone count limit on skinned meshes (the MDL format supports a maximum of 17 bones per mesh, hence why KOTOR models split off arms/hands and heads) and a maximum character count of 16 for any object name, there's no problem with custom rigs. Except of course said rigs would obviously require custom animations. The plan was indeed to use the TOR rig directly in KOTOR if we could have managed to retarget the KOTOR animations successfully. Oh, nice. Well I guess that makes things easier then. And do you have to convert the rig to bone objects like the game uses or can it be actual bones? If so, how would you convert them? Also, can these custom rigs have IK constraints? That would make my life much easier. Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted December 21, 2019 No constraints, or at least none are used by the game. But as long as you can bake out the bone transforms as simple keyframes afterwards, you could presumably use them to create custom anims though. If you can get your rig into Max with anims as bone transform keyframes then KOTORMax should be able to export an ASCII model. Then you'll want to create a trimesh rig, since you need that as a shadowcaster. From there you have two options. Use the first model as a supermodel, or just transfer the anims over to the trimesh rig directly. The easiest route would be simply copying and pasting from one ASCII to the other, assuming your trimesh rig is properly set up with the correct pivots. Quote Share this post Link to post Share on other sites
Alvar007 130 Posted December 21, 2019 Oh my god, I think I have found the way. I tried baking the action of the bones to the trimesh rig and it actually works! Previously I just tried selecting all of them to do the baking in one go but Blender only does it for the last one you selected. I think that's why I haven't noticed this before and thought that this didn't work. So I have to do them one by one but it's still faster than all the hassle I had to go through in the first post, so no need for delta transforms or messy things like that. I just have to make sure to delete some scales Blender applies after doing the baking. So in summary: I just have to create the temporary bone rig, parent it to the trimesh rig, do the animation and then bake it to the trimesh rig and voila! And all of this inside Blender! But I noticed it was giving me a "tuple index out of range" error when exporting. So I deleted some of the keyframes in between and it worked. Do you think the game models have a limit in keyframes or something? I haven't tried the IK constraints yet, but it should work. I just have to convert the IK to FK after finishing the animation and then bake as I stated. Quote Share this post Link to post Share on other sites
JCarter426 1,215 Posted December 21, 2019 It would accept anything, provided the model format was otherwise accurate, but the issue is that if you want to use the existing supermdel and don't want to replace every single animation in the game yourself, you need the original rig. With the MMO rig, that's not so much an issue. The bones are mostly in the same place, although the proportions are a little off. I forget if I tried retargeting the bones themselves, but I did manage to set up a rig to pose an MMO model into KOTOR size and position. But it still needed some tweaking and would have to be repeated for each body size. As for the Selkath and other animation stuff, we last left it in the state where it looked doable, but I think it would take a lot of time and effort for someone with my level of ineptitude and I have a million other things to do. I remember there were three big hurdles that I anticipated. First, the reach of the arms was a little - like when holding a melee weapon, the left hand didn't quite reach and grip the weapon. So that means all the combat animations would possibly have to be adjusted manually. Second, I noticed the key frame numbers were off sometimes, maybe due to rounding errors. If they got too out of sync, then the whole timeline would need to be adjusted so the animation times match the actual key frames again. Finally, there are things that can't be retargeted at all, like the eyes and any bones on the model that aren't present on the human rig (on the Selkath, for example, the flappy cephalic nodes) and those would always have to be manually animated. I can provide a library of thousands of free sourced animations for anyone who does manage it, though. One of the other goals of messing with the MotionBuilder stuff was the potential of getting new animations from anywhere onto the KOTOR rig. Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted December 22, 2019 8 hours ago, JCarter426 said: I forget if I tried retargeting the bones themselves We did. That's what one of those GIFs I posted on the previous page was, the dance animation retargeted to the TOR rig. Ironically it turned out much worse than the Selkath attempt, despite being notionally more similar in structure. But maybe that's just down to my lack of ability. Quote Share this post Link to post Share on other sites
JCarter426 1,215 Posted December 22, 2019 Hmm, either that was you solo or I just don't remember. I could see why the MMO rig would be a bit of trouble, like the arm length, but I don't know why it would be that much trouble. Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted December 22, 2019 2 minutes ago, JCarter426 said: I don't know why it would be that much trouble The fact that I suck at retargeting was probably some sort of factor. 1 Quote Share this post Link to post Share on other sites
Alvar007 130 Posted January 16, 2020 Ok so I renamed all the Selkath animations to their humanoid equivalents. There were multiple variations of the same action (attack, parry, dodge ,etc.) and there are only 1 or 2 slots in the humanoid supermodels so some of them will not be playing. They mostly work except for the die animation which sometimes does and sometimes it doesn't. I don't know why this happens, must be a bug with the game or something. The times that it doesn't work the Selkath is just playing the previous animation it was playing before dying which kind of ruins it but I just can't do anything about that unless someone knows what's going on. I don't know if this happens in the vanilla game as well. Also the insane Selkath remain unaffected as they use another appearance with the L modeltype. But the model they use is the same so they should be affected, it's so weird. I also included the appearance.2da that is mixed with JC's K2 Robe mod in case you want to use that mod with this one. (Or if there are problems overriding appearance.2da like other people had then just open the one you are using and change the modeltype of the Alien_Selkath_01 appearance (row 40) from L to F). n_selkath.mdx n_selkath.mdl appearance.2da 1 Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted January 16, 2020 There are 3 different die/dead animations. The combat animations (actually falling down) are die and die1. The matching dead animations (laying on ground) are dead and dead1. There are also getupdead and getupdead1, which should be self-explanatory. You can just duplicate the existing ones and rename them, since they are just variations of the same thing (falling over face-first). There is also die3/dead3, which is the prone/laying on back anim, the difference in this case being that die3 is dying while already prone, not falling from standing. I'm not sure if those two are used in combat. Possibly some Force powers may end in that prone state. If you want to test it you could always make a duplicate of something really obvious (like dance, assuming you made that) and see if/when it gets triggered. Regarding the insane Selkath, the Race model is set to N_SelkathCr, so it is presumably using that, not N_Selkath. Although the latter is set as body model A (naked/underwear model), and most of them don't have any equipped clothes/armour. Perhaps when a RaceTex is specified the Race model overrides the body models, not sure. I would suggest editing those rows in appearance.2da and changing the A model to N_SelkathCr to be safe. When you have a finalised mod ready for release, a TSLPatcher setup can be made that will dynamically edit appearance.2da. Quote Share this post Link to post Share on other sites
Jango32 23 Posted January 16, 2020 I think Force Whirlwind can lead to death3 if the final spin's damage kills. Quote Share this post Link to post Share on other sites
Alvar007 130 Posted January 17, 2020 23 hours ago, DarthParametric said: You can just duplicate the existing ones and rename them, since they are just variations of the same thing That's what I did, but I still had no luck. 23 hours ago, DarthParametric said: There is also die3/dead3 23 hours ago, DarthParametric said: I'm not sure if those two are used in combat. I thought the same as you and didn't give them too much importance so I didn't include them before. But now that I did it appears to be working consistently. 23 hours ago, DarthParametric said: When you have a finalised mod ready for release, a TSLPatcher setup can be made that will dynamically edit appearance.2da. Someone will have to explain me how to do that. 1 Quote Share this post Link to post Share on other sites
Salk 374 Posted January 23, 2020 Hello Alvar007. Using the TSL Patcher is not particularly complicated but it may take some time to become comfortable. I don't use it for my own modding but if I can be of assistance when the time comes, let me know. Others could help you with it much better than I could though. Cheers! Quote Share this post Link to post Share on other sites
Alvar007 130 Posted January 24, 2020 18 hours ago, Salk said: Hello Alvar007. Using the TSL Patcher is not particularly complicated but it may take some time to become comfortable. I don't use it for my own modding but if I can be of assistance when the time comes, let me know. Others could help you with it much better than I could though. Cheers! Hello Salk! Funnily enough I was looking at TSLPatcher after trying a mod that didn't work for some reason. I am talking about this mod. When I run TSLPatcher it first asks me if I have a spells.2da in my override folder, but why would I have that? From what I read, the mod should have a clean spells.2da in the tslpatchdata folder and then inject whatever it has to do after placing it in override folder. If I don't have it, the mod doesn't install at all. And if I do the installer gives me warnings that some files could not be copied because they don't exist. The mod should be providing these files but they are not in the tslpatchdata folder. Either way, when I load up the item in game no text appears at all and I can't select anything. Do you know what's going on? Also regarding the Selkath mod if I read the manual carefully I could try and prepare it to be installed with TSLPatcher. I would just have to modify a column in appearance.2da and then copy paste the selkath model into override. Although I don't know if placing my appearance.2da in the tslpatchdata folder will override any appearance.2da people may already have in their override folder or if it would just detect it and change the column dinamically. Quote Share this post Link to post Share on other sites
Salk 374 Posted January 24, 2020 Hello, Alvar007! From what little I know the installer should provide the original file that it is going to modify if it is not already present in the override or, in case of GFF changes, in the module folder and skip doing that if there is already a file present. So your modification, if using the TSL Patcher, will provide the original, unaltered appearance.2da file and proceed to make the necessary changes using that file. If the TSL Patcher finds already the appearance.2da file in the override, it will use that instead. I am really the last one who should speak about it though since I have practically never bothered to learn much about it since I am not using it myself. If @ebmar finds he has some time, he is excellent at tutorials and explanations and he might chime in. Cheers! Quote Share this post Link to post Share on other sites
Alvar007 130 Posted February 16, 2020 That's good to know Salk, thanks! I have now learned how to use TSLPatcher and it's going to be useful for the Selkath mod. Also, for anyone interested, as per @Liserg's request I managed to fix the animations for Darth Malak so that he can now use all the animations from the humanoid supermodels including the cutscene ones while maintaining his original ones as you can see here: I added a custom portrait for him as well, and made him selectable in the character creation menu. I also ported both Nihilus and Malak (the latter having all the additional animations from K2) to K1 and K2 respectively: But I have a problem when trying to play as them from the selectable character menu: Nihilus dissapears after the first cutscene (right when the dialogue with Trask) and Malak has his head placed down a little inside his body. So they only properly work selecting them from KSE at the moment. Anyway, I could make a mod release for Malak at least if someone is interested. 1 3 1 Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted February 16, 2020 Using KSE is basically equivalent to using them as a disguise. Since they are full body models, a disguise is probably the most expedient route for a mod, albeit one saddled with a few potential issues. If you really want to make a version that turns up in the character creation menu then you'll need to split out the heads to their own model, make provision for them in heads.2da and portraits.2da, etc. Look at an existing head mod for an idea of how the setup works. The main difference would be that you'd need to set every body model to their matching custom body, not the regular underwear/clothes/armour/robes models. Note that since character creation ignores the head's appearance.2da row, the head will be slapped on the appropriate class outfit in K1 and commoner clothes in TSL for that bit. 1 Quote Share this post Link to post Share on other sites
Salk 374 Posted February 16, 2020 Very nice job done there, my friend! I don't personally use non standard PC characters myself but giving Malak a full set of animations was a really good feat. I will be eagerly waiting for the Selkath mod to be out and I do hope your exams have been very successful. Cheers! Quote Share this post Link to post Share on other sites
Ebony Moon 187 Posted February 16, 2020 22 hours ago, Alvar007 said: That's good to know Salk, thanks! I have now learned how to use TSLPatcher and it's going to be useful for the Selkath mod. Also, for anyone interested, as per @Liserg's request I managed to fix the animations for Darth Malak so that he can now use all the animations from the humanoid supermodels including the cutscene ones while maintaining his original ones as you can see here: I added a custom portrait for him as well, and made him selectable in the character creation menu. I also ported both Nihilus and Malak (the latter having all the additional animations from K2) to K1 and K2 respectively: Anyway, I could make a mod release for Malak at least if someone is interested. Both Sith Lords selectable in both games would be awesome. Would love to see the Malak one. Thank you for your work. 2 Quote Share this post Link to post Share on other sites
Liserg 10 Posted February 18, 2020 To be honest, I had no hope that Darth Malak's model would ever be animated. Thank you for knowing how difficult this task is and how much easier it would be to refuse citing employment, you not only did a great job with it, you did much more, you fulfilled a dream. Thank you very much for this and immense respect. 1 Quote Share this post Link to post Share on other sites
Alvar007 130 Posted February 22, 2020 The Selkath mod and Darth Malak fix have been uploaded. I will only do the items for the other two for now, since I can't figure out how to fix those problems. I have sent a message to @Ӄhrizby asking for permission to use his Darth Nihilus Animation Fix that I want to include with my port, but he hasn't connected for a year so I don't know if I can upload it if he doesn't reply. Also, I wanted to create a custom icon for the Darth Malak item (you can check it out in the Malak fix) but it appears so big that it fills the whole UI space in game instead of having that blue frame around it like the rest of the icons. Anyone knows how can I achieve that? 2 Quote Share this post Link to post Share on other sites
Sith Holocron 2,478 Posted February 22, 2020 11 hours ago, Alvar007 said: Also, I wanted to create a custom icon for the Darth Malak item (you can check it out in the Malak fix) but it appears so big that it fills the whole UI space in game instead of having that blue frame around it like the rest of the icons. Anyone knows how can I achieve that? What size is your icon? Quote Share this post Link to post Share on other sites
Alvar007 130 Posted February 22, 2020 6 hours ago, Sith Holocron said: What size is your icon? 64x64 just like the rest of the icons. Quote Share this post Link to post Share on other sites
Sith Holocron 2,478 Posted February 22, 2020 1 hour ago, Alvar007 said: 64x64 just like the rest of the icons. That seems strange... Quote Share this post Link to post Share on other sites
Emperor Turnip 45 Posted February 25, 2020 I've been working on remodeling droids on Peragus in 3dsMax. Have you determined if you can use your own rigs for animations? Or would I be stuck just building around the "bones" that the original models have. Thanks for any info! Love your work, and great to see there are still ambitious modders out there 1 Quote Share this post Link to post Share on other sites