conditions
The `conditions` table
This table allows you to define conditions for various systems - Gossip, loot etc.
Structure
Field | Type | Attributes | Key | Null | Default | Extra | Comment |
mediumint(8) | signed | PRI | NO | 0 |
|
| |
mediumint(8) | unsigned | PRI | NO | 0 |
|
| |
mediumint(8) | signed | PRI | NO | 0 |
|
| |
int(11) | signed | PRI | NO | 0 |
| smart_scripts.source_type || 0 for everything else | |
mediumint(8) | unsigned | PRI | NO | 0 |
|
| |
mediumint(8) | signed | PRI | NO | 0 |
|
| |
tinyint(3) | unsigned | PRI | NO | 0 |
|
| |
int(10) | unsigned | PRI | NO | 0 |
|
| |
int(10) | unsigned | PRI | NO | 0 |
|
| |
int(10) | unsigned | PRI | NO | 0 |
|
| |
tinyint(3) | unsigned |
| NO | 0 |
| Boolean 0 or 1 (if NegativeCondition | |
mediumint(8) | unsigned |
| NO | 0 |
|
| |
mediumint(8) | unsigned |
| NO | 0 |
|
| |
char(64) | signed |
| NO | ' ' |
|
| |
varchar(255) |
|
| YES | NULL |
|
|
Description of the fields
SourceTypeOrReferenceId
if negative, then it is a reference template.
SourceTypeOrReferenceId | ID | SourceGroup | SourceEntry | ConditionTarget | Notes | |
|---|---|---|---|---|---|---|
CONDITION_SOURCE_TYPE_NONE | 0 | Always 0 | (See below) | Only used in Reference Templates! See below. | ||
CONDITION_SOURCE_TYPE_CREATURE_LOOT_TEMPLATE | 1 | creature_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_DISENCHANT_LOOT_TEMPLATE | 2 | disenchant_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_FISHING_LOOT_TEMPLATE | 3 | fishing_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_GAMEOBJECT_LOOT_TEMPLATE | 4 | gameobject_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_ITEM_LOOT_TEMPLATE | 5 | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
| |
CONDITION_SOURCE_TYPE_MAIL_LOOT_TEMPLATE | 6 | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
| |
CONDITION_SOURCE_TYPE_MILLING_LOOT_TEMPLATE | 7 | milling_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_PICKPOCKETING_LOOT_TEMPLATE | 8 | pickpocketing_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_PROSPECTING_LOOT_TEMPLATE | 9 | prospecting_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_REFERENCE_LOOT_TEMPLATE | 10 | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
| |
CONDITION_SOURCE_TYPE_SKINNING_LOOT_TEMPLATE | 11 | skinning_loot_template.Entry or reference_loot_template.Entry | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
|
CONDITION_SOURCE_TYPE_SPELL_LOOT_TEMPLATE | 12 | item id (_loot_template.Item or reference_loot_template.Item) | Always 0 | Always 0 |
| |
|
| Mask of effects to be affected by condition: | Spell Id from Spell DBC file | Always 0 | 0 : Potential spell Target | Don't use wowhead to get number of effects, data from wowhead sometimes doesn't match real effect number. |
CONDITION_SOURCE_TYPE_GOSSIP_MENU | 14 | gossip_menu.entry (gossip menu entry) | gossip_menu.text_id (points to npc_text.ID) | Always 0 | 0 = Player |
|
CONDITION_SOURCE_TYPE_GOSSIP_MENU_OPTION | 15 | gossip_menu_option.menu_id (menu entry) | Always 0 | 0 = Player |
| |
CONDITION_SOURCE_TYPE_CREATURE_TEMPLATE_VEHICLE | 16 | Always 0 | creature entry (creature_template.entry) | Always 0 | 0 = Player riding vehicle |
|
|
|
|
|
|
|
|
CONDITION_SOURCE_TYPE_SPELL_CLICK_EVENT | 18 | creature entry (npc_spellclick_spells.npc_entry) | Spell (npc_spellclick_spells.spell_id) | Always 0 | 0 = Clicker |
|
CONDITION_SOURCE_TYPE_QUEST_AVAILABLE | 19 | Always 0 | Always 0 | Always 0 | Condition must be met for quest to be available to player. | |
UNUSED | 20 |
|
|
|
|
|
|
| creature entry (creature_template.entry) |
|
| 0 = Player for whom spell bar is shown |
|
CONDITION_SOURCE_TYPE_SMART_EVENT | 22 | ID (smart_scripts.id) + 1 | EntryOrGuid (smart_scripts.entryorguid) | SourceType (smart_scripts.source_type) | 0 = Invoker |