Jump to content

Attempting to have a conversation activate on trigger.


LeonAnders

Recommended Posts

Here is what is going on i'm attempting to: I need the player to activate a conversation when he walks into a trigger but when I enter in the codes to actually start the conversation (codes from http://geck.bethsoft.com/index.php/StartConversation ) it won't save the script. All i really understand is that the conversation codes are what does it. since i've changed them to "setstage (questname) 20 and the script saved fine. I just don't know what I keyed in wrong or what i'm missing for this script.

 

scn HWQ01stage10triggerSCRIPT
begin onTriggerEnter player
if getStage HWQ01 == 10
StartConversation knightcom1, HWQ01Dialogue
StartConversation player, ForceGreetTopic
StartConversation player, ForceGreetTopic ref.joe ref.player 1
endif
end
Any help would be appreciated, and thanks in advance.
Link to comment
Share on other sites

I have some forcegreet triggers working properly in my game. Here's the script I'm using. I know there must be a cleaner way to do this, but y'know, whatever. It took me forever to get it working too, haha!


Give both the NPC and the trigger box their own REFs and make them persistent references.




SCN ForceGreetScript

short doonce

BEGIN OnTriggerEnter Player

NPCwhoWillTalkToPlayerREF.StartConversation player, ForceGreetTopicID
TriggerBoxREF.disable
TriggerBoxREF.MarkForDelete

set doonce to 1

END


Something to keep in mind is that, at least during my own testing, this only works if the NPC does not have any AI packages to start with. You can add them later in the result script of your goodbye topic with AddScriptPackage. Good luck! :)

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...