Skip to content
Snippets Groups Projects
Commit 3ae7a427 authored by dg's avatar dg
Browse files

Displace no longer works in vaults.

Feed no longer feeds on yourself when frozen.
Alchemist gems no longer become cursed.
Only *body* armor gets the Grim Craft bonus
Removed healing factor curses (which didn't work anyway)


git-svn-id: http://svn.net-core.org/repos/t-engine4@3840 51575b47-30f0-44d4-a5cc-537603b46e54
parent 122090cf
No related branches found
No related tags found
No related merge requests found
......@@ -135,6 +135,29 @@ newBirthDescriptor{
__allow_rod_recall = false,
},
}
newBirthDescriptor{
type = "difficulty",
name = "Exploration",
locked = function(birther) return birther:isDonator() or "hide" end,
locked_desc = "Exploration mode: Infinite lives (donator feature)",
desc =
{
"#GOLD##{bold}#Exploration mode#WHITE#",
"Provides the normal game experience but with infinite lives.#{normal}#",
"Infinite number of lives available.",
"This is not the way the game is meant to be played, but it allows you to have a more forgiving experience.",
"Remember though that dying is an integral part of the game and helps you become a better player.",
},
descriptor_choices =
{
race = { ["Tutorial Human"] = "forbid", },
class = { ["Tutorial Adventurer"] = "forbid", },
},
copy = {
__game_difficulty = 2,
infinite_lifes = 1,
},
}
newBirthDescriptor{
type = "difficulty",
name = "Easy",
......
......@@ -21,8 +21,6 @@ local Stats = require "engine.interface.ActorStats"
local DamageType = require "engine.DamageType"
local Talents = require "engine.interface.ActorTalents"
newEntity{ name = "arm healing factor", weighting = 4, copy = { wielder = { healing_factor = resolvers.mbonus_material(30, 15) }, }, }
newEntity{ name = "arm max life", weighting = 2, copy = { wielder = { max_life = resolvers.mbonus_material(60, 40) }, }, }
newEntity{ name = "arm life regen", weighting = 2, copy = { wielder = { life_regen = resolvers.mbonus_material(15, 5, function(e, v) v=v/10 return 0, v end) }, }, }
newEntity{ name = "arm combat armor", weighting = 2, copy = { wielder = { combat_armor = resolvers.mbonus_material(8, 2), }, }, }
......
......@@ -28,7 +28,6 @@ newEntity{ name = "ben wil", weighting = 1, copy = { wielder = { inc_stats = { [
newEntity{ name = "ben cun", weighting = 1, copy = { wielder = { inc_stats = { [Stats.STAT_CUN] = resolvers.mbonus_material(4, 1) }, }, }, }
newEntity{ name = "ben con", weighting = 1, copy = { wielder = { inc_stats = { [Stats.STAT_CON] = resolvers.mbonus_material(4, 1) }, }, }, }
--newEntity{ name = "ben healing factor", weighting = 1, copy = { wielder = { healing_factor = resolvers.mbonus_material(10, 5, function(e, v) v=v/100 return 0, v end) }, }, }
newEntity{ name = "ben mentalresist", weighting = 1, copy = { wielder = { combat_mentalresist = resolvers.mbonus_material(4, 2) }, }, }
newEntity{ name = "ben physresist", weighting = 1, copy = { wielder = { combat_physresist = resolvers.mbonus_material(4, 2) }, }, }
newEntity{ name = "ben spellresist", weighting = 1, copy = { wielder = { combat_spellresist = resolvers.mbonus_material(4, 2) }, }, }
......
......@@ -33,7 +33,6 @@ newEntity{ name="det res light", weighting = 2, copy = { wielder = { resists={ [
newEntity{ name="det res fire", weighting = 2, copy = { wielder = { resists={ [DamageType.FIRE] = -5 }, }, }, }
newEntity{ name="det res arcane", weighting = 2, copy = { wielder = { resists={ [DamageType.ARCANE] = -5 }, }, }, }
--newEntity{ name="det healing factor", weighting = 1, copy = { wielder = { healing_factor = resolvers.mbonus_material(10, 5, function(e, v) v=-v/100 return 0, v end) }, }, }
newEntity{ name="det mentalresist", weighting = 1, copy = { wielder = { combat_mentalresist = resolvers.mbonus_material(8, 3, function(e, v) return 0, -v end) }, }, }
newEntity{ name="det physresist", weighting = 1, copy = { wielder = { combat_physresist = resolvers.mbonus_material(8, 3, function(e, v) return 0, -v end) }, }, }
newEntity{ name="det spellresist", weighting = 1, copy = { wielder = { combat_spellresist = resolvers.mbonus_material(8, 3, function(e, v) return 0, -v end) }, }, }
......
......@@ -44,6 +44,7 @@ newTalent{
local tg = {type="hit", range=range}
local x, y, target = self:getTarget(tg)
if not x or not y or not target or core.fov.distance(self.x, self.y, x, y) > range then return nil end
if target == self then return nil end -- avoid targeting while frozen
if self:reactionToward(target) >= 0 or target.summoner == self then
game.logPlayer(self, "You can only gain sustenance from your foes!");
......
......@@ -83,7 +83,7 @@ newTalent{
if item.unique then return end
if item.quest then return end
if not item:wornInven() then return end
if item.type == "ammo" then return end
if item.type == "ammo" or item.type == "gem" then return end
item.cursed_touch = true
......@@ -121,7 +121,7 @@ newTalent{
end
-- grim craft
if item.type == "armor" then
if item.type == "armor" and (sub_type == "cloth" or sub_type == "light" or sub_type == "heavy" or sub_type == "medium" or sub_type == "massive") then
local tGrimCraft = self:getTalentFromId(self.T_GRIM_CRAFT)
if tGrimCraft and self:getTalentLevelRaw(tGrimCraft) > 0 then
if not curses_armor then curses_armor = mod.class.Object:loadList("/data/general/objects/egos/curses-armor.lua") end
......
......@@ -120,6 +120,12 @@ newTalent{
-- but we cant ...
local _ _, x, y = self:canProject(tg, x, y)
if not self:canMove(x, y) or (self.x == x and self.y == y) then return nil end
if not self:canBe("teleport") or game.level.map.attrs(x, y, "no_teleport") then
game.logSeen(self, "Your attempt to displace fails!")
return true
end
game.level.map:particleEmitter(self.x, self.y, 1, "teleport_out")
self:move(x, y, true)
game.level.map:particleEmitter(self.x, self.y, 1, "teleport_in")
......
......@@ -140,9 +140,6 @@ function _M:init(title, actor, order, at_end, quickbirth, w, h)
}
self:setupUI()
-- If we wanted to hide the custom tile selector for non donators, but we dont want to
-- if not profile.auth or not tonumber(profile.auth.donated) or tonumber(profile.auth.donated) <= 1 then self:toggleDisplay(self.c_tile, false) end
if self.descriptors_by_type.difficulty == "Tutorial" then
self:raceUse(self.all_races[1], 1)
self:raceUse(self.all_races[1].nodes[1], 2)
......@@ -421,7 +418,7 @@ end
function _M:getLock(d)
if not d.locked then return false end
local ret = d.locked()
local ret = d.locked(self)
if ret == "hide" then return "hide" end
return not ret
end
......@@ -1029,7 +1026,7 @@ function _M:selectTile()
end}
local list = ImageList.new{width=500, height=500, tile_w=64, tile_h=64, padding=10, list=list, fct=function(item)
game:unregisterDialog(d)
if not profile.auth or not tonumber(profile.auth.donated) or tonumber(profile.auth.donated) <= 1 then
if not self:isDonator() then
self:selectTileNoDonations()
else
self:setTile(item.f, item.w, item.h)
......@@ -1043,3 +1040,7 @@ function _M:selectTile()
d.key:addBind("EXIT", function() game:unregisterDialog(d) end)
game:registerDialog(d)
end
function _M:isDonator()
if not profile.auth or not tonumber(profile.auth.donated) or tonumber(profile.auth.donated) <= 1 then return false else return true end
end
......@@ -115,8 +115,10 @@ end
--- Send the party to the Eidolon Plane
function _M:eidolonPlane()
game:onTickEnd(function()
self.actor:attr("easy_mode_lifes", -1)
game.log("#LIGHT_RED#You have %s left.", (self.actor:attr("easy_mode_lifes") and self.actor:attr("easy_mode_lifes").." life(s)") or "no more lives")
if not self.actor:attr("infinite_lifes") then
self.actor:attr("easy_mode_lifes", -1)
game.log("#LIGHT_RED#You have %s left.", (self.actor:attr("easy_mode_lifes") and self.actor:attr("easy_mode_lifes").." life(s)") or "no more lives")
end
self:cleanActor(self.actor)
self:resurrectBasic(self.actor)
......@@ -234,7 +236,7 @@ function _M:generateList()
if config.settings.cheat then list[#list+1] = {name="Resurrect by cheating", action="cheat"} end
if not self.actor.no_resurrect and allow_res then
if self.actor:attr("easy_mode_lifes") then
if self.actor:attr("easy_mode_lifes") or self.actor:attr("infinite_lifes") then
self:use{action="easy_mode"}
self.dont_show = true
return
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment