f.jpg

Description of the MaNGOSZero conditions Table.

With this table and the new conditions it is possible to create tree like and very complicated combined conditions (like HasAura && (HasItem || HasQuest)) Used in: DBScript gossip_menu gossip_menu_option npc_spellclick_spells spell_area

Table Notes

This table uses the 'MyISAM' DB Engine

The Field definitions follow
Field Name Field Type Nullable Key Default Value Attributes Notes
condition_entry mediumint(8) unsigned NO PRI NULL 'auto_increment' Identifier
type tinyint(3) NO MUL '0'   Type of the condition.
value1 mediumint(8) unsigned NO   '0'   Data field One for the condition.
value2 mediumint(8) unsigned NO   '0'   Data field Two for the condition.

Description of the fields

'condition_entry' mediumint(8) unsigned

Identifier

'type' tinyint(3)

Type of the condition:

ID Type Description
-3 CONDITION_NOT Used to evaluate if another condition is NOT true.
-2 CONDITION_OR Used to evaluate if condition OR condition is true.
-1 CONDITION_AND Used to evaluate if condition AND condition is true.
0 CONDITION_NONE This condition is not used at all.
1 CONDITION_AURA Checks target currently has the specified aura on him/her.
2 CONDITION_ITEM Checks if the player has the required amount (value2) of items in his/hers inventory.
3 CONDITION_ITEM_EQUIPPED Checks if the player has the specified item equipped.
4 CONDITION_AREAID Checks if the player is within the specified area.
5 CONDITION_REPUTATION_RANK_MIN Checks if the player has the minimum required reputation rank with a specific faction.
6 CONDITION_TEAM Checks what team the target is a member of.
7 CONDITION_SKILL Checks if the player has the required minimum skill value of the specified skill.
8 CONDITION_QUESTREWARDED Checks if the player has been rewarded for the specified quest.
9 CONDITION_QUESTTAKEN Checks if the player has taken the quest (as in has it in his/hers quest log.)
10 CONDITION_AD_COMMISSION_AURA TODO
11 CONDITION_NO_AURA Checks if the target DOES NOT currently have the specified aura on him/her.
12 CONDITION_ACTIVE_GAME_EVENT Checks if a game event is currently active.
13 CONDITION_AREA_FLAG Checks if area_flag is present in current area (if area_flag set != 0) AND if not_have_flag is not present in current area (if not_have_flag != 0)
14 CONDITION_RACE_CLASS Checks if the target is a certain race AND/OR class.
15 CONDITION_LEVEL Checks the targets level.
16 CONDITION_NOITEM Checks if the player DOES NOT have the required amount (value2) of items in his/hers inventory.
17 CONDITION_SPELL Checks if the target has or hasn’t (value2) the specified spell.
18 CONDITION_INSTANCE_SCRIPT TODO
19 CONDITION_QUESTAVAILABLE Checks if the specified quest is available (can start it) for the player.
20 CONDITION_RESERVED_1 Reserved for later usage
21 CONDITION_RESERVED_2 Reserved for later usage
22 CONDITION_QUEST_NONE Checks if the player has NOT taken the quest AND has NOT been rewarded for the quest.
23 CONDITION_ITEM_WITH_BANK Checks if the player has the required amount (value2) of items in his/hers inventory OR bank.
24 CONDITION_NOITEM_WITH_BANK Checks if the player DOES NOT have count (value2) of items in his/hers inventory OR bank.
25 CONDITION_NOT_ACTIVE_GAME_EVENT Checks if a game event is currently NOT active.
26 CONDITION_ACTIVE_HOLIDAY Checks if a holiday is active
27 CONDITION_NOT_ACTIVE_HOLIDAY Checks if a holiday is not active
28 CONDITION_LEARNABLE_ABILITY Checks if the player can learn ability (using minimum skill value from SkillLineAbility.dbc.) If the player has spell or has item (when defined) the condition will evaluate to false.
29 CONDITION_SKILL_BELOW TODO
30 CONDITION_REPUTATION_RANK_MAX Checks if the player has a higher reputation rank than specified a faction.
31 CONDITION_RESERVED_3 Reserved for later usage
32 CONDITION_SOURCE_AURA Checks if the source of the condition (like looted npc) has an aura.
33 CONDITION_LAST_WAYPOINT Checks the waypoint-state of the source of the condition.
34 CONDITION_RESERVED_4 Reserved for later usage
35 CONDITION_GENDER Checks the gender of a player.
36 CONDITION_DEAD_OR_AWAY Checks if a player, a player's group, all players in an instance, or a creature is dead or left the map.
37 CONDITION_CREATURE_IN_RANGE Checks if the creature (alive) is in the defined range.
38 CONDITION_GAMEOBJECT_IN_RANGE Checks if the gameobject is in the range.

