Ejemplo n.º 1
0
class Healer( base.Monster ):
    name = "Healer"
    statline = { stats.STRENGTH: 12, stats.TOUGHNESS: 16, stats.REFLEXES: 12, \
        stats.INTELLIGENCE: 14, stats.PIETY: 18, stats.CHARISMA: 18 }
    SPRITENAME = "monster_spellcasters.png"
    FRAME = 16
    TEMPLATES = ()
    MOVE_POINTS = 10
    HABITAT = ( context.HAB_EVERY, context.HAB_BUILDING, context.SET_EVERY,
     context.DES_CIVILIZED, context.DES_SOLAR, context.DES_WATER, context.MTY_BOSS,
     context.MTY_HUMANOID, context.MTY_PRIEST, context.GEN_KINGDOM )
    ENC_LEVEL = 10
    TREASURE = treasuretype.HighItems( ( items.potions.PotionOfHealing, items.scrolls.Rank4Scroll, items.scrolls.Rank5Scroll ) )
    COMBAT_AI = aibrain.BasicTechnicalAI()
    COMPANIONS = (NoviceWarrior,NovicePriest,Warrior)
    ATTACK = items.Attack( (3,6,0), element = stats.RESIST_SOLAR,
        hit_anim=animobs.YellowExplosion )
    TECHNIQUES = ( spells.priestspells.SMITE, spells.solarspells.MASS_CURE,
        spells.solarspells.MAXIMUM_CURE, invocations.MPInvocation( "Repent",
            effects.TargetIsAlly( on_true = (
                effects.Enchant( enchantments.BlessingEn, anim=animobs.GreenSparkle ),
                effects.TargetIsDamaged( on_true= (
                    effects.HealthRestore( dice=(3,12,12) ),
                ))
            ), on_false=(
                effects.TargetIsEnemy( on_true = (
                    effects.HealthDamage( (3,12,0), stat_bonus=stats.CHARISMA, element=stats.RESIST_WATER, anim=animobs.Bubbles ),
                )),
            )), shot_anim=animobs.BlueComet, com_tar=targetarea.Blast(radius=3),
            ai_tar=invocations.TargetEnemy(), mp_cost=12 )
        )
    def init_monster( self ):
        self.levels.append( base.Spellcaster( 6, self ) )
        self.levels.append( base.Defender( 4, self ) )
Ejemplo n.º 2
0
class MadMonk(base.Monster):
    name = "Mad Monk"
    statline = { stats.STRENGTH: 12, stats.TOUGHNESS: 14, stats.REFLEXES: 16, \
        stats.INTELLIGENCE: 12, stats.PIETY: 16, stats.CHARISMA: 10,
        stats.NATURAL_DEFENSE: -10, stats.MAGIC_DEFENSE: 10 }
    SPRITENAME = "monster_chaos.png"
    FRAME = 7
    TEMPLATES = ()
    MOVE_POINTS = 10
    HABITAT = (context.HAB_EVERY, context.HAB_DESERT, context.SET_EVERY,
               context.MTY_HUMANOID, context.MTY_FIGHTER, context.MTY_PRIEST,
               context.DES_FIRE, context.GEN_CHAOS)
    ENC_LEVEL = 5
    TREASURE = treasuretype.Standard((items.POTION, items.CLOTHES))
    TECHNIQUES = (invocations.MPInvocation(
        "Fire Soul",
        effects.TargetIsAlly(
            on_true=(effects.Enchant(enchantments.RegeneratEn,
                                     anim=animobs.RedCloud),
                     effects.TargetIsDamaged(on_true=(effects.HealthRestore(
                         dice=(2, 6, 0)), ))),
            on_false=(effects.HealthDamage((2, 6, 0),
                                           stat_bonus=None,
                                           element=stats.RESIST_FIRE,
                                           anim=animobs.RedCloud), )),
        com_tar=targetarea.SelfCentered(radius=2, delay_from=-1),
        ai_tar=invocations.TargetWoundedAlly(),
        mp_cost=25), )
    ATTACK = items.Attack((1, 8, 0),
                          element=stats.RESIST_CRUSHING,
                          extra_effect=effects.ManaDamage(
                              (1, 8, 0),
                              stat_bonus=None,
                              anim=animobs.PurpleExplosion))

    def init_monster(self):
        self.levels.append(base.Humanoid(5, self))
Ejemplo n.º 3
0
from base import SOLAR, EARTH, WATER, FIRE, AIR, LUNAR, Spell
import effects
import targetarea
import enchantments
import animobs
import stats
import invocations

# CIRCLE 1

