Tuto 6xx Repair quests with Keira2 & SAI-Editor

dokuro

Veteran Member
Verified Member
31
2020
8
Location
Paris
Repair quests with Keira2 & SAI-Editor
keira.jpg
The necessary tools:

Keira2
SAI-Editor
The site Actualites concernant World of Warcraft : Shadowlands
PHPMyAdmin or equivalent


Intro

Doing a tutorial to fix quests is a bit like wanting to go pick up salads on the moon by bike ... it's impossible ... because there are a lot of different types of bugs and for each one several ways to do . I will therefore touch on the subject without going into too much detail but in the end you will have identified Keira2 and the concept for repairing the quests. Be aware that there is still a miracle solution that adapts to almost any case, it is the 6d killcredit.

The bugs on these quests can be roughly of 2 different types: one of the data is missing, it is wrong or the whole quest or one of these branches does not exist.

To repair these quests in general we will use Keira2 for all that is quest definitions and SAI-Editor to fulfill these conditions. I would invite you before continuing to read the tutorial on SAI-Editor, to experience it a little bit to begin to understand it.

Keira2 is not a program per se as Truice was under 335 but a site which can be local or online. It also does not execute sql created by our mods directly in the DB but just generates the sql lines to copy / paste in its PHPMyAdmin. So as not to go too far and get lost, I would mainly talk here only about the quest part of Keira2.

Be aware however that once these sql lines copy / paste into your PhpmyAdmin you can for most of them (but not all) reload them in the game without having to restart your server with the command .reload all.


Are you close? Shall we start?
:p
I already see one there at the bottom that is sweating ... but no come back you'll see ... it's easy


Part A - Appetizer: Presentation of the different parts of Keira2:
By identifying the various parts of Keira2 you will understand by logic how to repair quests. I would come back to their uses a little lower by some type of quests.

0) Launch of Keira2:
You will find in the upper part the buttons towards the various subjects treated by Keira2: Quests, Mob, etc and in the lower part the part concerning this subject which will adapt to this choice, by default it is positioned on the search but each subject has its own sub-branches.

Quest Part-0.jpg
The quest part of Keira2 is made up of Quest Part1, Quest Part2, Quest Part3, etc.

1) The Quest Part1 branch:

1 PrevQuestID & RewardNextQuest which define in a sequence the previous and next quest are sometimes a case of bug because not indicated. ExclusiveGroup is used to separate this suite when you have the choice between several quests but you can only do one. The value must be the same for all these quests ie the id of one of these quests.

2 Defined conditions required to do this quest, level, time zone, etc. Flag manages here it is repeatable automatically rendered without NPCs, etc.

3 A can like 2

4 Startitem designates a given item necessary for this quest, ProvidedItemCount the number and SourceSpellID a spell cast on you when you accept this quest as an aura to phase or see certain NPCs

5 The blabla itself, the one that appears in the game window

Quest Part-1.jpg

2) The Quest Part2 branch:
6 The emotes played by the NPC by taking or returning the Point of interest quest
7 When a quest asks you to bring back items to it but we will rather use another possibility in Quest Part3
8 Rewards: items, reputation, title, etc. RewardDisplaySpell & RewardSpell for withdrawing an aura given when we took the quest (in 4) or to give you another as a reward.

UloqqqJ


3) The Quest Part3 branch: we will quickly pass on this part, I have never personally touched.

Defines the portraits that appear in certain quests or the audio that is played. I never touched this part there.

Quest Part-3.jpg

4) The Quest Objectives branch:

This is undoubtedly the most important part in debugging a quest, the one where you will intervene most often. Not to neglect . It conditions what is asked of you: kill x mob, bring back x item, etc.
Next to the ID column you have an icon which allows you to select the line and bring it up in the editor above. After editing, you must validate one of the Edit, Delete or Add new buttons. Each line corresponds to one thing requested to complete the quest.

ID (which has nothing to do with the id of the quest) indicates in a way the "GUID" for the objectives, it can be any but unique to all the quests.
Type indicates the type of objective: I have not tested all those listed below, I mainly use 0, 1 or 2

