Skip to content
Snippets Groups Projects
Commit 26b88d93 authored by dg's avatar dg
Browse files

Reintroduced Nightmare mode as a step between normal and insane

Insane mode is now unlocked by winning on Nightmare mode


git-svn-id: http://svn.net-core.org/repos/t-engine4@5851 51575b47-30f0-44d4-a5cc-537603b46e54
parent 40121305
No related branches found
No related tags found
No related merge requests found
......@@ -325,7 +325,12 @@ function _M:loaded()
-- Increases zone level for higher difficulties
if not zone.__applied_difficulty then
zone.__applied_difficulty = true
if self.difficulty == self.DIFFICULTY_INSANE then
if self.difficulty == self.DIFFICULTY_NIGHTMARE then
zone.base_level_range = table.clone(zone.level_range, true)
zone.specific_base_level.object = -10 -zone.level_range[1]
zone.level_range[1] = zone.level_range[1] * 1.2 + 10
zone.level_range[2] = zone.level_range[2] * 1.2 + 10
elseif self.difficulty == self.DIFFICULTY_INSANE then
zone.base_level_range = table.clone(zone.level_range, true)
zone.specific_base_level.object = -10 -zone.level_range[1]
zone.level_range[1] = zone.level_range[1] * 2 + 10
......
......@@ -144,7 +144,11 @@ function _M:zoneCheckBackupGuardian()
if self.allow_backup_guardians[game.zone.short_name] then
local data = self.allow_backup_guardians[game.zone.short_name]
game.zone.base_level = data.new_level
if game.difficulty == game.DIFFICULTY_INSANE then
if game.difficulty == game.DIFFICULTY_NIGHTMARE then
game.zone.base_level_range = table.clone(game.zone.level_range, true)
game.zone.specific_base_level.object = -10 -game.zone.base_level
game.zone.base_level = game.zone.base_level * 1.2 + 10
elseif game.difficulty == game.DIFFICULTY_INSANE then
game.zone.base_level_range = table.clone(game.zone.level_range, true)
game.zone.specific_base_level.object = -10 -game.zone.base_level
game.zone.base_level = game.zone.base_level * 2 + 10
......
......@@ -336,7 +336,12 @@ end
--- Call when added to a level
-- Used to make escorts and such
function _M:addedToLevel(level, x, y)
if game.difficulty == game.DIFFICULTY_INSANE and not game.party:hasMember(self) then
if game.difficulty == game.DIFFICULTY_NIGHTMARE and not game.party:hasMember(self) then
-- Increase talent level
for tid, lev in pairs(self.talents) do
self:learnTalent(tid, true, math.ceil(lev / 2))
end
elseif game.difficulty == game.DIFFICULTY_INSANE and not game.party:hasMember(self) then
-- Increase talent level
for tid, lev in pairs(self.talents) do
self:learnTalent(tid, true, lev)
......
......@@ -162,7 +162,7 @@ newBirthDescriptor{
selection_default = true,
desc =
{
"#GOLD##{bold}#Adventure mode#WHITE##{normal}#",
"#GOLD##{bold}#Normal mode#WHITE##{normal}#",
"Provides the normal level of chalenges.",
},
descriptor_choices =
......@@ -174,13 +174,34 @@ newBirthDescriptor{
__game_difficulty = 2,
},
}
newBirthDescriptor{
type = "difficulty",
name = "Nightmare",
desc =
{
"#GOLD##{bold}#Nightmare mode#WHITE##{normal}#",
"Unfair game setting",
"All zone levels increased by 20% + 10",
"All creatures talent levels increased by 50%",
},
descriptor_choices =
{
race = { ["Tutorial Human"] = "forbid", },
class = { ["Tutorial Adventurer"] = "forbid", },
},
copy = {
__game_difficulty = 3,
},
}
newBirthDescriptor{
type = "difficulty",
name = "Insane",
locked = function() return profile.mod.allow_build.difficulty_insane end,
locked_desc = "Easy is for the weak! Normal is for the weak! Nightmare is too easy! Bring on the true pain!",
desc =
{
"#GOLD##{bold}#Insane mode#WHITE##{normal}#",
"Absolutely unfair game setting",
"Absolutely unfair game setting, you are really mentally ill to play this mode!",
"All zone levels increased by 100% + 10",
"All creatures talent levels increased by 100%",
"Player rank is normal instead of elite",
......
......@@ -122,6 +122,7 @@ function win(self, how)
end
game:setAllowedBuild("adventurer", true)
if game.difficulty == game.DIFFICULTY_NIGHTMARE then game:setAllowedBuild("difficulty_insane", true) end
local p = game:getPlayer(true)
p.winner = how
......
......@@ -104,7 +104,7 @@ newTalent{
info = function(self, t)
local icedamage = t.getIceDamage(self, t)
local icedamageinc = t.getIceDamageIncrease(self, t)
return ([[Engulfs your hands (and weapons) in a sheath of lightnings, dealing %d lightning damage per melee attack and increasing all lightning damage by %d%%.
return ([[Engulfs your hands (and weapons) in a sheath of lightnings, dealing %d lightning damage with a chance to daze per melee attack and increasing all lightning damage by %d%%.
Each hit will also regenerate %0.2f mana.
The effects will increase with your Spellpower.]]):
format(damDesc(self, DamageType.LIGHTNING, icedamage), icedamageinc, self:getTalentLevel(t) / 3)
......
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010, 2011 Nicolas Casalini
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
--
-- Nicolas Casalini "DarkGod"
-- darkgod@te4.org
return "New game difficulty mode: #LIGHT_GREEN#Insane",
[[You won the game on Nightmare mode, you are a big tought player.
You thought you had seen it all, done it all...
But no! If nightmare mode couldnt bring you down, Insane mode will!
Insane features:#YELLOW#
- all zone levels increased by 100% + 10
- all creatures talent levels increased by 100%
- player rank is normal instead of elite
- player can earn Insane version of achievements if also playing in Roguelike permadeath mode.
#WHITE#May you suffer many fun and unfair deaths!
]]
......@@ -39,7 +39,9 @@ Someone foolish has tried to reconstruct it, but it seems like it misses an eye
if eye then
require("engine.ui.Dialog"):yesnoPopup("Atamathon", "It seems that your "..eye:getName{do_color=true}.." is made to fit inside the empty eye socket of Atamathon. This is probably very unwise.", function(ret)
if not ret then return end
if game.difficulty == game.DIFFICULTY_INSANE then
if game.difficulty == game.DIFFICULTY_NIGHTMARE then
game.zone.base_level = 50 * 1.2 + 10
elseif game.difficulty == game.DIFFICULTY_INSANE then
game.zone.base_level = 50 * 2 + 10
else
game.zone.base_level = 50
......
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