ProjectsWhat's NewDownloadsCommunitySupportCompany
Forum Index » S.T.A.L.K.E.R.: Shadow of Chernobyl Forum » Mod discussion
I Am Having A Weird Issue.

« Previous 10 events | 1 2 | All Messages
Posted by/on
Question/AnswerMake Newest Up Sort by Descending
  00:10:23  12 July 2012
profilee-mailreply Message URLTo the Top
Vintar
a bit of this and a lot of that
(Resident)

 

 
On forum: 08/08/2008
Messages: 6349
yes Lijestina is right, you cant declare variables (actor, npc) then use first_speaker.
If you wanted it that way then you couldve done this :
function wolf_mission_hasbox(first, second)
    local actor = if_then_else(first:id() == db.actor:id(), first, second)
    return ((actor:object("quest_case_01") ~= nil) and (actor:object("wpn_wolfs_akm") ~= nil))
end

  09:22:24  12 July 2012
profilee-mailreply Message URLTo the Top
Derranged
Senior Resident
 

 
On forum: 04/12/2010
 

Message edited by:
Derranged
07/12/2012 13:03:38
Messages: 1009
Well, it still crashes on Wolf... I hope I still haven't made a mistake in the script... Vintar, maybe I should just send you the file?

EDIT:

Alright, now... before there must've been an Error with Wolfs Preconditions which bugged out every Precondition.

I got rid of Wolfs Preconditions, re-created the weapon ordering Preconditions and here is what works:

function trader_weapon_ak74(actor, npc)
return actor:money() > 10000
end
function trader_weapon_ak74_buy(actor, npc)
dialogs.relocate_money(actor, 10000, "out"
dialogs.relocate_item_section(actor, "wpn_ak74", "in"
end

----

I will now attempt to re-add Wolfs Preconditions and Rewards through these types of scripts. If it starts happening again I will probably tear my hair out.
 
Each word should be at least 3 characters long.
Search:    
Search conditions:    - spaces as AND    - spaces as OR   
 
Forum Index » S.T.A.L.K.E.R.: Shadow of Chernobyl Forum » Mod discussion
 

All short dates are in Month-Day-Year format.


 

Copyright © 1995-2021 GSC Game World. All rights reserved.
This site is best viewed in Internet Explorer 4.xx and up and Javascript enabled. Webmaster.
Opera Software products are not supported.
If any problem concerning the site functioning under Opera Software appears apply
to Opera Software technical support service.