'value1' mediumint(8) unsigned

Data field One for the condition.

'value2' mediumint(8) unsigned

Data field Two for the condition.

Condition Types:

ID Type Description
-3 CONDITION_NOT Used to evaluate if another condition is NOT true.
-2 CONDITION_OR Used to evaluate if condition OR condition is true.
-1 CONDITION_AND Used to evaluate if condition AND condition is true.
0 CONDITION_NONE This condition is not used at all.
1 CONDITION_AURA Checks target currently has the specified aura on him/her.
2 CONDITION_ITEM Checks if the player has the required amount (value2) of items in his/hers inventory.
3 CONDITION_ITEM_EQUIPPED Checks if the player has the specified item equipped.
4 CONDITION_AREAID Checks if the player is within the specified area.
5 CONDITION_REPUTATION_RANK_MIN Checks if the player has the minimum required reputation rank with a specific faction.
6 CONDITION_TEAM Checks what team the target is a member of.
7 CONDITION_SKILL Checks if the player has the required minimum skill value of the specified skill.
8 CONDITION_QUESTREWARDED Checks if the player has been rewarded for the specified quest.
9 CONDITION_QUESTTAKEN Checks if the player has taken the quest (as in has it in his/hers quest log.)
10 CONDITION_AD_COMMISSION_AURA TODO
11 CONDITION_NO_AURA Checks if the target DOES NOT currently have the specified aura on him/her.
12 CONDITION_ACTIVE_GAME_EVENT Checks if a game event is currently active.
13 CONDITION_AREA_FLAG Checks if area_flag is present in current area (if area_flag set != 0) AND if not_have_flag is not present in current area (if not_have_flag != 0)
14 CONDITION_RACE_CLASS Checks if the target is a certain race AND/OR class.
15 CONDITION_LEVEL Checks the targets level.
16 CONDITION_NOITEM Checks if the player DOES NOT have the required amount (value2) of items in his/hers inventory.
17 CONDITION_SPELL Checks if the target has or hasn’t (value2) the specified spell.
18 CONDITION_INSTANCE_SCRIPT TODO
19 CONDITION_QUESTAVAILABLE Checks if the specified quest is available (can start it) for the player.
20 CONDITION_RESERVED_1 Reserved for later usage
21 CONDITION_RESERVED_2 Reserved for later usage
22 CONDITION_QUEST_NONE Checks if the player has NOT taken the quest AND has NOT been rewarded for the quest.
23 CONDITION_ITEM_WITH_BANK Checks if the player has the required amount (value2) of items in his/hers inventory OR bank.
24 CONDITION_NOITEM_WITH_BANK Checks if the player DOES NOT have count (value2) of items in his/hers inventory OR bank.
25 CONDITION_NOT_ACTIVE_GAME_EVENT Checks if a game event is currently NOT active.
26 CONDITION_ACTIVE_HOLIDAY Checks if a holiday is active
27 CONDITION_NOT_ACTIVE_HOLIDAY Checks if a holiday is not active
28 CONDITION_LEARNABLE_ABILITY Checks if the player can learn ability (using minimum skill value from SkillLineAbility.dbc.) If the player has spell or has item (when defined) the condition will evaluate to false.
29 CONDITION_SKILL_BELOW TODO
30 CONDITION_REPUTATION_RANK_MAX Checks if the player has a higher reputation rank than specified a faction.
31 CONDITION_RESERVED_3 Reserved for later usage
32 CONDITION_SOURCE_AURA Checks if the source of the condition (like looted npc) has an aura.
33 CONDITION_LAST_WAYPOINT Checks the waypoint-state of the source of the condition.
34 CONDITION_RESERVED_4 Reserved for later usage
35 CONDITION_GENDER Checks the gender of a player.
36 CONDITION_DEAD_OR_AWAY Checks if a player, a player's group, all players in an instance, or a creature is dead or left the map.
37 CONDITION_CREATURE_IN_RANGE Checks if the creature (alive) is in the defined range.
38 CONDITION_GAMEOBJECT_IN_RANGE Checks if the gameobject is in the range.

 

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注

Captcha Code