Editing Stashes
From Mod Wiki
Revision as of 15:04, 12 July 2008 (edit) Gr1ph00n (Talk | contribs) (New page: In this tutorial I will explain how to edit a stash. __TOC__ == Editing Stashes == === Introduction === The file which contain all information about stashes is treasure_manager.ltx loc...) ← Previous diff |
Current revision (15:49, 12 July 2008) (edit) (undo) Don Reba (Talk | contribs) m (small formatting adjustment) |
||
(4 intermediate revisions not shown.) | |||
Line 3: | Line 3: | ||
__TOC__ | __TOC__ | ||
- | + | == Introduction == | |
- | + | ||
- | The file which contain all information about stashes is treasure_manager.ltx located in gamedata\config\misc | + | The file which contain all information about stashes is '''treasure_manager.ltx''' located in <tt>gamedata\config\misc</tt> |
Opening that file, we can see a section called [list] and below a lots of others section with a different noun, that appear in the list. | Opening that file, we can see a section called [list] and below a lots of others section with a different noun, that appear in the list. | ||
For example : | For example : | ||
<code><source lang="ini"> | <code><source lang="ini"> | ||
[esc_secret_village_rucksack] | [esc_secret_village_rucksack] | ||
- | target = 5010 | + | target = 5010 |
- | name = esc_secret_0010_name | + | name = esc_secret_0010_name |
description = esc_secret_0010_descr | description = esc_secret_0010_descr | ||
- | items = wpn_pb, ammo_9x18_fmj, 50 | + | items = wpn_pb, ammo_9x18_fmj, 50 |
- | condlist = {npc_rank(novice)} 3 | + | condlist = {npc_rank(novice)} 3 |
- | community = stalker, bandit | + | community = stalker, bandit |
</source></code> | </source></code> | ||
- | + | == Analysis == | |
As we can see there are 6 editable fields, but only the last 3 are useful : items, codlist and community. | As we can see there are 6 editable fields, but only the last 3 are useful : items, codlist and community. | ||
Line 79: | Line 78: | ||
We can assign more than one community | We can assign more than one community | ||
- | + | == Example == | |
This is an example of what we can do. | This is an example of what we can do. | ||
After choosing the stash we want to edit, we can start : | After choosing the stash we want to edit, we can start : | ||
Line 86: | Line 85: | ||
;-- a stash in garbage level | ;-- a stash in garbage level | ||
[gar_secret_bandit_hiding] | [gar_secret_bandit_hiding] | ||
- | target = 5030 | + | target = 5030 |
- | name = gar_secret_0000_name | + | name = gar_secret_0000_name |
description = gar_secret_0000_descr | description = gar_secret_0000_descr | ||
- | items = outfit_exo_m1, wpn_vintorez, ammo_9x39_sp5, 1000, wpn_groza, wpn_desert_eagle, ammo_11.43x23_hydro, 100 | + | items = outfit_exo_m1, wpn_vintorez, ammo_9x39_sp5, 1000, wpn_groza, wpn_desert_eagle, ammo_11.43x23_hydro, 100 |
- | condlist = 1 | + | condlist = 1 |
- | community = bandit | + | community = bandit |
</source></code> | </source></code> | ||
As you can read, in this stash there are : a Fang's Exo, a Vintar BC (aka vintorez), a Tunder S14 (aka groza), a Black Kite (aka Desert Eagle), 1000 9x39 mm SP-5 rounds bullets and 100 .45ACP Hydro-Shock rounds bullets. To get this stash, we have to kill at least one bandit. | As you can read, in this stash there are : a Fang's Exo, a Vintar BC (aka vintorez), a Tunder S14 (aka groza), a Black Kite (aka Desert Eagle), 1000 9x39 mm SP-5 rounds bullets and 100 .45ACP Hydro-Shock rounds bullets. To get this stash, we have to kill at least one bandit. | ||
- | + | == Extra == | |
If someone wants to understand how stashes are assigned, they can read treasure_manager.script, in scripts dir, function '''CTreasure:use(npc)''' check the probability to get a stash by a npc and function '''CTreasure:give_treasure(k)''' gives it us. | If someone wants to understand how stashes are assigned, they can read treasure_manager.script, in scripts dir, function '''CTreasure:use(npc)''' check the probability to get a stash by a npc and function '''CTreasure:give_treasure(k)''' gives it us. | ||
- | + | [[category:articles]] | |
- | + | ||
- | + | ||
- | + |
Current revision
In this tutorial I will explain how to edit a stash.
Contents |
Introduction
The file which contain all information about stashes is treasure_manager.ltx located in gamedata\config\misc Opening that file, we can see a section called [list] and below a lots of others section with a different noun, that appear in the list. For example :
[esc_secret_village_rucksack]
target = 5010
name = esc_secret_0010_name
description = esc_secret_0010_descr
items = wpn_pb, ammo_9x18_fmj, 50
condlist = {npc_rank(novice)} 3
community = stalker, bandit
Analysis
As we can see there are 6 editable fields, but only the last 3 are useful : items, codlist and community.
Items show us what items are in that stash and their quantity. In that stash there is a Noiseless pistol (PB1s) and 50 9x18 mm rounds bullets. So to indicate the quantity we can write a number after the items. For example using that code,
items = wpn_fn2000, 1, ammo_5.56x45_ap, 200, outfit_exo_m1
the stash will have a ft200m ( aka fn2000 ), 200 5.56x45 mm AP rounds bullets and Fang’s Exo
If the quantity is 1, it can be omitted
Condlist tell us the condition that we must meet to get stash info
There are some condition that we can apply like :
actor_on_level(level_name) >> that means the npc who has got the stash is in level_name map
Those are names of levels
l01_escape > Cordon l02_garbage > Garbage l03_agroprom > Agroprom l03u_agr_underground > Agroprom underground l04_darkvalley > Dark Valley l04u_labx18 > Lab X18 l05_bar > Bar l06_rostok > Wild Territory/Rostok l07_military > Army Warehouses l08_yantar > Yantar l08u_brainlab > Lab X16 l10_radar > Red Forest l11_pripyat > Pripyat
npc_profile(profile) – this means that a specific npc has got it, check character_desc_level-name.xml
npc_rank(rank) - this tell us the rank of the npc which has got the stash, ranks = novice, experienced, veteran, master
we can add extra condition too, they are info_portion, “+” indicates that you have to get that info_portion, and “-“ if not
eg :-bar_darklab_document_doneor
+bar_darklab_document_done
It’s possible to add a number of npcs that we have to kill to get that stash
community field tells us the faction of the npc which has got the stash
- stalker - loner stalker - bandit - bandit - military - soldier - killer - mercs - dolg - duty - freedom - freedom - zombied - zombified stalker - ecolog – scientist - monolith – monolith
We can assign more than one community
Example
This is an example of what we can do. After choosing the stash we want to edit, we can start : eg
;-- a stash in garbage level
[gar_secret_bandit_hiding]
target = 5030
name = gar_secret_0000_name
description = gar_secret_0000_descr
items = outfit_exo_m1, wpn_vintorez, ammo_9x39_sp5, 1000, wpn_groza, wpn_desert_eagle, ammo_11.43x23_hydro, 100
condlist = 1
community = bandit
As you can read, in this stash there are : a Fang's Exo, a Vintar BC (aka vintorez), a Tunder S14 (aka groza), a Black Kite (aka Desert Eagle), 1000 9x39 mm SP-5 rounds bullets and 100 .45ACP Hydro-Shock rounds bullets. To get this stash, we have to kill at least one bandit.
Extra
If someone wants to understand how stashes are assigned, they can read treasure_manager.script, in scripts dir, function CTreasure:use(npc) check the probability to get a stash by a npc and function CTreasure:give_treasure(k) gives it us.