From b4ad928baf8dbe880a1ebabbb11c5792fdd265a0 Mon Sep 17 00:00:00 2001
From: dg <dg@51575b47-30f0-44d4-a5cc-537603b46e54>
Date: Wed, 28 Nov 2012 00:39:59 +0000
Subject: [PATCH] Move to normal inventory is the first action when an item is
 in the transmo chest (unless unidentified) Artifacts can now be identified
 from the inventory if you have the orb/talent/.. to do so anyway

git-svn-id: http://svn.net-core.org/repos/t-engine4@5856 51575b47-30f0-44d4-a5cc-537603b46e54
---
 game/modules/tome/data/general/objects/egos/lite.lua | 2 +-
 game/modules/tome/dialogs/UseItemDialog.lua          | 6 +++++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/game/modules/tome/data/general/objects/egos/lite.lua b/game/modules/tome/data/general/objects/egos/lite.lua
index 57c9c50a85..e8bede1a59 100644
--- a/game/modules/tome/data/general/objects/egos/lite.lua
+++ b/game/modules/tome/data/general/objects/egos/lite.lua
@@ -89,7 +89,7 @@ newEntity{
 
 newEntity{
 	power_source = {psionic=true},
-	name = " of the forge", prefix=true, instant_resolve=true,
+	name = " of the forge", suffix=true, instant_resolve=true,
 	keywords = {forge=true},
 	level_range = {30, 50},
 	greater_ego = 1,
diff --git a/game/modules/tome/dialogs/UseItemDialog.lua b/game/modules/tome/dialogs/UseItemDialog.lua
index 840842d40a..1d4aa0c6d5 100644
--- a/game/modules/tome/dialogs/UseItemDialog.lua
+++ b/game/modules/tome/dialogs/UseItemDialog.lua
@@ -66,6 +66,9 @@ function _M:use(item)
 			self.actor:playerUseItem(self.object, self.item, self.inven, self.onuse)
 			self.onuse(self.inven, self.item, self.object, true)
 		end
+	elseif act == "identify" then
+		self.object:identify(true)
+		self.onuse(self.inven, self.item, self.object, false)
 	elseif act == "drop" then
 		self.actor:doDrop(self.inven, self.item, function() self.onuse(self.inven, self.item, self.object, false) end)
 	elseif act == "wear" then
@@ -95,10 +98,11 @@ function _M:generateList()
 
 	local transmo_chest = self.actor:attr("has_transmo")
 
+	if not self.object:isIdentified() and self.actor:attr("auto_id") and self.actor:attr("auto_id") >= 2 then list[#list+1] = {name="Identify", action="identify"} end
+	if self.object.__transmo then list[#list+1] = {name="Move to normal inventory", action="toinven"} end
 	if not self.object.__transmo then if self.object:canUseObject() then list[#list+1] = {name="Use", action="use"} end end
 	if self.inven == self.actor.INVEN_INVEN and self.object:wornInven() and self.actor:getInven(self.object:wornInven()) then list[#list+1] = {name="Wield/Wear", action="wear"} end
 	if not self.object.__transmo then if self.inven ~= self.actor.INVEN_INVEN and self.object:wornInven() then list[#list+1] = {name="Take off", action="takeoff"} end end
-	if self.object.__transmo then list[#list+1] = {name="Move to normal inventory", action="toinven"} end
 	if self.inven == self.actor.INVEN_INVEN then list[#list+1] = {name="Drop", action="drop"} end
 	if self.inven == self.actor.INVEN_INVEN and transmo_chest and self.actor:transmoFilter(self.object) then list[#list+1] = {name="Transmogrify now", action="transmo"} end
 	if profile.auth and profile.hash_valid then list[#list+1] = {name="Link item in chat", action="chat-link"} end
-- 
GitLab