diff --git a/game/modules/tome/class/Actor.lua b/game/modules/tome/class/Actor.lua index cf99068299cb013a99669bcd76fae584cc4f08d3..82a28a4b00dfacfd5b52d7d8da98b436dcd28ca8 100644 --- a/game/modules/tome/class/Actor.lua +++ b/game/modules/tome/class/Actor.lua @@ -4573,6 +4573,7 @@ function _M:startTalentCooldown(t) t = self:getTalentFromId(t) if not t.cooldown then return end self.talents_cd[t.id] = self:getTalentCooldown(t) + if self.talents_cd[t.id] <= 0 then self.talents_cd[t.id] = nil end self.changed = true end diff --git a/game/modules/tome/class/interface/Archery.lua b/game/modules/tome/class/interface/Archery.lua index c15745745fa95f55a7a5e6cf1e271f0c6b638f8f..7b217813d7d71c612e59e2ebe41163e8c3c70ea8 100644 --- a/game/modules/tome/class/interface/Archery.lua +++ b/game/modules/tome/class/interface/Archery.lua @@ -32,14 +32,18 @@ module(..., package.seeall, class.make) function _M:archeryAcquireTargets(tg, params) params = params or {} local weapon, ammo, offweapon = self:hasArcheryWeapon() + -- Awesome, we can shoot from our offhand! + if self.can_offshoot and not weapon and offweapon then weapon, offweapon = offweapon, nil end if not weapon then game.logPlayer(self, "You must wield a bow or a sling (%s)!", ammo) + print("== no weapon") return nil end local infinite = ammo.infinite or self:attr("infinite_ammo") or params.infinite if not ammo or (ammo.combat.shots_left <= 0 and not infinite) then game.logPlayer(self, "You do not have enough ammo left!") + print("== no ammo") return nil end @@ -51,6 +55,7 @@ function _M:archeryAcquireTargets(tg, params) local val = self['get'..weapon.use_resource.kind:capitalize()](self) if val < weapon.use_resource.value then game.logPlayer(self, "You do not have enough %s left!", weapon.use_resource.kind) + print("== no ressource") return nil end end @@ -590,6 +595,8 @@ end function _M:hasDualArcheryWeapon(type) local w, a, o = self:hasArcheryWeapon(type) + if self.can_solo_dual_archery and w and not o then w, o = w, w end + if self.can_solo_dual_archery and not w and o then w, o = o, o end if w and a and o then return w, a, o end return nil end diff --git a/game/modules/tome/data/chats/eidolon-plane.lua b/game/modules/tome/data/chats/eidolon-plane.lua index 9c6d120ef360eb41ceb0feb69fa4c413a03289b2..09c9434cdd02b694a8c1ff7f614f015abd02634f 100644 --- a/game/modules/tome/data/chats/eidolon-plane.lua +++ b/game/modules/tome/data/chats/eidolon-plane.lua @@ -27,15 +27,15 @@ As for your probable many questions, they will stay unanswered. I may help, but answers = { {"Thank you. I will rest for a while."}, {"Thank you. I am ready to go back!", - cond=function() return game.level.source_level end, + cond=function() return game.level.source_level and not game.level.source_level.no_return_from_eidolon end, action=function() game.level.data.eidolon_exit(false) end }, {"Thank you, but I fear I will not survive anyway, can you send me back somewhere else please?", - cond=function() return game.level.source_level and (not game.level.source_level.data or not game.level.source_level.data.no_worldport) end, + cond=function() return game.level.source_level and not game.level.source_level.no_return_from_eidolon and (not game.level.source_level.data or not game.level.source_level.data.no_worldport) end, action=function() game.level.data.eidolon_exit(true) end }, {"Thank you, I am ready to go back!", - cond=function() return not game.level.source_level end, + cond=function() return not game.level.source_level or game.level.source_level.no_return_from_eidolon end, jump="jump_error", }, {"Thank you, but I am weary of this life, I wish no more, please let me go.", jump="die"}, @@ -43,7 +43,7 @@ As for your probable many questions, they will stay unanswered. I may help, but } newChat{ id="jump_error", - text = [[It seems the threads of time have been disrupted... + text = [[It seems the threads of time and space have been disrupted... I will try to send you to safety.]], answers = { {"Thanks.", action=function(npc, player) game:changeLevel(1, "wilderness") end}, diff --git a/game/modules/tome/data/talents/techniques/archery.lua b/game/modules/tome/data/talents/techniques/archery.lua index d7c81109bf8667dbb2a0ccfe3c06218ae8dc848a..b8bed8a249192ea93cee7fcc85211893ff7da4d2 100644 --- a/game/modules/tome/data/talents/techniques/archery.lua +++ b/game/modules/tome/data/talents/techniques/archery.lua @@ -25,6 +25,7 @@ newTalent{ hide = true, innate = true, points = 1, + cooldown = 0, range = archery_range, message = "@Source@ shoots!", requires_target = true, diff --git a/game/modules/tome/dialogs/debug/ChangeZone.lua b/game/modules/tome/dialogs/debug/ChangeZone.lua index a14da30bfafb82d335c3f97e77f7560c7f03e501..d4b178c33420378e63b8b2ae5ddfafecada28c68 100644 --- a/game/modules/tome/dialogs/debug/ChangeZone.lua +++ b/game/modules/tome/dialogs/debug/ChangeZone.lua @@ -64,14 +64,14 @@ end function _M:generateList() local list = {} - local function parse(base, add) + local function parse(base, add, add_simple) for i, dir in ipairs(fs.list(base.."/zones/")) do local f = loadfile(base.."/zones/"..dir.."/zone.lua") if f then setfenv(f, setmetatable({}, {__index=_G})) local ok, z = pcall(f) if ok then - list[#list+1] = {name=z.name, zone=add..dir, min=1, max=z.max_level} + list[#list+1] = {name=z.name..(add_simple and " ["..add_simple.."]" or ""), zone=add..dir, min=1, max=z.max_level} end end end @@ -81,7 +81,7 @@ function _M:generateList() for i, dir in ipairs(fs.list("/")) do local _, _, addon = dir:find("^data%-(.+)$") if addon then - parse("/"..dir, addon.."+") + parse("/"..dir, addon.."+", addon) end end diff --git a/game/modules/tome/dialogs/debug/GrantQuest.lua b/game/modules/tome/dialogs/debug/GrantQuest.lua index f2ea1f1eb290034e4968a51b4716a996b8ec3a8f..acc85b25a990fd6ce08b8db23331e4e0cb5691d6 100644 --- a/game/modules/tome/dialogs/debug/GrantQuest.lua +++ b/game/modules/tome/dialogs/debug/GrantQuest.lua @@ -69,12 +69,23 @@ end function _M:generateList() local list = {} - for i, file in ipairs(fs.list("/data/quests/")) do - if file:find(".lua$") then - local n = file:gsub(".lua$", "") - list[#list+1] = {name=n, quest=n, hasit=game.player:hasQuest(n)} + local function parse(base, add, add_simple) + for i, file in ipairs(fs.list(base.."/quests/")) do + if file:find(".lua$") then + local n = file:gsub(".lua$", "") + list[#list+1] = {name=n..(add_simple and " ["..add_simple.."]" or ""), quest=add..n, hasit=game.player:hasQuest(n)} + end end end + + parse("/data", "") + for i, dir in ipairs(fs.list("/")) do + local _, _, addon = dir:find("^data%-(.+)$") + if addon then + parse("/"..dir, addon.."+", addon) + end + end + table.sort(list, function(a,b) return a.name < b.name end) local chars = {}