Macro Tip

Doc requests, organization, and submissions

Moderators: dorpond, trevor, Azhrei

Post Reply
DevoDog
Dragon
Posts: 456
Joined: Sat Jul 12, 2008 9:56 am

Macro Tip

Post by DevoDog »

I've been struggling with macros and the character limit in macros and the complexity of some macros....so I did a little test.

Basically, it's making the creation of individual macros a lot easier.

I set token properties of WPNBaseAttack, WPNBaseDamage, and WPNCritDamage. The values of those properties are the formulas that are used for attacks with that weapon.

WPNBaseAttack: WPNMagic+WPNProf+WPNAttackBonus+HalfLevel+AttackBonus

WPNBaseDamage: roll(Mult*WPNNo,WPNDice)+WPNMagic+WPNDamageBonus+DamageBonus

WPNCritDamage: Mult*WPNNo*WPNDice+WPNMagic+WPNDamageBonus+DamageBonus+eval(WPNMagicCritDamage)+If(WPNHighCrit=="Y",roll(ceiling(Level/10)*WPNNo,WPNDice),0)

The Melee Basic Attack macro (to hit and damage) is:
[H:input("AttackBonus","DamageBonus")]
[H:AttackRoll=1d20]
[H:Mult= If(Level>20,2,1)]
To Hit:
[AttackRoll+eval(WPNBaseAttack)+STRBonus]
[If(AttackRoll>WPNCritRoll," (Critical)","")]<br/>
Damage:
[If(AttackRoll>WPNCritRoll,eval(WPNCritDamage),eval(WPNBaseDamage))+STRBonus]

This should really streamline my creation of macros. I won't need to enter as much in individual macros and this should eliminate a lot of my errors.

DevoDog
Dragon
Posts: 456
Joined: Sat Jul 12, 2008 9:56 am

Post by DevoDog »

Adding another example:

Macro for Priest's Shield (formatted):

<table width="90%"><tr style="background:#009900;color:white;font-weight:bold;"><td>Priest's Shield</td><td align="right">Cleric Attack 1</td></tr><tr><td colspan="2" style="background:#EEEEEE"><i>You utter a minor defensive prayer as you attack with your weapon.</i><br/><b>At-Will</b> * <b>Divine, Weapon</b><br/><b>Standard Action</b>  <b>Melee weapon</b><br/><b>Target:</b>  One creature<br/><b>Attack:</b>  [H:input("AttackBonus","DamageBonus")][H:AttackRoll=1d20]
[AttackRoll+eval(WPNBaseAttack)+STRBonus] vs AC
[If(AttackRoll>WPNCritRoll," (Critical Hit)","")]<br/><b>Damage:</b>  [H:Mult=If(Level>21,2,1)]
[If(AttackRoll>WPNCritRoll,eval(WPNCritDamage),eval(WPNBaseDamage))+STRBonus] damage and you and one adjacent ally gain a +1 power bonus to AC until the end of your next turn.<br/></td></tr></table>

Mynose
Kobold
Posts: 3
Joined: Tue Sep 23, 2008 1:02 pm

Post by Mynose »

think you can help me make a macro i need?

Post Reply

Return to “Documentation Requests/Discussion”