A_ChangeFlag

From ZDoom Wiki

Jump to: navigation, search

A_ChangeFlag (string flagname, bool value)

Changes the specified flag and sets it to the given value. Not all flags will produce useful results when changed in the game.

Example

actor CowardImp : DoomImp
{
states
{
Pain:
  TROO H 2 A_ChangeFlag("FRIGHTENED", 1)
  TROO H 2 A_Pain
  goto See
}
}

This imp will activate the FRIGHTENED flag when he enters his pain state, meaning when he gets hit he will attempt to flee from the attacker.

See Also

Actor flags

Personal tools