Skip to content

Commit

Permalink
[11958] Add support for no-fly-zone text message
Browse files Browse the repository at this point in the history
Signed-off-by: Schmoozerd <[email protected]>
  • Loading branch information
DomGries authored and Schmoozerd committed Apr 13, 2012
1 parent 5611602 commit 50e4ab6
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 4 deletions.
3 changes: 2 additions & 1 deletion sql/mangos.sql
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ CREATE TABLE `db_version` (
`version` varchar(120) default NULL,
`creature_ai_version` varchar(120) default NULL,
`cache_id` int(10) default '0',
`required_11955_02_mangos_command` bit(1) default NULL
`required_11958_01_mangos_mangos_string` bit(1) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Used DB version notes';

--
Expand Down Expand Up @@ -3845,6 +3845,7 @@ INSERT INTO `mangos_string` VALUES
(814,'Member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(815,'Initiate',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(816,'Your body is too exhausted to travel to the Spectral Realm.',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(817,'Warning: You\'ve entered a no-fly zone and are about to be dismounted!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(1000,'Exiting daemon...',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(1001,'Account deleted: %s',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
(1002,'Account %s NOT deleted (probably sql file format was updated)',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),
Expand Down
4 changes: 4 additions & 0 deletions sql/updates/11958_01_mangos_mangos_string.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
ALTER TABLE db_version CHANGE COLUMN required_11955_02_mangos_command required_11958_01_mangos_mangos_string bit;

DELETE FROM mangos_string WHERE entry=817;
INSERT INTO mangos_string VALUES (817,'Warning: You\'ve entered a no-fly zone and are about to be dismounted!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
3 changes: 2 additions & 1 deletion src/game/Language.h
Original file line number Diff line number Diff line change
Expand Up @@ -810,7 +810,8 @@ enum MangosStrings
LANG_GUILD_MEMBER = 814,
LANG_GUILD_INITIATE = 815,
LANG_FAIL_ENTER_SPECTRAL_REALM = 816,
// Room for in-game strings 817-999 not used
LANG_NO_FLY_ZONE = 817,
// Room for in-game strings 818-999 not used

// Level 4 (CLI only commands)
LANG_COMMAND_EXIT = 1000,
Expand Down
4 changes: 4 additions & 0 deletions src/game/SpellAuras.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
#include "GridNotifiersImpl.h"
#include "Vehicle.h"
#include "CellImpl.h"
#include "Language.h"

#define NULL_AURA_SLOT 0xFF

Expand Down Expand Up @@ -2147,6 +2148,9 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
case 54729: // Winged Steed of the Ebon Blade
Spell::SelectMountByAreaAndSkill(target, GetSpellProto(), 0, 0, 54726, 54727, 0);
return;
case 58600: // Restricted Flight Area
target->MonsterWhisper(LANG_NO_FLY_ZONE, target, true);
return;
case 62061: // Festive Holiday Mount
if (target->HasAuraType(SPELL_AURA_MOUNTED))
// Reindeer Transformation
Expand Down
2 changes: 1 addition & 1 deletion src/shared/revision_nr.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "11957"
#define REVISION_NR "11958"
#endif // __REVISION_NR_H__
2 changes: 1 addition & 1 deletion src/shared/revision_sql.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#ifndef __REVISION_SQL_H__
#define __REVISION_SQL_H__
#define REVISION_DB_CHARACTERS "required_11785_02_characters_instance"
#define REVISION_DB_MANGOS "required_11955_02_mangos_command"
#define REVISION_DB_MANGOS "required_11958_01_mangos_mangos_string"
#define REVISION_DB_REALMD "required_10008_01_realmd_realmd_db_version"
#endif // __REVISION_SQL_H__

0 comments on commit 50e4ab6

Please sign in to comment.