BLESSING = Spell(
    "Blessing",
    "Increases the physical and magic attack scores of all allies within 6 tiles by +5%. This effect lasts until the end of combat.",
    effects.TargetIsAlly(on_true=(effects.Enchant(
        enchantments.BlessingEn, anim=animobs.YellowSparkle), )),
    rank=1,
    gems={SOLAR: 1},
    com_tar=targetarea.SelfCentered(),
    ai_tar=invocations.TargetAllyWithoutEnchantment(enchantments.BlessingEn),
    mpfudge=-1)

MINOR_CURE = Spell("Minor Cure",
                   "This spell will heal one nearby ally for 1-10 damage.",
                   effects.HealthRestore(dice=(1, 10, 0)),
                   rank=1,
                   gems={SOLAR: 1},
                   com_tar=targetarea.SingleTarget(reach=1),
                   ai_tar=invocations.TargetWoundedAlly(),
                   exp_tar=targetarea.SinglePartyMember())

# CIRCLE 2
Ejemplo n.º 4
0
from base import SOLAR, EARTH, WATER, FIRE, AIR, LUNAR, Spell
import effects
import targetarea
import enchantments
import animobs
import stats
import invocations
import context

# CIRCLE ONE

AIR_ARMOR = Spell(
    "Shield of Wind",
    "Increases the physical and magical defense of all allies within 6 tiles by +5%. This effect lasts until the end of combat.",
    effects.TargetIsAlly(on_true=(
        effects.Enchant(enchantments.AirArmor, anim=animobs.BlueSparkle), )),
    rank=1,
    gems={AIR: 1},
    com_tar=targetarea.SelfCentered(),
    ai_tar=invocations.TargetAllyWithoutEnchantment(enchantments.AirArmor))

PROBE = Spell("Probe",
              "This spell reveals secret knowledge about one target creature.",
              effects.NoEffect(anim=animobs.BlueSparkle,
                               children=(effects.Probe(), )),
              rank=1,
              gems={AIR: 1},
              mpfudge=-1,
              com_tar=targetarea.SingleTarget(),
              exp_tar=targetarea.SingleTarget())
Ejemplo n.º 5
0
    "Imbues a single ally with supernatural strength, giving +4 strength, +4 toughness, and +5% to attack.",
    effects.Enchant(enchantments.BeastlyMightEn, anim=animobs.OrangeSparkle),
    rank=2,
    gems={EARTH: 1},
    com_tar=targetarea.SingleTarget(),
    ai_tar=invocations.TargetAllyWithoutEnchantment(
        enchantments.BeastlyMightEn))

# CIRCLE 3

SHAPE_FLESH = Spell(
    "Shape Flesh",
    "By touching a living creature, you may reshape its flesh so as to either cause or cure 3-18 damage.",
    effects.TargetIs(
        effects.ALIVE,
        on_true=(effects.TargetIsAlly(
            on_true=(effects.HealthRestore(dice=(3, 6, 0)), ), ),
                 effects.TargetIsEnemy(
                     on_true=(effects.HealthDamage((3, 6, 0),
                                                   stat_bonus=None,
                                                   element=stats.RESIST_ATOMIC,
                                                   anim=animobs.RedBoom), ))),
        on_false=(effects.NoEffect(anim=animobs.SmallBoom), )),
    rank=3,
    gems={EARTH: 2},
    com_tar=targetarea.SingleTarget(reach=1),
    exp_tar=targetarea.SinglePartyMember(),
    mpfudge=-1)

# CIRCLE 4

