[Quest] Tomb of the Lightbringer

Edit: got reply from Kaelima and made a patch suggestion

Tested on TrinityCore Rev: 11462 Release Hash: 12b65aa206f1 (Unix, little-endian)

Problem: When doing the escort all seems to work just fine - except that the NPCs involved speak Draconic.

Expected: They speak the language of players.

I could have just reported the bug on the tracker, but I’d prefer to learn from the experience, so posting here. I hope that is OK.

I’m not sure where to fix this - the quest itself is here:

/src/server/scripts/EasternKingdoms/western_plaguelands.cpp

but I didn’t see any information about the language spoken - and I haven’t been able to find it in the world database (where I would expect it). So that’s why I ended posting my question here.

Could someone here enlighten me, please?

SAY_WP_0                    = -1800064,
...
DoScriptText(SAY_WP_0, me);

world_script_texts.sql

[SQL]
INSERT INTO script_texts (npc_entry,entry,content_default,content_loc1,content_loc2,content_loc3,content_loc4,content_loc5,content_loc6,content_loc7,content_loc8,sound,type,language,emote,comment) VALUES

(0,-1800064,‘Beware! We are attacked!’,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,11,1,‘npc_anchorite_truuen - SAY_WP_0’),
[/SQL]
Language is set to 11, change it to 0

[/CODE]

Oh, that’s pretty neat. Thanks a lot for the explanation! I guess common is a better choice for language since it’s Alliance only though.

So the fix could be:

-- Quest: Tomb of the Lightbringer, make Anchorite Truuen speak common UPDATE `script_texts` SET `language`='7' WHERE `entry`='-1800064'; UPDATE `script_texts` SET `language`='7' WHERE `entry`='-1800065'; UPDATE `script_texts` SET `language`='7' WHERE `entry`='-1800066'; UPDATE `script_texts` SET `language`='7' WHERE `entry`='-1800067'; UPDATE `script_texts` SET `language`='7' WHERE `entry`='-1800068'; UPDATE `script_texts` SET `language`='7' WHERE `entry`='-1800069'; UPDATE `script_texts` SET `language`='7' WHERE `entry`='-1800070';[/sql]

or the shorter version:

[sql]-- Quest: Tomb of the Lightbringer, make Anchorite Truuen speak common
UPDATE script_texts SET language=‘7’ WHERE comment LIKE ‘npc_anchorite_truuen%’;
I tested it and it seems to work perfectly.

-- Quest: Tomb of the Lightbringer, make Anchorite Truuen speak common UPDATE `script_texts` SET `language`=7 WHERE `comment` LIKE 'npc_anchorite_truuen%';[/sql]

Just wanting to say I posted it to the tracker as:

http://www.trinitycore.org/t/trinitycore/ticket/1327

So I assume this can be moved to “Completed”.

Actually any NEW cpp script is suppose to use the new creature_text table not the old script_text table.