local STRINGS = GLOBAL.STRINGS
local require = GLOBAL.require
local Ingredient = GLOBAL.Ingredient
local RECIPETABS = GLOBAL.RECIPETABS
GetPlayer = GLOBAL.GetPlayer
GetWorld = GLOBAL.GetWorld
STRINGS = GLOBAL.STRINGS
RECIPETABS = GLOBAL.RECIPETABS
Recipe = GLOBAL.Recipe
Ingredient = GLOBAL.Ingredient
TECH = GLOBAL.TECH
Action = GLOBAL.Action
Vector3 = GLOBAL.Vector3
local Vector3 = GLOBAL.Vector3
require "class"
local FRAMES = GLOBAL.FRAMES
FRAMES = GLOBAL.FRAMES
local TimeEvent = GLOBAL.TimeEvent
TimeEvent = GLOBAL.TimeEvent
local EventHandler = GLOBAL.EventHandler
EventHandler = GLOBAL.EventHandler
localEQUIPSLOTS = GLOBAL.EQUIPSLOTS
EQUIPSLOTS = GLOBAL.EQUIPSLOTS
local SpawnPrefab = GLOBAL.SpawnPrefab
SpawnPrefab = GLOBAL.SpawnPrefab


--swords and armor Knight
STRINGS.NAMES.BROADSWORD 				= "Broadsword"
STRINGS.RECIPE_DESC.BROADSWORD 			= "Just hit your enemy."
STRINGS.NAMES.CLAYMORE 				= "Claymore"
STRINGS.RECIPE_DESC.CLAYMORE 		= "More damage - more power."
STRINGS.NAMES.KNIGHTARMOR 			= "Knight armor"
STRINGS.RECIPE_DESC.KNIGHTARMOR 	= "For sturdy bodies."
STRINGS.NAMES.KNIGHTHELMET 			= "Knight Helmet"
STRINGS.RECIPE_DESC.KNIGHTHELMET 	= "For sturdy heads."
STRINGS.NAMES.SUNARMOR 				= "Armor of the Sun"
STRINGS.RECIPE_DESC.SUNARMOR 		= "Praise the Sun!"
STRINGS.NAMES.SUNHELMET 			= "Helmet of the Sun"
STRINGS.RECIPE_DESC.SUNHELMET 		= "Praise the Sun!"
STRINGS.NAMES.LIGHT_SWORD 			= "Light Sword of Artorias"
STRINGS.RECIPE_DESC.LIGHT_SWORD 	= "Fill the might of light!"
STRINGS.NAMES.DARK_SWORD 			= "Abyss Greatsword"
STRINGS.RECIPE_DESC.DARK_SWORD 		= "Abyss will consume you..."

--thief blade
STRINGS.NAMES.THIEF_KNIFE 			= "Thief's knife"
STRINGS.RECIPE_DESC.THIEF_KNIFE 	= "Little sharp blade."
STRINGS.NAMES.FALCHION 				= "Falchion"
STRINGS.RECIPE_DESC.FALCHION 		= "Sharp crooked sword"
STRINGS.NAMES.CHAOSBLADE 			= "Chaos Blade"
STRINGS.RECIPE_DESC.CHAOSBLADE 		= "Dip all in chaos with yourself!"
STRINGS.NAMES.MIRRAH_ARMOR 			= "Mirrah Armor"
STRINGS.RECIPE_DESC.MIRRAH_ARMOR	= "Light and elegant"
STRINGS.NAMES.RICARDS_RAPIER 		= "Ricard's Rapier"
STRINGS.RECIPE_DESC.RICARDS_RAPIER	= "Light and sharp"
---estus
STRINGS.NAMES.ESTUS_FULL 							= "Estus flask"
STRINGS.CHARACTERS.GENERIC.DESCRIBE.ESTUS_FULL		= "Impossible! Infinite one!"
STRINGS.NAMES.ESTUS_EMPTY							= "Empty Estus flask"
STRINGS.CHARACTERS.GENERIC.DESCRIBE.ESTUS_EMPTY 	= "It needs to be refilled"
--STRINGS.NAMES.CLERIC_BELL 							= "Cleric Bell"
--STRINGS.CHARACTERS.GENERIC.DESCRIBE.CLERIC_BELL		= "Healing is always amazing"

--Magic
--STRINGS.NAMES.LIGHTNING_STAFF 						= "Lightning staff"
--STRINGS.CHARACTERS.GENERIC.DESCRIBE.LIGHTNING_STAFF	= "It does launching lightning bolts. May hurt"

--Drop

GLOBAL.STRINGS.NAMES.SOUL = "Ancient Soul"
STRINGS.CHARACTERS.GENERIC.SOUL = "Сoncentration of power!"

