FORUM ARCHIVED

What's wrong in this code?

Discussion in 'Modding' started by Cullen, Dec 19, 2012.

  1. Cullen

    Cullen Member

    <spell name="Crab Attack Scale " type="target" icon="skills/warrior/berserker0_32.png" wand="0">
    <anim sprite="sprites/sfx/rage/rage" frames="3" framerate="50" sfx="ping" />
    <buff useTimer="1" time="11" stacksize="1" icon="skills/spells/monstrous_rage64.png" smallicon="skills/spells/monstrous_rage32.png">
    <targetHitEffectBuff percentage="100" name="Crab Attack Scale " />
    </buff>
    <description text="This rage is monstrous!" monsterText="smoulders with RAGE!"/>
    <ai hint="buff"/>
    </spell>

    <spell name="Toxic Spore Cloud "
    type="targetfloor"
    icon="skills/spells/lethian_mist32.png"
    mineTimer="18"
    mineUseGlints="1"
    mineGlintDensity="8"
    mineSpritePNGSeries="sprites/sfx/smokepuffA/smokepuffA"
    mineSpritePNGFirst="0"
    mineSpritePNGNum="8"
    mineSpritePNGRate="120"
    mine="1"
    mineradius="1" >
    <description text="Creates clouds of highly-confusing toxic spores."/>
    <effect type="trigger" spell="Pyrokinesis" />
    <anim sprite="sprites/sfx/smokepuffbig/smokepuffbig" frames="6" sfx="darkmagic" centerEffect="1"/>
    </spell>


    <spell name="Raise the Diggles" type="targetfloor" icon="skills/core_diggle32.png" >
    <requirements mp="1" />
    <effect type="trigger" spell="Raise the Diggles 2" />
    <effect type="trigger" spell="Find Crustaceanoid" />
    <anim sprite="sprites/sfx/summonA/summonA" frames="10" framerate="100" sfx="blast" centerEffect="1"/>
    <description text="Summon a Hunting Diggle." />
    </spell>

    <spell name="Raise the Diggles 2" type="template" templateID="5925" icon="skills/core_diggle32.png" >
    <requirements mp="1" />
    <effect type="summon" monsterType="Crustaceanoid MK II" amount="20" />
    <effect type="trigger" spell="Toxic Spore Cloud " />
    <anim sprite="sprites/sfx/summonA/summonA" frames="10" framerate="100" sfx="blast" centerEffect="1"/>
    <description text="Summon a Hunting Diggle." />
    </spell>

    <spell name="Raise the Diggles 3" type="template" templateID="5926" icon="skills/core_diggle32.png" >
    <requirements mp="1" />
    <effect type="summon" monsterType="Crustaceanoid MK III" amount="0" />
    <anim sprite="sprites/sfx/summonA/summonA" frames="10" framerate="100" sfx="blast" centerEffect="1"/>
    <description text="Summon a Hunting Diggle." />
    </spell>



    <spell name="Find Crustaceanoid" type="area" radius="100">
    <effect type="trigger" spell="Activate Crustaceanoid" amount="1" />
    <effect type="trigger" spell="Crab Attack Scale " taxa="Crustaceanoid" amount="1" />
    <effect type="trigger" spell="De-Activate Crustaceanoid" amount="11" />
    <anim sprite="sprites/sfx/summonA/summonA" frames="2" framerate="1" />
    <description text="First discovered by the great Doc Brown, Brownian Motion forces your body into the gap between space and time. As long as this is maintained your physical form will periodically realign itself." />
    </spell>


    <spell name="Activate Crustaceanoid" type="target">
    <effect type="damage" existential="190" taxa="Crustaceanoid" resistable="0" />
    <effect type="heal" amount="1" amountF="1" primaryScale="5" taxa="Crustaceanoid" />
    </spell>

    <spell name="De-Activate Crustaceanoid" type="target">
    <effect type="damage" existential="250" taxa="Crustaceanoid" resistable="0" />
    </spell>

    <spell name="Crab Charm" type="target" icon="skills/spells/unconditional_love32.png" >
    <requirements mp="32" savvyBonus="0.48" />
    <effect type="charm" turns="100" taxa="Crustaceanoid" />
    <description text="Magically charms a monster into giving up their evil ways to become your buddy ... for a short time. Then they just stab you in the back again." />
    <anim sprite="sprites/sfx/psionic_generic/psionic_generic" frames="5" framerate="70" sfx="choir"/>
    </spell>


    <spell name="Crab Attack Scale " type="target" >
    <effect type="damage" slashing="1" slashingF="5" primaryScale="5" affectscaster="1"/>
    </spell>

    Problem is,

    1) At 1floor their hp scales well, but after 2 floor, they summon'd with half hp like damage is resist'd. sometimes even 1floor they resist damage. (reduce resist to 0 may fix it but i never tried.)

    2) Crab scale somehow buff me instead of crabs. well. crap

    3) I tried let them have 100% spell use and summon as hostile -> charm them after 2 turn. they start kill each other after charm'd and sometimes un-charm'd.

    4) on hit doesn't work

    <monster name="Crustaceanoid MK III" level="1" special="1" taxa="Crustaceanoid">
    <idleSprite
    left="sprites/monster/crustaceanoid/crustaceanoid_idle_l.xml"
    right="sprites/monster/crustaceanoid/crustaceanoid_idle_r.xml"
    up="sprites/monster/crustaceanoid/crustaceanoid_idle_u.xml"
    down="sprites/monster/crustaceanoid/crustaceanoid_idle_d.xml"/>
    <attackSprite
    left="sprites/monster/crustaceanoid/crustaceanoid_atk_l.xml"
    right="sprites/monster/crustaceanoid/crustaceanoid_atk_r.xml"
    up="sprites/monster/crustaceanoid/crustaceanoid_atk_u.xml"
    down="sprites/monster/crustaceanoid/crustaceanoid_atk_d.xml"/>
    <hitSprite
    left="sprites/monster/crustaceanoid/crustaceanoid_idle_l.xml"
    right="sprites/monster/crustaceanoid/crustaceanoid_idle_r.xml"
    up="sprites/monster/crustaceanoid/crustaceanoid_idle_u.xml"
    down="sprites/monster/crustaceanoid/crustaceanoid_idle_d.xml"/>
    <!-- TODO: NEED HIT SPRITES -->
    <dieSprite
    name="sprites/monster/crustaceanoid/crustaceanoid_death.xml"/>
    <castSpellSprite
    name="sprites/monster/crustaceanoid/crustaceanoid_cast.xml" />

    <sfx attack="batty_attack"
    hit="batty_damage"
    die="batty_die"
    spell="batty_cast"/>

    <stats numFig="5" xpValue="1" />
    <damage slashing="2" piercing="2" />
    <secondarybuff id="0" amount="175"/> <!-- hp -->
    <secondarybuff id="10" amount="1"/> <!-- armour -->
    <info latin="(Crustacea sapiens)" text="It came from crabby shores to seek adventure."/>

    <spell name="Aethereal Missile"/>
    <ai aggressiveness="4" span="16" spellPercentage="100"/>
    <sight cone="90" modifier="1.35" />

    <monster name="Crustaceanoid MK II" level="1" special="1">
    <onhit spell="Diggle Flu" onechancein="5" />
    <stats numFig="5" xpValue="1" />
    <damage slashing="2" piercing="2" />
    <secondarybuff id="0" amount="175"/> <!-- hp -->
    <secondarybuff id="10" amount="1"/> <!-- armour -->
    <info text="The Djinn Fizz likes to blow things up. It's not a complicated thinker."/>
    <ai aggressiveness="7" span="24" spellPercentage="100"/>
    <spell name="Crab Attack Scale"/>
    </monster>

    <monster name="Crustaceanoid MK III" level="1" special="1">
    <ai aggressiveness="5" span="6" />
    <stats numFig="5" xpValue="1" />
    <damage slashing="2" piercing="2" />
    <secondarybuff id="0" amount="175"/> <!-- hp -->
    <secondarybuff id="10" amount="1"/> <!-- armour -->
    <info latin="(Crustacea sapiens)" text="It came from crabby shores to seek adventure."/>
    </monster>

    </monster>
     
    OmniaNigrum likes this.
  2. Kazeto

    Kazeto Member

    Please bear in mind that I am replying while pretty much half-asleep, so don't do anything radical just because I wrote it.

    Re.1: Make the healing effect non-resistable? Or stuff like that, it's stupid so it might help.
    Re.2: Player responds to every taxa ever, really.
    Re.3: It's an issue with monsters summoned as hostile - they keep their "enforced hostile" status even after being charmed, and thus the genocide your charmed troops partake in (because anything currently marked as "hostile" is fair game for minion targeting).
    Re.4: It's chance-based from what I see, so it is possible for it never to had triggered due to a streak of bad luck.
     
    OmniaNigrum likes this.
  3. Cullen

    Cullen Member

    ninja'd (log-out'd when typing :( )

    Re.1: Problem was they don't take damage. i never'd see they resist heal Edit : i think i made confuse. i mean they summon with half of their max hp. which 100-ish

    Re.2: fix'd with "i'm not crab" (remove buff right after buff. also self="0"

    Re.3: yes right. I also notice they only kill one as a team and left other 2 are friendly, sometimes they also kill each other until left only one

    Re.4: No. i tested with 100%




    1) half-fixed, reduce resist doesn't change anything(or i just didn't notice difference) but deal x2 damage cause cannot summon at 1 floor. but well scale at 2 floor (with somewhat more hp, like 10?). but after 3floor have slightly more health(i don't know 4 floor tho) like 30 ~ 50? floor scale may fix this but i have no idea how is it work. any mod using it?

    2) Fix'd, used self="0" and i'm not crab, but targethiteffectbuff does not work with monster. but this is work

    <spell name="Crab Attack Scale " type="target" icon="skills/warrior/berserker0_32.png" wand="0">
    <anim sprite="sprites/sfx/rage/rage" frames="3" framerate="50" sfx="ping" />
    <buff useTimer="1" self="0" time="11" stacksize="1" icon="skills/spells/monstrous_rage64.png" smallicon="skills/spells/monstrous_rage32.png">
    <description text="This rage is monstrous!" monsterText="smoulders with RAGE!"/>
    <targetHitEffectBuff percentage="100" name="Pyrokinesis" />
    </buff>
    <effect type="dot" amount="5" spell="Corpse Removal 2" />
    <ai hint="buff"/>
    </spell>

    <spell name="Corpse Removal 2" type="template" templateID="20" anchored="0">
    <effect type="damage" blasting="1" blastingF="0.2" primaryScale="5" affectscaster="0" />
    </spell>

    maybe make similar attack scale? (pyrokinesis doesn't work but dot effect work until pet dead. if i'm not mistaken)

    3) Cruel crabs. maybe intend'd, but now i can teach crabs to spell-ing

    4) Does your mustache use root?
     
    OmniaNigrum likes this.
  4. Cullen

    Cullen Member

    WIP


    <spell name="Drone hp 0 to 7" type="self" downtime="5" icon="skills/warrior/berserker0_32.png">


    <effect type="removebuffbyname" name="Drone hp 0"/>

    <effect type="removebuffbyname" name="Drone hp 1"/>

    <effect type="removebuffbyname" name="Drone hp 2"/>

    <effect type="removebuffbyname" name="Drone hp 3"/>

    <effect type="removebuffbyname" name="Drone hp 4"/>

    <effect type="removebuffbyname" name="Drone hp 5"/>

    <effect type="removebuffbyname" name="Drone hp 6"/>


    <anim sprite="sprites/sfx/psionic_generic/psionic_generic" frames="5" framerate="80" sfx="wait" centerEffect="0"/>
    <description text="Years of study have taught you how to bypass the normal flow of time... or it would have if you spent less time daydreaming. Refreshes you, but beware of being disturbed." monsterText="starts daydreaming" />
    </spell>

    <spell name="Drone hp 7 to 0" type="self" downtime="5" icon="skills/warrior/berserker0_32.png">

    <effect type="trigger" spell="Drone hp 0" requirebuffontrigger="1" requirebuffontriggername="Drone hp 1" affectsCorpses="0"/>

    <effect type="trigger" spell="Drone hp 1" requirebuffontrigger="1" requirebuffontriggername="Drone hp 2" affectsCorpses="0"/>

    <effect type="trigger" spell="Drone hp 2" requirebuffontrigger="1" requirebuffontriggername="Drone hp 3" affectsCorpses="0"/>

    <effect type="trigger" spell="Drone hp 3" requirebuffontrigger="1" requirebuffontriggername="Drone hp 4" affectsCorpses="0"/>

    <effect type="trigger" spell="Drone hp 4" requirebuffontrigger="1" requirebuffontriggername="Drone hp 5" affectsCorpses="0"/>

    <effect type="trigger" spell="Drone hp 5" requirebuffontrigger="1" requirebuffontriggername="Drone hp 6" affectsCorpses="0"/>

    <effect type="trigger" spell="Drone hp 6" requirebuffontrigger="1" requirebuffontriggername="Drone hp 7" affectsCorpses="0"/>


    <anim sprite="sprites/sfx/psionic_generic/psionic_generic" frames="5" framerate="80" sfx="wait" centerEffect="0"/>
    <description text="Years of study have taught you how to bypass the normal flow of time... or it would have if you spent less time daydreaming. Refreshes you, but beware of being disturbed." monsterText="starts daydreaming" />
    </spell>


    <spell name="Drone hp 7" downtime="1" type="self" icon="skills/warrior/berserker0_32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/warrior/berserker0_64.png"
    smallicon="skills/warrior/berserker0_32.png" >
    <secondarybuff id="0" amount="7"/> <!-- hp -->
    <playerHitEffectBuff percentage="100" name="Drone hp 7 to 0"/>
    </buff>
    <effect type="trigger" amount="1" spell="Drone hp 0 to 7" affectsCorpses="0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="A sensible stance for uncertain times." />
    </spell>



    <spell name="Drone hp 6" downtime="1" type="self" icon="skills/spells/monstrous_rage32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/spells/monstrous_rage64.png"
    smallicon="skills/spells/monstrous_rage32.png" >
    <secondarybuff id="0" amount="6"/> <!-- hp -->
    <playerHitEffectBuff percentage="100" name="Drone hp 7 to 0"/>
    </buff>
    <effect type="removebuffbyname" name="Drone hp 7"/>
    <effect type="heal" amount="1" resistable="0" />
    <effect type="trigger" amount="7" spell="Drone hp 7" requirebuffontrigger="1" requirebuffontriggername="Drone hp 6" affectsCorpses="0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="A sensible stance for uncertain times." />
    </spell>

    <spell name="Drone hp 5" downtime="1" type="self" icon="skills/polearm_defensive32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/polearm_defensive64.png"
    smallicon="skills/polearm_defensive32.png" >
    <secondarybuff id="0" amount="5"/> <!-- hp -->
    <playerHitEffectBuff percentage="100" name="Drone hp 7 to 0"/>
    </buff>
    <effect type="removebuffbyname" name="Drone hp 6"/>
    <effect type="heal" amount="1" resistable="0" />
    <effect type="trigger" amount="7" spell="Drone hp 7" requirebuffontrigger="1" requirebuffontriggername="Drone hp 5" affectsCorpses="0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="A sensible stance for uncertain times." />
    </spell>

    <spell name="Drone hp 4" downtime="1" type="self" icon="skills/spells/monstrous_rage32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/spells/monstrous_rage64.png"
    smallicon="skills/spells/monstrous_rage32.png" >
    <secondarybuff id="0" amount="4"/> <!-- hp -->
    <playerHitEffectBuff percentage="100" name="Drone hp 7 to 0"/>
    </buff>
    <effect type="removebuffbyname" name="Drone hp 5"/>
    <effect type="heal" amount="1" resistable="0" />
    <effect type="trigger" amount="7" spell="Drone hp 7" requirebuffontrigger="1" requirebuffontriggername="Drone hp 4" affectsCorpses="0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="A sensible stance for uncertain times." />
    </spell>

    <spell name="Drone hp 3" downtime="1" type="self" icon="skills/polearm_defensive32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/polearm_defensive64.png"
    smallicon="skills/polearm_defensive32.png" >
    <secondarybuff id="0" amount="3"/> <!-- hp -->
    <playerHitEffectBuff percentage="100" name="Drone hp 7 to 0"/>
    </buff>
    <effect type="removebuffbyname" name="Drone hp 4"/>
    <effect type="heal" amount="1" resistable="0" />
    <effect type="trigger" amount="7" spell="Drone hp 7" requirebuffontrigger="1" requirebuffontriggername="Drone hp 3" affectsCorpses="0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="A sensible stance for uncertain times." />
    </spell>

    <spell name="Drone hp 2" downtime="1" type="self" icon="skills/spells/monstrous_rage32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/spells/monstrous_rage64.png"
    smallicon="skills/spells/monstrous_rage32.png" >
    <secondarybuff id="0" amount="2"/> <!-- hp -->
    <playerHitEffectBuff percentage="100" name="Drone hp 7 to 0"/>
    </buff>
    <effect type="removebuffbyname" name="Drone hp 3"/>
    <effect type="heal" amount="1" resistable="0" />
    <effect type="trigger" amount="7" spell="Drone hp 7" requirebuffontrigger="1" requirebuffontriggername="Drone hp 2" affectsCorpses="0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="A sensible stance for uncertain times." />
    </spell>

    <spell name="Drone hp 1" downtime="1" type="self" icon="skills/polearm_defensive32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/polearm_defensive64.png"
    smallicon="skills/polearm_defensive32.png" >
    <secondarybuff id="0" amount="1"/> <!-- hp -->
    <playerHitEffectBuff percentage="100" name="Drone hp 7 to 0"/>
    </buff>
    <effect type="removebuffbyname" name="Drone hp 2"/>
    <effect type="heal" amount="1" resistable="0" />
    <effect type="trigger" amount="7" spell="Drone hp 7" requirebuffontrigger="1" requirebuffontriggername="Drone hp 1" affectsCorpses="0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="I hurt" />
    </spell>

    <spell name="Drone hp 0" downtime="1" type="self" icon="skills/spells/monstrous_rage32.png" wand="0">
    <buff useTimer="0" stacksize="1" allowstacking="0" removable="1" bad="0"
    icon="skills/spells/monstrous_rage64.png"
    smallicon="skills/spells/monstrous_rage32.png" >
    <secondarybuff id="0" amount="1"/> <!-- hp -->
    </buff>
    <effect type="removebuffbyname" name="Drone hp 1"/>
    <effect type="heal" amount="1" resistable="0" />
    <effect type="trigger" amount="14" spell="Drone hp 7" requirebuffontrigger="1" requirebuffontriggername="Drone hp 0"/>
    <anim sprite="sprites/sfx/glintA/glintA" frames="5" framerate="60" centerEffect="0" sfx="metal_drop" />
    <description text="Stop taking hit you stupid! (Self-Repair require X2 Turn from usual)" />
    </spell>


    Still not sure how to scaled summon spells
     
    OmniaNigrum likes this.
  5. Kazeto

    Kazeto Member

    I would like to point out that "onhit" uses a "one in x" rather than "x out of 100" system, so setting it to 100 means it only has a 1% chance of triggering; setting it to 1 instead would make it into a 100% chance.
     
    OmniaNigrum likes this.
  6. Cullen

    Cullen Member

    mmmm.. Doesn't work for me.. i don't think it's not work just because it's pet. maybe i wrecked somewhere when paste/tweaking i'll keep try.


    Gun drone attack entire game(maybe random aoe attack and less damage deal when attack far way?) vs When activate choose near ? target and attack them 3(or more)time. What's better?

    first one will hard to balance, but still it's more like pet also unique(just keep move will kill everything with just drone, latter one easy to balance but nothing unique and more like just a skill.
     
    OmniaNigrum likes this.