PDA

View Full Version : Non-Scripting Item Placing


The Doctor
08-05-2006, 02:04 PM
First off: Yes, I have read through the tutorial. But I've encountered a problem it doesn't explain.

When I click on Inventory to place my item in it, it opens the says "Getting INventory From Warehouse". Cool. Except I can't find my item anywhere in the 'Warehouse'. How do I place a custom item?? I can't only seem to place items already in the game using this method.

stoffe
08-05-2006, 02:10 PM
First off: Yes, I have read through the tutorial. But I've encountered a problem it doesn't explain.

When I click on Inventory to place my item in it, it opens the says "Getting INventory From Warehouse". Cool. Except I can't find my item anywhere in the 'Warehouse'. How do I place a custom item?? I can't only seem to place items already in the game using this method.

In KotorTool the treeview with inventory items only list the standard items in the game, not custom items from mods. You'll have to add those manually. Drag one of the standard items to the inventory, then change the ResRef of it in the inventory list to the ResRef of your item instead. (Or if you want to place it in one of the equipment slots on a creature: doubleclick on the slot and type in the ResRef in the box that pops up.)

The Doctor
08-05-2006, 02:34 PM
One last quick question, and then I think I'll have it figured out.

I'm not sure if the file rnepillr001.utp is a ULP. How can I tell? I know that if the name reflects the module, it's a ULP, but both the files in the module that reflect the name don't actually appear in the module - one's a footlocker, the other's a wicker basket. I know that rnepillr001.utp is actually there, but is it a ULP?

stoffe
08-05-2006, 02:43 PM
I'm not sure if the file rnepillr001.utp is a ULP. How can I tell?

Uh, what is "ULP"?

The Doctor
08-05-2006, 02:45 PM
It's mentioned in the tutorial. It says it's short for Unique Location Placeable.

stoffe
08-05-2006, 02:51 PM
It's mentioned in the tutorial. It says it's short for Unique Location Placeable.

Oh, I haven't read the tutorial so I wasn't aware of the meaning of any terminology it has invented. :)

Anyway, you can use the FindRefs GUI (http://www.starwarsknights.com/tools.php#gmt) utility to check if a placeable is unique or exists within different modules. Run it and type in the ResRef of your placeable in the search box and it will list the location of all matches within the game data.

The Doctor
08-05-2006, 03:08 PM
Thanks a lot, stoffe! I appreciate it. :D

Mav
08-05-2006, 06:16 PM
You want to be careful, when placing custom items in a placeable such as a footlocker, because the game sometimes re-uses the same .utp in several modules, meaning you may find your item more than once. There are other methods as well though, if this is for TSL you could make you item createable at the workbench. Plenty of opitions :)

The Doctor
08-05-2006, 06:39 PM
No, this is for KotOR. And I know that the game uses the same placeable multiple times - that's why I need to know if rnepillr001.utp is a Unique Location Placeable - I don't know if it's used multiple times or not.

I've found out that it's actually not. Unfortunately, the placeables in that module that are ULPs don't actually exist in the game... and the ones that do exist don't have anything in them in the files, but in the game, they have a medpack and antidote kit.

That brings me to my question. WTF?

stoffe
08-05-2006, 07:38 PM
I've found out that it's actually not. Unfortunately, the placeables in that module that are ULPs don't actually exist in the game... and the ones that do exist don't have anything in them in the files, but in the game, they have a medpack and antidote kit.


What you need to make sure is that the name of the placeable template (UTP) file is unique across all modules. As long as there is only a file with that name in one module (or in the global game data) you can safely extract that UTP file, modify it and save it in the override folder for it to take effect in-game.

You'll likely have to use a save from before entering the area where the placeable is for your new content to show up though, since the placeable has already been created in the savegame otherwise.)

The reason you need to make sure the name of the template file is unique is that it would override the file in all the modules where one with an identical name exists otherwise, and they are not necessarily identical. Not to mention that your gear would show up in a lot of places. :)

To check if the placeable template is then used multiple times within the same module you'll have to (using a GFF Editor) look inside the PlaceableList in the .GIT file of the module where the UTP file exists, to see if that template is called more than once in the TemplateResRef field within each struct field there.

The Doctor
08-05-2006, 07:42 PM
Yeah, I get that much. I'll try to explain my problem better...

The module is the Unkown World Temple Catacombs. There are supposed to be two template files with unique names (confirmed by the FindRefs Utility you provided me with). The problem is, they don't actually appear in the game. The footlocker and wicker basket (I'm pretty sure that's what they are) themselves simply aren't accessible in the game. They're not there.

