Question about parsed sniffs and more


I would like to contribute to trinitycore and began sniffing on areas that previously were empty (like pandaria’s dungeons) to get the correct values for the database queries.

After pulling the sniffer (and modifying it a bit because it seems like it doesnt cope with the 6.x-Database) it generates queries like:

INSERT INTO creature (guid, id, map,…
(‘@CGUID+0’, 56812, 870, 0, 0, 1, 1

My question now is: how do you determine CGUID the correct way? Get the last insert ID and use that? Or are there specific creature GUIDs that are somewhere in the sniffs?

After sorting this out I would like to actually script the dungeon itself. I am a C# developer but I did some things in C++ aswell. Is there any literature concerning TrinityCore that you could recommend? Looking at the source of it, and spell scripts and so on, it looks fairly easy to understand. But lets say there is a spell which is not working yet, how do you begin fixing it? By sniffing it and then comparing the values?

I hope my questions are not too annoying. There are just some things I’d really love to know before going deep into this and doing it the wrong way :slight_smile:

Regarding the parser, the @CGUIDs can any free guid in the creature (or gameobject table), it’s set by us. For testing locally, you can use a high value like 600000. If you submit the fix to TC, when pushing your fix we’ll pick a better value for the guids (e.g one that fills gaps using

There’s currently a bug in the parser where it puts quotes around the @CGUID+X. That’s wrong. (@carbenium).

Regarding spell scripts, that might be a bit more difficult. There’s not really a book where it explains how to fix any spell (and that would probably be impossible to write down). You might be successful fixing most of the spells you need by looking at sniffs, checking what happens and/or looking at similar existing spell scripts and doing it similarly.

Thank you very much for your answer.

Yes I noticed that bug, i wrote a small Regular Expression for Notepad++ to deal with the quotes.