Quests (Inactive)

150k Downloads

Fail to obtain rewards with NPCs that have citizens' chat color code

PizzaStyx opened this issue ยท 4 comments

commented

Hello!
In my server I have designed quest NPCs to have colored names so they stand out from normal NPCs. Unfortunately, item fetching quests don't seem to work with NPCs that have certain color codes in their names, specifically, the color code used for the NPC text of citizens.

For example, in my server, NPCs talk with the color code "&a". If I name the NPC "&aBeggar", "&eBeggar&a" or anything involving the Citizens' text color code, the item fetching quest fails to finish and reward the player, even though the objective is displayed as completed. However, if I named my NPC with any other color code, the quest works perfectly.

No console errors are present in either the server console or the logs.

Here is an album of screenshots to visually describe my problem: http://imgur.com/a/fSvZ5

My quests.yml is attached below, in case you need it.
quests_YML.zip

commented

I can confirm this, and that it has been a problem for a loooong time. Coincidentally enough, one of my head admins had just discovered that &a was the cause of his quest failing to complete. Any other color works fine with quests, and it is purely the lime green color.

One of the oldest quest chains we have (all stand-alone quests with their own NPCs), the final quest has always had that problem where the player delivers the items, the quest even registers it, but doesn't fire the completion event. We have had to manually complete it with /questadmin. After my admin had discovered this as well (coincidentally just this week), we checked this quest's NPC name and... &aGeneral &f&lFrost. Changing "General" to another color solved this issue we've had for over a year and a half! lol

I suspect it's related to changes made for 1.8 compatibility, but have no basis for this suspicion to be honest.

commented

Likely duplicate of #297

commented

Version 2.5.5 introduced this bug. If you recreate your quest in version 2.5.3, green works.

commented

Sorry for necro-posting, but I found an interesting solution to this.
Apparently Quests/Citizens considers &f and &r to be different color codes, so if an NPC has the name "&eBeggar&r" and the text in Citizens is set to "&f", the quests all complete perfectly and the NPC text doesn't look like garbage!