Jump to content

Home


Kitty Kitty

Recommended Posts

TL;DR: Search for "TL;DR" down below.

 

So... I started playing K1 again, and of course, that meant sticking in some mods and then immediately finding certain things mildly annoying, and before I knew it.. I'd dusted off my modding tools and started getting my hands dirty in there. (Yep. Here we go again.. lol)

 

Basically, I was having some fun playing around with some various clothing/disguise items I'd picked up over the years, but then I started wishing for things they didn't provide on their own. For example, the excellent Bastila Revelation Robes mod (by ChAiNz and svösh) doesn't work on anyone BUT Bastila, but I wanted to be able to wear it on my main PC.

 

After some item copying/editing, and modifying my appearance.2da file, that was fixed, but the problem only persisted. Soon enough I had dozens of new entries in my 2da file, all of which only really putting my custom PC head on someone else's body, and my inventory was getting clogged with oodles of individual disguise items. Suddenly, an idea was born...

 

I began making an armband for K1 that will allow you to select any viable disguise from a dialogue menu of choices, modeled as if the armband has a computer interface built in. You'll be able to do this for the main PC, or any of the standard NPCs (though if there are some highly popular add-on NPCs, I could probably support them easily), and it will allow you to select any "full disguise" (either matched sets like say Bastila's head and body, or body-only models such as Zaalbar), or to mix and match any combination of head and body the game will allow for, such as keeping your PC's head while using Bastila's body (in order that her Revelation Robes will work or whatever other reason you may wish).

 

Right now, I'm working with a set of data that includes the K1 Restoration mod, and my custom female PC (though it's been revised from the ancient version I released a decade ago and will be re-released soon), and plan to release versions of the armband that are compatible with any combination of either, both or none of those mods (at least, see below) installed.

 

Now I'm looking for some input on a few aspects... Some of it just so I can get a feel for any obvious stuff I didn't think of ahead of time, and some because it's been a very long time since I touched KotOR modding and some of my knowledge has rusted more than a little. :p

 

TL;DR Section: I'm making a Disguise Armband and requesting community input.

 

Questions for the community:

  1. Are there any highly popular mods out that I should try to incorporate? (If they don't touch appearance.2da, they should already be compatible.)
  2. Does anyone know if an item mod, that's meant to be available for the scope of most of the game can be packed into some sort of containing file like a mod, erf, etc? I never really worked with any of those, but it'd be nice to make this mess a bit more contained. (If this were for TSL it wouldn't be an issue, but because I can't pass script parameters from a dialogue in K1, the thing requires somewhere in the neighborhood of 1,000 scripts. Bleh :p )
  3. Are there any new models/skins out there that I should really know about and try to incorporate? I'm not really looking for simple re-skins or the like, as most of those will just work as they are if someone has them installed to replace defaults anyways. But something like where the game has a hooded Revan robe, but it's a little glitchy. I remember years ago we found some ways around that, and some basic google searches have turned up some options, but I thought if anyone has some decent information that's a bit more recent than mine, it never hurts to ask questions. :)
  4. More if I think of anything, and of course, feel free to offer any suggestions I haven't come up with yet.

 

I realize this is a whole lot of work for what's essentially a minor little "toy" item, but it's been fun getting back in and doing some modding and I figure at worst, it helps me remember half of what I knew once upon a time, and there may just be someone else out there who'd like to play around with the thing, so why not make it available?

 

I'll also be eventually scripting it into the game so you won't even need cheat codes or editors to get it. Probably somewhere after going down the elevator on Taris so as not to conflict with the story and the Sith Armor tangent.

 

Anyways, thanks for reading. Fire away with questions, comments, blah blah blah. :)

 

-Kitt

Link to comment
Share on other sites

That's an interesting idea... my own Override folders for both games are cluttered with disguise items as well. I assume you'd be using the DuplicateHeadAppearance function for mixing the heads and bodies like you describe.

 

But yeah, that would be a lot of scripts for K1. I don't know if there's a way to get around that. A MOD file would only work in that specific module, I believe - so you'd have to do one for each module, and it wouldn't be compatible with other edits, or with new modules. The data and rims folders should apply globally, but I don't know if you can put anything new in there and have the game recognize them. Might be worth a try though.

Link to comment
Share on other sites

That's an interesting idea... my own Override folders for both games are cluttered with disguise items as well. I assume you'd be using the DuplicateHeadAppearance function for mixing the heads and bodies like you describe.

 

Indeed, nicely spotted.

 

I actually have all the scripting done already, and everything works as intended. (At least, until/unless I need to add/change anything, which can always happen). It was kinda tricky to work out ways to get everything to behave, as the DuplicateHeadAppearance function is kinda wonky.

 

