Jump to content

getting vendor to sell a house-key


Hupfstrudel

Recommended Posts

hey guys,

 

Im working on a house mod and i dont want to be able to obtain it for free, so i locked the door using a key and added a new merchant to the game. he has the key in his merchantcontainer, but when in dialogue he refuses to sell it to me. ive tryed using different keywords for the key, such as vendoritemkey, vendoritemweapon and thought that maybe that would hep, but nope.

 

maybe any of you have an idea, cause im going crazy here

Link to comment
Share on other sites

hey guys,

 

Im working on a house mod and i dont want to be able to obtain it for free, so i locked the door using a key and added a new merchant to the game. he has the key in his merchantcontainer, but when in dialogue he refuses to sell it to me. ive tryed using different keywords for the key, such as vendoritemkey, vendoritemweapon and thought that maybe that would hep, but nope.

 

maybe any of you have an idea, cause im going crazy here

 

 

Probably your best bet is to make a dialogue option to remove gold from the player and add the key. Make sure to put in the conditions to check that the player has enough gold to do it, and create a secondary dialogue option for if the player doesn't enough gold that says something like "I'm sorry you don't have enough gold to buy the key."

Link to comment
Share on other sites

Another option would be to sell a misc. item that when added to the players inventory get's removed and replaced with a key, but this would require a script doing some polling and be imo unneccesarily complicated.

 

 

Edit: I'm working on the assumption with my replies that the game won't allow merchants to sell/buy keys. It seems from memory that this was the case in Oblivion at least. So probably is in Skyrim as well.

Link to comment
Share on other sites

hey guys,

 

Im working on a house mod and i dont want to be able to obtain it for free, so i locked the door using a key and added a new merchant to the game. he has the key in his merchantcontainer, but when in dialogue he refuses to sell it to me. ive tryed using different keywords for the key, such as vendoritemkey, vendoritemweapon and thought that maybe that would hep, but nope.

 

maybe any of you have an idea, cause im going crazy here

Do you have the merchant faction in the NPC? I think it's JobMerchantFaction.

Also, did you create aliases for both the key and the merchant? Make the merchant a unique actor and alias UniqueActor 'MerchantsName' then lower on the aliases list make a new alias for the unique key - Create Reference to Object> 'KeyName'> Level - Easy (this doesn't matter but easy is default)> Create In> 'MerchantsName'.

By making aliases you can also track the key in the quest by adding the 'KeyName' on Quest Objectives tab under Target Ref.

Link to comment
Share on other sites

Maybe it will help you to look at the quest 'HousePurchase', to see how it's done for the vanilla player houses.

 

You can use the conditions and script fragments from this quest and change them to your needs.

 

That works too...this quest uses the scripts:

game.getplayer().RemoveItem(Gold, GoldAmount.getvalueint())

 

game.getplayer().AddItem(HouseKey)

Edited by DizzasterJuice
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...