Description: All guards except Deathguard Elites & Stormwind Guards do not have the script to cast Shoot.
Current behaviour: They don't have the script to cast Shoot..
Expected behaviour:
They should be able to use the shoot ability (they already have a ranged weapon equipped).
Steps to reproduce the problem:
Branch(es): 3.3.5a
TC rev. hash/commit:
TrinityCore rev. ad796318e8c3 2018-03-02 02:57:23 -0300 (3.3.5 branch) (Win64, RelWithDebInfo, Static)
TDB version: 335.64
Operating system: Windows 10
Note: I was asked to create a new issue for the rest of the guards that don't have the script, I have been wondering since almost all guards use GuardAI could it be done using that? (Excluding Silvermoon City Guardians)
if you re-read the comments
you will notice that guards using GuardAI need changes in their C++ script, whereas Orgrimmar and Stormwind guards are involved in Death Knight final class quest to join the rest of Azeroth and therefore use SAI already.
So a solution here needs to be twofold: SAI for the Orgrimmar guards (Stormwind guards already received the Shoot ability in commit https://github.com/TrinityCore/TrinityCore/commit/20a0d27b5bcbc2c3a334edef37f6a05e653ca401) and C++ script update for GuardAI.
Note: For any contributor ambitious enough, there is always the solution to re-write the Death Knight final quest phase in C++ and make all the guards use GuardAI instead of SAI.
edit: Linked content for those who would like to know more about the GuardAI script:
https://github.com/TrinityCore/TrinityCore/blob/efef6b5e36a8cd8eca023b8aa6a5d8cbd532ca68/src/server/game/AI/CoreAI/GuardAI.cpp#L18-L77
Or update GuardAI to include the spell shoot, and will not modify SAI behaviour for the DK quest
Partially what I was going for in sentence 2 in my previous comment, but maybe I should have rephrased it to make it easier to read.
I still don't understand too much about the whole "GuardAI" thing, but here is the fix for Orgrimmar Grunts and Kor'kron Elites, as well as for Stormwind City Patroller and Stormwind Royal Guard (all these NPCs are already using SmartAI scripts). I also updated the script for Stormwind City Guard to make them stop for a few seconds when performing emote reactions if they have waypoint movement.
``sql
-- Stormwind City Guard
DELETE FROMsmart_scriptsWHEREentryorguidIN (6800,6801,6802,6803,6804) ANDsource_type=9;
INSERT INTOsmart_scripts(entryorguid,source_type,id,link,event_type,event_phase_mask,event_chance,event_flags,event_param1,event_param2,event_param3,event_param4,action_type,action_param1,action_param2,action_param3,action_param4,action_param5,action_param6,target_type,target_param1,target_param2,target_param3,target_x,target_y,target_z,target_o,comment`) VALUES
(6800,9,0,0,0,0,100,0,0,0,0,0,103,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted On"),
(6800,9,1,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6800,9,2,0,0,0,100,0,2000,2000,0,0,5,3,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Play Emote 'Wave'"),
(6800,9,3,0,0,0,100,0,4000,4000,0,0,66,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6800,9,4,0,0,0,100,0,0,0,0,0,103,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted Off"),
(6801,9,0,0,0,0,100,0,0,0,0,0,103,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted On"),
(6801,9,1,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6801,9,2,0,0,0,100,0,2000,2000,0,0,5,66,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Play Emote 'Salute'"),
(6801,9,3,0,0,0,100,0,4000,4000,0,0,66,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6801,9,4,0,0,0,100,0,0,0,0,0,103,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted Off"),
(6802,9,0,0,0,0,100,0,0,0,0,0,103,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted On"),
(6802,9,1,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6802,9,2,0,0,0,100,0,2000,2000,0,0,5,2,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Play Emote 'Bow'"),
(6802,9,3,0,0,0,100,0,4000,4000,0,0,66,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6802,9,4,0,0,0,100,0,0,0,0,0,103,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted Off"),
(6803,9,0,0,0,0,100,0,0,0,0,0,103,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted On"),
(6803,9,1,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6803,9,2,0,0,0,100,0,2000,2000,0,0,5,23,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Play Emote 'Flex'"),
(6803,9,3,0,0,0,100,0,4000,4000,0,0,66,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6803,9,4,0,0,0,100,0,0,0,0,0,103,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted Off"),
(6804,9,0,0,0,0,100,0,0,0,0,0,103,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted On"),
(6804,9,1,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,7,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6804,9,2,0,0,0,100,0,2000,2000,0,0,5,25,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Play Emote 'Point'"),
(6804,9,3,0,0,0,100,0,4000,4000,0,0,66,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Orientation"),
(6804,9,4,0,0,0,100,0,0,0,0,0,103,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Guard - On Script - Set Rooted Off");
-- Stormwind City Patroller
DELETE FROM smart_scripts WHERE entryorguid=1976 AND source_type=0 AND id IN (1,2,3,4,5,6,7,8,9,10,11);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(1976,0,1,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Stormwind City Patroller - In Combat - Cast 'Shoot'"),
(1976,0,2,0,9,0,100,0,0,5,11000,14000,11,12169,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - Within 0-5 Range - Cast 'Shield Block'"),
(1976,0,3,0,0,0,100,0,5000,9000,8000,13000,11,12170,0,0,0,0,0,2,0,0,0,0,0,0,0,"Stormwind City Patroller - In Combat - Cast 'Revenge'"),
(1976,0,4,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - On Received Emote 'Wave' - Run Script"),
(1976,0,5,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - On Received Emote 'Salute' - Run Script"),
(1976,0,6,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - On Received Emote 'Kiss' - Run Script"),
(1976,0,7,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - On Received Emote 'Shy' - Run Script"),
(1976,0,8,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - On Received Emote 'Rude' - Run Script"),
(1976,0,9,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - On Received Emote 'Chicken' - Run Script"),
(1976,0,10,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind City Patroller - On Received Emote 'Bow' - Run Script");
-- Stormwind Royal Guard
DELETE FROM smart_scripts WHERE entryorguid=1756 AND source_type=0 AND id IN (1,2,3,4,5,6,7,8,9,10);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(1756,0,1,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Stormwind Royal Guard - In Combat - Cast 'Shoot'"),
(1756,0,2,0,9,0,100,0,0,5,11000,14000,11,12169,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - Within 0-5 Range - Cast 'Shield Block'"),
(1756,0,3,0,0,0,100,0,5000,9000,8000,13000,11,12170,0,0,0,0,0,2,0,0,0,0,0,0,0,"Stormwind Royal Guard - In Combat - Cast 'Revenge'"),
(1756,0,4,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - On Received Emote 'Wave' - Run Script"),
(1756,0,5,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - On Received Emote 'Salute' - Run Script"),
(1756,0,6,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - On Received Emote 'Kiss' - Run Script"),
(1756,0,7,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - On Received Emote 'Shy' - Run Script"),
(1756,0,8,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - On Received Emote 'Rude' - Run Script"),
(1756,0,9,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - On Received Emote 'Chicken' - Run Script"),
(1756,0,10,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Royal Guard - On Received Emote 'Bow' - Run Script");
-- Orgrimmar Grunt
DELETE FROM smart_scripts WHERE entryorguid=3296 AND source_type=0 AND id IN (1,2,3,4,5,6,7,8,9,10,11);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(3296,0,1,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Orgrimmar Grunt - In Combat - Cast 'Shoot'"),
(3296,0,2,0,0,0,100,0,5000,9000,8000,13000,11,40505,0,0,0,0,0,2,0,0,0,0,0,0,0,"Orgrimmar Grunt - In Combat - Cast 'Cleave'"),
(3296,0,3,0,2,0,100,1,0,30,0,0,11,8599,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - Between 0-30% Health - Cast 'Enrage' (No Repeat)"),
(3296,0,4,0,2,0,100,1,0,30,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - Between 0-30% Health - Say Line 0 (No Repeat)"),
(3296,0,5,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - On Received Emote 'Wave' - Run Script"),
(3296,0,6,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - On Received Emote 'Salute' - Run Script"),
(3296,0,7,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - On Received Emote 'Kiss' - Run Script"),
(3296,0,8,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - On Received Emote 'Shy' - Run Script"),
(3296,0,9,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - On Received Emote 'Rude' - Run Script"),
(3296,0,10,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - On Received Emote 'Chicken' - Run Script"),
(3296,0,11,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Grunt - On Received Emote 'Bow' - Run Script");
DELETE FROM creature_text WHERE CreatureID=3296 AND GroupID=0;
INSERT INTO creature_text (CreatureID, GroupID, ID, Text, Type, Language, Probability, Emote, Duration, Sound, BroadcastTextId, TextRange, comment) VALUES
(3296,0,0,"%s becomes enraged!",16,0,100,0,0,0,10677,0,"Orgrimmar Grunt");
-- Kor'kron Elite
DELETE FROM smart_scripts WHERE entryorguid=14304 AND source_type=0 AND id IN (1,2,3,4,5,6,7,8,9,10,11);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(14304,0,1,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Kor'kron Elite - In Combat - Cast 'Shoot'"),
(14304,0,2,0,0,0,100,0,5000,9000,8000,13000,11,40505,0,0,0,0,0,2,0,0,0,0,0,0,0,"Kor'kron Elite - In Combat - Cast 'Cleave'"),
(14304,0,3,0,2,0,100,0,0,30,120000,120000,11,8599,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - Between 0-30% Health - Cast 'Enrage'"),
(14304,0,4,0,2,0,100,1,0,30,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - Between 0-30% Health - Say Line 1 (No Repeat)"),
(14304,0,5,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - On Received Emote 'Wave' - Run Script"),
(14304,0,6,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - On Received Emote 'Salute' - Run Script"),
(14304,0,7,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - On Received Emote 'Kiss' - Run Script"),
(14304,0,8,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - On Received Emote 'Shy' - Run Script"),
(14304,0,9,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - On Received Emote 'Rude' - Run Script"),
(14304,0,10,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - On Received Emote 'Chicken' - Run Script"),
(14304,0,11,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Kor'kron Elite - On Received Emote 'Bow' - Run Script");
DELETE FROM creature_text WHERE CreatureID=14304 AND GroupID=1;
INSERT INTO creature_text (CreatureID, GroupID, ID, Text, Type, Language, Probability, Emote, Duration, Sound, BroadcastTextId, TextRange, comment) VALUES
(14304,1,0,"%s becomes enraged!",16,0,100,0,0,0,10677,0,"Kor'kron Elite");
As for the rest of the guards, if someone wants to update "GuardAI" to include the spell 'Shoot', might also include the emote reactions (are the same for every guard).
Also, guards are supposed to have some combat spells/abilities, not just the normal melee attacks. For instance:
Bluffwatchers cast 'Cleave' & 'Net'
Ironforge Guards cast 'Thunderclap' & 'Sunder Armor'
How can that be handled using the same script for everyone?
Different abilities would need to be defined via C++ script conditions and have each guard NPC entry defined in enumeration (no "magic" numbers). So it would basically be the C++ script parallel to the SAI guard scripts, without being divided into columns and always using enum referencing for creatures and spells throughout the script.
1- This guards (68,1756,1976,3296,14304) using SAI are scripted correctly now. (DONE)
2- This guards using SAI have probably some missing scripts: (DONE)
SELECT * FROM smart_scripts WHERE entryorguid IN (2405, 2621, 23257, 20556, 7980, 12996, 14375, 17855, 14376, 16222, 14377, 15184);
3- Combat script for guards using cpp is missing
4- Guards without any script:
SELECT * FROM `creature_template` WHERE AIName="" AND ScriptName="" AND `flags_extra`=32768;
5- This is a list of all npcs that have a faction related to guard behavior:
``sql
SELECT * FROMcreature_templateWHEREfaction` IN (11,57,71,79,85,105,150, 877,1054,1495, 1603,1639,1645,1647,1650,1656,1666,1668,1721, 1775,1819,1835,1874,1891,2024,2085,2130,2132, 1245,1625,1661,1726,1863,1837,1870);
Here are the missing scripts for the guards you pointed out, @Killyana, except for Silvermoon City Guardians (16222). I couldn't find their spells/abilities.
``sql
-- Tarren Mill Deathguard
DELETE FROMsmart_scriptsWHEREentryorguid=2405 ANDsource_type=0 ANDidIN (1,2,3,4,5,6,7,8,9,10);
INSERT INTOsmart_scripts(entryorguid,source_type,id,link,event_type,event_phase_mask,event_chance,event_flags,event_param1,event_param2,event_param3,event_param4,action_type,action_param1,action_param2,action_param3,action_param4,action_param5,action_param6,target_type,target_param1,target_param2,target_param3,target_x,target_y,target_z,target_o,comment`) VALUES
(2405,0,1,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Tarren Mill Deathguard - In Combat - Cast 'Shoot'"),
(2405,0,2,0,9,0,100,0,0,5,11000,14000,11,12169,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - Within 0-5 Range - Cast 'Shield Block'"),
(2405,0,3,0,0,0,100,0,5000,9000,8000,13000,11,12170,0,0,0,0,0,2,0,0,0,0,0,0,0,"Tarren Mill Deathguard - In Combat - Cast 'Revenge'"),
(2405,0,4,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - On Received Emote 'Wave' - Run Script"),
(2405,0,5,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - On Received Emote 'Salute' - Run Script"),
(2405,0,6,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - On Received Emote 'Kiss' - Run Script"),
(2405,0,7,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - On Received Emote 'Shy' - Run Script"),
(2405,0,8,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - On Received Emote 'Rude' - Run Script"),
(2405,0,9,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - On Received Emote 'Chicken' - Run Script"),
(2405,0,10,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Tarren Mill Deathguard - On Received Emote 'Bow' - Run Script");
UPDATE creature_text SET Language=33 WHERE CreatureID=2405; -- Fix language for Tarren Mill Deathguard's aggro text
-- Hammerfall Guardian
DELETE FROM smart_scripts WHERE entryorguid=2621 AND source_type=0;
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(2621,0,0,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Hammerfall Guardian - In Combat - Cast 'Shoot'"),
(2621,0,1,0,9,0,100,0,0,5,11000,14000,11,12169,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - Within 0-5 Range - Cast 'Shield Block'"),
(2621,0,2,0,0,0,100,0,5000,9000,8000,13000,11,12170,0,0,0,0,0,2,0,0,0,0,0,0,0,"Hammerfall Guardian - In Combat - Cast 'Revenge'"),
(2621,0,3,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - On Received Emote 'Wave' - Run Script"),
(2621,0,4,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - On Received Emote 'Salute' - Run Script"),
(2621,0,5,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - On Received Emote 'Kiss' - Run Script"),
(2621,0,6,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - On Received Emote 'Shy' - Run Script"),
(2621,0,7,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - On Received Emote 'Rude' - Run Script"),
(2621,0,8,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - On Received Emote 'Chicken' - Run Script"),
(2621,0,9,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Hammerfall Guardian - On Received Emote 'Bow' - Run Script");
-- Skyguard Windcharger
DELETE FROM smart_scripts WHERE entryorguid=23257 AND source_type=0 AND id=1;
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(23257,0,1,0,9,0,100,0,0,20,12000,16000,11,12024,0,0,0,0,0,2,0,0,0,0,0,0,0,"Skyguard Windcharger - Within 0-20 Range - Cast 'Net'");
-- Stormwind Marine
DELETE FROM smart_scripts WHERE entryorguid=20556 AND source_type=0 AND id IN (2,3,4,5,6,7,8,9);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(20556,0,2,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Stormwind Marine - In Combat - Cast 'Shoot'"),
(20556,0,3,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Marine - On Received Emote 'Wave' - Run Script"),
(20556,0,4,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Marine - On Received Emote 'Salute' - Run Script"),
(20556,0,5,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Marine - On Received Emote 'Kiss' - Run Script"),
(20556,0,6,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Marine - On Received Emote 'Shy' - Run Script"),
(20556,0,7,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Marine - On Received Emote 'Rude' - Run Script"),
(20556,0,8,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Marine - On Received Emote 'Chicken' - Run Script"),
(20556,0,9,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Marine - On Received Emote 'Bow' - Run Script");
UPDATE creature_template SET npcflag=0, IconName=NULL WHERE entry=20556; -- They don't give directions and don't have gossip text
-- Deathguard Elite
DELETE FROM smart_scripts WHERE entryorguid=7980 AND source_type=0 AND id IN (1,2,3,4,5,6,7,8,9,10);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(7980,0,1,0,25,0,100,0,0,0,0,0,11,18950,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Reset - Cast 'Invisibility and Stealth Detection'"),
(7980,0,2,0,0,0,100,0,5000,7000,7000,10000,11,14516,0,0,0,0,0,2,0,0,0,0,0,0,0,"Deathguard Elite - In Combat - Cast 'Strike'"),
(7980,0,3,0,9,0,100,0,0,5,12000,16000,11,9080,0,0,0,0,0,2,0,0,0,0,0,0,0,"Deathguard Elite - Within 0-5 Range - Cast 'Hamstring'"),
(7980,0,4,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Received Emote 'Wave' - Run Script"),
(7980,0,5,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Received Emote 'Salute' - Run Script"),
(7980,0,6,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Received Emote 'Kiss' - Run Script"),
(7980,0,7,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Received Emote 'Shy' - Run Script"),
(7980,0,8,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Received Emote 'Rude' - Run Script"),
(7980,0,9,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Received Emote 'Chicken' - Run Script"),
(7980,0,10,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Deathguard Elite - On Received Emote 'Bow' - Run Script");
-- Mounted Ironforge Mountaineer
DELETE FROM smart_scripts WHERE entryorguid=12996 AND source_type=0 AND id IN (2,3,4,5,6,7,8,9);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(12996,0,2,0,22,0,100,0,101,5000,5000,0,80,6800,0,0,0,0,0,1,0,0,0,0,0,0,0,"Mounted Ironforge Mountaineer - On Received Emote 'Wave' - Run Script"),
(12996,0,3,0,22,0,100,0,78,5000,5000,0,80,6801,0,0,0,0,0,1,0,0,0,0,0,0,0,"Mounted Ironforge Mountaineer - On Received Emote 'Salute' - Run Script"),
(12996,0,4,0,22,0,100,0,58,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Mounted Ironforge Mountaineer - On Received Emote 'Kiss' - Run Script"),
(12996,0,5,0,22,0,100,0,84,5000,5000,0,80,6803,0,0,0,0,0,1,0,0,0,0,0,0,0,"Mounted Ironforge Mountaineer - On Received Emote 'Shy' - Run Script"),
(12996,0,6,0,22,0,100,0,77,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Mounted Ironforge Mountaineer - On Received Emote 'Rude' - Run Script"),
(12996,0,7,0,22,0,100,0,22,5000,5000,0,80,6804,0,0,0,0,0,1,0,0,0,0,0,0,0,"Mounted Ironforge Mountaineer - On Received Emote 'Chicken' - Run Script"),
(12996,0,8,0,22,0,100,0,17,5000,5000,0,80,6802,0,0,0,0,0,1,0,0,0,0,0,0,0,"Mounted Ironforge Mountaineer - On Received Emote 'Bow' - Run Script");
UPDATE creature_template SET gossip_menu_id=2121 WHERE entry=12996; -- Add gossip text
-- Scout Stronghand
DELETE FROM smart_scripts WHERE entryorguid=14375 AND source_type=0 AND id IN (1,2,3);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(14375,0,1,0,9,0,100,0,0,30,8000,12000,11,14030,0,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Stronghand - Within 0-30 Range - Cast 'Hooked Net'"),
(14375,0,2,0,0,0,100,0,5000,7000,5000,9000,11,15572,0,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Stronghand - In Combat - Cast 'Sunder Armor'"),
(14375,0,3,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Stronghand - In Combat - Cast 'Shoot'");
-- Expedition Warden
DELETE FROM smart_scripts WHERE entryorguid=17855 AND source_type=0;
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(17855,0,0,0,9,0,100,0,0,20,12000,16000,11,12024,0,0,0,0,0,2,0,0,0,0,0,0,0,"Expedition Warden - Within 0-20 Range - Cast 'Net'"),
(17855,0,1,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Expedition Warden - In Combat - Cast 'Shoot'"),
(17855,0,2,0,4,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Expedition Warden - On Aggro - Cast Say Line 0");
DELETE FROM creature_text WHERE CreatureID=17855;
INSERT INTO creature_text (CreatureID, GroupID, ID, Text, Type, Language, Probability, Emote, Duration, Sound, BroadcastTextId, TextRange, comment) VALUES
(17855,0,0,"Taste blade, mongrel!",12,0,100,0,0,0,10950,0,"Expedition Warden"),
(17855,0,1,"Please tell me that you didn't just do what I think you just did. Please tell me that I'm not going to have to hurt you...",12,0,100,0,0,0,10951,0,"Expedition Warden"),
(17855,0,2,"As if we don't have enough problems, you go and create more!",12,0,100,0,0,0,10953,0,"Expedition Warden"),
(17855,0,3,"You dare spill blood on neutral ground? OUT! OUT, I SAY!",12,0,100,0,0,0,10948,0,"Expedition Warden"),
(17855,0,4,"We don't take kindly to miscreants, $r.",12,0,100,0,0,0,10949,0,"Expedition Warden"),
(17855,0,5,"Get a rope!",12,0,100,0,0,0,10952,0,"Expedition Warden"),
(17855,0,6,"Believe me when I tell you this: You're gonna wish you weren't born, sissy!",12,0,100,0,0,0,10954,0,"Expedition Warden"),
(17855,0,7,"Your actions shame us all, $c. I hurt inside as I beat you senseless.",12,0,100,0,0,0,10955,0,"Expedition Warden");
-- Scout Manslayer
DELETE FROM smart_scripts WHERE entryorguid=14376 AND source_type=0 AND id IN (1,2,3);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(14376,0,1,0,9,0,100,0,0,30,8000,12000,11,14030,0,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Manslayer - Within 0-30 Range - Cast 'Hooked Net'"),
(14376,0,2,0,0,0,100,0,5000,7000,5000,9000,11,15572,0,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Manslayer - In Combat - Cast 'Sunder Armor'"),
(14376,0,3,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Manslayer - In Combat - Cast 'Shoot'");
-- Scout Tharr
DELETE FROM smart_scripts WHERE entryorguid=14377 AND source_type=0 AND id IN (1,2,3);
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(14377,0,1,0,9,0,100,0,0,30,8000,12000,11,14030,0,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Tharr - Within 0-30 Range - Cast 'Hooked Net'"),
(14377,0,2,0,0,0,100,0,5000,7000,5000,9000,11,15572,0,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Tharr - In Combat - Cast 'Sunder Armor'"),
(14377,0,3,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Scout Tharr - In Combat - Cast 'Shoot'");
-- Cenarion Hold Infantry
DELETE FROM smart_scripts WHERE entryorguid=15184 AND source_type=0 AND id=4;
INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES
(15184,0,4,0,0,0,100,0,0,0,2000,4000,11,6660,64,0,0,0,0,2,0,0,0,0,0,0,0,"Cenarion Hold Infantry - In Combat - Cast 'Shoot'");
I can confirm these SQL fixes work, just tested them. :-)
EDIT: Testing ZenoX92's latest one now. :-) (Working! :-))
For Silvermoon City Guardians (16222) they must say some texts, but I cannot find when:
``sql
DELETE FROMcreature_textWHERECreatureID=16222;
INSERT INTOcreature_text(CreatureID,GroupID,ID,Text,Type,Language,Probability,Emote,Duration,Sound,BroadcastTextId,TextRange,comment`) VALUES
(16222,0,0,"Even the Light is no match for the indomitable will of our people.",12,1,100,0,0,0,14793,0,"Silvermoon City Guardian"),
(16222,0,1,"Glory to the Sun K-- ah... Silvermoon!",12,1,100,0,0,0,14807,0,"Silvermoon City Guardian"),
(16222,0,2,"Our lives are yours, Blood Knight.",12,1,100,0,0,0,14791,0,"Silvermoon City Guardian"),
(16222,0,3,"Your power strengthens us all.",12,1,100,0,0,0,14792,0,"Silvermoon City Guardian");
So probably this is missing:
``sql
DELETE FROMsmart_scriptsWHEREsource_type=9 ANDentryorguidIN (1814603,1814604) ANDsource_type=9 ANDid>1;
INSERT INTOsmart_scripts(entryorguid,source_type,id,link,event_type,event_phase_mask,event_chance,event_flags,event_param1,event_param2,event_param3,event_param4,action_type,action_param1,action_param2,action_param3,action_param4,action_param5,action_param6,target_type,target_param1,target_param2,target_param3,target_x,target_y,target_z,target_o,comment`) VALUES
(1814603,9,2,0,0,0,100,0,1000,1000,0,0,1,2,0,0,0,0,0,19,16222,10,0,0,0,0,0,'Champion Vranesh - Script 3 - Silvermoon City Guardian say 2'),
(1814604,9,2,0,0,0,100,0,1000,1000,0,0,1,2,0,0,0,0,0,19,16222,10,0,0,0,0,0,'Champion Vranesh - Script 3 - Silvermoon City Guardian say 3');
DELETE FROM creature_text WHERE CreatureID=16222 AND GroupID>1;
INSERT INTO creature_text (CreatureID, GroupID, ID, Text, Type, Language, Probability, Emote, Duration, Sound, BroadcastTextId, TextRange, comment) VALUES
(16222,2,0,"Even the Light is no match for the indomitable will of our people.",12,1,100,0,0,0,14793,0,"Silvermoon City Guardian"),
(16222,3,0,"Your power strengthens us all.",12,1,100,0,0,0,14792,0,"Silvermoon City Guardian");
To do list:
I did some tests on live for the emotes, to see to which ones they respond. Here are my findings.
Stormwind City Guard:
Stormwind Royal Guard:
Ironforge Guard:
/kiss
/wave
/salute
/shy
/rude
/chicken
Stormwind City Patroller:
Darnassus Sentinel:
Deathguard Elite:
Bluffwatcher:
/salute
Orgrimmar Grunt:
/kiss
/wave
/salute
None of the guards i tried responded to /bow at all. There is no way to check if they responded to the same emotes in 3.3.5 without a time machine obviously, but it seemed reasonable to assume that this hasn't changed.
They will bow at you if you kiss them
I mentioned that some respond to /kiss. My list is about which emotes the NPCs respond to from the player, not which ones they reply with in return. If you do /bow at them, none of the guards i tested do anything.
Afaik this was implemented for some guards 10+ years ago
There is no way to check if they responded to the same emotes in 3.3.5
Btw wowhead comments is a good source for that