DarthParametric

Modders
  • Content Count

    4,710
  • Joined

  • Last visited

  • Days Won

    537

Everything posted by DarthParametric

  1. Putting commonly/repeatedly used functions into includes makes for less work. Rather than add it directly to the script you are working on, you can just call it via a linked include. You can see the difference in size this can make for even a very simple script when you compare what DeNCS spits out vs the cleaned up version I posted above. Albeit the Bioware compiler adds a bunch of unnecessary guff not actually used in the script. This is why I said above that eventually you'll start to recognise commonly functions. Take a look at sub3 for example. As soon as you spot those cascading GiveXPToCreature calls, you know that's UT_SetPlotBooleanFlag from k_inc_utility, one of the most commonly used functions you'll encounter. So as you comb through those functions and ID them, you can start to change the function names, remove the superfluous function blocks, and rely on linking the relevant include/s.
  2. It does. That's what the giant list of variables and functions is. Calling stuff externally via includes is just for the source to make it easier to parse. When the script is compiled, all those functions are pulled into the NCS.
  3. It's possible that the NWVault has a totally legal copy of it in their "NWN University"....
  4. NWScript is C-like - https://en.wikipedia.org/wiki/NWScript#Syntax As to my scripting abilities, they are fairly meagre, but enough to brute force a solution most of the time. To my own regret, I avoided scripting for most of the time I have been modding. I dabbled on the odd occasion when scripting was the only solution, but typically relied heavily on outside assistance for even the most basic of tasks. It wasn't until I got involved with K1CP that I really started to wrap my head around how scripting works. Almost entirely out of necessity, since probably 80-90% of the content is partially or entirely script-based. I owe a lot to JCarter426 for shepherding me along and answering all my noobish questions along the way. You could say I now know enough to be dangerous. The best way to wrap your head around things is to just look at vanilla scripts and examine how and why they do what they do to achieve their desired outcome. Obviously only global scripts have original source available, and most of those aren't commented particularly well, so initially it can be a bit overwhelming when looking at decompiled module scripts. But eventually you'll start to recognise familiar Include functions and drill down to the meat of a given script. And K1CP has all its source available to peruse, so it's worth having a look at some of those to see how we went about fixing things.
  5. From the Endar Spire's Include - k_inc_end.
  6. If you want to gate via a specific skill rank, then you need to check for that instead: // 315: Get the number of ranks that oTarget has in nSkill. // - nSkill: SKILL_* // - oTarget // * Returns -1 if oTarget doesn't have nSkill. // * Returns 0 if nSkill is untrained. int GetSkillRank(int nSkill, object oTarget=OBJECT_SELF); By the way, your script is bloated because of the Include guff. The cleaned up original script is: #include "k_inc_end" void main() { if (GetIsPC(GetEnteringObject())) { if (HasNeverTriggered()) { SetGlobalFadeOut(); PlayMovie("01A"); SetReturnStrref(FALSE, 32228, 0); //String 32228 is "Return To Hideout". Should instead be 38550, "Transit Disabled". SetGlobalNumber("K_CURRENT_PLANET", 5); SpawnStartingEquipment(); SetGlobalFadeOut(); SetGlobalFadeIn(3.0, 1.5); DelayCommand(0.1, AssignCommand(GetTrask(), ActionStartConversation(GetFirstPC(), "m01aa_c01", FALSE, CONVERSATION_TYPE_CINEMATIC, TRUE))); SetMinOneHP(GetFirstPC(), TRUE); } } } You just want to replace the SpawnStartingEquipment function with your own custom one, but presumably the rest can be pulled from the Includes at compile. However, K1CP made some minor adjustments to the script to fix the player being visible before the first cutscene starts, so I would suggest using that version as a basis instead - https://github.com/KOTORCommunityPatches/K1_Community_Patch/blob/master/Source/k_pend_area01.nss
  7. I'd guess it was probably intended to be some sort of insectoid race.
  8. You don't need compresstexture or downsamplemax. Those aren't TXI semantics, they are for Bioware's internal image processor (i.e. their version of TGA2TPC).
  9. Because the body texture columns in appearance.2da specify a variant base name, not a discreet texture name. The specific variant is specified by the UTI, or failing that it defaults to the 01 variant.
  10. There is also the fact that John Cygan (Canderous) and Robin Sachs (Admiral Karath) are also both dead.
  11. For models like weapons, the texture needs to be specified in the model itself. I don't use Blender, so I don't know how KBlender handles this, but you can always edit the ASCII it exports manually in a text editor. You'll see a bitmap line amongst the various data for the mesh. For example: node trimesh BlstrPst02 parent w_BlstrPstl_003 position 0.0102975 0.131421 0.0833597 orientation 1.0 0.0 0.0 0.0 alpha 1.0 scale 1.0 selfillumcolor 0.0 0.0 0.0 diffuse 1.0 1.0 1.0 ambient 1.0 1.0 1.0 transparencyhint 0 animateuv 0 uvdirectionx 0.0 uvdirectiony 0.0 uvjitter 0.0 uvjitterspeed 0.0 lightmapped 0 rotatetexture 0 m_bIsBackgroundGeometry 0 shadow 0 beaming 0 render 1 dirt_enabled 0 dirt_texture 1 dirt_worldspace 1 hologram_donotdraw 0 tangentspace 0 inv_count 94 bitmap w_BlstrPstl_003 If your mesh doesn't have a texture assigned, it will say NULL.
  12. No. The GOG exe is not protected and can be used as-is.
  13. Sounds like oldflash's movie saber mod: https://www.gamefront.com/games/knights-of-the-old-republic/file/movie-style-replacement-lightsaber-hilts
  14. Low I would assume. The only way to find out would be to test it yourself.
  15. Try this - https://github.com/SWTOR-Slicers/WikiPedia/wiki Join their Discord channel if you need help.
  16. Fairly trivial if you know what you are doing, but there's no reason to bother with this garbage now that porting from TOR is allowed. you'd just use their version instead, like this.
  17. You're using a model with PBR textures, metal-rough in this particular case (the other major type is spec-gloss). Odyssey pre-dates PBR usage by a decade or more. PBR attempts to approximate real world lighting and thus has no lighting data baked into the textures. Ye olde engines like Odyssey use Blinn-Phong, which is all faked and thus relies heavily on baking highlights and shadows into the diffuse map. It's not really practical to convert existing textures from one to the other. It's something that needs to be done at the authoring stage. Those texture outputs are from Substance Painter. I doubt they supplied the source files, but if they did it would be possible to edit it and export it with baked lighting. It does, but not like a modern engine. It's implementation is extremely anaemic and you're not going to see any real benefit from it, especially on something like a sword. That said, enabling it is done via TXI semantics, and it is tied heavily to envmap use (the envmap mask acting as a mask for the normal map as well).
  18. Edit the ini and add EnableCheats=1 under the [Game Options] section.
  19. The spawning of the party is the same for both LS and DS routes. The updated OnEnter should work correctly. Make sure you are loading a save before entering the beach for the final time. Even reverting to the vanilla OnEnter won't work just loading a save already on the beach, since there is a specific check for that.
  20. It's not particularly difficult if you know what you're doing, but it's not something you can expect someone with no experience to manage since you'd have to edit the full body model to do the head swap, then create a custom texture for the head.
  21. Except that you are forgetting that Dodonna has a separate unique full body hologram appearance, because K1 doesn't do holograms the same way as TSL.
  22. You've got the permanent slow debuff bug. I have a couple of mods that fix it. For non-droids use the Cup of Caf mod and for droids use the Droid Oil Bath mod. I'm pretty sure Sniggles mentions this in the build instructions somewhere.
  23. Looks to me that what @LDR intended to do was hijack the original OnEnter to run his required spawns, then load the vanilla OnEnter afterwards. Except he forgot to add that ExecuteScript part to the end. So the vanilla OnEnter never fires at all, which is why the party doesn't spawn. This should also cause the initial Rakatan encounter to break as well, since the OnEnter also spawns those.
  24. You might want to attach that here so we can see what was changed. What mod was it from?
  25. Looks like the module OnEnter (k_punk_41aa_en) spawns the party and a separate trigger OnEnter (k_punk_fincs_en) starts the cutscene. If the party is not present but the cutscene triggers then the problem is that the G_FinalChoice global is correct (i.e. > 0) but the UNK_PARTYSHOWDOWN global is already at 1 (i.e. the party should already have been spawned). Seems like the only way that should be possible is if the scene has already been completed and everyone warped back aboard the Hawk for take-off. Load up a save at the top of the beach before you hit the cutscene trigger in KSE and check Globals -> Numerics for G_FinalChoice and UNK_PARTYSHOWDOWN and report what the values are.