WOOD_SKIN = Spell(
Ejemplo n.º 6
0
# CIRCLE 3

ACID_CLOUD = Spell( "Acid Cloud",
    "Calls forth billowing clouds of acid which do 2d6 damage to all targets within 3 tiles.",
    effects.OpposedRoll( on_success = (
        effects.HealthDamage( (2,6,0), stat_bonus=stats.INTELLIGENCE, element=stats.RESIST_ACID, anim=animobs.GreenCloud )
    ,), on_failure = (
        effects.HealthDamage( (1,6,0), stat_bonus=None, element=stats.RESIST_ACID, anim=animobs.GreenCloud )
    ,) ), rank=3, gems={EARTH:1,LUNAR:1}, com_tar=targetarea.Blast(radius=3), shot_anim=animobs.GreenComet, 
    ai_tar=invocations.TargetEnemy(min_distance=4) )

PROTECT_FROM_GOOD = Spell( "Protection from Good",
    "All allies within 6 tiles get +10% defense, +10% aura, and 50% resistance to holy damage for the duration of combat.",
    effects.TargetIsAlly( on_true = (
        effects.Enchant( enchantments.ProtectFromGoodEn, anim=animobs.PurpleSparkle ),
    )),
    rank=3, gems={LUNAR:1,WATER:1}, com_tar=targetarea.SelfCentered(),
    ai_tar=invocations.TargetAllyWithoutEnchantment(enchantments.ProtectFromGoodEn) )


# CIRCLE FOUR

RAISE_UNDEAD = Spell( "Raise Undead",
    "You conjure dark forces to animate an undead creature which will fight on your behaf.",
    effects.CallMonster( {context.MTY_UNDEAD: True, context.DES_LUNAR: context.MAYBE, context.GEN_UNDEAD: context.MAYBE}, 8, anim=animobs.PurpleSparkle ),
    rank=4, gems={EARTH:1,LUNAR:2}, com_tar=targetarea.SingleTarget(reach=2), ai_tar=invocations.TargetEmptySpot(), mpfudge=6 )

ICE_WEAPON = Spell( "Icy Weapon",
    "One ally's weapon will glow with magical cold, causing an extra 1-10 points of damge per hit and potentially freezing enemies solid. This effect lasts until the end of combat.",
    effects.Enchant( enchantments.FrostWepEn, anim=animobs.PurpleSparkle ),
Ejemplo n.º 7
0
        effects.HealthDamage( (2,4,0), stat_bonus=stats.INTELLIGENCE, element=stats.RESIST_FIRE, anim=animobs.OrangeExplosion ),
        effects.HealthDamage( (2,4,0), stat_bonus=stats.INTELLIGENCE, element=stats.RESIST_COLD, anim=animobs.BlueBoom ),
        effects.HealthDamage( (2,4,0), stat_bonus=stats.INTELLIGENCE, element=stats.RESIST_LIGHTNING, anim=animobs.BlueZap ),
        effects.HealthDamage( (2,4,0), stat_bonus=stats.INTELLIGENCE, element=stats.RESIST_ACID, anim=animobs.GreenSplat )
    ), on_failure = (
        effects.HealthDamage( (2,4,0), stat_bonus=None, element=stats.RESIST_FIRE, anim=animobs.OrangeExplosion ),
        effects.HealthDamage( (2,4,0), stat_bonus=None, element=stats.RESIST_COLD, anim=animobs.BlueBoom ),
        effects.HealthDamage( (2,4,0), stat_bonus=None, element=stats.RESIST_LIGHTNING, anim=animobs.BlueZap ),
        effects.HealthDamage( (2,4,0), stat_bonus=None, element=stats.RESIST_ACID, anim=animobs.GreenSplat )
    ) ), rank=5, gems={FIRE:2,SOLAR:1}, com_tar=targetarea.Blast(radius=3), shot_anim=animobs.CrystalBall, 
    ai_tar=invocations.TargetEnemy(min_distance=4) )

TRANSFORMATION = Spell( "Transformation",
    "Transforms all allies within six tiles, providing +10% to defense plus 25% resistance to slashing, crushing, and piercing damage.",
    effects.TargetIsAlly( on_true = (
        effects.Enchant( enchantments.WoodSkinEn, anim=animobs.OrangeSparkle ),
    )), rank=5, gems={EARTH:3,FIRE:1}, com_tar=targetarea.SelfCentered(),
    ai_tar=invocations.TargetAllyWithoutEnchantment(enchantments.WoodSkinEn) )


# CIRCLE SIX

CALL_BEHEMOTH = Spell( "Call Behemoth",
    "This spell will summon a very powerful monster to fight on your behaf.",
    effects.CallMonster( {context.MTY_CREATURE: True, context.DES_EARTH: context.MAYBE, context.GEN_NATURE: context.MAYBE, context.DES_SOLAR: context.MAYBE}, 12, anim=animobs.OrangeSparkle ),
    rank=6, gems={EARTH:2,SOLAR:2}, com_tar=targetarea.SingleTarget(reach=2), ai_tar=invocations.TargetEmptySpot(), mpfudge = 12 )


# CIRCLE SEVEN

CALL_COLOSSUS = Spell( "Call Colossus",
                             stat_bonus=None,
                             element=stats.RESIST_SOLAR,
                             anim=animobs.YellowExplosion), )), )),
    rank=2,
    gems={
        SOLAR: 1,
        WATER: 1
    },
    com_tar=targetarea.SelfCentered(radius=3, exclude_middle=True),
    mpfudge=-2,
    ai_tar=invocations.TargetEnemy())

HEROISM = Spell(
    "Heroism",
    "All allies within 6 tiles get a +2 bonus to strength, toughness, reflexes, intelligence, piety, and charisma until the end of combat.",
    effects.TargetIsAlly(on_true=(effects.Enchant(
        enchantments.HeroismEn, anim=animobs.YellowSparkle), )),
    rank=2,
    gems={
        AIR: 1,
        WATER: 1
    },
    com_tar=targetarea.SelfCentered(),
    ai_tar=invocations.TargetAllyWithoutEnchantment(enchantments.HeroismEn))

# CIRCLE THREE

HEALING_LIGHT = Spell("Healing Light",
                      "Blessed radiance will heal one ally for 3-24 damage.",
                      effects.HealthRestore(dice=(3, 8, 0)),
                      rank=3,
                      gems={