Type = 0: KILL pnj
Type = 1: ITEM
Type = 2: action on an object or condition type kill
Type = 3: interaction with a PNJ example gossip hello
Type = 4: Collect Brand
Type = 5: learn a skill or reach a level (3 ?!)
Type = 6: friendly reputation or more - hai -42000 Hostile -6000, Unfriendly - 3000, Neutral 0, Friendly 3000, Honored 9000, Revered 21000, Exalted 43000
Type = 7: unfriendly reputation or -
Type = 8: Copper coin
Type = 9: Player killed
Type = 10: exploration ObjectID -1 other param at zero
Type = 11: defeat mascot
Type = 12: defeat combat mascot
Type = 13: Defeat player using Find a fight with a team of mascots
Type = 14: StorageIndex 0 = defeat boss - StorageIndex = 1 & 2 mission field?!
Type = 15: explore / attack ?!

StorageIndex is a serial number which must be unique
ObjectID will designate according to the Type (0 to 15) the ID of the mob to kill or the item to bring back
Amount indicates how much to kill of mob or bring back of item, 0 will automatically validate the condition, practical to auto complete the quest without losing these info
Flags & UnkFloat ... I have no idea
Description means the text that will be displayed on your screen in the quest tracking and which details the objectives of the quest below its name, for example "explore stitchland" or "10 bandit koala neutralized"

Quest Part-4.jpg

5) The Creature Starters, Creature Enders, Gameobject Starters, Gameobject Enders branches designate the NPC or gameobject IDs that give or end the quest.


Part B - examples of quest bugs and how to fix them

6) types of Some types of quests:

I would not detail all the Types listed in 4 because I still use only very few, so I do not know them very well. its will come over the debug of the DB.

Kill x mob
Bring back x items
Go talk to / gossip_hello
killcredit: Performing an action that requires neither a mob, an item, nor an action on a brief gameobject, its can be anything like an escort, using a vehicle
Take action on a gameobject
explore a place
Spell


6a) Kill x mob:

It may seem simple this one ... and yet there is a small Big Grin trap
- In the majority of cases, that is to say when there is only one kind of MOB to kill, you will have to enter the line as shown on screen 4 with Type = 0
- In the case where there are several kinds of MOB to kill you with 2 possible choices:

You repeat these lines as many times as necessary with the ID of the 1st different column each time. It is suitable for quests that require a maximum of 3 or 4 kinds of mobs.
but some quests will ask you more, for example x mobs of the region or of such clan ... it can represent a lot of people. In this case we will only enter one in keira2 and for the next we will enter for each kind of mobs the box KillCredit1 or KillCredit2 in the table creature_template of these mobs. Basically the quest asks me to kill mobs with ID 111, I fill in the KillCredit1 box of a mob 222 with this value 111 and this one will count here I kill it as a mob 111 and 222. Nothing could be easier than doing an UPDATE `creature_template` SET` KillCredit1` = 111 WHERE entry = 222;


6b) Bring back x items:

as shown on screen 4 but with Type = 1

6c) Go talk to (2 cases) / gossip_hello:

The quest asks you to go talk to an NPC and that's it, this NPC ends the quest. It is often in this case when at the end of a region we want to guide you to the next. In this case you leave Quest Objectives completely empty. As there is no condition the quest will be auto-complete automatically. Then just define the mob to whom you should speak as the one to whom you return the quest.

The quest asks you to go talk to an NPC but it is only one step and does not finish the quest. In this case you have 2 solutions: use Type = 3 or use what is called a killcredit. Personally I prefer to use a killcredit because so when I list Quest Objectives in Keyra2 I have everything that is requested on the same mask. I detail this killcredit just below in 6d. In the same scenario there is also the case where a quest asks you like at the start of the worgen to save NPCs who drown or to find missing children, this is the same scenario but presented a little differently. There is not necessarily any text, so we will use killcredit with a simple gossip_hello (a click on the PNJ): EVENT_GOSSIP_HELLO (64), don't forget the gossip flag in creature_template.