Hence my question: WTF?

stoffe
08-05-2006, 07:48 PM
The module is the Unkown World Temple Catacombs. There are supposed to be two template files with unique names (confirmed by the FindRefs Utility you provided me with). The problem is, they don't actually appear in the game. The footlocker and wicker basket (I'm pretty sure that's what they are) themselves simply aren't accessible in the game. They're not there.


As said above, simply putting an UTP file in a module won't make it appear in the game world. Only placeables added to the PlaceablesList list field within the .GIT file of that area will appear in the game world (unless it's spawned dynamically by a script). Thus it's possible that there are unused UTP template files littering the module files for whatever reason. :) You'll have to check inside the area .GIT file to make sure the placeable is actually pre-placed in the game world.

If they are listed in the area's GIT file but you still can't find them in-game, check the coordinates listed in the GIT. It's possible that they are present inside a wall, above the ceiling or below the ground of the area. :)

(The .GIT file can be found in the module RIM file without the _s suffix at the end of the file name. KotorTool puts it under the "Dynamic Area Info" heading.)

The Doctor
08-05-2006, 07:58 PM
Alright, thanks stoffe.

ADD: Alright. I've opened the GTI file... but it makes no sense. There are supposedly 30 struts under placeables. Does that mean that there are 30 placeables in the module???

On a side not... someone (I forget who) linked me to a page that showed me which modules were what in the game. I can't find the link anymore. Does anyone happen to have something silimar on hand? I need one for KotOR.

stoffe
08-05-2006, 08:04 PM
On a side not... someone (I forget who) linked me to a page that showed me which modules were what in the game. I can't find the link anymore. Does anyone happen to have something silimar on hand? I need one for KotOR.

Don't know about a list page, but KotorTool should show you what the modules are in the treeview, though it's possible you may need to enable it in the Options window first (don't remember if it's on by default). Go to the Tools menu, choose Options and make sure the "Show module locations" and "Show module descriptions" checkboxes are checked.

The Doctor
08-05-2006, 08:07 PM
That's done it! :)

Alright. I've opened the GTI file... but it makes no sense. There are supposedly 30 struts under placeables. Does that mean that there are 30 placeables in the module??? And what are all these values and things?

stoffe
08-05-2006, 08:16 PM
Alright. I've opened the GTI file... but it makes no sense. There are supposedly 30 struts under placeables. Does that mean that there are 30 placeables in the module???

Yes, each struct in the PlaceablesList represent a pre-placed placeable within the module. The TemplateResref field within each struct contains the name (resref) of the UTP file to use to create the placeable. Thus if a resref occurs more than once in the placeableslist it means that there are more than one placeable created from the same template. :)

The Doctor
08-05-2006, 08:23 PM
Ok. There are some placeables listed here that KotOR Tool doesn't list, and vice vera. My previous questions still stands: WTF?

Are the placeables marked
Bearing [TYPE: FLOAT] Value: 0
the ones that are not accessible in the game?

The Doctor
08-05-2006, 09:06 PM
Alright, for now I'm just going to use Nemo's Remains - I know for sure that they're not used anywhere else in the game. But I would still like a little help explaining what some of this stuff means - at the very least, the placeable options. I have no idea what any of the below means, and would appreciate some help understanding this thing.

[STRUCT ID: 9]
Bearing [Type: FLOAT]Value: 0
Template ResRef [Type: RESREF]Value: rakatacom001
X [Type: FLOAT]Value: 73.2400436401367
Y [Type: FLOAT]Value: 107.729286193848
Z [Type: FLOAT]Value: 0.0935247838497162

stoffe
08-05-2006, 09:10 PM
Ok. There are some placeables listed here that KotOR Tool doesn't list, and vice vera. My previous questions still stands: WTF?
Are the placeables marked the ones that are not accessible in the game?

Those UTP templates referenced in the area .GIT file but not present in the modules directly are most likely found in the global game data in the templates.bif file.

As for the fields in each PlaceableList struct:
[b]Bearing is the direction the placeable is facing in the game world.
X, Y, Z are the coordinates for where in the game world the placeable is placed.
TemplateResref is the name (resref) of the UTP file which should be used to create this placeable.

The Doctor
08-05-2006, 10:04 PM
stoffe, you get my favourite person of the year award. You've helped me so much today I don't know how I can repay you! :D