[REJECTED][Complete] Candy Bucket (Hallows End)[REJECTED]

Maybe this will help, probably not but here goes. When a character tries to access the candy bucket, worldserver says: 2011-10-19 12:01:47 ERROR: HACK ALERT: Player Jorn (guid: 1) is trying to complete quest (id: 12332) but he has no right to do it! Hopefully that is of some use. This is on the latest revision of core and db with all updates installed.

I notice that the quest template entries for candy bucket are the only ones that seem to have flag QUEST_FLAGS_AUTOCOMPLETE. This doesn’t seem right. Surely there are other autocomplete quests in the game? If not, maybe this is why it is not working.

Actually to me it makes sense seeing as how when you pick up the quest you also complete it, plus that flag is part of the wdb field so that wouldnt be a fix.

if ((!_player->CanSeeStartQuest(quest) &&  _player->GetQuestStatus(questId) == QUEST_STATUS_NONE) ||
			(_player->GetQuestStatus(questId) != QUEST_STATUS_COMPLETE && !quest->IsAutoComplete()))
		{
			sLog->outError("HACK ALERT: Player %s (guid: %u) is trying to complete quest (id: %u) but he has no right to do it!",
						   _player->GetName(), _player->GetGUIDLow(), questId);
			return;
		}

!quest->IsAutoComplete()… that function only checks method. I guess it should check for quest flags to

Edit:

Could someone test this patch and report back?

https://gist.github.com/1299518

[/CODE]

For me it worked to do the quest but now the candy bucket retains its yellow question mark, the innkeeper has one, and the matron that gives the fire fighting quests has one.

I guess I should mention that the toon i tested with was freshly made and ran straight to the candy bucket at the Inn in Kharanos.

You can auto-complete almost every non-item related quests with this aptch :confused:

Let me preface this with the statement: I am not strong in the way of the c++. I like this project as it gives me a reason to get better at it. That being said I dont know if this is good or not but when i change

bool Quest::IsAutoComplete() const

{

return QuestMethod || HasFlag(QUEST_FLAGS_AUTOCOMPLETE);

}

in quest.cpp of your patch to

bool Quest::IsAutoComplete() const

{

return QuestMethod && HasFlag(QUEST_FLAGS_AUTOCOMPLETE);

}

The quest function normally except that the buckets retain the yellow question mark until you rezone. Maybe a start for someone better than me at it.

well, in the existing version, QuestMethod is true if method is either 2 (auto-accept) or 1 (not implemented). I think, to avoid confusion, the test should be explicit (ie QuestMethod==2, except a non-magic number). Then using the “and” makes sense. Unless of course, one WANTS the quest to be autocompleted if its not implemented yet, which also has a certain amount of logic to it.

Just read the comment on his gist.

Kaelima is right, there was a type in the patch. It should be “!Method” or “Method == 0”.

hippie159, it should be an or. A quest is autocomplete if it has Method 0 OR autocomplete flag.

The quest exclamation mark bug is not related to this bug nor patch.

Knowing now about the typo it absolutely does make sense to use or. Thanks for allowing me to learn some more.

Report whether Nay’s fix work or not, lazy guinea pigs.

I will mom as soon as I can get my server to build again after ubuntu’s update.

This little piggy returns a positive. In plain english: working as intended.

Fix commited (and that is how you don’t hack shiz up /emoticons/default_cool.png )

My apolgies for starting the ‘method’ hack.

eh, it got fixed AND someone somewhere probably learned something. Thats really the most you can hope for out of life.