Adding to Trader Sell Condition? -1 reply

Please wait...

harley914

GF makes me horny

50 XP

16th November 2005

0 Uploads

85 Posts

0 Threads

#1 9 years ago

How could I add some event to a traders sell condition list? For example, let's say I wanted sid to trade something after doing the side quest where you steal documents from military in cordon.




harley914

GF makes me horny

50 XP

16th November 2005

0 Uploads

85 Posts

0 Threads

#2 9 years ago

bump?




MattyDienhoff

Addicted to GF

50 XP

30th June 2006

0 Uploads

252 Posts

0 Threads

#3 9 years ago

First you have to add the new trade conditions to the "sell_condition" and "buy_supplies" fields at the top of the trader's file. For example:

sell_condition = {+yan_labx16_switcher_primary_off} trader_after_brain_sell, {+bar_darklab_document_done} trader_after_darkvalley_sell, {+esc_kill_bandits_quest_done} trader_after_fabric_sell, trader_start_sell

buy_supplies = {+yan_labx16_switcher_primary_off} supplies_after_brain, {+bar_darklab_document_done} supplies_after_darkvalley, {+esc_kill_bandits_quest_done} supplies_after_fabric, supplies_start

The parts in bold are the new conditions I just added to Sidorovich's file. That means that Sidorovich will change his stock a third time after the mini-Brain Scorcher in Yantar is disabled. Note that the conditions are in reverse order. The "start" condition should always be the last in the list.

Of course, because you want to use a different event to trigger a stock change, you'll have to figure out which info portion to use for your new sell condition.

"bar_darklab_document_done" is an info portion, for instance. It's the one that states the player has the X18 documents. You can find info portions in:

\gamedata\config\gameplay\

And they files containing them will be named like this:

info_l01escape.xml

I'm looking at that file now and this is likely to be the info portion you're looking for.

escape_blockpost_case_done

So I just added a new trade condition to Sidorovich's file using that info portion, this is what it looks like (additions in bold):

sell_condition = {+bar_darklab_document_done} trader_after_darkvalley_sell, {+escape_blockpost_case_done} trader_after_blockpost_sell, {+esc_kill_bandits_quest_done} trader_after_fabric_sell, trader_start_sell

buy_supplies = {+bar_darklab_document_done} supplies_after_darkvalley, {+escape_blockpost_case_done} supplies_after_blockpost, {+esc_kill_bandits_quest_done} supplies_after_fabric, supplies_start

That means that (in theory, anyway, I haven't tested it) Sidorovich will now update his stock when you give him the documents from the military outpost.

Now that that's done, you just have to create the new sections you refer to at the top of the file (supplies_after_blockpost and trader_after_blockpost_sell), and you're done!




harley914

GF makes me horny

50 XP

16th November 2005

0 Uploads

85 Posts

0 Threads

#4 9 years ago

thanks, I'll try it out

Edit: Tested and it works. Thanks. Now, that I know I can do that, is it possible to create my own events for this? Not that I really need to but I had an idea where your STALKER score/rank thing effects what traders will sell to you and if I find that's possible, I'll go on to find out if it's possible to set what effects the stalker score/rank thing (I.E.: Killing, Saving people with medpacks, completing missions).




NatVac

of the ZRP

50 XP

10th August 2008

0 Uploads

124 Posts

0 Threads

#5 9 years ago

See your other related thread for a possible answer to the follow-up question, [COLOR=Sienna]harley914[/COLOR]:

STALKER ranking?