System Generated Macros

The system generates certain macros with drag and drop functionality.

Dragging Items from Actors

These macros can be used if the actor is selected. Note the only item types this supports currently are weapons, skills, prayers, spells, and traits.

2020-01-31_19-43-10

Dragging Actors and Journal Entries

These macros open the entity’s sheet. 2020-02-02_17-16-52

Script Macros

Characteristics and skills can’t be dragged, so they will have be entered manually into the macro, as shown below.


Test a Characteristic

game.wfrp4e.utility.rollItemMacro("ws", "characteristic");
game.wfrp4e.utility.rollItemMacro("bs", "characteristic");
game.wfrp4e.utility.rollItemMacro("s", "characteristic");
game.wfrp4e.utility.rollItemMacro("t", "characteristic");
game.wfrp4e.utility.rollItemMacro("i", "characteristic");
game.wfrp4e.utility.rollItemMacro("ag", "characteristic");
game.wfrp4e.utility.rollItemMacro("dex", "characteristic");
game.wfrp4e.utility.rollItemMacro("int", "characteristic");
game.wfrp4e.utility.rollItemMacro("wp", "characteristic");
game.wfrp4e.utility.rollItemMacro("fel", "characteristic");

Test a Skill

Simply match the name of the skill you wish to roll for the test.

game.wfrp4e.utility.rollItemMacro("Athletics", "skill");


Dialog Options

The third argument of rollItemMacro can be used to configure the dialog.

fields - Concerns all the actual fillable fields within the dialog, the notable ones are modifier, slBonus and successBonus.

appendTitle - Adds a string to the title of the dialog and test

skipTargets - Whether or not to consider any targets in the test. If skipped, no opposed tests are created

bypass - Whether or not to bypass the roll dialog entirely

Examples

game.wfrp4e.utility.rollItemMacro("ws", "characteristic", {fields : {difficulty: "average"}})

game.wfrp4e.utility.rollItemMacro("Dodge", "skill", {fields : {modifier: +20}, appendTitle : " - Dive Roll!"})

game.wfrp4e.utility.rollItemMacro("Zweihander", "weapon", {bypass: true, fields: {modifier: -10, slBonus: 2, successBonus: 1}})

Roll a Table

You can either use a chat macro /table hitloc

Or a script macro ChatMessage.create({content : game.wfrp4e.tables.formatChatRoll("hitloc"), user : game.user.id})

Script macros are more powerful - for example: I want a macro to roll the Winds and Weather tables simultaneously

ChatMessage.create({content : game.wfrp4e.tables.formatChatRoll("winds"), user : game.user.id})
ChatMessage.create({content : game.wfrp4e.tables.formatChatRoll("weather"), user : game.user.id})

You can find table names by entering /table help in the chat.