I came up with a method whereby I'm storing some numbers in a rather creative manner, and then through a combination of standard disguise effects and the head duplication function.. blah blah. Don't wanna babble on about the tech aspects, but you probably get the general idea.

 

It's working very nicely. What I'm doing now is crafting the dialogue file. I'm trying to set it up with a decent balance of avoiding too much duplication (it's going to be huge enough no matter what I do) with ease of use. (Like keeping the number of choices "per page" limited to avoid needing to scroll too much, etc). Once I get that all hammered out, V1.0 will pretty much be ready, after a few last-minute checks to be able to duplicate a few things and modify them slightly for a base/K1/KK_custom/K1+KK_custom compatible release.

 

But yeah, that would be a lot of scripts for K1. I don't know if there's a way to get around that. A MOD file would only work in that specific module, I believe - so you'd have to do one for each module, and it wouldn't be compatible with other edits, or with new modules. The data and rims folders should apply globally, but I don't know if you can put anything new in there and have the game recognize them. Might be worth a try though.

 

Yeah.. it's sad they hadn't thought of script params like we get in K2 dialogues. If I had those, I could have done the whole thing in 2 scripts. xD

Well, one really, but I can't help but put a lot of the data crunching and crap off in an _inc script. Just way too messy otherwise, so 2. hehehe

 

And damn.. I was really hoping one of the 'container' style formats would work. Like I know in NWN itself (which the engine is based from), the community can create "hak packs" or something similar. From my reading, they sound like plug-in style "mods", but they act differently than actual mod files in that they aren't keyed to a specific area, etc.

 

Thanks for the info in any case. At the end of the day, while the clutter may annoy me, it won't really hurt anything. As far as I know, you can have as many files in \override as you need, so.. Meh. Is what it is. ;)

 

-Kitt

Link to comment
Share on other sites

Yeah, since it's the same engine there's a chance that stuff would work... I've just never known anyone to attempt it for KOTOR.

 

From the little I know of NWN, there is a "haks" folder (called that, all lowercase) in the main game folder that has .hak files, which are another ERF-formatted package file. The format should be the exact same as the other ERF files (.sav, .erf, .mod) except for the first bit of the File Header would be "HAK " instead of "ERF " or "SAV " or "MOD ".

 

Whether the game engine would still actually look for these files or not... I don't know.

Link to comment
Share on other sites

From the little I know of NWN, there is a "haks" folder (called that, all lowercase) in the main game folder that has .hak files, which are another ERF-formatted package file. The format should be the exact same as the other ERF files (.sav, .erf, .mod) except for the first bit of the File Header would be "HAK " instead of "ERF " or "SAV " or "MOD ".

 

Whether the game engine would still actually look for these files or not... I don't know.

 

I'm betting not. My guess is that it was added in later, much like NWN's version of NWScript got the 'const' keyword and loads of other fun stuff we can't use.

 

Problem is, I never really had a very clear understanding about exactly what one could/should (or not) do with the various EFR formats in the first place. Like.. I kinda get that in KotOR, in general, 'mod' = area/level. What, precisely are the other ones doing, or rather, what sort of application can modders safely bend them to? Does anyone know if any of them are particularly suited to an idea like this? Where basically I'm building an item, but it has a crapload of files, and I'd like to collect it more neatly? Getting solid info on this stuff is kinda tricky these days. lol

 

-Kitt

Link to comment
Share on other sites

I'm betting not. My guess is that it was added in later, much like NWN's version of NWScript got the 'const' keyword and loads of other fun stuff we can't use.

 

Problem is, I never really had a very clear understanding about exactly what one could/should (or not) do with the various EFR formats in the first place. Like.. I kinda get that in KotOR, in general, 'mod' = area/level. What, precisely are the other ones doing, or rather, what sort of application can modders safely bend them to? Does anyone know if any of them are particularly suited to an idea like this? Where basically I'm building an item, but it has a crapload of files, and I'd like to collect it more neatly? Getting solid info on this stuff is kinda tricky these days. lol

 

-Kitt

 

The files only have power depending on the type and the location:

 

.erf files:

1. In the texturepacks folder, the game will search these for textures. I would theorize that you could add textures to these (icons in the _gui.erf) instead of the override folder, which would be made easier by TSLPatcher's backing up the originals in the backup folder.

 

2. In K2, these can be named "<module>_dlg.erf" and can hold that level's dialog files. Not sure if this works in K1.

 

.sav files:

1. Only used for save-games. The SAVEGAME.sav will have all the .sav files for modules in the savegame. A module can be "grouped" into a list of modules using modulesave.2da, but this is only useful in that you can tell the game to delete the entire group of .sav files after a certain module is saved (for example, deleting all the Taris ones after you reach Dantooine). Only useful to avoid bloating saves.

 

.mod files:

