Heya, I'm trying to do my own mod and I've hit a snag.. I looked through http://dredmod.com/wiki/Spell_Effects but I can't seem to find something that will do what I want. swapwithmonster is the closest one I found, but I don't want to change places, I want to get right next to it, or to any other enemy in the path towards it, sorta like how a bolt usually does. Anyone has an idea on how I should do that? I also remember seeing a post by a modder, I believe it was either Ruigi or Fax but I'm not sure, who showed a modified version of Charge of the Steam Brigade and Rocket Jump with an animation similar to what I'd want to use instead of the regular teleport animation.. I couldn't find the thread he had posted it in however.
Make a spell that targets a monster, then make it trigger something that will randomly teleport you to one of the eight squares around it (or slightly farther if all of these are occupied). Depending on the way you do it it might require some code or some more code, but it's pretty easy to do. Unless you mean the "charge at monster and stop one tile before it", in which case you might want to start with something that triggers the teleporting effect and uses "beam" as its type.
That's pretty much what I want to do. The "beam" type stops if it encounters something along it's path, correct?
Would it be possible to use suction to bring the monster back to its original location after you swap with it (or would the suction effect fail to follow the monster and/or player's new position).
It would, but that would still make you move to the tile it originally occupied, and the point here is that the monster ought to remain where it was.
Right, it was "beammissile" or something like that for all things. I have to get some sleep. And you can kill me for screwing up a one-word answer.
Download Compleat Essential Skills. Look under spellDB for "Saved By The Bell". That's pretty much the exact spell you want.
Thanks Essence. I had never used DiD before so I didn't know that skill did that. I've had CES for quite a while
Ok, that worked sorta like I would have liked.. One problem however is that I seem to teleport on top of the enemy instead of next to it.. I copy pasted (and changed some of the stuff) your spell, so I can't figure out why it does that instead of what ByTheBell does :/ Here's the code itself, maybe you can tip me into where I went wrong (and if I'm doing the scaling thing correctly.. I'd like it to scale to health instead of magic power, but dredmod didn't say how to change the scaling type.. Or I missed that bit) Code: <spell name="BandageToss" type="beammissile" icon="skills/BandageToss32.png"> <requirements mp="8"/> <anim sprite="sprites/sfx/energy_ball/energy_ball" frames="6" framerate="90" sfx="darkmagic" /> <effect type="teleport" skipAnimation="1"/> <effect type="damage" asphyxiative="3" asphyxiativeF="0.7" affectscaster="0" /> <effect type="trigger" spell="BandageTossStun"/> </spell>
You missed the part where Saved By The Bell triggers a spell that moves you backward one square just after it's teleport effect is finished. Also, to scale to health use <effect type="damage" asphyxiative="3" asphyxiativeF=".07" secondaryScale="0"/> secondaryScale tells it which secondary stat to scale off of. Or primaryScale tells it what primary stat to scale off of.
Awesome, thanks Essence. Did that now. Another thing since I have one of the cleanest mod makers in my thread.. I'm trying to do a brittle buff that does AoE damage around you as long as it's going.. the validator keeps spitting out this error: Code: Line 27, Position: 8 -- The '=' character, hexadecimal value 0x3D, cannot be included in a name. Line 27, position 8. .. I don't quite understand why since I've done a similar line in another one of my spells.. Spoiler <spell name="DespairBuff" type="self" icon="skills/Despair32.png"> <buff usetimer="0" brittle="1" removable="0" bad="1" stacksize="1" allowstacking="0" icon="skills/Despair64.png" smallicon="skills/Despair32.png"> <type="template" templateID="11" anchored="1" icon="skills/Despair32.png"> <effect type="damage" asphyxiative="2" asphyxiativeF="0.4" affectscaster="0"/> </buff> </spell> The error is at the template line..
That's easy -- the entire <type="template"> line needs to be part of the <spell> line, thusly: <spell name="DespairBuff" type="template" templateID="11" anchored="1" icon="skills/Despair32.png"> <buff usetimer...etc.
That was indeed easy.. Thanks again. I'm still new to actually coding in xml, using your code as an helper but some stuff are still beyond me.
No problem! Though, to be honest, I'd hardly consider myself a "clean" coder. I'm more of a "hack at it until it gets done" coder (see: Arcane Capacitor). If you want clean code, I highly suggest r_b_bergstrom or Null's mods.
Hm.. Doesn't look like it's doing what I want.. It's doing an aoe attack and then puts a buff on me that does nothing at all My guess is that I need to do it in a different way, like "cast spell, it goes on you and THEN that calls another spell that anchors a template dealing damage every turn as long as the buff is on you". I really wish I was better at xml lol
Sorry, I was mostly just thinking aloud. I'm still playing around with it but this was the latest "working" one (i say working loosely cause it's not doing what I want. It just wasn't giving me errors). Spoiler <spell name="Despair" type="template" templateID="11" anchored="1" icon="skills/Despair32.png" > <buff usetimer="0" manaUpkeep="1" removable="1" bad="1" stacksize="1" allowstacking="0" icon="skills/Despair64.png" smallicon="skills/Despair32.png"> <effect type="damage" asphyxiative="3" asphyxiativeF="0.4" secondaryScale="0" affectscaster="0"/> </buff> <description text="Your tears are so painful."/>
OK, so -- what you want here is actually kind of complicated. It looks like this: Code: <spell name="DespairingPain" type="template" templateID="11" anchored="1"> <effect type="damage" axsphyxiative="3" asphyxiativeF=".4" secondaryScale="0"> <anim --SOMETHING NEEDS TO GO HERE OR THE SPELL WON'T WORK-- > </spell> <spell name="DespairingPainTrigger" type="self"> <effect type="trigger" requirebuffontrigger="1" requirebuffontriggername="Despair" spell="DespairingPain"> <effect type="trigger" amount="2" requirebuffontrigger="1" requirebuffontriggername="Despair" spell="DespairingPainTrigger"> </spell> <spell name="Despair" type="self" icon="skills/Despair32.png"> <buff usetimer="0" manaUpkeep="1" removable="1" allowstacking="0" icon="skills/Despair64.png" smallicon="skills/Despair32.png"> <description text="Your tears are so painful"/> </buff> <effect type="trigger" spell="DespairingPainTrigger"> </spell> See if that makes sense to you, and if it doesn't, ask me anything you like.