## References # http://crawl.akrasiac.org/docs/options_guide.txt # http://doc.dcss.io/modules/you.html # https://crawl.develz.org/wiki/doku.php?id=dcss:help:maps:lua:modules:you:start # https://github.com/crawl/crawl/tree/master/crawl-ref/source/rltiles/mon # https://github.com/crawl/crawl/blob/master/crawl-ref/source/rltiles/dc-mon.txt ## Dependency # Call 'FormChange()' in your ready() function. : crawl.mpr("FormChange.rc is included.") : is_included_FormChange = true { local oldXL = 0 function FormChange() if you.xl() ~= oldXL then oldXL = you.xl() else return end if you.race() == "Draconian" then crawl.setopt("tile_player_tile = playermons") end if you.race() == "Minotaur" then if you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_minotaur") else crawl.setopt("tile_player_tile = tile:mons_asterion") end end if you.race() == "Demigod" then if you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_demigod") else crawl.setopt("tile_player_tile = tile:mons_frederick") end end if you.race() == "Formicid" then if you.xl() < 4 then crawl.setopt("tile_player_tile = tile:mons_worker_ant") elseif you.xl() < 8 then crawl.setopt("tile_player_tile = tile:mons_soldier_ant") elseif you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_queen_ant") elseif you.xl() < 16 then crawl.setopt("tile_player_tile = tile:mons_formicid") else crawl.setopt("tile_player_tile = tile:mons_entropy_weaver") end end if you.race() == "Deep Dwarf" then if you.xl() < 12 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_dwarf") else crawl.setopt("tile_player_tile = tile:mons_deep_dwarf") end else if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_wiglaf") else crawl.setopt("tile_player_tile = tile:mons_jorgrun") end end end if you.race() == "Human" or you.race() == "halfling" then if you.god() == "Lugonu" then crawl.setopt("tile_player_tile = tile:mons_louise") elseif you.god() == "Xom" or you.god() == "Nemelex Xobeh" then crawl.setopt("tile_player_tile = tile:mons_killer_klown") elseif you.god() == "Okawaru" then crawl.setopt("tile_player_tile = tile:mons_donald") elseif you.god() == "Trog" then crawl.setopt("tile_player_tile = tile:mons_rupert") elseif you.god() == "Yredelemnul" then crawl.setopt("tile_player_tile = tile:mons_death_knight") elseif you.god() == "Makhleb" then crawl.setopt("tile_player_tile = tile:mons_hell_knight") elseif you.god() == "Zin" then crawl.setopt("tile_player_tile = tile:mons_mennas") elseif you.best_skill() == "Necromancy" then crawl.setopt("tile_player_tile = tile:mons_josephine") elseif you.best_skill() == "Summonings" then crawl.setopt("tile_player_tile = tile:mons_kirke") elseif you.best_skill() == "Fire magic" then crawl.setopt("tile_player_tile = tile:mons_margery") elseif you.best_skill() == "Air magic" then crawl.setopt("tile_player_tile = tile:mons_nikola") elseif you.best_skill() == "Polearms" then crawl.setopt("tile_player_tile = tile:mons_edmund") elseif you.best_skill() == "Maces & Flails" then crawl.setopt("tile_player_tile = tile:mons_edmund") elseif you.best_skill() == "Long blades" then crawl.setopt("tile_player_tile = tile:mons_erica") elseif you.best_skill() == "Slings" then crawl.setopt("tile_player_tile = tile:mons_joseph") elseif you.best_skill() == "Hexes" then crawl.setopt("tile_player_tile = tile:mons_psyche") elseif you.best_skill() == "Fighting" then crawl.setopt("tile_player_tile = tile:mons_terence") elseif you.best_skill() == "Spellcasting" then crawl.setopt("tile_player_tile = tile:mons_wizard") elseif you.best_skill() == "Stealth" then crawl.setopt("tile_player_tile = tile:mons_maurice") else crawl.setopt("tile_player_tile = tile:mons_human") end end if you.race() == "Felid" then if you.xl() < 3 then crawl.setopt("tile_player_tile = tile:felid_2") elseif you.xl() < 6 then crawl.setopt("tile_player_tile = tile:felid_1") elseif you.xl() < 9 then crawl.setopt("tile_player_tile = tile:felid_3") elseif you.xl() < 12 then crawl.setopt("tile_player_tile = tile:felid_6") elseif you.xl() < 15 then crawl.setopt("tile_player_tile = tile:felid_5") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:felid_8") elseif you.xl() < 21 then crawl.setopt("tile_player_tile = tile:felid_7") elseif you.xl() < 24 then crawl.setopt("tile_player_tile = tile:felid_4") else crawl.setopt("tile_player_tile = tile:mons_natasha") end end if you.race() == "Demonspawn" then if you.xl() == 2 and you.get_base_mutation_level("antennae", true, false, false) >= 1 then else if you.get_base_mutation_level("magic link", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_blood_saint") elseif you.get_base_mutation_level("black mark", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_black_sun") elseif you.get_base_mutation_level("powered by death", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_warmonger") elseif you.get_base_mutation_level("demonic guardian", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_corrupter") elseif you.get_base_mutation_level("ignite blood", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_infernal_demonspawn") elseif you.get_base_mutation_level("passive freeze", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_gelid_demonspawn") elseif you.get_base_mutation_level("spiny", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_torturous_demonspawn") elseif you.get_base_mutation_level("nightstalker", true, false, false) >= 1 then crawl.setopt("tile_player_tile = tile:mons_monstrous_demonspawn") else crawl.setopt("tile_player_tile = tile:mons_demonspawn") end end end if you.race() == "Deep Elf" then if you.xl() < 12 then if you.base_skill("Bows") >= 14 then crawl.setopt("tile_player_tile = tile:mons_deep_elf_archer") elseif you.base_skill("Short Blades") >= 10 then crawl.setopt("tile_player_tile = tile:mons_deep_elf_knight") elseif you.base_skill("Long Blades") >= 10 then crawl.setopt("tile_player_tile = tile:mons_deep_elf_knight") else crawl.setopt("tile_player_tile = tile:mons_deep_elf_mage") end else if you.base_skill("Bows") >= 18 then crawl.setopt("tile_player_tile = tile:mons_deep_elf_master_archer") elseif you.base_skill("Short Blades") >= 14 then crawl.setopt("tile_player_tile = tile:mons_deep_elf_blademaster") elseif you.base_skill("Long Blades") >= 14 then crawl.setopt("tile_player_tile = tile:mons_deep_elf_blademaster") elseif you.base_skill("Summonings") > you.base_skill("Fire Magic") then crawl.setopt("tile_player_tile = tile:mons_deep_elf_demonologist") elseif you.base_skill("Necromancy") > you.base_skill("Fire Magic") then crawl.setopt("tile_player_tile = tile:mons_deep_elf_death_mage") elseif you.base_skill("Air Magic") > you.base_skill("Fire Magic") then crawl.setopt("tile_player_tile = tile:mons_deep_elf_elementalist") elseif you.base_skill("Earth Magic") > you.base_skill("Fire Magic") then crawl.setopt("tile_player_tile = tile:mons_deep_elf_annihilator") elseif you.base_skill("Ice Magic") > you.base_skill("Fire Magic") then crawl.setopt("tile_player_tile = tile:mons_deep_elf_high_priest") else crawl.setopt("tile_player_tile = tile:mons_deep_elf_sorcerer") end end end if you.race() == "Gargoyle" then if you.xl() < 9 then crawl.setopt("tile_player_tile = tile:mons_gargoyle") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_molten_gargoyle") else crawl.setopt("tile_player_tile = tile:mons_war_gargoyle") end end if you.race() == "Centaur" then if you.xl() < 9 then crawl.setopt("tile_player_tile = tile:mons_centaur") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_centaur_warrior") else crawl.setopt("tile_player_tile = tile:mons_nessos") end end if you.race() == "Octopode" then if you.xl() < 9 then crawl.setopt("tile_player_tile = tile:mons_octopode") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_tentacled_monstrosity") else crawl.setopt("tile_player_tile = tile:mons_cigotuvis_monster") end end if you.race() == "Kobold" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_kobold") elseif you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_big_kobold") elseif you.xl() < 18 then if you.base_skill("Summonings") >= 10 then crawl.setopt("tile_player_tile = tile:mons_kobold_demonologist") else crawl.setopt("tile_player_tile = tile:mons_pikel") end else crawl.setopt("tile_player_tile = tile:mons_sonja") end end if you.race() == "Ghoul" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_necrophage") elseif you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_bog_body") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_ghoul") else crawl.setopt("tile_player_tile = tile:mons_jiangshi") end end if you.race() == "Barachi" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_bullfrog") elseif you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_spiny_frog") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_blink_frog") else crawl.setopt("tile_player_tile = tile:mons_prince_ribbit") end end if you.race() == "Tengu" then if you.xl() < 5 then crawl.setopt("tile_player_tile = tile:mons_tengu") elseif you.xl() < 12 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_tengu_warrior") else crawl.setopt("tile_player_tile = tile:mons_tengu_conjurer") end elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_tengu_reaver") else crawl.setopt("tile_player_tile = tile:mons_sojobo") end end if you.race() == "Gnoll" then if you.god() == "Xom" then crawl.setopt("tile_player_tile = tile:mons_crazy_yiuf") elseif you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_gnoll") elseif you.xl() < 12 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_gnoll_sergeant") else crawl.setopt("tile_player_tile = tile:mons_gnoll_shaman") end elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_grum") else crawl.setopt("tile_player_tile = tile:mons_crazy_yiuf") end end if you.race() == "Vampire" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_vampire") elseif you.xl() < 18 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_vampire_knight") else crawl.setopt("tile_player_tile = tile:mons_vampire_mage") end else crawl.setopt("tile_player_tile = tile:mons_jory") end end if you.race() == "Merfolk" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_merfolk") elseif you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_merfolk_impaler") elseif you.xl() < 18 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_merfolk_javelineer") else crawl.setopt("tile_player_tile = tile:mons_merfolk_aquamancer") end else crawl.setopt("tile_player_tile = tile:mons_ilsuiw") end end if you.race() == "Spriggan" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_spriggan") elseif you.xl() < 12 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_spriggan_defender") else crawl.setopt("tile_player_tile = tile:mons_spriggan_druid") end elseif you.xl() < 18 then if you.flying() == true then crawl.setopt("tile_player_tile = tile:mons_spriggan_rider") elseif you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_spriggan_berserker") else crawl.setopt("tile_player_tile = tile:mons_spriggan_air_mage") end else if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_agnes") else crawl.setopt("tile_player_tile = tile:mons_the_enchantress") end end end if you.race() == "Hill Orc" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_orc") elseif you.xl() < 12 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_orc_warrior") else crawl.setopt("tile_player_tile = tile:mons_orc_wizard") end elseif you.xl() < 18 then if you.god() == "Beogh" then crawl.setopt("tile_player_tile = tile:mons_orc_priest") elseif you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_urug") else crawl.setopt("tile_player_tile = tile:mons_blork_the_orc") end elseif you.xl() < 22 then if you.god() == "Beogh" then crawl.setopt("tile_player_tile = tile:mons_orc_high_priest") elseif you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_orc_knight") else crawl.setopt("tile_player_tile = tile:mons_orc_sorcerer") end else if you.god() == "Beogh" then crawl.setopt("tile_player_tile = tile:mons_saint_roka") elseif you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_warlord") else crawl.setopt("tile_player_tile = tile:mons_nergalle") end end end if you.race() == "Troll" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_purgy") elseif you.xl() < 10 then crawl.setopt("tile_player_tile = tile:mons_troll") elseif you.xl() < 14 then crawl.setopt("tile_player_tile = tile:mons_snorg") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_deep_troll") elseif you.xl() < 22 then if you.base_skill("Earth Magic") >= 9 then crawl.setopt("tile_player_tile = tile:mons_deep_troll_earth_mage") else crawl.setopt("tile_player_tile = tile:mons_deep_troll_shaman") end else crawl.setopt("tile_player_tile = tile:mons_iron_troll") end end if you.race() == "Ogre" then if you.xl() < 9 then crawl.setopt("tile_player_tile = tile:mons_ogre") elseif you.xl() < 18 then if you.base_skill("SpellCasting") >= 10 then crawl.setopt("tile_player_tile = tile:mons_ogre_mage") else crawl.setopt("tile_player_tile = tile:mons_two_headed_ogre") end else crawl.setopt("tile_player_tile = tile:mons_erolcha") end end if you.race() == "Naga" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_naga") elseif you.xl() < 10 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_naga_warrior") else crawl.setopt("tile_player_tile = tile:mons_naga_ritualist") end elseif you.xl() < 14 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_naga_sharpshooter") else crawl.setopt("tile_player_tile = tile:mons_naga_mage") end elseif you.xl() < 18 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_vashnia") else crawl.setopt("tile_player_tile = tile:mons_nagaraja") end else crawl.setopt("tile_player_tile = tile:mons_lamia") end end if you.race() == "Mummy" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_mummy") elseif you.xl() < 13 then crawl.setopt("tile_player_tile = tile:mons_guardian_mummy") elseif you.xl() < 18 then crawl.setopt("tile_player_tile = tile:mons_mummy_priest") elseif you.xl() < 22 then crawl.setopt("tile_player_tile = tile:mons_grater_mummy") else crawl.setopt("tile_player_tile = tile:mons_menkaure") end end if you.race() == "Vine Stalker" then if you.xl() < 6 then crawl.setopt("tile_player_tile = tile:mons_vine_stalker") elseif you.xl() < 12 then crawl.setopt("tile_player_tile = tile:mons_oklob_sapling") elseif you.xl() < 18 then if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_mons_dryad") else crawl.setopt("tile_player_tile = tile:mons_oklob_plant") end else if you.base_skill("Fighting") > you.base_skill("SpellCasting") then crawl.setopt("tile_player_tile = tile:mons_treant") else crawl.setopt("tile_player_tile = tile:mons_thorn_hunter") end end end end }