1. Used as a module/level file. Will override the .rim files, so it's a common format when editing existing levels. I personally recommend that new levels should be released as .rim files to allow for later modding, but that's just me.

 

2. Used in the lips folder as "<module>_loc.mod", these packages will contain all the .lip files used in that module.

 

.rim files:

1. Used as a module/level file. Will be overriden by the .mod files, so I personally recommend that new levels should be released as .rim files to allow for later modding, but that's just me.

 

2. Used in the rims folder for storing a lot of the games' assets, though a lot of them are also from the .bif packages, so I don't know how or why they're used... Maybe by the Xbox?

Link to comment
Share on other sites

Ah, thank you FS. That's exactly the info I was looking for.

 

Not sure any of it will apply to my current little project, but it's nice to get a solid handle on exactly what all the 'pak' style files are actually doing. Never know when that info will be handy. :)

 

-Kitt

Link to comment
Share on other sites

Used in the rims folder for storing a lot of the games' assets, though a lot of them are also from the .bif packages, so I don't know how or why they're used... Maybe by the Xbox?

The Xbox's is actually called "rimsxbox" and yes, it's not empty. A lot of stuff from the data folder on PC ("dataxbox") is there instead, including the area models.

 

I do think it's worth testing to see if putting new stuff in data and rims would work. I didn't know you could get the game to recognize new 2DA files until I tried it, not expecting it to work. Sometimes the game surprises you by cooperating.

Link to comment
Share on other sites

  1. Does anyone know if an item mod, that's meant to be available for the scope of most of the game can be packed into some sort of containing file like a mod, erf, etc? I never really worked with any of those, but it'd be nice to make this mess a bit more contained.

 

If I remember right you could use the TSLPatcher to insert the script files into the RIM files for the relevant modules, but if it's something that is meant to be used globally anywhere in the game they'd have to be inserted into all the modules, which would be rather excessive. It would also break the convention of having modded files in a location separate from the base game data, and I'd imagine a steam version of the game would complain about corrupted data files and overwrite them if doing a repair.

 

To my knowledge the only global data is that in the BIF files in the data folder (which would be a pain to edit since they're tired to the chitin.key file) and the override folder. While override folder bloat would be a thing I still think it would be the easiest and safest way of doing something like this.

 

Haven't done any KOTOR modding in a long time though so my memory may well be hazy on this. :)

Link to comment
Share on other sites

If I remember right you could use the TSLPatcher to insert the script files into the RIM files for the relevant modules, but if it's something that is meant to be used globally anywhere in the game they'd have to be inserted into all the modules, which would be rather excessive. It would also break the convention of having modded files in a location separate from the base game data, and I'd imagine a steam version of the game would complain about corrupted data files and overwrite them if doing a repair.

 

To my knowledge the only global data is that in the BIF files in the data folder (which would be a pain to edit since they're tired to the chitin.key file) and the override folder. While override folder bloat would be a thing I still think it would be the easiest and safest way of doing something like this.

 

Haven't done any KOTOR modding in a long time though so my memory may well be hazy on this. :)

 

Holy crap. The legend speaks!

 

lol.. Hey stoffe. Great to see ya. ^-^

 

But no.. I'm pretty sure you're right on the money. Was about what I was thinking, though admittedly, I'd never really monkeyed about with the 'container' files more than I'd absolutely had to in the past, but I sure could't think of a way to go about it. Asked here thinking maybe someone knew secrets I wasn't aware of, but sounds like I'll just have to deal with littering up the override.

 

Not like it really matters all that much, but eh. I just have this compulsion about being neat with my projects and whatnot... Hell.. I can't even stand to get 10+ icons on my desktop before I find them directories to go live in somewhere. xD

 

Incidentally.. a bit off topic, but should you glance this way again.. do you happen to still have a link to those awesome reconstructions you did years ago from bytecode into actual readable scripts? I expect I'll be stopping to tweak lots of things in my next few playthroughs, and good source is always nice to have. :)

 

-Kitt

Link to comment
Share on other sites

Incidentally.. a bit off topic, but should you glance this way again.. do you happen to still have a link to those awesome reconstructions you did years ago from bytecode into actual readable scripts? I expect I'll be stopping to tweak lots of things in my next few playthroughs, and good source is always nice to have. :)

 

I don't know if it's all of them but at a quick glance I did find a folder on my computer with a bunch of reconstructed scripts. I've attached them to this post. If there are more I've no idea where I might have put them. :¬:

recreated.7z

Link to comment
Share on other sites

@ stoffe: Ooh.. source scripts. It's like Christmas, only in February. ^-^

 

*huggles!*

 

Thanks a ton, stoffe. I'm sure these will come in handy. Once I get started really digging around in the scripts, it's almost compulsive to keep finding things to fix, tweak, play with.. lol I'm sure you can relate. ;)

 

-Kitt

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...