0.4.3 Update

This commit is contained in:
Chris Schmalz
2023-10-09 13:12:55 -07:00
parent f7c6bba498
commit fc4cc5d6c5
559 changed files with 1822 additions and 4699 deletions
+64
View File
@@ -0,0 +1,64 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
//pop up the death save dialog box
new Dialog({
title: `Death Save`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/rolltables/death_save.png" style="border:none"/></div>
<div class="macro_desc"><h3>Death Save</h3><strong>Whenever you reach 0 Health, make a Body Save: Failure means you die.</strong> Success means you fall unconscious, make a <strong>Death Save</strong> to find out when you regain consciousness. Crew members with a medscanner, relevant skills like First Aid or Biology, or scientists and androids who pass an <strong>Intellect Check</strong> can determine your condition.</div>
</div>
</div>
<h4>Select your roll type:</h4>
`,
buttons: {
button1: {
label: `Advantage`,
callback: () => game.mosh.initRollTable(`cZOHlhEJcYGZsQBM`,`1d10 [+]`,`high`,false,false,null,null),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button2: {
label: `Normal`,
callback: () => game.mosh.initRollTable(`cZOHlhEJcYGZsQBM`,`1d10`,`high`,false,false,null,null),
icon: `<i class="fas fa-minus"></i>`
},
button3: {
label: `Disadvantage`,
callback: () => game.mosh.initRollTable(`cZOHlhEJcYGZsQBM`,`1d10 [-]`,`high`,false,false,null,null),
icon: `<i class="fas fa-angle-double-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
+64
View File
@@ -0,0 +1,64 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Gain Calm`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/macros/relieve_stress.png" style="border:none"/></div>
<div class="macro_desc"><h3>Gain Calm</h3>Occasionally, certain moments, places, or events can automatically <strong>calm you down.</strong> Escaping perilous situations, finding a serene location, or experiencing a touching moment with a loved one can have meaningful impacts on your mood and outlook on life. If your Calm is getting close to 0, you should consider making a <strong>Rest Save</strong> - as the effects of a failed <strong>Panic Check</strong> can be devastating.</div>
</div>
</div>
<h4>Select your modification:</h4>
`,
buttons: {
button1: {
label: `Gain 5 Calm`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',5,null,true),
icon: `<i class="fas fa-angle-up"></i>`
},
button2: {
label: `Gain 10 Calm`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',10,null,true),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button3: {
label: `Gain 1d20 Calm`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`1d20`,true),
icon: `<i class="fas fa-arrow-circle-up"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Gain Stress`,
content: `
<style>
@@ -53,18 +47,19 @@ new Dialog({
buttons: {
button1: {
label: `Gain 1 Stress`,
callback: () => prepModifyActor('system.other.stress.value',1,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',1,null,true),
icon: `<i class="fas fa-angle-up"></i>`
},
button2: {
label: `Gain 2 Stress`,
callback: () => prepModifyActor('system.other.stress.value',2,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',2,null,true),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button3: {
label: `Gain 1d5 Stress`,
callback: () => prepModifyActor('system.other.stress.value',null,`1d5`,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`1d5`,true),
icon: `<i class="fas fa-arrow-circle-up"></i>`
}
}
},{width: 600,height: 265}).render(true);
},{width: 600,height: 265}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Lose Calm`,
content: `
<style>
@@ -53,18 +47,19 @@ new Dialog({
buttons: {
button1: {
label: `Lose 5 Calm`,
callback: () => prepModifyActor('system.other.stress.value',-5,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',-5,null,true),
icon: `<i class="fas fa-angle-down"></i>`
},
button2: {
label: `Lose 10 Calm`,
callback: () => prepModifyActor('system.other.stress.value',-10,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',-10,null,true),
icon: `<i class="fas fa-angle-double-down"></i>`
},
button3: {
label: `Lose 1d20 Calm`,
callback: () => prepModifyActor('system.other.stress.value',null,`-1d20`,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`-1d20`,true),
icon: `<i class="fas fa-arrow-circle-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
},{width: 600,height: 265}).render(true);
}
+65
View File
@@ -0,0 +1,65 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
//pop up the panic check dialog box
new Dialog({
title: `Panic Check`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/rolltables/panic_check.png" style="border:none"/></div>
<div class="macro_desc"><h3>Panic Check</h3>Stress, Damage, and emotional wear and tear eventually bring characters to their breaking point. When that happens, there’s a chance they Panic. You determine this by making a <strong>Panic Check</strong>. Some results of the Panic Table are so severe that they leave a lasting impression on you. These are called <strong>Conditions</strong>, and they affect you until you are able to treat them.
</div>
</div>
</div>
<h4>Select your roll type:</h4>
`,
buttons: {
button1: {
label: `Advantage`,
callback: () => game.mosh.initRollTable(`panicCheck`,`[+]`,null,false,false,null,null),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button2: {
label: `Normal`,
callback: () => game.mosh.initRollTable(`panicCheck`,``,null,false,false,null,null),
icon: `<i class="fas fa-minus"></i>`
},
button3: {
label: `Disadvantage`,
callback: () => game.mosh.initRollTable(`panicCheck`,`[-]`,null,false,false,null,null),
icon: `<i class="fas fa-angle-double-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
+65
View File
@@ -0,0 +1,65 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Gain Stress`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/macros/relieve_stress.png" style="border:none"/></div>
<div class="macro_desc"><h3>Relieve Stress</h3>Occasionally, certain moments, places, or events can automatically <strong>relieve your stress.</strong> Escaping perilous situations, finding a serene location, or experiencing a touching moment with a loved one can have meaningful impacts on your mood and outlook on life. If your stress is getting close to 20, you should consider making a <strong>Rest Save</strong> - as the effects of a failed <strong>Panic Check</strong> can be devastating.</div>
</div>
</div>
<h4>Select your modification:</h4>
`,
buttons: {
button1: {
label: `Relieve 1 Stress`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',-1,null,true),
icon: `<i class="fas fa-angle-down"></i>`
},
button2: {
label: `Relieve 2 Stress`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',-2,null,true),
icon: `<i class="fas fa-angle-double-down"></i>`
},
button3: {
label: `Relieve 1d5 Stress`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`-1d5`,true),
icon: `<i class="fas fa-arrow-circle-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepCheck(rollString,aimFor,attribute,skill,skillValue,weapon) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Rest Save`,
content: `
<style>
@@ -50,8 +44,9 @@ new Dialog({
buttons: {
button1: {
label: `Next`,
callback: () => prepCheck(null,'low','restSave',null,null,null),
callback: () => game.mosh.initRollCheck(null,'low','restSave',null,null,null),
icon: `<i class="fas fa-chevron-circle-right"></i>`
}
}
},{width: 600,height: 237}).render(true);
},{width: 600,height: 237}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepCheck(rollString,aimFor,attribute,skill,skillValue,weapon) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Save`,
content: `
<style>
@@ -102,8 +96,9 @@ new Dialog({
buttons: {
button1: {
label: `Next`,
callback: (html) => prepCheck(null,'low',html.find("input[name='save']:checked").val(),null,null,null),
callback: (html) => game.mosh.initRollCheck(null,'low',html.find("input[name='save']:checked").val(),null,null,null),
icon: `<i class="fas fa-chevron-circle-right"></i>`
}
}
},{width: 600,height: 545}).render(true);
},{width: 600,height: 545}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepCheck(rollString,aimFor,attribute,skill,skillValue,weapon) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Stat Check`,
content: `
<style>
@@ -103,8 +97,9 @@ new Dialog({
buttons: {
button1: {
label: `Next`,
callback: (html) => prepCheck(null,'low',html.find("input[name='stat']:checked").val(),null,null,null),
callback: (html) => game.mosh.initRollCheck(null,'low',html.find("input[name='stat']:checked").val(),null,null,null),
icon: `<i class="fas fa-chevron-circle-right"></i>`
}
}
},{width: 600,height: 545}).render(true);
},{width: 600,height: 545}).render(true);
}
+64
View File
@@ -0,0 +1,64 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
//pop up the death save dialog box
new Dialog({
title: `Death Save`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/rolltables/death_save.png" style="border:none"/></div>
<div class="macro_desc"><h3>Death Save</h3>Your character is incapacitated when you receive a fatal wound, or once your Current Wounds equal your Maximum Wounds. As soon as someone spends a turn checking your vitals, make a <strong>Death Save</strong> to reveal your fate. If your death seems imminent, make your last moments count: save someone’s life, solve an important mystery, or give the others time to escape.</div>
</div>
</div>
<h4>Select your roll type:</h4>
`,
buttons: {
button1: {
label: `Advantage`,
callback: () => game.mosh.initRollTable(`W36WFIpCfMknKgHy`,`1d10 [+]`,`low`,true,false,null,null),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button2: {
label: `Normal`,
callback: () => game.mosh.initRollTable(`W36WFIpCfMknKgHy`,`1d10`,`low`,true,false,null,null),
icon: `<i class="fas fa-minus"></i>`
},
button3: {
label: `Disadvantage`,
callback: () => game.mosh.initRollTable(`W36WFIpCfMknKgHy`,`1d10 [-]`,`low`,true,false,null,null),
icon: `<i class="fas fa-angle-double-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
+64
View File
@@ -0,0 +1,64 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Gain Calm`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/macros/relieve_stress.png" style="border:none"/></div>
<div class="macro_desc"><h3>Gain Calm</h3>Occasionally, certain moments, places, or events can automatically <strong>calm you down.</strong> Escaping perilous situations, finding a serene location, or experiencing a touching moment with a loved one can have meaningful impacts on your mood and outlook on life. If your Calm is getting close to 0, you should consider making a <strong>Rest Save</strong> - as the effects of a failed <strong>Panic Check</strong> can be devastating.</div>
</div>
</div>
<h4>Select your modification:</h4>
`,
buttons: {
button1: {
label: `Gain 5 Calm`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',5,null,true),
icon: `<i class="fas fa-angle-up"></i>`
},
button2: {
label: `Gain 10 Calm`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',10,null,true),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button3: {
label: `Gain 1d20 Calm`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`1d20`,true),
icon: `<i class="fas fa-arrow-circle-up"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Gain Stress`,
content: `
<style>
@@ -53,18 +47,19 @@ new Dialog({
buttons: {
button1: {
label: `Gain 1 Stress`,
callback: () => prepModifyActor('system.other.stress.value',1,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',1,null,true),
icon: `<i class="fas fa-angle-up"></i>`
},
button2: {
label: `Gain 2 Stress`,
callback: () => prepModifyActor('system.other.stress.value',2,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',2,null,true),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button3: {
label: `Gain 1d5 Stress`,
callback: () => prepModifyActor('system.other.stress.value',null,`1d5`,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`1d5`,true),
icon: `<i class="fas fa-arrow-circle-up"></i>`
}
}
},{width: 600,height: 265}).render(true);
},{width: 600,height: 265}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.modifyActor(fieldAddress,modValue,modRollString,outputChatMsg);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Lose Calm`,
content: `
<style>
@@ -53,18 +47,19 @@ new Dialog({
buttons: {
button1: {
label: `Lose 5 Calm`,
callback: () => prepModifyActor('system.other.stress.value',-5,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',-5,null,true),
icon: `<i class="fas fa-angle-down"></i>`
},
button2: {
label: `Lose 10 Calm`,
callback: () => prepModifyActor('system.other.stress.value',-10,null,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',-10,null,true),
icon: `<i class="fas fa-angle-double-down"></i>`
},
button3: {
label: `Lose 1d20 Calm`,
callback: () => prepModifyActor('system.other.stress.value',null,`-1d20`,true),
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`-1d20`,true),
icon: `<i class="fas fa-arrow-circle-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
},{width: 600,height: 265}).render(true);
}
+65
View File
@@ -0,0 +1,65 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
//pop up the panic check dialog box
new Dialog({
title: `Panic Check`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/rolltables/panic_check.png" style="border:none"/></div>
<div class="macro_desc"><h3>Panic Check</h3>Stress, Damage, and emotional wear and tear eventually bring characters to their breaking point. When that happens, there’s a chance they Panic. You determine this by making a <strong>Panic Check</strong>. Some results of the Panic Table are so severe that they leave a lasting impression on you. These are called <strong>Conditions</strong>, and they affect you until you are able to treat them.
</div>
</div>
</div>
<h4>Select your roll type:</h4>
`,
buttons: {
button1: {
label: `Advantage`,
callback: () => game.mosh.initRollTable(`panicCheck`,`[+]`,null,false,false,null,null),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button2: {
label: `Normal`,
callback: () => game.mosh.initRollTable(`panicCheck`,``,null,false,false,null,null),
icon: `<i class="fas fa-minus"></i>`
},
button3: {
label: `Disadvantage`,
callback: () => game.mosh.initRollTable(`panicCheck`,`[-]`,null,false,false,null,null),
icon: `<i class="fas fa-angle-double-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
+65
View File
@@ -0,0 +1,65 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Gain Stress`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/macros/relieve_stress.png" style="border:none"/></div>
<div class="macro_desc"><h3>Relieve Stress</h3>Occasionally, certain moments, places, or events can automatically <strong>relieve your stress.</strong> Escaping perilous situations, finding a serene location, or experiencing a touching moment with a loved one can have meaningful impacts on your mood and outlook on life. If your stress is getting close to 20, you should consider making a <strong>Rest Save</strong> - as the effects of a failed <strong>Panic Check</strong> can be devastating.</div>
</div>
</div>
<h4>Select your modification:</h4>
`,
buttons: {
button1: {
label: `Relieve 1 Stress`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',-1,null,true),
icon: `<i class="fas fa-angle-down"></i>`
},
button2: {
label: `Relieve 2 Stress`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',-2,null,true),
icon: `<i class="fas fa-angle-double-down"></i>`
},
button3: {
label: `Relieve 1d5 Stress`,
callback: () => game.mosh.initModifyActor('system.other.stress.value',null,`-1d5`,true),
icon: `<i class="fas fa-arrow-circle-down"></i>`
}
}
},{width: 600,height: 265}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepCheck(rollString,aimFor,attribute,skill,skillValue,weapon) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Rest Save`,
content: `
<style>
@@ -50,8 +44,9 @@ new Dialog({
buttons: {
button1: {
label: `Next`,
callback: () => prepCheck(null,'low','restSave',null,null,null),
callback: () => game.mosh.initRollCheck(null,'low','restSave',null,null,null),
icon: `<i class="fas fa-chevron-circle-right"></i>`
}
}
},{width: 600,height: 237}).render(true);
},{width: 600,height: 237}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepCheck(rollString,aimFor,attribute,skill,skillValue,weapon) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Save`,
content: `
<style>
@@ -89,8 +83,9 @@ new Dialog({
buttons: {
button1: {
label: `Next`,
callback: (html) => prepCheck(null,'low',html.find("input[name='save']:checked").val(),null,null,null),
callback: (html) => game.mosh.initRollCheck(null,'low',html.find("input[name='save']:checked").val(),null,null,null),
icon: `<i class="fas fa-chevron-circle-right"></i>`
}
}
},{width: 600,height: 470}).render(true);
},{width: 600,height: 470}).render(true);
}
@@ -1,18 +1,12 @@
//tell the actor to run the function
async function prepCheck(rollString,aimFor,attribute,skill,skillValue,weapon) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//run the function for the player's 'Selected Character'
game.user.character.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
token.actor.rollCheck(rollString,aimFor,attribute,skill,skillValue,weapon);
});
}
}
new Dialog({
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
new Dialog({
title: `Stat Check`,
content: `
<style>
@@ -103,8 +97,9 @@ new Dialog({
buttons: {
button1: {
label: `Next`,
callback: (html) => prepCheck(null,'low',html.find("input[name='stat']:checked").val(),null,null,null),
callback: (html) => game.mosh.initRollCheck(null,'low',html.find("input[name='stat']:checked").val(),null,null,null),
icon: `<i class="fas fa-chevron-circle-right"></i>`
}
}
},{width: 600,height: 545}).render(true);
},{width: 600,height: 545}).render(true);
}
+130
View File
@@ -0,0 +1,130 @@
//init vars
let macroTarget = game.settings.get('mosh','macroTarget');
//warn user if character is not selected
if ((macroTarget === 'character' && !game.user.character) || (macroTarget === 'token' && !canvas.tokens.controlled.length)) {
//warn player
game.mosh.noCharSelected();
//else pop up the dialog
} else {
//pop up the wound check dialog box
new Dialog({
title: `Wound Check`,
content: `
<style>
.macro_window{
background: rgb(230,230,230);
border-radius: 9px;
}
.macro_img{
display: flex;
justify-content: center;
}
.macro_desc{
font-family: "Roboto", sans-serif;
font-size: 10.5pt;
font-weight: 400;
padding-top: 8px;
padding-right: 8px;
padding-bottom: 8px;
}
.grid-2col {
display: grid;
grid-column: span 2 / span 2;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 2px;
padding: 0;
}
</style>
<div class ="macro_window" style="margin-bottom : 7px;">
<div class="grid grid-2col" style="grid-template-columns: 150px auto">
<div class="macro_img"><img src="systems/mosh/images/icons/ui/macros/wound_check.png" style="border:none"/></div>
<div class="macro_desc"><h3>Wound Check</h3>Make a <strong>Wound Check</strong> according to the type of Damage received. <strong>Flesh Wounds</strong> are small inconveniences. <strong>Minor/Major Injuries</strong> cause lasting issues which require medical treatment. <strong>Lethal Injuries</strong> can kill you if not dealt with immediately. <strong>Fatal Injuries</strong> can kill outright. <strong>Bleeding</strong> wounds, if not treated can quickly overwhelm you.</div>
</div>
</div>
<label for="bf">
<div class ="macro_window" style="margin-bottom : 7px; vertical-align: middle; padding-left: 3px;">
<div class="grid grid-3col" style="grid-template-columns: 20px 60px auto">
<input type="radio" id="bf" name="wound_table" value="31YibfjueXuZdNLb" checked="checked">
<div class="macro_img" style="padding-top: 5px; padding-left: 0px; padding-right: 0px; padding-bottom: 5px;"><img src="systems/mosh/images/icons/ui/rolltables/wounds_blunt_force.png" style="border:none"/></div>
<div class="macro_desc" style="display: table;">
<span style="display: table-cell; vertical-align: middle;">
<strong>Blunt Force:</strong> Getting punched, hit with a crowbar or a thrown object, falling, etc.
</span>
</div>
</div>
</div>
</label>
<label for="b">
<div class ="macro_window" style="margin-bottom : 7px; vertical-align: middle; padding-left: 3px;">
<div class="grid grid-3col" style="grid-template-columns: 20px 60px auto">
<input type="radio" id="b" name="wound_table" value="ata3fRz3uoPfNCLh">
<div class="macro_img" style="padding-top: 5px; padding-left: 0px; padding-right: 0px; padding-bottom: 5px;"><img src="systems/mosh/images/icons/ui/rolltables/wounds_bleeding.png" style="border:none"/></div>
<div class="macro_desc" style="display: table;">
<span style="display: table-cell; vertical-align: middle;">
<strong>Bleeding:</strong> Getting stabbed or cut.
</span>
</div>
</div>
</div>
</label>
<label for="g">
<div class ="macro_window" style="margin-bottom : 7px; vertical-align: middle; padding-left: 3px;">
<div class="grid grid-3col" style="grid-template-columns: 20px 60px auto">
<input type="radio" id="g" name="wound_table" value="XjDU2xFOWEasaZK0">
<div class="macro_img" style="padding-top: 5px; padding-left: 0px; padding-right: 0px; padding-bottom: 5px;"><img src="systems/mosh/images/icons/ui/rolltables/wounds_gunshot.png" style="border:none"/></div>
<div class="macro_desc" style="display: table;">
<span style="display: table-cell; vertical-align: middle;">
<strong>Gunshot:</strong> Getting shot by a firearm.
</span>
</div>
</div>
</div>
</label>
<label for="fe">
<div class ="macro_window" style="margin-bottom : 7px; vertical-align: middle; padding-left: 3px;">
<div class="grid grid-3col" style="grid-template-columns: 20px 60px auto">
<input type="radio" id="fe" name="wound_table" value="lqiaWwh5cGcJhvnu">
<div class="macro_img" style="padding-top: 5px; padding-left: 0px; padding-right: 0px; padding-bottom: 5px;"><img src="systems/mosh/images/icons/ui/rolltables/wounds_fire_&_explosives.png" style="border:none"/></div>
<div class="macro_desc" style="display: table;">
<span style="display: table-cell; vertical-align: middle;">
<strong>Fire & Explosives:</strong> Grenades, flamethrowers, doused in fuel and lit on fire, etc.
</span>
</div>
</div>
</div>
</label>
<label for="gm">
<div class ="macro_window" style="margin-bottom : 7px; vertical-align: middle; padding-left: 3px;">
<div class="grid grid-3col" style="grid-template-columns: 20px 60px auto">
<input type="radio" id="gm" name="wound_table" value="uVfC1CqYdojaJ7yR">
<div class="macro_img" style="padding-top: 5px; padding-left: 0px; padding-right: 0px; padding-bottom: 5px;"><img src="systems/mosh/images/icons/ui/rolltables/wounds_gore_&_massive.png" style="border:none"/></div>
<div class="macro_desc" style="display: table;">
<span style="display: table-cell; vertical-align: middle;">
<strong>Gore & Massive:</strong> Giant or gruesome attacks.
</span>
</div>
</div>
</div>
</label>
<h4>Select your roll type:</h4>
`,
buttons: {
button1: {
label: `Advantage`,
callback: (html) => game.mosh.initRollTable(html.find("input[name='wound_table']:checked").val(),`1d10 [+]`,`low`,true,false,null,null),
icon: `<i class="fas fa-angle-double-up"></i>`
},
button2: {
label: `Normal`,
callback: (html) => game.mosh.initRollTable(html.find("input[name='wound_table']:checked").val(),`1d10`,`low`,true,false,null,null),
icon: `<i class="fas fa-minus"></i>`
},
button3: {
label: `Disadvantage`,
callback: (html) => game.mosh.initRollTable(html.find("input[name='wound_table']:checked").val(),`1d10 [-]`,`low`,true,false,null,null),
icon: `<i class="fas fa-angle-double-down"></i>`
}
}
},{width: 600,height: 650}).render(true);
}
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('QEVnimwq5o0DxmZz',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('23qE7TnIHxtw1E9y',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('ZzvKo0yTqOcRP5Xo',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('Qnv6ZDPsbOXLi9go',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('uoeVaOy5a6BIAGAi',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('PiMuPeHR5EobSPBP',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('dAJRV7JG0Wh1shcJ',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('6vExNGxZiXcC3RFy',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('kI2Yxt0Eo2mEywpZ',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('5E3FGlNzi05S792f',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('8D9ZtBYScCKjcBH3',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('B8vRorrFy3c2cOf5',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('RZ5X3UuiM0Wzg3pQ',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('A3qRm3Gs36Nbfs29',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('9vveNoR1VA9Bx0Wo',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('hAfwbHxZih4Xb0qi',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('1r6ruvSdxn2bHHIk',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('AXxmouWPp6Tx1JbK',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('lxIZLdg2IkwOC2b9',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('lf1QZaUHSy82w7SR',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('Gm2XrTqVMbECVPan',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('GbDO8pRNdPA5tQXE',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('zbKI2RCl5h3vowoy',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.sanity.value',1,null,true);
@@ -0,0 +1 @@
game.mosh.initModifyItem('H4UUQsZOSaYGRPSY',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('xVW5zbK05EqQmaA4',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('1rUlQJ5iwD29X4oT',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',1,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('JV43ilZwsikj75j1',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('xlKWL5nZm3SJPhrf',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('iZzcfZ26I2svoonl',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyItem('qsOHsbKMonl9tiaq',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('x0YRvBbVoHPILD6x',1);
@@ -0,0 +1 @@
game.mosh.initModifyItem('ZIYe2ULX7AKP5MVI',1);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.combat.value',null,'1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.fear.value',null,'1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.max',null,'1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',null,'1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',null,'1d5',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.min',2,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',2,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.body.value',null,'2d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.speed.value',null,'2d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.strength.value',null,'2d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',3,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.min',-1,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',-1,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.hits.value',-1,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.body.value',null,'-1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.health.value',null,'-1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.intellect.value',null,'-1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.max',null,'-1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',null,'-1d10',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.sanity.value',null,'-1d5',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.value',null,'-1d5',true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.other.stress.max',-2,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.intellect.value',-5,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.speed.value',-5,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initModifyActor('system.stats.strength.value',-5,null,true);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [+]','low','body',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [-]','low','body',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100','low','body',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [+]','low','combat',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [-]','low','combat',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100','low','combat',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollTable(`cZOHlhEJcYGZsQBM`,`1d10 [+]`,`high`,false,false,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollTable(`cZOHlhEJcYGZsQBM`,`1d10 [-]`,`high`,false,false,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [+]','low','fear',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [-]','low','fear',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100','low','fear',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [+]','low','intellect',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [-]','low','intellect',null,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100','low','intellect',null,null,null);
@@ -2,15 +2,26 @@ prepModifyActor();
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//is there a selected character? warn if no
if (!game.user.character) {
//warn player
game.mosh.noCharSelected();
} else {
//get the health for this token
let curValue = game.user.character.system.health.value;
//calculate difference
let lowerBy = 1 - curValue;
//run the function for the player's 'Selected Character'
game.user.character.modifyActor('system.health.value',lowerBy,null,true);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
}
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//is there a selected character? warn if no
if (!canvas.tokens.controlled.length) {
//warn player
game.mosh.noCharSelected();
} else {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
//get the health for this token
@@ -21,4 +32,5 @@ async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg
token.actor.modifyActor('system.health.value',lowerBy,null,true);
});
}
}
}
@@ -2,15 +2,26 @@ prepModifyActor();
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//is there a selected character? warn if no
if (!game.user.character) {
//warn player
game.mosh.noCharSelected();
} else {
//get the health for this token
let curValue = game.user.character.system.other.stress.min;
//calculate difference
let lowerBy = 2 - curValue;
//run the function for the player's 'Selected Character'
game.user.character.modifyActor('system.other.stress.min',lowerBy,null,true);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
}
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//is there a selected character? warn if no
if (!canvas.tokens.controlled.length) {
//warn player
game.mosh.noCharSelected();
} else {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
//get the health for this token
@@ -21,4 +32,5 @@ async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg
token.actor.modifyActor('system.other.stress.min',lowerBy,null,true);
});
}
}
}
@@ -2,15 +2,26 @@ prepModifyActor();
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//is there a selected character? warn if no
if (!game.user.character) {
//warn player
game.mosh.noCharSelected();
} else {
//get the health for this token
let curValue = game.user.character.system.hits.value;
//calculate difference
let lowerBy = 0 - curValue;
//run the function for the player's 'Selected Character'
game.user.character.modifyActor('system.hits.value',lowerBy,null,true);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
}
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//is there a selected character? warn if no
if (!canvas.tokens.controlled.length) {
//warn player
game.mosh.noCharSelected();
} else {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
//get the health for this token
@@ -21,4 +32,5 @@ async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg
token.actor.modifyActor('system.hits.value',lowerBy,null,true);
});
}
}
}
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollTable(`panicCheck`,`[+]`,null,false,false,null,null);
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollTable(`panicCheck`,`[-]`,null,false,false,null,null);
@@ -2,9 +2,14 @@ prepModifyActor();
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//get the health for this token
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//is there a selected character? warn if no
if (!game.user.character) {
//warn player
game.mosh.noCharSelected();
} else {
//get the health for this character
let curValue = game.user.character.system.other.stress.max;
//calculate difference
let raiseBy = 85 - curValue;
@@ -12,7 +17,13 @@ async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg
if (raiseBy < 0) {raiseBy = 0;}
//run the function for the player's 'Selected Character'
game.user.character.modifyActor('system.other.stress.max',raiseBy,null,true);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
}
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//is there a selected character? warn if no
if (!canvas.tokens.controlled.length) {
//warn player
game.mosh.noCharSelected();
} else {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
//get the health for this token
@@ -25,4 +36,5 @@ async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg
token.actor.modifyActor('system.other.stress.max',raiseBy,null,true);
});
}
}
}
@@ -2,9 +2,14 @@ prepModifyActor();
//tell the actor to run the function
async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg) {
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//get the health for this token
//determine who to run the macro for
if (game.settings.get('mosh','macroTarget') === 'character') {
//is there a selected character? warn if no
if (!game.user.character) {
//warn player
game.mosh.noCharSelected();
} else {
//get the health for this character
let curValue = game.user.character.system.other.stress.min;
//calculate difference
let raiseBy = 5 - curValue;
@@ -12,7 +17,13 @@ async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg
if (raiseBy < 0) {raiseBy = 0;}
//run the function for the player's 'Selected Character'
game.user.character.modifyActor('system.other.stress.min',raiseBy,null,true);
} else if (game.settings.get('mosh','macroTarget') === 'token') {
}
} else if (game.settings.get('mosh','macroTarget') === 'token') {
//is there a selected character? warn if no
if (!canvas.tokens.controlled.length) {
//warn player
game.mosh.noCharSelected();
} else {
//run the function for all selected tokens
canvas.tokens.controlled.forEach(function(token){
//get the health for this token
@@ -25,4 +36,5 @@ async function prepModifyActor(fieldAddress,modValue,modRollString,outputChatMsg
token.actor.modifyActor('system.other.stress.min',raiseBy,null,true);
});
}
}
}
+1
View File
@@ -0,0 +1 @@
game.mosh.initRollCheck('1d100 [+]','low','restSave',null,null,null);

Some files were not shown because too many files have changed in this diff Show More