Edit the script (S.T.A.L.K.E.R.: Call of Pripyat)
In General, there is a script in the dialogue on the issuance of money GG nitrogen, alter the amount for that day without the log. I suspect that in addition to the amount needed to edit something else, but that ? Who will help the example of the original script ?Here is the original
Спойлерfunction jup_azot_by_sborka1 (first_speaker, second_speaker)
dialogs.relocate_item_section_from_actor (first_speaker, second_speaker, grenade_rgd5, 2)
end
function jup_azot_by_sborka11 (first_speaker, second_speaker)
local amount = 2000
dialogs.relocate_money_from_actor (first_speaker, second_speaker, amount)
dialogs.relocate_item_section_to_actor (first_speaker, second_speaker, grenade_rgd5_double)
end
function jup_forazot_actor_has_2000(first_speaker, second_speaker)
return db.actor:money() >= 2000
end
function jup_forazot_actor_hasnt_2000(first_speaker, second_speaker)
return db.actor:money() < 2000
end
function jup_forazot_actor_has_grsborkatype1 (first_speaker, second_speaker)
local cnt = 0
local function zat_b30_count(npc, item)
--printf(item:section: %s, item:section())
if item:section() == grenade_rgd5 then
cnt = cnt + 1
end
end
db.actor:iterate_inventory(zat_b30_count, nil)
if cnt > 1 then
return true
end
return false
end
function jup_forazot_actor_hasnt_ grsborkatype1(first_speaker, second_speaker)
local cnt = 0
local function zat_b30_count(npc, item)
--printf(item:section: %s, item:section())
if item:section() == grenade_rgd5 then
cnt = cnt + 1
end
end
db.actor:iterate_inventory(zat_b30_count, nil)
if cnt > 1 then
return false
end
return true
end
And that's what I naispravlyali
Спойлерfunction jup_azot_by_sborka1 (first_speaker, second_speaker)
dialogs.relocate_item_section_from_actor (first_speaker, second_speaker, grenade_rgd5, 2)
end
function jup_azot_by_sborka11 (first_speaker, second_speaker)
local amount = 300
dialogs.relocate_money_from_actor (first_speaker, second_speaker, amount)
dialogs.relocate_item_section_to_actor (first_speaker, second_speaker, grenade_rgd5_double)
end
function jup_forazot_actor_has_300 (first_speaker, second_speaker)
return db.actor:money() >= 300
end
function jup_forazot_actor_hasnt_300 (first_speaker, second_speaker)
return db.actor:money() < 300
end
function jup_forazot_actor_has_grsborkatype1 (first_speaker, second_speaker)
local cnt = 0
local function zat_b30_count(npc, item)
--printf(item:section: %s, item:section())
if item:section() == grenade_rgd5 then
cnt = cnt + 1
end
end
db.actor:iterate_inventory(zat_b30_count, nil)
if cnt > 1 then
return true
end
return false
end
function jup_forazot_actor_hasnt_grsborkatype1 (first_speaker, second_speaker)
local cnt = 0
local function zat_b30_count(npc, item)
--printf(item:section: %s, item:section())
if item:section() == grenade_rgd5 then
cnt = cnt + 1
end
end
db.actor:iterate_inventory(zat_b30_count, nil)
if cnt > 1 then
return false
end
return true
end
Thanks in advance.
here is the full script, because I don't know, can miss that
Original
Спойлерhttps://yadi.sk/d/IZXLV_bK3ZEVzT
My fix
Спойлерhttps://yadi.sk/d/j6lFgDqa3ZEWBo
Cheeki_Breeki
Better function names
jup_forazot_actor_has_2000
and
jup_forazot_actor_hasnt_2000
not change, maybe they where used.
Cheeki_Breeki
The provided files are very different.
Example 1
dialogs_jupiter.script
function jup_b32_give_reward_to_actor (first_speaker, second_speaker)
local amount = 5000
dialogs.relocate_money_to_actor (first_speaker, second_speaker, amount)
dialogs.relocate_item_section_to_actor (first_speaker, second_speaker, skill_book_usp)
give_mp3_bonus ([[Bonuses\Бонус_10]], mp3_club_bonus_10)
give_secret (1)
end
_jupiter.script
function jup_b32_give_reward_to_actor (first_speaker, second_speaker)
local amount = 5000
dialogs.relocate_money_to_actor (first_speaker, second_speaker, amount)
give_skill_book ()
give_mp3_bonus ()
give_secret (1)
end
Example 2
dialogs_jupiter.script
if not has_alife_info (jup_b1_squad_is_dead) and squad_name == jup_b1_stalker_squad then
_jupiter.script
if dont_has_alife_info (jup_b1_squad_is_dead) and squad_name == jup_b1_stalker_squad then
Something somewhere with the files that you messed up, because of this error.
KPOT1987
hmm, perhaps with different versions of the mod got rid of... the crash is exactly when the conversation, or rather, on a branch of a dialogue with the function of transfer of money.
Cheeki_Breeki
if you change the amount of what to change the name I do not understand?
Of course you will fly)))