Denizen/Commands/Flag

From Citizens Wiki

< Denizen‎ | Commands

Revision as of 15:35, 18 June 2013 by Morphan1 (talk | contribs) (Created page with "== Introduction == Flags are variables that can be checked anywhere in a script and in other scripts by using flag replaceable tags or the flagged requirement. A flag can be p...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Introduction

Flags are variables that can be checked anywhere in a script and in other scripts by using flag replaceable tags or the flagged requirement. A flag can be placed on the player, the NPC or globally. Flags placed on a player only apply to that player, and flags placed on an NPC only apply to that individual NPC based on its ID, so NPCs with the same name have different flags because they have different IDs. However, a global flag applies to the entire server and can easily be read from any script.

If a flag's type (player, npc or global) is not specified, the flag is placed on the player by default, and if a value for the flag is not specified, the value is "true" by default.

Usage

Examples