litlamzetiv
07-08-2009, 12:27 PM
I want players to have to kill nagafen before they can go to Karnor. The method I've chosen to do this with is faction. The steps I've taken are as follows:
[TABLE: Faction List] Created a new faction (ID: 19938) called RED DRAGON SLAYERS.
[TABLE: npc_faction_entries] Modified npc_faction_id 23 (nagafen) to also have a faction ID 19938 value of 1500 and npc_value of 0.
[TABLE: npc_types] I created an NPC in soltemple and modified his npc_faction_id in this table to be 19938.
Modified the quest for this mob to the following:
sub EVENT_SAY
{
if($text=~/slain/i) {
$npc->SetAppearance(0);
if($faction >=1000) {
quest::say("Yes, Chronicler Crinklespark told me all about your feat in conquering the great lord Nagafen. I hear that the first to try were a bunch of crazy gnomish wizards, though I hope you managed to complete the task without quite as much bloodshed. Have you [performed the other tasks] as instructed?");
}
}
}
I'm sort of at a loss as to why that doesn't work. I've confirmed the following:
Killing Nagafen properly gives a message that my faction 19938 has increased.
My character has the proper value for the faction [Table: faction_values].
Do I also need to somehow add an entry for the quest NPC in [Table: npc_faction] in order to set his primary faction to 19938? I wouldn't figure this was necessary, because when I use the NPC and Loot Editor, it shows the npc_faction_id properly; however, when I con the mob (even after killing nagafen). If this is what I need to do, what does the value mean? Is that just an arbitrary unique number I can assign? Does it use "name" as a lockup in some other table?
While I'm at it, is there a way for a quest to check more than one faction, or can it really only compare the faction against the primary faction of the quest giver? I'm under the assumption that it can only do one, but if it could do several, that'd be downright handy.
Thanks in advance.
-Rob
[TABLE: Faction List] Created a new faction (ID: 19938) called RED DRAGON SLAYERS.
[TABLE: npc_faction_entries] Modified npc_faction_id 23 (nagafen) to also have a faction ID 19938 value of 1500 and npc_value of 0.
[TABLE: npc_types] I created an NPC in soltemple and modified his npc_faction_id in this table to be 19938.
Modified the quest for this mob to the following:
sub EVENT_SAY
{
if($text=~/slain/i) {
$npc->SetAppearance(0);
if($faction >=1000) {
quest::say("Yes, Chronicler Crinklespark told me all about your feat in conquering the great lord Nagafen. I hear that the first to try were a bunch of crazy gnomish wizards, though I hope you managed to complete the task without quite as much bloodshed. Have you [performed the other tasks] as instructed?");
}
}
}
I'm sort of at a loss as to why that doesn't work. I've confirmed the following:
Killing Nagafen properly gives a message that my faction 19938 has increased.
My character has the proper value for the faction [Table: faction_values].
Do I also need to somehow add an entry for the quest NPC in [Table: npc_faction] in order to set his primary faction to 19938? I wouldn't figure this was necessary, because when I use the NPC and Loot Editor, it shows the npc_faction_id properly; however, when I con the mob (even after killing nagafen). If this is what I need to do, what does the value mean? Is that just an arbitrary unique number I can assign? Does it use "name" as a lockup in some other table?
While I'm at it, is there a way for a quest to check more than one faction, or can it really only compare the faction against the primary faction of the quest giver? I'm under the assumption that it can only do one, but if it could do several, that'd be downright handy.
Thanks in advance.
-Rob