Veggiesama's Framework (Shadowrun 4th & 5th editions)

Framework(s) for SR4, including Veggiesama's.

Moderators: Azhrei, dorpond, trevor, giliath, Gamerdude, jay, Mr.Ice

Posts: 1
Joined: Tue Mar 06, 2018 9:12 am

Re: Veggiesama's Framework (Shadowrun 4th & 5th editions)

Post by Raven77 »

Hi all,

i use an older version of this Framework (i think it's v18) and want to add a Macro for Grenades.
So let me explane a bit what i use and what's missing.

So first i use a normal Macro for a Throw Grenede Attak

<Third Test = Scatter Range>
[H: dicePoolObject = json.set("{}",
"Name" , "Scatter (Range)",
"Notes" , "Aerodynamic Grenate",
"DicePool" , "2"
[MACRO("[email protected]:SR4"):dicePoolObject]

<Second Test = Scatter Diraction>
[H: dicePoolObject = json.set("{}",
"Name" , "Scatter (Direction)",
"Notes" , "1 = Forward | 2 = Forward-Right | 3 = Back-Right | 4 = Back | 5 = Back-Left | 6 = Forward-Left",
"DicePool" , "1"
[MACRO("[email protected]:SR4"):dicePoolObject]

<First Test = Throwing>
[H: dicePoolObject = json.set("{}",
"Name" , "Fragmentationt Granade",
"Notes" , "6 (AGI) + 4 (Throwing)<br>Range: 0-10 (-0) | 11-20 (-1) | 21-40 (-3) | 41-75 (-6)<br>PB +5 | Basic-Damage: 14P(f)",
"DicePool" , "10",
"Gremlins" , "0",
"MinGlitch", "1",
"Wounds" , "P&S"
[MACRO("[email protected]:SR4"):dicePoolObject]

So i can use this Macro for the Test but what i need is a change in Test 2 and 3. What i need is a fix in
or a new one like
or so.

For the Second and Third Test i don't need the Sucess Value.. i only need the Roll Value to determine the Scattering. Yes i can hold the cursor over the Value but that's what i want to change.

But is hard to drigg deep into the library to find the source to chage the Value "Sucess" to "Roll". Also i don't need Edge or Glitch for that test.

Can someone help me to fix this or create a new
Macro for the Grenade test?

[spoiler=my current executeQuickRoll macro]<!-- Veggiesama's executeQuickRoll macro, MapTool B56 -->

<!-- Initialize variables -->
[H: dicePoolObject = macro.args]
[H: unpackDicePoolObject(dicePoolObject)]
[H: unloadLibProps()]
[h: dicePool = checkForProperties(dicePool)]

<!-- Recall last inputs -->
[H: lastUseEdge = getStrProp(Last, "useEdge", 0)]
[H: output = listGet(ROLL_MODE_VALUES, RollMode)]

<!-- Backwards compatibility -->
[H, IF(!json.contains(dicePoolObject, "Gremlins")): gremlins = 0]
[H, IF(!json.contains(dicePoolObject, "MinGlitch")): minGlitch = MINIMUM_TO_GLITCH]
[H, IF(!json.contains(dicePoolObject, "Wounds")): wounds = "P&S"]

<!-- rudimentary auto-resize based on number of <br> tags -->
[H: count = 1]
[H: finder = indexOf(notes, "<br>")]
[H, WHILE(finder != -1), CODE: {
[H: count = count + 1]
[H: finder = indexOf(notes, "<br>", finder+1)]
[H: height = 185 - if(notes=="", 20, 0) + (count * 20)]

<!-- Do the dialog! -->
[H: dialogName = name]
[dialog(dialogName, "input=1; width=400; height=" + height + "; temporary=1;"): {
<title>[R: dialogName]</title>
<meta name="input" content="true">
<link rel="stylesheet" type="text/css" href="[email protected][R:getMacroLocation()]">
<form name="[R:dialogName]"
action="[R:macroLinkText('[email protected]', output, '', currentToken())]">

<input type="hidden" name="Name" value="[R: name]"></input>
<input type="hidden" name="Notes" value="[R: notes]"></input>
<input type="hidden" name="DicePool" value="[R: dicePool]"></input>
<input type="hidden" name="wounds" value="[R: wounds]"></input>

<table width="100%" class="dice">
<tr><th colspan=6 align="center">
[H: woundPenalty = 0]
[H: woundPenalty = if(wounds=="P&S", getWoundMod(), woundPenalty)]
[H: woundPenalty = if(wounds=="P&S&M", getWoundMod(1), woundPenalty)]
[R: name + " (" + dicePool + if(woundPenalty, "<font color=red>" + woundPenalty + "</font>)", ")")]
</th></tr><tr class="oddRow"><td class="rowHeader">
</td><td colspan=5>
<input tabindex="1" type="text" name="DicePoolMod" value="" size="25"></input>
</td></tr><tr class="evenRow"><td class="rowHeader">
Regel der Sechs:
<input type="checkbox" name="UseEdge" value="1"></input>
</td><td class="rowHeader">
<input type="text" name="Gremlins" value="[r:gremlins]" size=2></input>
</td><td class="rowHeader">
<input type="text" name="MinGlitch" value="[r:minGlitch]" size=2></input>
</td></tr><tr class="oddRow"><td colspan=6 align="center">
<input tabindex="2" name="Roll" type="submit" value=" W&uuml;rfeln "></input>
<input tabindex="3" name="Cancel" type="submit" value="Abbrechen"></input>
</td></tr><tr class="evenRow"><td colspan=5>
<u><b>Notizen</b></u><br>[R: notes]


Post Reply

Return to “Shadowrun 4e Frameworks”