Jump to content

[Dialogue] Force Greeting


Zorkaz

Recommended Posts

How can I make it so a NPC automatically starts the greeting converstation when I appraoch him, without the need for player activation?

 

ForceGreetHello does nothing for me.

Link to comment
Share on other sites

A non Requires Player Activation flagged Topic Info that has the highest Priority Greeting subtyped Topic among the dialogue quests applicable to the NPC should make the NPC automatically greet the player if they have a Package with Package Template ForceGreet, assuming there's no blocking Condition.

If it doesn't, well I'm not sure right now if fAIGreetingTimer [GMST:000467BC] applies to non Requires Player Activation topic infos but I think it does.. and the native code sometimes "forgets" to trigger the greet line, causing the NPC to stand still.

 

You can be certain the line is played if you write a script for it.

Function RegisterForGetWithinActivateDistance()

	RegisterForDistanceLessThanEvent(greeterActorRef, Game.GetPlayer(), 180.0)		; INI setting fActivatePickLength:Interface

EndFunction


Event OnDistanceLessThan(ObjectReference akObj1, ObjectReference akObj2, float afDistance)

	Actor greeterActor = akObj1 as Actor
	If greeterActor
		Topic GreetingTopic = Game.GetForm(0x123456) as Topic		; assuming you know the FormID of the Topic
		greeterActor.Say(GreetingTopic, akTarget = akObj2)
	EndIf

EndEvent

 

  • Like 1
Link to comment
Share on other sites

  • Recently Browsing   0 members

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