Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
#646698 10/06/18 06:10 PM
Joined: May 2014
Z
zadkey Offline OP
stranger
OP Offline
stranger
Z
Joined: May 2014
As I was playing I noticed some enemies had constant effect skills. E.g. Skills/effects that were always on and never had to be cast.

Alexander's holy aura is an example.

The 2 voidwoken on the Fort Joy beach with Vampyric Hunger on Tactician mode is another example.

I looked through the Stats editor far and wide and never saw anything that indicated how this was done.

How do we as modders replicate this?

Joined: Nov 2017
L
member
Offline
member
L
Joined: Nov 2017
I would suggest the GLO_SetStatusOnInit behaviour script.

It might be sufficient to simply StatusApply from Story, however, depending on what your exact circumstances are.

Joined: May 2014
Z
zadkey Offline OP
stranger
OP Offline
stranger
Z
Joined: May 2014
GLO_SetStatusOnInit and StatusApply, where do I find these in the editor?

Also, where/how do I use them?

Last edited by zadkey; 16/06/18 05:13 PM.
Joined: May 2014
Z
zadkey Offline OP
stranger
OP Offline
stranger
Z
Joined: May 2014
statusapply <status> <duration> - e.g. statusapply FROZEN 5 - apply status to selected for 5 turns. Duration -1 sets a permanent status.


I wonder if I can use the -1 in the stats editor.

Joined: May 2017
enthusiast
Offline
enthusiast
Joined: May 2017
GLO_SetStatusOnInit is a script attached to specific object instances (in a level), or a root template, within the "Scripts" property window while a root template or instanced object is selected.

Infinite duration statuses can also be set in the stats, via something like a skill or equipment. Here's some examples:

Skill example:
Code
new entry "Target_PowerInfusion"
type "SkillData"
data "SkillType" "Target"
data "ForGameMaster" "Yes"
data "Ability" "Summoning"
data "Tier" "Novice"
data "ActionPoints" "1"
data "Cooldown" "3"
data "AIFlags" "CanNotUse"
data "SkillProperties" "INF_POWER,100,-1"

Power Infusion applies INF_POWER to the incarnate permanently, as you can see here.

Item example:
Code
new entry "ARM_UNIQUE_BraccusCursedRing"
type "Armor"
using "_Rings"
data "ItemGroup" "ARM_UNIQUE_BraccusCursedRing"
data "Act part" "7"
data "Value" "120"
data "IntelligenceBoost" "2"
data "ConstitutionBoost" "2"
data "MemoryBoost" "-1"
data "ExtraProperties" "Self:OnEquip:CURSED"
data "ComboCategory" "ArmorRing"
data "Unique" "1"

Statuses applied by equipment, like the cursed Braccus ring, are permanent by nature.

___________________________________________________

Also, like LarIlya mentioned, behavior scripts and story scripts have functions for applying statuses, and you can set the duration to -1 that way:

Behavior script example (simplified version of GLO_SetStatusOnInit):
Code
INIT
CHARACTER:__Me
EXTERN STATUS:%StatusOnInit=DRUNK

EVENTS
EVENT SetStatusOnInit
ON
	OnInit()
ACTIONS
	IF "!c1"
		CharacterHasStatus(__Me,%StatusOnInit)
	THEN
		CharacterApplyStatus(__Me,%StatusOnInit,-1,1)
	ENDIF


Story script example:
Code
IF
CharacterEnteredTrigger(_Character, RC_FTJ_Autosave_AfterBridge_48254132-f413-44f1-8f92-263f201ef9d6)
THEN
ApplyStatus(_Character, "HASTED", -1.0, 1);


Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5