6c) Go talk to (2 cases) / gossip_hello:

The quest asks you to go talk to an NPC and that's it, this NPC ends the quest. It is often in this case when at the end of a region we want to guide you to the next. In this case you leave Quest Objectives completely empty. As there is no condition the quest will be auto-complete automatically. Then just define the mob to whom you should speak as the one to whom you return the quest.

The quest asks you to go talk to an NPC but it is only one step and does not finish the quest. In this case you have 2 solutions: use Type = 3 or use what is called a killcredit. Personally I prefer to use a killcredit because so when I list Quest Objectives in Keyra2 I have everything that is requested on the same mask. I detail this killcredit just below in 6d. In the same scenario there is also the case where a quest asks you like at the start of the worgen to save NPCs who drown or to find missing children, this is the same scenario but presented a little differently. There is not necessarily any text, so we will use killcredit with a simple gossip_hello (a click on the PNJ): EVENT_GOSSIP_HELLO (64), don't forget the gossip flag in creature_template.


6d) killcredit:

Performing a condition which requires neither a mob, an item, nor an action on a brief gameobject, its can be anything like an escort, using a vehicle, etc. this is the method that will be used in most debugs ... so the most
What is killcredit? ... thank you for asking me the question, it makes me a good sequence please

In fact the answer is in its name killcredit: credit when you kill an MOB ... "Bravo Stitch 3600 lines to get there ... Bravo, + REP" okai

Well seriously it is exactly as for 6a, we act as if we were asked to kill a mob even if what is asked is only to open a door. The only difference is that in 6a it was enough to kill the said MOB to be credited, this is not the case.

The credit will simply be given thanks to SmartAI and its action ACTION_CALL_KILLEDMONSTER (33) instead of a mob. The only conditions are that the id of this "MOB" must exist in the DB and of course not to be spawn somewhere, it will only be used for its purpose. You now understand why you come across mobs on wowhead with the mention "The location of this NPC is unknown" ... its may also indicate a fart but good.

