eNoodles 31 Posted August 6, 2018 For some reason when I add sitting npc placeables into a module (like plc_sitrodian for example), they're t-posed in-game. I've tried messing around with the Animation State field, but nothing changes. I haven't noticed anything else on the sitting placeables in vanilla modules that could affect this. Any ideas? 1 Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted August 6, 2018 You'll probably need to add to the module's on-enter script. Something like this: sub3(OBJECT_SELF); oAreaObject = GetFirstObjectInArea(OBJECT_INVALID, 64); while (GetIsObjectValid(oAreaObject)) { if ((GetTag(oAreaObject) == "ptar_pazplayer")) { AssignCommand(oAreaObject, ActionPlayAnimation(206, 1.0, 0.0)); } if ((GetTag(oAreaObject) == "ptar_sitter")) { AssignCommand(oAreaObject, ActionPlayAnimation(204, 1.0, 0.0)); } if ((GetTag(oAreaObject) == "ptar_drinker")) { AssignCommand(oAreaObject, ActionPlayAnimation(205, 1.0, 0.0)); } oAreaObject = GetNextObjectInArea(OBJECT_INVALID, 64); } Check the on-enter scripts of other modules with sitting placeables to see what they do. Edit: The 64 in the oAreaObject statement equates to OBJECT_TYPE_PLACEABLE. The 204/205/206 in the ActionPlayAnimation statements equate to ANIMATION_PLACEABLE_ANIMLOOP01/02/03, respectively. You'll want to check the model to see what animations it has to determine which you want to play. Edit 2: Ah, that's right, the placeable sitters are actually just standard character models. The animations are on the S_Male02 supermodel. Looking at it in Max, ANIMLOOP01 is a static sitting pose, ANIMLOOP02 is sitting and drinking, ANIMLOOP03 is sitting playing pazaak. 1 1 Quote Share this post Link to post Share on other sites
eNoodles 31 Posted August 6, 2018 Thanks DP, all working. There aren't source scripts for the on-enter scripts for vanilla modules, but yours works fine. Quote Share this post Link to post Share on other sites
DarthParametric 3,785 Posted August 6, 2018 You have to decompile the scripts yourself. That snippet is from the decompiled on-enter for TAR_M03AE (Javyar's Cantina). You'll want DeNCS for that - http://www.starwarsknights.com/mtools/DeNCS.zip I would suggest creating a duplicate copy in a separate folder and using K1's nwscript.nss for decompiling K1 scripts. 1 Quote Share this post Link to post Share on other sites
Guest Qui-Gon Glenn Posted August 7, 2018 Just to add to DP's good instructions... You don't need to decompile any area on_enter, you only need to know the name of the script so you can inject it into your new on_enter, using ExecuteScript. There are many tutorials for this. Quote Share this post Link to post Share on other sites
eNoodles 31 Posted August 7, 2018 1 hour ago, Qui-Gon Glenn said: Just to add to DP's good instructions... You don't need to decompile any area on_enter, you only need to know the name of the script so you can inject it into your new on_enter, using ExecuteScript. There are many tutorials for this. Yeah I know that, that's what I've been doing. We just needed to decompile to see how they work (for the sitting placeables). Quote Share this post Link to post Share on other sites
ebmar 893 Posted November 12, 2019 On 8/6/2018 at 5:08 PM, eNoodles said: ...add sitting npc placeables into a module (like plc_sitrodian for example), they're t-posed in-game. I've tried messing around with the Animation State field, but nothing changes. Thank you for brought the topics up! I have been fiddling with the sitting NPC placeables recently and stumbled to the exact problems as yours - I am thankful for this. On 8/6/2018 at 5:48 PM, DarthParametric said: The 204/205/206 in the ActionPlayAnimation statements equate to ANIMATION_PLACEABLE_ANIMLOOP01/02/03, respectively... ANIMLOOP01 is a static sitting pose, ANIMLOOP02 is sitting and drinking, ANIMLOOP03 is sitting playing pazaak. Much thanks for the insight! They works for me. Anyway, about this - On 8/6/2018 at 5:48 PM, DarthParametric said: ...probably need to add to the module's on-enter script. I've found the alternative that is as effective but with less effort as we don't have to inject or reconstruct the module's OnEnter. We can use the NPC placeables' OnHeartbeat to signal the sitting animation with something like this - //::////////////////////////////////////////////////////////////// //:: Sitting and Drinking Animation for NPC Placeables //::////////////////////////////////////////////////////////////// /* Fired by NPC placeables' *OnHeartbeat* for them to routinely does the *sitting and drinking* animation. */ //::////////////////////////////////////////////////////////////// //:: Constructed By: ebmar //:: Constructed On: November 12, 2019 //::////////////////////////////////////////////////////////////// void main() { // Play the looping *sitting and drinking* animation with the NPC placeables PlayAnimation(ANIMATION_PLACEABLE_ANIMLOOP02); } I have found no issue so far using that, as far as the sitting animation does looping forever - uninterrupted. 1 Quote Share this post Link to post Share on other sites