Baldur's Gate Wiki
Advertisement

GENSHT01, short for general shout (01) is one of the scripts that handles creatures' "shouts", as well as their reaction when hearing another creature's "shout". A creature may shout for help if attacked or being otherwise involved in combat.

This script is introduced in the original Baldur's Gate II: Shadows of Amn and adopted without changes by the Enhanced Editions, where it also appears in Baldur's Gate: Enhanced Edition campaigns.

IF
	AttackedBy([GOODCUTOFF],DEFAULT)
	Allegiance(Myself,NEUTRAL)
THEN
	RESPONSE #100
		Shout(89)
		Enemy()
END

IF
	HitBy([GOODCUTOFF],CRUSHING)
THEN
	RESPONSE #100
		Shout(89)
		Continue()
END

IF
	OR(5)
		AttackedBy([PC],DEFAULT)
		AttackedBy([FAMILIAR],DEFAULT)
		AttackedBy([ALLY],DEFAULT)
		AttackedBy([CONTROLLED],DEFAULT)
		AttackedBy([CHARMED],DEFAULT)
	Allegiance(Myself,ENEMY)
	ActionListEmpty()
THEN
	RESPONSE #100
		Shout(89)
		Continue()
END

IF
	Heard([ANYONE],89)
	Allegiance(Myself,NEUTRAL)
	!Class(Myself,INNOCENT)
THEN
	RESPONSE #100
		Enemy()
		MoveToObject(LastHeardBy(Myself))
END

IF
	Heard([ANYONE],89)
	Allegiance(Myself,NEUTRAL)
THEN
	RESPONSE #100
		Enemy()
END

IF
	Heard([ANYONE],89)
	!Class(Myself,INNOCENT)
	!See(NearestEnemyOf(Myself))
THEN
	RESPONSE #100
		MoveToObject(LastHeardBy(Myself))
		Continue()
END
Advertisement