JCarter426

M478_Staff
  • Content Count

    1,502
  • Joined

  • Last visited

  • Days Won

    124

Posts posted by JCarter426


  1. As far as I recall, no, that is not a local issue, but there's a reason for it. Most of Carth's dialogue has to be advanced before the Leviathan because he repeatedly broods about getting revenge on Saul. The Dustil quest is triggered when the global K_SWG_CARTH is set to 8, but the value must be at 14 after the Leviathan in order for the romance to continue along the romance branch "I think it's time we talked about me being Revan, don't you?" instead of the non-romance branch "We need to talk. About me being Darth Revan." And as you noticed, it is not possible to advance Carth's dialogue tree while the Dustil quest is active.

    I don't believe that editing k_plev_throwdown alone would solve the problem, however. It looks like the reason they set the global to 99 there is to make it impossible to advance the Saul-centric dialogue after Saul is dead, as the conditional scripts don't check for that:

    Spoiler
    
    //:: k_swg_carth25
    /*
        After the final Star Map has been found
    */
    //:: Created By: David Gaider
    //:: Copyright (c) 2002 Bioware Corp.
    
    #include "k_inc_debug"
    
    int StartingConditional()
    {
        int nRomance = GetGlobalNumber("K_SWG_CARTH");
        int nPlot = GetGlobalNumber("K_STAR_MAP");
        if ((nRomance == 14) && (nPlot > 49))
        {
            return TRUE;
        }
        return FALSE;
    }

     

    They only seem to check if the value of K_STAR_MAP is greater than whatever is relevant, so this would still be true.

    I'm also not sure whether it's feasible to allow you to continue advancing Carth's dialogue while the Dustil quest is active. It depends on the dialogue, I suppose.

    If I recall correctly, there is another potential issue in that you can't trigger the Dustil if you have already visited and completed Korriban. I'm not sure how this affects the romance.

    • Like 2

  2. In general, I don't think so. There are similar problems with the saving throws, which other mods can fix. There is also a bug with Ramana and the Red Eclipse refusing to pay you once you have a prestige class, which we plan to fix for the next update, but that won't be for a while. But considering how worthless credits are in this game, the benefits outweigh this problem, and of course these bugs are limited to specific dark-sided choices.


  3. As for the arms and floaty ball thing, it's possible to copy the animations over. I'd suggest that you create dummy objects for each mesh, placed where the pivot point is, and then copy the position and rotation animation controllers over. Then after you model your replacement, you only need to parent the objects to these dummy objects, similar to how the lightsaber throw animation is set up.


  4. See the discussion here. Basically, area models in KOTOR 2 won't render a room if it has no walkmesh, unlike KOTOR 1. Skyboxes in KOTOR 2 always have a walkmesh somewhere on the model to get around this.

    @bead-v had talked about updating MDLEdit to add a dummy aabb node when models are missing one but I don't know what the status of that is.


  5. 18 hours ago, ManGuyBen said:

    The closest I've come to finding what I'm looking for is coming across the GetEnteringObject() function being used. But I have yet to find the NSS file where it's defined.

    This is a C++ routine, not a function defined in Neverwinter Script. It's defined in the source code for the game executable. Neverwinter Script is a separate scripting language that makes calls to the actual C++ routines. You can find a list of them in nwscript.nss. But they are implemented in C++, not Neverwinter Script. Since we don't have the game's source code, all we can really do is make guesses about how they work.

    I was skeptical of it being related to player coordinates—based on my experience with it, and what I've heard from other modders, I thought it was some sort of resource management issue with the game mistaking a reference to one trigger for another. However, I was able to repeat the issue on the Endar Spire in the same location after moving the door, and I don't believe there is another trigger in that location.

    For the record, I encountered the issue during regular play in the enclave, somewhere around the rotunda. I was able to repeat it on the Endar Spire without Trask in the party by warping back to it, and also by controlling a different party member.

    • Thanks 1

  6. 6 minutes ago, TSLforever said:

    I take it Lorna Vash was not supposed to be found dead? Korriban feels extremely short too. Then there is the Droid Planet (I haven't read too much about it or played the mod).

    Given that she has different voice actresses in the trial and on M4-78, I am not certain that the one on Korriban was even meant to be Vash. There is an unused female Jedi head that was used for Kaevee in TSLRCM and TSLRP before it. Perhaps they were originally two different characters.

    The Vash on M4-78 was also called Mara at some point.

    8 minutes ago, TSLforever said:

    Also, why did Mandalore not want the Republic to suspect that they were on the Ravager?

    The only thing that makes sense to me here is that he was talking about the Ravager crew and using "Republic" generally to mean non-Mandalorian. They mention that the Ravager was a Republic ship later on in the conversation after all. Still, it's weird.

    12 minutes ago, TSLforever said:

    How did the Force Bond between Kreia and The Exile break? Did it break?

    I remember having this conversation before, but I think it was on LucasForums. If you're talking about how killing Kreia doesn't kill the Exile,  as far as I see it, there are a few different ways you can interpret this. For one, we only have Kreia's word that the bond could be fatal. Everyone else you talk to about it says that bonds don't usually work that way. Kreia manipulates the Exile by letting them believe things she knows not to be true, e.g. the Council being responsible for cutting the Exile off from the Force, so perhaps you could simply add this to the list. Second, Kreia herself says that in battle they will be able to shield each other from the effects of the bond—which is evident since damage to Kreia doesn't translate to damage to the player in gameplay—so perhaps this was never a danger for a different reason. The Jedi also describe some ways in which a bond can be broken, such as if one person falls to the dark side, or their if their feelings about each other changed. Whether Kreia fell to the dark side is a whole other argument, but a possibility, and I think it's a much easier argument to make that the Exile's feelings about Kreia changed after her betrayal. So perhaps the bond broke one of those ways. Finally, in some cut content in the dark side version of the enclave meeting, and in the final duel, Kreia talks about making the Exile feel the Force again and overcome the weakness of relying on Force bonds. So perhaps confronting Kreia and not being able to draw on their bond cured them of their bond addiction.

    To add to the confusion, Kreia has an alternate line in the enclave in which she says that she has severed their bond.

    24 minutes ago, TSLforever said:

    Who blasted HK-47 to pieces and how did Droid Merchants get parts for him!!??

    I don't have any good answers for this. I got the impression that HK was dismantled so that he couldn't override the navicomputer voice lock, but then there's also talk that he was in the process of being rebuilt for some task.

    26 minutes ago, TSLforever said:

    I am still not completely clear about the sequence of events that lead to Kreia being on the Hawk in the beginning of the game.

    Neither am I, since Kreia, the Peragus staff, and even the disembodied tutorial voice mention the Ebon Hawk having a crew that we never see.


  7. 7 hours ago, TSLforever said:

    Dialogue on the Ravager seems to indicate that The Exile was not supposed to accompany Mandalore and Visas.

    It certainly seems that way. On the other hand, there are parts where the Exile was clearly meant to be in control, such as the encounter with Tobin and Visas' cell. @bead-v, @InSidious, @VarsityPuppet, @zbyl2, and I have discussed it at length on Discord in the past and honestly I don't think anything any of us have come up with makes sense of it. We have various ideas on how to resolve the awkwardness but everything we've come up with is almost certainly not what the developers intended due to some other weird part that contradicts it.

    7 hours ago, TSLforever said:

    How did Kreia and Handmaiden get back to Telos? How did HK and Bao-Dur go to the HK Factory without anyone noticing?

    How does Kreia get to Malachor? How do the Handmaidens get to Dantooine when the Exile is female? Who rebuilds the enclave in the dark side ending?

    I have no answers.

    I think we have to live with stuff happening off-screen for a lot of it for the sake of the pacing.

    7 hours ago, TSLforever said:

    And Malachor?!?! How did the Hawk get fixed? Why was the party separated?

    Presumably T3 fixes the ship, and it seems that the party was all thrown out of the ship like how you get repeatedly thrown clear of shuttle crashes earlier.

    I believe these issues were things that Malachor VI intended to address.

    @VarsityPuppet@VarsityPuppet@VarsityPuppet hint hint

    • Like 4
    • Haha 1

  8. Well, there is the Force Enlightenment power that does exactly that, but you don't normally get it until late in the game. You could give it to yourself earlier with KSE.

    As far as extending the duration of Force powers goes, all powers run through the script k_sp1_generic, so compatibility is not really possible regardless of TSLPatcher. For better mod compatibility, spells.2da would have to be patched so the different powers use different scripts, and then new scripts would need to be written. It's a project I've considered before, but I am still busy working on improving the random loot system at the moment.

    • Like 1

  9. I've fixed a lot of bugs in that code and documented it, which might help. Although I have to get around to fixing the bugs I introduced to it by foolishly forgetting how switch cases work... I'll get back to you.


  10. Hmm, is that not just from from GetTreasureBundle()? That function calls another function that returns a string containing both the item template and the amount of items, and then extracts the the template from it.

    My guess is that the stack issue is from the recursive function GetTreasureSpecific(). It still happens with my cleaned up version, and actually it happens with a critical capacity of fewer items due to my changes that eat up more of the stack.

    In my tests I think the original code failed at somewhere between 100 and 200 items, while my code fails at about 60. It's should be fine for all realistic use cases but it would also be nice if the problem could be avoided.


  11. 1 hour ago, AmanoJyaku said:

    Tsk tsk. Placing side effects into your conditions. Shame on you. 😛

    Nah, it's not side effects I'm worried about, it's stuff like checking if an object is valid, and only doing something if so. Safe navigation. I don't remember any specific code I wrote where that might be a problem, but I can definitely imagine the possibility. I probably would've used && and it would be safe though.

    1 hour ago, DrMcCoy said:

    Up until now, I had assumed they fixed that bug by the time they moved to other games. I know that the bug is in some scripts in NWN, but not in all.

    @DarthParametric and I observed in some tests that the compiler we have is definitely not the most up-to-date one, and it seems like it was the case with the one BioWare used as well because the game scripts are full of unused garbage included from header files that the same update to the NWN compiler was supposed to scrub out.

    • Like 1

  12. 14 hours ago, AmanoJyaku said:

    So, I have to do more than just decompile code. I must also decompile code that is incorrect, and decide on whether or not to fix this.

    I would say fix it where possible. I can't imagine a situation where someone would purposefully write a condition with side effects as a secondary condition with the intent that short-circuit evaluation would be ignored, or more importantly, any situation where that would be needed. It's far more likely that there are scripts that are taking performance hit from the lack of short-circuit evaluation, and could potentially be causing bugs. The random loot in KOTOR 2 overflows the stack if you spawn too many items at once, for example. There could be more intensive operations, like in the AI, that could potentially be causing problems. Maybe that would even account for bugs such as creatures randomly not attacking in the middle of combat.

    I'm certainly worried I might've written code under the assumption that short-circuit evaluation would be obeyed. I suppose if that's true, I could invert the logic to use && in the meantime, since that does seem to short-circuit properly.

    14 hours ago, AmanoJyaku said:

    Jump statements

    • break
    • continue
    • return

    I'm almost afraid to ask, but does NWScript have a goto statement? I haven't seen any example of it in code, or any reference to it, so I assume not.

    14 hours ago, AmanoJyaku said:

    Also, as I work on this I'm encountering what appears to be poorly coded scripts.

    Oh, I hadn't seen this one before, but I've seen problems like it. It's understandable considering that not all the developers were computer scientists, and even designers like David Gaider and Chris Avellone did incidental scripting to take some of the burden off the programmers, but the downside to that is not everybody necessarily knew what they were doing. Plus the one you quoted looks like it might've been a copy/paste error, considering that it's only the last branch that's wrong. Stupid mistakes can happen to anyone.

    • Like 1

  13. JC's Fashion Line I: Cloaked Hybrid Robes for K1


    Summary

    This mod adds cloaks to the Jedi robes worn by the player and many NPCs, combining the body of the KOTOR 1 robes with the cloaks of the KOTOR 2 robes in a hybrid model.

    There are three texture options: 100% Brown, Brown-Red-Blue, and Brown-Red-Blue Alternative. The Brown-Red-Blue textures maintain the color scheme of the K1 Jedi Robes. The 100% Brown textures look more like K2 textures, with different (brown) designs for the Jedi robes instead of different colors. The Brown-Red-Blue Alternative uses the K1 color scheme, but gives the red and blue robes dark grey cloaks.

    All styles come with or without gloves for your player character and some non-player characters. If you choose a gloveless option, your hands will be bare and match your usual skin tone.

    Installation

    Automatic Installation (Recommended)

    1. Extract files from the downloaded archive.
    2. Run Fashion_I_Cloaked_Hybrid_Robes_K1.exe.
    3. Select one of the six install options:
      a) 100% Brown
      b) 100% Brown (No Gloves)
      c) Brown-Red-Blue
      d) Brown-Red-Blue (No Gloves)
      e) Brown-Red-Blue Alternative
      f) Brown-Red-Blue Alternative (No Gloves)
    4. Click "Install Mod" and select your game directory (default name SWKotOR).

    Manual Installation

    1. Extract files from the downloaded archive.
    2. If you do not have an override folder, make one in your game directory (default name SWKotOR).
    3. Select one of the three folders in tslpatchdata:
      h_bbb – 100% Brown
      h_brb – Brown-Red-Blue
      h_brb-a – Brown-Red-Blue Alternative
    4. Copy all files from the selected folder to your override folder except appearance.2da and the .ini and .rtf files.

    The gloveless options require patching appearance.2da and are not supported by the manual installation.

    Uninstallation

    1. Remove the installed files or replace from backups if necessary.

    Uninstallation

    1. Remove the installed files or replace from backups if necessary.

    Compatibility

    This mod is not compatible with my Cloaked Jedi Robes mod; you have to pick one or the other.

    This mod is compatible with my Cloaked Party Robes mod, if you install it after installing this mod.

    This mod is likely not compatible with other mods that alter the Jedi robes.

    This mod uses my Supermodel Port for K1. This makes it super cripplingly incompatible with any other mods that alter the game's supermodels (the S_Female and S_Male files) unless the other mods utilize my Supermodel Port assets. These edits are necessary to give the player supermodels the bones required for the cloaks to animate.

    This mod's supermodels include my Supermodel Fixes for K1. So you don't have to worry about using that, or if these files are overwriting those. Use this mod's files.

    These supermodel edits somewhat alter some animations in the game. These adjustments were necessary to prevent the old stuff from clipping with the new stuff. It's essentially what Obsidian did when they added the new bones to the supermodel, but I've reversed the changes a bit to bring the animations closer to the original K1 style.

    Some models aren't so happy with the new rig. I've made some hotfixes for such cases where I can, but they won't be compatible with other mods that alter these models. I've instructed TSLPatcher not to overwrite these.

    P_JuhaniBB.mdl and P_JuhaniBB.mdx are two such files that will be skipped. If you use the Juhani Catlike Head Mod, I suggest that you use my version because I happened to fix the same thing that mod fixes anyway. You can copy those two files manually from tslpatchdata to Override.

    The gloveless options only support appearances from the original game release. If you use a modded player appearance, they'll still wear gloves.

    While this mod adds skirt bones to the player supermodels, at this time it does not add the bones or the necessary animations to the cutscene models. So the skirt flaps may appear stiff in scenes that use those.

    Credits

    KOTOR Tool – Fred Tetra
    TSLPatcher – stoffe, Fair Strides
    NWMax – Joco
    KOTORMax & MDLEdit – bead-v
    waifu2x – nagadomi

    This mod contains assets ported from Star Wars: Knights of the Old Republic II - The Sith Lords by Obsidian Entertainment.

    Permissions

    I hereby grant nobody except myself permission to upload some or all of this mod anywhere for any reason. For any reason. I have uploaded a separate mod resource with essentially all of these assets free for anyone who wants to use them. But I want to keep them separate for simplicity's sake, so this release here is strictly a mod.

    I have uploaded a separate mod resource with essentially all of these assets free for anyone who wants to use them. But I want to keep them separate for simplicity's sake, so this release here is strictly a mod.

    Disclaimers

    OBSIDIAN IS THE NEW BLACK. DON'T WEAR BIOWARE AFTER LABOR DAY.

    Donations

    If you enjoy my mods and would like to show your support in a monetary manner, you may do so via PayPal with this donation link.

    For various legal and ethical reasons, this is entirely optional and is not a requirement to downloading or using any of my mods. I also do not create specific mods for hire.

    I make mods as a hobby and will most likely do so regardless of any donations or lack thereof, but modding does take up a lot of my time and every bit helps.


    • Submitter
    • Submitted
      09/03/2020
    • Category
    • K1R Compatible
      Yes

     

    • Like 1

  14. Off the top of my head, end_m01aa, end_m01ab, danm14aa, and tat_m17ab are the odd ones out that I remember. And possibly 151HAR and 605DAN in KOTOR 2 since they were based on KOTOR 1 oddities.

    But I haven't investigated this weirdness much because it was easier to get in the habit of checking where north is.

     

    Edit: DarthParametric investigated it and apparently the direction of north is entirely based on the rotation system and not dependent on the area. The Endar Spire has some weirdness with the minimap, and maybe other areas do too, but that's all it is. I think I over the years got confused by the mismatch between the different rotation systems and chalked it up to the area on account of the weirdness with the Endar Spire.

    • Like 1

  15. Doors and placeables in GIT files use the Bearing field, which is in radians except written as decimal. So the valid values are from 0 to 3.14159 or 0 to -3.14159. 0 is either north or east, depending on the module. Placeables spawned through scripts use rotation in degrees, with values from 0 to 180 or 0 to -180.

    Creatures in GIT files use the XOrientation and YOrientation fields, which are quaternions. Converting from radians or degrees is pretty straightforward and here's a random online calculator that can do it. Creatures spawned through scripts use rotation in degrees. Same as the above for placeables.

    Static cameras use the Orientation field, which is also a quaternion. I don't remember how these work because there are a lot of advantages to using animated camera models, one of which being that you don't have to mess around with quaternions.

    • Thanks 1

  16. 11 hours ago, Salk said:

    Sometimes while running, the controlled party member suddenly stop advancing and runs on the spot instead (just as if running against a solid wall) despite the absence of any real obstacle.

    Yeah, I've seen this one. I've observed it happen in relatively the same area before, such as near Geg's shop in Iziz, so I assume it's caused by some imperfection in the walkmesh.

    11 hours ago, Salk said:

    Sometimes one of the party members get stuck against your controlled party member which can no longer move away from the current spot.

    I don't think I've seen this one, but I imagine the personal space-respecting code that was added to the AI for K2 would fix this. Probably could be duplicated for K1. I know I came across this code before because I copied some of it for the follower scripts in my toolbox, so this bit of code from that might come from there:

    float fDist = GetDistanceBetween(oPC, OBJECT_SELF);
    
    if( fDist <= 1.5 ) ActionMoveAwayFromObject(oPC, 1, 1.5);
    11 hours ago, Salk said:

    Often, at the end of the loading process, it is possible to witness the spawning of the NPCs for a brief moment so that they are seen transitioning from their T-pose to the intended pose.

    10 hours ago, DarthParametric said:

    The last one can at least be masked by manual adjustments of fade-ins if there are specific instances that are particularly egregious

    This could potentially be made into a global solution if all the modules were patched to run the same OnHeartbeat and OnEnter and other event scripts. I worked on a bit of this before but didn't release it because I figured mod compatibility would be too much of a problem. But since we've patched dozens of modules for the Community Patch anyway, we could probably slip it in there and force people to deal with it.

    • Like 3