From f45574e575da970162e45faf703dc8d0c8a2419f Mon Sep 17 00:00:00 2001 From: "James D. Callahan III" Date: Mon, 22 Mar 2010 05:30:02 -0400 Subject: [PATCH] In FormatRecipeText(): Strip "Enchant " from any recipes leading with that prefix - may or may not work in languages other than English due to grammatical constructs. --- Frame.lua | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Frame.lua b/Frame.lua index e06bc4c..46c6260 100644 --- a/Frame.lua +++ b/Frame.lua @@ -2148,10 +2148,18 @@ do spell_tip:Hide() end local SKILL_LEVEL_FORMAT = "[%d]" + local SPELL_ENCHANTING = GetSpellInfo(51313) local function FormatRecipeText(recipe_entry) local _, _, _, quality_color = GetItemQualityColor(recipe_entry.quality) - local recipe_string = string.format("%s%s|r", quality_color, recipe_entry.name) + local recipe_name = recipe_entry.name + + if Player.current_prof == SPELL_ENCHANTING then + recipe_name = string.gsub(recipe_name, _G.ENSCRIBE.." ", "") + else + print(string.format("Current profession is %s.", Player.current_prof)) + end + local recipe_string = string.format("%s%s|r", quality_color, recipe_name) local skill_level = Player["ProfessionLevel"] local recipe_level = recipe_entry.skill_level -- 1.7.9.5