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

Enable the Adventurer bonus class when winning the game. It allows you to...

Enable the Adventurer bonus class when winning the game. It allows you to select any of the possible talent trees in the game. Beware this is not balanced nor even sure all combos are working. Use at your own risk, and fun

git-svn-id: http://svn.net-core.org/repos/t-engine4@5725 51575b47-30f0-44d4-a5cc-537603b46e54
parent a9799017
No related branches found
No related tags found
No related merge requests found
......@@ -20,9 +20,10 @@
newBirthDescriptor{
type = "class",
name = "Adventurer",
locked = function() return profile.mod.allow_build.adventurer and true or "hide" end,
desc = {
"Adventurer can learn to do a bit of everything, getting training in whatever they happen to find.",
"#{bold}#This is a bonus class for winning the game, it is by no means balanced.#{normal}#",
"#{bold}##GOLD#This is a bonus class for winning the game, it is by no means balanced.#WHITE##{normal}#",
},
descriptor_choices =
{
......@@ -40,9 +41,10 @@ newBirthDescriptor{
newBirthDescriptor{
type = "subclass",
name = "Adventurer",
locked = function() return profile.mod.allow_build.adventurer and true or "hide" end,
desc = {
"Adventurer can learn to do a bit of everything, getting training in whatever they happen to find.",
"#{bold}#This is a bonus class for winning the game, it is by no means balanced.#{normal}#",
"#{bold}##GOLD#This is a bonus class for winning the game, it is by no means balanced.#WHITE##{normal}#",
"Their most important stats depends on what they wish to do.",
"#GOLD#Stat modifiers:",
"#LIGHT_BLUE# * +2 Strength, +2 Dexterity, +2 Constitution",
......@@ -54,7 +56,7 @@ newBirthDescriptor{
talents_types = function(birth)
local tts = {}
for _, class in ipairs(birth.all_classes) do
for _, sclass in ipairs(class.nodes) do if sclass.id ~= "Adventurer" then
for _, sclass in ipairs(class.nodes) do if sclass.id ~= "Adventurer" and not sclass.not_on_random_boss then
if birth.birth_descriptor_def.subclass[sclass.id].talents_types then
local tt = birth.birth_descriptor_def.subclass[sclass.id].talents_types
if type(tt) == "function" then tt = tt(birth) end
......
......@@ -270,5 +270,5 @@ load("/data/birth/classes/corrupted.lua")
load("/data/birth/classes/afflicted.lua")
load("/data/birth/classes/chronomancer.lua")
load("/data/birth/classes/psionic.lua")
--load("/data/birth/classes/adventurer.lua")
load("/data/birth/classes/adventurer.lua")
load("/data/birth/classes/none.lua")
......@@ -46,7 +46,7 @@ local default_eyal_descriptors = function(add)
Afflicted = "allow",
Chronomancer = "allow",
Psionic = "allow",
-- Adventurer = "allow",
Adventurer = "allow",
},
subclass =
{
......
......@@ -121,6 +121,8 @@ function win(self, how)
elseif how == "yeek-sacrifice" then world:gainAchievement("YEEK_SACRIFICE", game.player)
end
game:setAllowedBuild("adventurer", true)
local p = game:getPlayer(true)
p.winner = how
game:registerDialog(require("engine.dialogs.ShowText").new("Winner", "win", {playername=p.name, how=how}, game.w * 0.6))
......
-- ToME - Tales of Maj'Eyal
-- Copyright (C) 2009, 2010, 2011, 2012 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 Class: #LIGHT_GREEN#Adventurer",
[[Congratulations, you have won the game!
You can now create new characters with the #LIGHT_GREEN#Adventurer class#WHITE#.
Adventurers start the game with 7 talent categories points and all possible class and generic trees in the game.
They are a #{bold}#bonus#{normal}# class, they are in no way meant to be balanced or even working with all possible talents combos.
Use at your own risk and fun.]]
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