PrefabFiles = {
	
	"thief_ds",
	"thief_knife",
	"falchion",
	"chaosblade",
	"ricards_rapier",
	"mirrah_armor",
	"ds_knight",
	"broadsword",
	"claymore",
	"light_sword",
	"dark_sword",
	"knightarmor",
	"knighthelmet",
	"sunarmor",
	"sunhelmet",
	"estus_full",	
	"estus_empty",
	--"cleric_bell",
	--"lightning_projectile",
	"soul",
}

Assets = {
    Asset( "IMAGE", "images/saveslot_portraits/ds_knight.tex" ),
    Asset( "ATLAS", "images/saveslot_portraits/ds_knight.xml" ),

    Asset( "IMAGE", "images/selectscreen_portraits/ds_knight.tex" ),
    Asset( "ATLAS", "images/selectscreen_portraits/ds_knight.xml" ),
	
    Asset( "IMAGE", "images/selectscreen_portraits/ds_knight_silho.tex" ),
    Asset( "ATLAS", "images/selectscreen_portraits/ds_knight_silho.xml" ),

    Asset( "IMAGE", "bigportraits/ds_knight.tex" ),
    Asset( "ATLAS", "bigportraits/ds_knight.xml" ),
	
	Asset( "IMAGE", "images/map_icons/ds_knight.tex" ),
	Asset( "ATLAS", "images/map_icons/ds_knight.xml" ),
	
	--swords and armor of Knight
	Asset( "ATLAS", "images/inventoryimages/broadsword.xml" ),
	Asset( "IMAGE", "images/inventoryimages/broadsword.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/claymore.xml" ),
	Asset( "IMAGE", "images/inventoryimages/claymore.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/knightarmor.xml" ),
	Asset( "IMAGE", "images/inventoryimages/knightarmor.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/knighthelmet.xml" ),
	Asset( "IMAGE", "images/inventoryimages/knighthelmet.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/sunarmor.xml" ),
	Asset( "IMAGE", "images/inventoryimages/sunarmor.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/sunhelmet.xml" ),
	Asset( "IMAGE", "images/inventoryimages/sunhelmet.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/light_sword.xml" ),
	Asset( "IMAGE", "images/inventoryimages/light_sword.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/dark_sword.xml" ),
	Asset( "IMAGE", "images/inventoryimages/dark_sword.tex" ),
	
	
	--Thief
	Asset( "IMAGE", "images/saveslot_portraits/thief_ds.tex" ),
    Asset( "ATLAS", "images/saveslot_portraits/thief_ds.xml" ),

    Asset( "IMAGE", "images/selectscreen_portraits/thief_ds.tex" ),
    Asset( "ATLAS", "images/selectscreen_portraits/thief_ds.xml" ),
	
    Asset( "IMAGE", "images/selectscreen_portraits/thief_ds_silho.tex" ),
    Asset( "ATLAS", "images/selectscreen_portraits/thief_ds_silho.xml" ),

    Asset( "IMAGE", "bigportraits/thief_ds.tex" ),
    Asset( "ATLAS", "bigportraits/thief_ds.xml" ),
	
	Asset( "IMAGE", "images/map_icons/thief_ds.tex" ),
	Asset( "ATLAS", "images/map_icons/thief_ds.xml" ),
	
	--Thief blades
	Asset( "ATLAS", "images/inventoryimages/thief_knife.xml" ),
	Asset( "IMAGE", "images/inventoryimages/thief_knife.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/falchion.xml" ),
	Asset( "IMAGE", "images/inventoryimages/falchion.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/chaosblade.xml" ),
	Asset( "IMAGE", "images/inventoryimages/chaosblade.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/mirrah_armor.xml" ),
	Asset( "IMAGE", "images/inventoryimages/mirrah_armor.tex" ),
	
	Asset( "ATLAS", "images/inventoryimages/ricards_rapier.xml" ),
	Asset( "IMAGE", "images/inventoryimages/ricards_rapier.tex" ),
	--Drop
	Asset("ATLAS", "images/inventoryimages/soul.xml"),
    Asset("IMAGE", "images/inventoryimages/soul.tex"),
	

}




-- The character select screen lines
GLOBAL.STRINGS.CHARACTER_TITLES.ds_knight = "Strong Knight"
GLOBAL.STRINGS.CHARACTER_NAMES.ds_knight = "Knight"
GLOBAL.STRINGS.CHARACTER_DESCRIPTIONS.ds_knight = "*Strong and survivable, but slow\n*Have a sturdy armor and weapon\n*Pavid and have a few sanity"
GLOBAL.STRINGS.CHARACTER_QUOTES.ds_knight = "\"It will be easy!\""

