I forgot the variables in the trader files..

Discussions on Modding of S.T.A.L.K.E.R. SoC & Clear Sky

I forgot the variables in the trader files..

Postby ket on 18 Dec 2008 22:05

Yes, I feel incredibly stupid.. but I've forgotten what the variables control in the trader files. Anyone want to give me a refresher on em?
Mobo: MSI X570 Tomahawk
CPU: R7 3700X @ 4.4GHz 1.3v
RAM: 2x16GB Klevv BoltX 3600MHz 16-20-20-35
GPU: Powercolor 6800XT Red Devil
Sound: Asus Xonar DX 7.1 PCI-E, Realtek ALC1200
HDD: 250GB & 500GB nVME 3.0 M.2 drives, 2TB Seagate Barracuda, Sata3 64MB Cache, 250GB Hynix SL301
Opticals: DVD-RW, Blu-Ray
PSU: eVGA 1000w G2 Supernova
Case: NZXT Phantom 530

STALKER: Singularity (SIN) homepage
User avatar
ket
Senior Resident
 
Posts: 1262
Joined: 14 Sep 2008 11:57
Location: The solar system

Re: I forgot the variables in the trader files..

Postby EggChen on 18 Dec 2008 22:20

Code: Select all
[barman_generic_buy]
af_medusa            = 0.3,   0.3


How much he will pay, or whether the trader will even buy the item. If commented out like = ;NO TRADE then he will not buy the item at all.

It is the percentage of the base cost of the item, found in the middle of the two figures.... so in my example it is 30%. If you used 1 and 0 it would be 50%.... 0 and 10, 500%. Don't ask me why they used that system rather than just one figure!!

Code: Select all
[supplies_start]
ammo_9x18_fmj            = 5,   0.5


How many items the trader can have in stock, and the percentage chance of each item being in stock. So in this example the game will do a math.random calculation 5 seperate times, each time with a 50% chance of that item being in stock. The reason for this is solid, in the example above you could have 0 items or 5, but the chances are high that you will get something at least.

For weapons I often use 1 and a percentage loosely based on its rarity. So the FN2000 with the freedom trader is 1, 0.1, whereas the Abakan with duty trader is 1, 0.8.

Code: Select all
[barman_start_sell]
ammo_5.45x39_ap            = 4, 4


Same as the first example, only this time, the price he charges you. So in this example he charge 400% for ammo.

One thing to remember, if you add items to his supplies, you also have to ensure he can sell the item. If it is listed as ;NO TRADE in the sell section it does not matter how many are in stock, they will not show in the ui.
User avatar
EggChen
Moderator
 
Posts: 1016
Joined: 13 Sep 2008 00:44
Location: Birmingham, UK

Re: I forgot the variables in the trader files..

Postby ket on 18 Dec 2008 22:55

Thanks! :d I should probably start writing some of this stuff down instead of relying on memory for it all :p
Mobo: MSI X570 Tomahawk
CPU: R7 3700X @ 4.4GHz 1.3v
RAM: 2x16GB Klevv BoltX 3600MHz 16-20-20-35
GPU: Powercolor 6800XT Red Devil
Sound: Asus Xonar DX 7.1 PCI-E, Realtek ALC1200
HDD: 250GB & 500GB nVME 3.0 M.2 drives, 2TB Seagate Barracuda, Sata3 64MB Cache, 250GB Hynix SL301
Opticals: DVD-RW, Blu-Ray
PSU: eVGA 1000w G2 Supernova
Case: NZXT Phantom 530

STALKER: Singularity (SIN) homepage
User avatar
ket
Senior Resident
 
Posts: 1262
Joined: 14 Sep 2008 11:57
Location: The solar system

Re: I forgot the variables in the trader files..

Postby ket on 18 Dec 2008 23:37

Oh I almost forgot, whats the deal with items only becoming available after specific game missions? I've never been able to get that working right :\
Mobo: MSI X570 Tomahawk
CPU: R7 3700X @ 4.4GHz 1.3v
RAM: 2x16GB Klevv BoltX 3600MHz 16-20-20-35
GPU: Powercolor 6800XT Red Devil
Sound: Asus Xonar DX 7.1 PCI-E, Realtek ALC1200
HDD: 250GB & 500GB nVME 3.0 M.2 drives, 2TB Seagate Barracuda, Sata3 64MB Cache, 250GB Hynix SL301
Opticals: DVD-RW, Blu-Ray
PSU: eVGA 1000w G2 Supernova
Case: NZXT Phantom 530

STALKER: Singularity (SIN) homepage
User avatar
ket
Senior Resident
 
Posts: 1262
Joined: 14 Sep 2008 11:57
Location: The solar system

Re: I forgot the variables in the trader files..

Postby EggChen on 18 Dec 2008 23:48

Check out the existing conditions, and you should be able to work it out.

Basically you define a section that is used in the event of an info_portion at the top of the file, then create the relevent section in the file.

I added a new condition to Sid's file, compare this to vanilla to see how.
You do not have the required permissions to view the files attached to this post.
User avatar
EggChen
Moderator
 
Posts: 1016
Joined: 13 Sep 2008 00:44
Location: Birmingham, UK

Re: I forgot the variables in the trader files..

Postby ket on 19 Dec 2008 00:19

:thumbright: Not sure If i'll implement the latter part, just something that always bugged me :p
Mobo: MSI X570 Tomahawk
CPU: R7 3700X @ 4.4GHz 1.3v
RAM: 2x16GB Klevv BoltX 3600MHz 16-20-20-35
GPU: Powercolor 6800XT Red Devil
Sound: Asus Xonar DX 7.1 PCI-E, Realtek ALC1200
HDD: 250GB & 500GB nVME 3.0 M.2 drives, 2TB Seagate Barracuda, Sata3 64MB Cache, 250GB Hynix SL301
Opticals: DVD-RW, Blu-Ray
PSU: eVGA 1000w G2 Supernova
Case: NZXT Phantom 530

STALKER: Singularity (SIN) homepage
User avatar
ket
Senior Resident
 
Posts: 1262
Joined: 14 Sep 2008 11:57
Location: The solar system


Return to Modding Techniques

Who is online

Users browsing this forum: No registered users and 34 guests