View Full Version : How to create a key to open a door
10-24-2005, 04:13 AM
I can't find this one. Is it possible to create a key to open certain doors, like in Khoonda with the Security door key? And also what is the script for giving an item in a conversation. And on top of that (lol getting longer) how do I script that a certain conversation option is available if the PC has weapons equipped- So you may be told to relinquish your weapons if you have them out.
10-24-2005, 07:10 AM
It probally is possible as I think there is a key to open a box in the prologue, I am not a modder so I don't know how to do it but I know it is in the game.
10-24-2005, 08:02 AM
I think in the door editor in kotor tool there is some things under lock that talk about keys but i never tried it.
10-24-2005, 09:03 AM
yes , it's possible: make a plot item that will be your key (.uti file). Then, go to your .utd file and in the lock tab, check the box: key required to unlock or lock and insert the tag of the key. Yoiu could also attach a script that checks if you have the item in your inventory.
And also what is the script for giving an item in a conversation.
To give an item to your PC:
object oPC = GetPCSpeaker();
object oItem = GetItemPossessedBy(GetObjectByTag("npc_tag", "item_resref");
And on top of that (lol getting longer) how do I script that a certain conversation option is available if the PC has weapons equipped- So you may be told to relinquish your weapons if you have them out.
object oPC= GetPCSpeaker();
//check the slots in nwscript.nss
object oItem = GetItemInSlot( INVENTORY_SLOT_*, oPC);
More here: http://www.lucasforums.com/showthread.php?t=154032
There are other ways of doing this depending on your needs but I don't have time right now. Try using the search function for this: there are tons of threads discussing this.
vBulletin®, Copyright ©2000-2015, Jelsoft Enterprises Ltd.