--Thief
GLOBAL.STRINGS.CHARACTER_TITLES.thief_ds = "Fast Thief"
GLOBAL.STRINGS.CHARACTER_NAMES.thief_ds = "Thief"
GLOBAL.STRINGS.CHARACTER_DESCRIPTIONS.thief_ds = "*Very fast\n*Have a quick knife and swords \n*Resistant from neganive auras"
GLOBAL.STRINGS.CHARACTER_QUOTES.thief_ds = "\"Death will never catch me!\""

-- Custom speech strings
GLOBAL.STRINGS.CHARACTERS.DS_KNIGHT = require "speech_ds_knight"
GLOBAL.STRINGS.CHARACTERS.THIEF_DS = require "speech_thief_ds"

-- Let the game know character is male, female, or robot
table.insert(GLOBAL.CHARACTER_GENDERS.MALE, "ds_knight")
table.insert(GLOBAL.CHARACTER_GENDERS.FEMALE, "thief_ds")

modimport ("soul_loot.lua")

local soul = GLOBAL.Ingredient( "soul", 1)
soul.atlas = "images/inventoryimages/soul.xml"

local function knight_recipes(inst)
   if inst.prefab == "ds_knight" then
local light_swordrecipe = GLOBAL.Recipe( ("light_sword"), { soul, Ingredient("bluegem", 2), Ingredient("rocks", 4)}, RECIPETABS.WAR,  {SCIENCE = 2})
      light_swordrecipe.atlas = "images/inventoryimages/light_sword.xml"
	  
local dark_swordrecipe = GLOBAL.Recipe( ("dark_sword"), { soul, Ingredient("nightmarefuel", 5), Ingredient("marble", 1)}, RECIPETABS.WAR,  {SCIENCE = 2})
      dark_swordrecipe.atlas = "images/inventoryimages/dark_sword.xml" 
	  
local sunarmorrecipe = GLOBAL.Recipe( ("sunarmor"), {  Ingredient("papyrus", 4), Ingredient("goldnugget", 4), Ingredient("marble", 6)}, RECIPETABS.WAR,  {SCIENCE = 2})
     sunarmorrecipe.atlas = "images/inventoryimages/sunarmor.xml"
	  
local sunhelmetrecipe = GLOBAL.Recipe( ("sunhelmet"), { Ingredient("flint", 2), Ingredient("marble", 2), Ingredient("charcoal", 2)}, RECIPETABS.WAR,  {SCIENCE = 2})
      sunhelmetrecipe.atlas = "images/inventoryimages/sunhelmet.xml" 	  
end
end

AddSimPostInit( knight_recipes )

local function thief_recipes(inst)
   if inst.prefab == "thief_ds" then
local thief_kniferecipe = GLOBAL.Recipe( ("thief_knife"), { Ingredient("twigs", 4), Ingredient("flint", 1), Ingredient("cutgrass", 1) }, RECIPETABS.WAR,  {SCIENCE = 0})
      thief_kniferecipe.atlas = "images/inventoryimages/thief_knife.xml"
	  
local falchionrecipe = GLOBAL.Recipe( ("falchion"), { Ingredient("twigs", 5), Ingredient("marble", 1), Ingredient("rope", 1)}, RECIPETABS.WAR,  {SCIENCE = 1})
      falchionrecipe.atlas = "images/inventoryimages/falchion.xml" 
	  
local mirrah_armorrecipe = GLOBAL.Recipe( ("mirrah_armor"), { Ingredient("rope", 1), Ingredient("cutgrass", 7), Ingredient("petals_evil", 5)}, RECIPETABS.WAR,  {SCIENCE = 1})
      mirrah_armorrecipe.atlas = "images/inventoryimages/mirrah_armor.xml" 
	  
local  ricards_rapierrecipe = GLOBAL.Recipe( ("ricards_rapier"), { Ingredient("rocks", 1), Ingredient("goldnugget", 1), Ingredient("goose_feather", 2)}, RECIPETABS.WAR,  {SCIENCE = 1})
      ricards_rapierrecipe.atlas = "images/inventoryimages/ricards_rapier.xml" 	  
	  
local chaosbladerecipe = GLOBAL.Recipe( ("chaosblade"), { soul, Ingredient("nightmarefuel", 3), Ingredient("redgem", 1)}, RECIPETABS.WAR,  {SCIENCE = 2})
     chaosbladerecipe.atlas = "images/inventoryimages/chaosblade.xml"   
	  
end
end

AddSimPostInit( thief_recipes )


AddMinimapAtlas("images/map_icons/ds_knight.xml")
AddModCharacter("ds_knight")

AddMinimapAtlas("images/map_icons/thief_ds.xml")
AddModCharacter("thief_ds")
