Jump to content

Unhide


Avenger

Recommended Posts

More iwd2 action oneliners (most are trivial):

 

1. SetAreaFlags - sets or removes area flags stored at 0xc in .are files.

2. SetMusic - sets area music. SetMusic(DAY, MX_1000) would set the current area's day music to mx1000.mus (See music.ids/music.2da)

3. WaitAnimation - waits till the target object reaches the stance. WaitAnimation(MySelf, READY) would wait till the actor stops casting, attacking, etc.

4. SetCreatureAreaFlag - sets bits in the field we call "mc flags", this is stored in the creature at offset 0x10

it is possible to add other flags, like (NO_CORPSE) to the ids file - but the original mc flags are mostly useless in iwd2.

Link to comment

WaitAnimation actually waits if the target is in the specified stance (what we already have in gemrb). An example from Phaen, where it is extra clear:

 

IF

!IsMarkedSpell(MARKED_SPELL)

THEN

RESPONSE #100

Spell(SpellTarget,MARKED_SPELL)

WaitAnimation(Myself,WALK)

WaitAnimation(Myself,CONJURE)

WaitAnimation(Myself,CAST)

ForceMarkedSpell(MARKED_SPELL)

END

Don't start a new casting before the last one is finished (or the actor is moving before starting the cast). Otherwise, the wait blocks his whole script eventually.

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...