The script corresponding to this screen:
SET @ENTRY: = 11000560;
UPDATE `creature_template` SET` AIName` = "SmartAI" WHERE `entry` = @ ENTRY;
DELETE FROM `smart_scripts` WHERE` entryorguid` = @ ENTRY 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_ `,` target_y`, `target_z`,` target_o`, `comment`) VALUES
(@ ENTRY, 0,10,0,64,0,100,0,0,0,0,0,33,111,0,0,0,0,0,7,7,0,0,0,0,0,0, 0, "Killcredit example");

The quest credit given by SmartAI it can be of any kind, it suffices to define an Event in SmartAi adapted. The script can be that of a MOB (AIName` = "SmartAI") as well as that of a gameobject (AIName` = "SmartGameObjectAI"). Example:

zsaCubl


In the screen above it is a simple right button on the mob 11000560, it can according to the context given by the quest a simple "go talk to" or a "save the NPCs who drown it like the departure of the worgen". It is advisable in this case to set the flag of this SmartAI to "non-repeatable" to avoid cheating and also to program a despawn of said MOB.

In the case of an NPC escort (who can follow you like a fart or follow a waitpoint) can give you this credit if he detects having arrived at a given point by defining the credit target in the "Target" of SmartAI . For this point I advise against using another MOB because if it has been killed ... the best is to use a trigger. A trigger is simply a passive and invisible MOB. It does absolutely nothing, just indicate that it is SmartAI. It just serves as a marker. To do this, create a neutral MOB with unit_flags Pacified (131072) and flags_extra (trigger = 128 = invisible).

the killcredit can also be used to give the credit of a kill when one is on a mount not invoked like the chariots of the yoke which by default does not give to the one who rides it. For this on this mount define Event_kill (5) for event and TARGET_OWNER_OR_SUMMONER (23) for the player who rides it.


6th) Take action on a gameobject

There are a variety of gameobject types and therefore as many sources of problems and solutions, for the curious you will find a list with their Trinity details HERE. Most of the time we will be dealing with a change of state such as opening a cage to release a prisoner or pressing a button. Here we can also use the killcredit but with our SmartAI event a test on this change of state.

Rather than write a novel, I will take the example of the prisoners of war at Carmine quest, which asks us to free prisoners locked in the black enclosure which is locked.

dZ3nAOh


This gameobject is actually a simple button (BUTTON = 1). I will detect that the player opens the enclosure by a change of his state thanks to EVENT_GO_STATE_CHANGED (70) which will be equal to 2: go_state_activated.

Locking is done by the gameobject itself. If we examine this gameobject (enclosure ID 204441) we will notice in the OPEN box an open value = 1930, if it had not been locked there would have been 0.
This 1930 corresponds to a 1930 entry in Lock.dbc where we will find a value 59261 ... 59261 which is in fact the id of the key unlock item (item 59261).

You will notice the main difficulty of SmartAI which is to connect event to target, here with TARGET_PLAYER_RANGE (17) it is not very optimal since another player having him also the quest and being carried would have the credit without activating the enclosure , I could have used TARGET_CLOSEST_PLAYER (21) but I noticed that it worked when it wanted.


6f) explore a place:

ObjectID being 99% with the value -1, I admit that I did not find a correlation in the DB between the zone and the quest, maybe the dbc or a spell (spell_area) but there too I found nothing. So I don't break my head anymore, I go through a trigger. A trigger is a passive and invisible mob that does nothing except in this case give a killcredit to a player detected within a certain radius.



6g) Spell problem:

Spell problem: Some quests will ask us to use an item provided for a special use but here it is ... this item casts a spell which does not work and therefore the quest cannot be completed.
To illustrate this example, the quest A radical weedkiller, it provides us with the item Massacr'herbes which precisely launches a spell that does not work, source of the bug.


To remedy this I will use the spell_linked_spell table, this one allows you to link one spell to another. When I launch the first sa will automatically launch the second. It is possible to link several spells to the first to achieve these ends. You should know that often spells exist in multiple copies, sometimes with a limitation or condition and sometimes precisely without.
Quite often we will find the equivalent or more which when combined will produce the desired effect. You will have to search by name on wowhead and experiment (with .learn 123). If a spell tested does not work I advise you to unlearn it (.unlearn 123) so that in your next try it does not interfere. It can also be that the spell tested has a lock like a need for mana and does not work on the player but works on the mob which has less lock.

REPLACE INTO `world`.`spell_linked_spell` (`spell_trigger`, `spell_effect`, `type`, `comment`) VALUES ('68211', '68212', '0', 'Massacr''herbes : quete 14236');

Another interesting thing is that this technique can be used to debug a class, at least temporarily while finding a C ++ Undecided pro
Do not be too illusionary for class spells, the equivalents are much more difficult to find without side effects, especially for talents.
To note in the DB the item_template_548 table which as its name indicates comes from MOP, I added it since the items no longer appear in the DB 6x and are managed by the DBC. It is used for nothing other than finding the spell launched by the item in the spellid_1 box.




7) Miscellaneous:

Weird little things that I could see and various tips

As far as possible avoid using the Smart Update event update, in fact in certain circumstances it skips the programmed temp and interprets it with a 0 or a crazy value like time x10. Prefer it for example EVENT_UPDATE_OOC, EVENT_OOC_LOS etc.
About the id in Quest Objectives on Keyra2. It happened to me 2 or 3 times or a quest did not seem to accept these conditions. I solved this problem by changing this id (remember that we can compare it to the GUID of creatures). it seems that these Quest Objectives can be locked by another table.
If a quest seems well programmed but still does not want to work properly: check that it is not disabled in the Disable table. I happened to come across Disabled quests that were still offered to the player but whose conditions were not validated in the game for this reason.
When using EVENT_LINK (61) or not, make sure that the links to & link from are valid. its may crash the server at startup.

i have finish but i didn't post more 5 image it's great problem for me...

Credit to : Stitch from Aquayoup
 
Last edited by a moderator:
Top