Skip to content
Snippets Groups Projects
snake.lua 3.71 KiB
Newer Older
  • Learn to ignore specific revisions
  • dg's avatar
    dg committed
    -- ToME - Tales of Middle-Earth
    -- Copyright (C) 2009, 2010 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
    
    
    dg's avatar
    dg committed
    local Talents = require("engine.interface.ActorTalents")
    
    newEntity{
    	define_as = "BASE_NPC_SNAKE",
    	type = "animal", subtype = "snake",
    	display = "J", color=colors.WHITE,
    	body = { INVEN = 10 },
    
    	max_stamina = 110,
    
    dg's avatar
    dg committed
    	rank = 2,
    
    dg's avatar
    dg committed
    	size_category = 2,
    
    dg's avatar
    dg committed
    
    	autolevel = "warrior",
    
    dg's avatar
    dg committed
    	ai = "dumb_talented_simple", ai_state = { talent_in=3, ai_move="move_snake" },
    
    dg's avatar
    dg committed
    	energy = { mod=1.3 },
    
    dg's avatar
    dg committed
    	stats = { str=14, dex=23, mag=5, con=5 },
    
    dg's avatar
    dg committed
    	combat_armor = 1, combat_def = 1,
    }
    
    newEntity{ base = "BASE_NPC_SNAKE",
    	name = "large brown snake", color=colors.UMBER,
    	desc = [[This large snake hisses at you, angry at being disturbed.]],
    	level_range = {1, 50}, exp_worth = 1,
    	rarity = 3,
    	max_life = resolvers.rngavg(20,30),
    	combat_armor = 1, combat_def = 3,
    	combat = { dam=2, atk=30, apr=10 },
    }
    
    newEntity{ base = "BASE_NPC_SNAKE",
    	name = "large white snake", color=colors.WHITE,
    	desc = [[This large snake hisses at you, angry at being disturbed.]],
    	level_range = {1, 50}, exp_worth = 1,
    	rarity = 3,
    	max_life = resolvers.rngavg(20,30),
    	combat_armor = 1, combat_def = 3,
    	combat = { dam=2, atk=30, apr=10 },
    }
    
    newEntity{ base = "BASE_NPC_SNAKE",
    	name = "copperhead snake", color=colors.SALMON,
    	desc = [[It has a copper head and sharp venomous fangs.]],
    	level_range = {2, 50}, exp_worth = 1,
    	rarity = 3,
    	max_life = resolvers.rngavg(30,40),
    	combat_armor = 2, combat_def = 5,
    	combat = { dam=3, atk=30, apr=10 },
    
    
    dg's avatar
    dg committed
    	resolvers.talents{ [Talents.T_BITE_POISON]=1 },
    
    dg's avatar
    dg committed
    }
    
    newEntity{ base = "BASE_NPC_SNAKE",
    	name = "rattlesnake", color=colors.FIREBRICK,
    	desc = [[As you approach, the snake coils up and rattles its tail threateningly.]],
    	level_range = {4, 50}, exp_worth = 1,
    	rarity = 3,
    	max_life = resolvers.rngavg(30,50),
    	combat_armor = 2, combat_def = 8,
    	combat = { dam=5, atk=30, apr=10 },
    
    
    dg's avatar
    dg committed
    	resolvers.talents{ [Talents.T_BITE_POISON]=1 },
    
    dg's avatar
    dg committed
    }
    
    newEntity{ base = "BASE_NPC_SNAKE",
    	name = "king cobra", color=colors.GREEN,
    	desc = [[It is a large snake with a hooded face.]],
    	level_range = {5, 50}, exp_worth = 1,
    	rarity = 6,
    	max_life = resolvers.rngavg(40,70),
    	combat_armor = 3, combat_def = 11,
    	combat = { dam=7, atk=30, apr=10 },
    
    
    dg's avatar
    dg committed
    	resolvers.talents{ [Talents.T_BITE_POISON]=2 },
    
    dg's avatar
    dg committed
    }
    
    newEntity{ base = "BASE_NPC_SNAKE",
    
    	name = "black mamba", color=colors.DARK_GREY,
    
    dg's avatar
    dg committed
    	desc = [[It has glistening black skin, a sleek body, and highly venomous fangs.]],
    
    	level_range = {15, 50}, exp_worth = 1,
    	rarity = 8,
    
    dg's avatar
    dg committed
    	max_life = resolvers.rngavg(50,80),
    	combat_armor = 4, combat_def = 12,
    	combat = { dam=10, atk=30, apr=10 },
    
    
    dg's avatar
    dg committed
    	resolvers.talents{ [Talents.T_BITE_POISON]=3 },
    
    dg's avatar
    dg committed
    }
    
    newEntity{ base = "BASE_NPC_SNAKE",
    	name = "anaconda", color=colors.YELLOW_GREEN,
    	desc = [[You recoil in fear as you notice this huge, 10 meter long snake.  It seeks to crush the life out of you.]],
    
    	level_range = {20, 50}, exp_worth = 1,
    
    dg's avatar
    dg committed
    	rarity = 11,
    
    dg's avatar
    dg committed
    	max_life = resolvers.rngavg(100,120),
    	combat_armor = 14, combat_def = 5,
    	combat = { dam=12, atk=10, apr=10 },
    	energy = { mod=0.8 },
    
    
    dg's avatar
    dg committed
    	resolvers.talents{ [Talents.T_STUN]=5 },
    
    dg's avatar
    dg committed
    }