19 lines
32 KiB
Plaintext
19 lines
32 KiB
Plaintext
{"name":"Blood Dragon Vampire Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.6t5oENQZQCZip1hs"}},"scope":"global","command":"async function getVampireTraits() {\n // First load the Vampire Traits pack index\n let vampireTraits = game.packs.get(\"wfrp4e-vampires.vampires-traits\");\n let vampireTraitsIndex = await vampireTraits.getIndex();\n console.log(vampireTraitsIndex )\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitAge = vampireTraitsIndex.find(trait => trait.name == \"Age\")._id;\n let traitClaw = vampireTraitsIndex.find(trait => trait.name == \"Claw\")._id;\n let traitCurse = vampireTraitsIndex.find(trait => trait.name == \"Night's Curse\")._id;\n console.log(traitAge, traitClaw, traitCurse);\n\n // Now build Trait locations\n let fromLocationAge = `Compendium.wfrp4e-vampires.vampires-traits.${traitAge}`;\n let fromLocationClaw = `Compendium.wfrp4e-vampires.vampires-traits.${traitClaw}`;\n let fromLocationCurse = `Compendium.wfrp4e-vampires.vampires-traits.${traitCurse}`;\n \n const age = await fromUuid(fromLocationAge);\n age.data.data.specification.value = \"1 day\";\n\n const claw = await fromUuid(fromLocationClaw);\n claw.data.data.specification.value = 3;\n\n const curse = await fromUuid(fromLocationCurse);\n curse.data.data.specification.value = \"Blood Dragon\";\n\n const createData = [age.data, claw.data, curse.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetVampireTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"9WLtRoMzYN1JQ3FM"}
|
|
{"name":"Von Carstein Vampire Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.YKRzoWomQrHlQqfM"}},"scope":"global","command":"async function getVampireTraits() {\n // First load the Vampire Traits pack index\n let vampireTraits = game.packs.get(\"wfrp4e-vampires.vampires-traits\");\n let vampireTraitsIndex = await vampireTraits.getIndex();\n console.log(vampireTraitsIndex )\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitAge = vampireTraitsIndex.find(trait => trait.name == \"Age\")._id;\n let traitClaw = vampireTraitsIndex.find(trait => trait.name == \"Claw\")._id;\n let traitCurse = vampireTraitsIndex.find(trait => trait.name == \"Night's Curse\")._id;\n console.log(traitAge, traitClaw, traitCurse);\n\n // Now build Trait locations\n let fromLocationAge = `Compendium.wfrp4e-vampires.vampires-traits.${traitAge}`;\n let fromLocationClaw = `Compendium.wfrp4e-vampires.vampires-traits.${traitClaw}`;\n let fromLocationCurse = `Compendium.wfrp4e-vampires.vampires-traits.${traitCurse}`;\n \n const age = await fromUuid(fromLocationAge);\n age.data.data.specification.value = \"1 day\";\n\n const claw = await fromUuid(fromLocationClaw);\n claw.data.data.specification.value = 3;\n\n const curse = await fromUuid(fromLocationCurse);\n curse.data.data.specification.value = \"Von Carstein\";\n\n const createData = [age.data, claw.data, curse.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetVampireTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"A6EULphImIASvpNL"}
|
|
{"name":"Independent Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.8enDbE9TaUC7SxuE"}},"scope":"global","command":"async function getTraits() {\n // First load the Traits pack index\n let coreTraits = game.packs.get(\"wfrp4e-core.traits\");\n let coreTraitsIndex = await coreTraits.getIndex();\n console.log(coreTraitsIndex)\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitBite = coreTraitsIndex.find(trait => trait.name == \"Bite\")._id;\n let traitDarkVision = coreTraitsIndex.find(trait => trait.name == \"Dark Vision\")._id;\n let traitFear = coreTraitsIndex.find(trait => trait.name == \"Fear\")._id;\n let traitPainless = coreTraitsIndex.find(trait => trait.name == \"Painless\")._id;\n let traitUndead = coreTraitsIndex.find(trait => trait.name == \"Undead\")._id;\n let traitVampiric = coreTraitsIndex.find(trait => trait.name == \"Vampiric\")._id;\n \n\n // Now build Trait locations\n let fromLocationBite = `Compendium.wfrp4e-core.traits.${traitBite}`;\n let fromLocationDarkVision = `Compendium.wfrp4e-core.traits.${traitDarkVision}`;\n let fromLocationFear = `Compendium.wfrp4e-core.traits.${traitFear}`;\n let fromLocationPainless = `Compendium.wfrp4e-core.traits.${traitPainless}`;\n let fromLocationUndead = `Compendium.wfrp4e-core.traits.${traitUndead}`;\n let fromLocationVampiric = `Compendium.wfrp4e-core.traits.${traitVampiric}`;\n \n // Now get the Traits and adapt them where necessary\n const bite = await fromUuid(fromLocationBite);\n bite.data.data.specification.value = 3;\n \n const darkVision = await fromUuid(fromLocationDarkVision);\n \n const fear = await fromUuid(fromLocationFear);\n fear.data.data.specification.value = 1;\n \n const painless = await fromUuid(fromLocationPainless);\n \n const undead = await fromUuid(fromLocationUndead);\n \n const vampiric = await fromUuid(fromLocationVampiric);\n\n const createData = [bite.data, darkVision.data, fear.data, painless.data, undead.data, vampiric.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"F7Y15tlytGg4P3ZF"}
|
|
{"name":"Necrarch Stats","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.RtOjYItHSiodu6JI"}},"scope":"global","command":"async function getStats() {\n // Find the selected actor\n let actorSelected = actor;\n console.log(actorSelected);\n\n // Then define the characteristic changes for this Bloodline\n let updates = {\n\t\"data.characteristics.s.modifier\": actorSelected.data.data.characteristics.s.modifier += 10,\n\t\"data.characteristics.t.modifier\": actorSelected.data.data.characteristics.t.modifier += 20,\n\t\"data.characteristics.i.modifier\": actorSelected.data.data.characteristics.i.modifier += 20,\n\t\"data.characteristics.dex.modifier\": actorSelected.data.data.characteristics.dex.modifier += 10,\n\t\"data.characteristics.int.modifier\": actorSelected.data.data.characteristics.int.modifier += 20,\n\t\"data.characteristics.wp.modifier\": actorSelected.data.data.characteristics.wp.modifier += 20,\n\t\"data.characteristics.fel.modifier\": actorSelected.data.data.characteristics.fel.modifier -= 15,\n\t\"data.status.fate.value\": 0,\n\t\"data.status.resilience.value\": 0,\n\t\"data.details.move.value\": 6\n };\n \n // Then update the actor\n actorSelected.update(updates);\n}\n\ngetStats()","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"FeJA2VfTyk7Rr3zA"}
|
|
{"name":"Lahmian Vampire Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.eDXBR6qZKmEQYejl"}},"scope":"global","command":"async function getVampireTraits() {\n // First load the Vampire Traits pack index\n let vampireTraits = game.packs.get(\"wfrp4e-vampires.vampires-traits\");\n let vampireTraitsIndex = await vampireTraits.getIndex();\n console.log(vampireTraitsIndex )\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitAge = vampireTraitsIndex.find(trait => trait.name == \"Age\")._id;\n let traitClaw = vampireTraitsIndex.find(trait => trait.name == \"Claw\")._id;\n let traitCurse = vampireTraitsIndex.find(trait => trait.name == \"Night's Curse\")._id;\n console.log(traitAge, traitClaw, traitCurse);\n\n // Now build Trait locations\n let fromLocationAge = `Compendium.wfrp4e-vampires.vampires-traits.${traitAge}`;\n let fromLocationClaw = `Compendium.wfrp4e-vampires.vampires-traits.${traitClaw}`;\n let fromLocationCurse = `Compendium.wfrp4e-vampires.vampires-traits.${traitCurse}`;\n \n const age = await fromUuid(fromLocationAge);\n age.data.data.specification.value = \"1 day\";\n\n const claw = await fromUuid(fromLocationClaw);\n claw.data.data.specification.value = 3;\n\n const curse = await fromUuid(fromLocationCurse);\n curse.data.data.specification.value = \"Lahmian\";\n\n const createData = [age.data, claw.data, curse.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetVampireTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"GJ3x2fDN59Vwm2m1"}
|
|
{"name":"Independent Stats","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.H9DGuo5xf3RBMFmK"}},"scope":"global","command":"async function getStats() {\n // Find the selected actor\n let actorSelected = actor;\n console.log(actorSelected);\n\n // Then define the characteristic changes for this Bloodline\n let updates = {\n\t\"data.characteristics.ws.modifier\": actorSelected.data.data.characteristics.ws.modifier += 10,\n\t\"data.characteristics.s.modifier\": actorSelected.data.data.characteristics.s.modifier += 10,\n\t\"data.characteristics.t.modifier\": actorSelected.data.data.characteristics.t.modifier += 10,\n\t\"data.characteristics.i.modifier\": actorSelected.data.data.characteristics.i.modifier += 10,\n\t\"data.characteristics.ag.modifier\": actorSelected.data.data.characteristics.ag.modifier += 10,\n\t\"data.characteristics.wp.modifier\": actorSelected.data.data.characteristics.wp.modifier += 10,\n\t\"data.characteristics.fel.modifier\": actorSelected.data.data.characteristics.fel.modifier += 10,\n\t\"data.characteristics.dex.modifier\": actorSelected.data.data.characteristics.dex.modifier += 10,\n\t\"data.status.fate.value\": 0,\n\t\"data.status.resilience.value\": 0,\n\t\"data.details.move.value\": 6\n };\n \n // Then update the actor\n actorSelected.update(updates);\n}\n\ngetStats()","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"GxSBH3tKXjTfPmUP"}
|
|
{"name":"Strigoi Stats","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.532avUNEO68JRkWj"}},"scope":"global","command":"async function getStats() {\n // Find the selected actor\n let actorSelected = actor;\n console.log(actorSelected);\n\n // Then define the characteristic changes for this Bloodline\n let updates = {\n\t\"data.characteristics.ws.modifier\": actorSelected.data.data.characteristics.ws.modifier += 10,\n\t\"data.characteristics.s.modifier\": actorSelected.data.data.characteristics.s.modifier += 20,\n\t\"data.characteristics.t.modifier\": actorSelected.data.data.characteristics.t.modifier += 20,\n\t\"data.characteristics.i.modifier\": actorSelected.data.data.characteristics.i.modifier += 10,\n\t\"data.characteristics.ag.modifier\": actorSelected.data.data.characteristics.ag.modifier += 20,\n\t\"data.characteristics.wp.modifier\": actorSelected.data.data.characteristics.wp.modifier += 10,\n\t\"data.characteristics.fel.modifier\": actorSelected.data.data.characteristics.fel.modifier -= 10,\n\t\"data.status.fate.value\": 0,\n\t\"data.status.resilience.value\": 0,\n\t\"data.details.move.value\": 6\n };\n \n // Then update the actor\n actorSelected.update(updates);\n}\n\ngetStats()","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"JlXyrPUzCmBxKAXA"}
|
|
{"name":"Blood Dragon Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.Tx4rrBQAAkIU7uZL"}},"scope":"global","command":"async function getTraits() {\n // First load the Traits pack index\n let coreTraits = game.packs.get(\"wfrp4e-core.traits\");\n let coreTraitsIndex = await coreTraits.getIndex();\n console.log(coreTraitsIndex)\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitBite = coreTraitsIndex.find(trait => trait.name == \"Bite\")._id;\n let traitDarkVision = coreTraitsIndex.find(trait => trait.name == \"Dark Vision\")._id;\n let traitFear = coreTraitsIndex.find(trait => trait.name == \"Fear\")._id;\n let traitPainless = coreTraitsIndex.find(trait => trait.name == \"Painless\")._id;\n let traitUndead = coreTraitsIndex.find(trait => trait.name == \"Undead\")._id;\n let traitVampiric = coreTraitsIndex.find(trait => trait.name == \"Vampiric\")._id;\n \n\n // Now build Trait locations\n let fromLocationBite = `Compendium.wfrp4e-core.traits.${traitBite}`;\n let fromLocationDarkVision = `Compendium.wfrp4e-core.traits.${traitDarkVision}`;\n let fromLocationFear = `Compendium.wfrp4e-core.traits.${traitFear}`;\n let fromLocationPainless = `Compendium.wfrp4e-core.traits.${traitPainless}`;\n let fromLocationUndead = `Compendium.wfrp4e-core.traits.${traitUndead}`;\n let fromLocationVampiric = `Compendium.wfrp4e-core.traits.${traitVampiric}`;\n \n // Now get the Traits and adapt them where necessary\n const bite = await fromUuid(fromLocationBite);\n bite.data.data.specification.value = 3;\n \n const darkVision = await fromUuid(fromLocationDarkVision);\n \n const fear = await fromUuid(fromLocationFear);\n fear.data.data.specification.value = 1;\n \n const painless = await fromUuid(fromLocationPainless);\n \n const undead = await fromUuid(fromLocationUndead);\n \n const vampiric = await fromUuid(fromLocationVampiric);\n\n const createData = [bite.data, darkVision.data, fear.data, painless.data, undead.data, vampiric.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"OMBDFPzaEh4iyqOJ"}
|
|
{"name":"Lahmian Stats","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.drapRDbX8eKua5n4"}},"scope":"global","command":"async function getStats() {\n // Find the selected actor\n let actorSelected = actor;\n console.log(actorSelected);\n\n // Then define the characteristic changes for this Bloodline\n let updates = {\n \"data.characteristics.bs.modifier\": actorSelected.data.data.characteristics.bs.modifier += 10,\n\t\"data.characteristics.i.modifier\": actorSelected.data.data.characteristics.i.modifier += 20,\n\t\"data.characteristics.ag.modifier\": actorSelected.data.data.characteristics.ag.modifier += 20,\n\t\"data.characteristics.wp.modifier\": actorSelected.data.data.characteristics.wp.modifier += 10,\n\t\"data.characteristics.fel.modifier\": actorSelected.data.data.characteristics.fel.modifier += 20,\n\t\"data.status.fate.value\": 0,\n\t\"data.status.resilience.value\": 0,\n\t\"data.details.move.value\": 6\n };\n \n // Then update the actor\n actorSelected.update(updates);\n}\n\ngetStats()","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"OsvuolbjzLkm1QTb"}
|
|
{"name":"Necrarch Vampire Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.9zAxkKsEuLNLE8TL"}},"scope":"global","command":"async function getVampireTraits() {\n // First load the Vampire Traits pack index\n let vampireTraits = game.packs.get(\"wfrp4e-vampires.vampires-traits\");\n let vampireTraitsIndex = await vampireTraits.getIndex();\n console.log(vampireTraitsIndex )\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitAge = vampireTraitsIndex.find(trait => trait.name == \"Age\")._id;\n let traitClaw = vampireTraitsIndex.find(trait => trait.name == \"Claw\")._id;\n let traitCurse = vampireTraitsIndex.find(trait => trait.name == \"Night's Curse\")._id;\n console.log(traitAge, traitClaw, traitCurse);\n\n // Now build Trait locations\n let fromLocationAge = `Compendium.wfrp4e-vampires.vampires-traits.${traitAge}`;\n let fromLocationClaw = `Compendium.wfrp4e-vampires.vampires-traits.${traitClaw}`;\n let fromLocationCurse = `Compendium.wfrp4e-vampires.vampires-traits.${traitCurse}`;\n \n const age = await fromUuid(fromLocationAge);\n age.data.data.specification.value = \"1 day\";\n\n const claw = await fromUuid(fromLocationClaw);\n claw.data.data.specification.value = 3;\n\n const curse = await fromUuid(fromLocationCurse);\n curse.data.data.specification.value = \"Necrarch\";\n\n const createData = [age.data, claw.data, curse.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetVampireTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"RBx6Lm9CP92gtPXE"}
|
|
{"name":"Independent Vampire Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.U7jcJQhGhN0RY3b1"}},"scope":"global","command":"async function getVampireTraits() {\n // First load the Vampire Traits pack index\n let vampireTraits = game.packs.get(\"wfrp4e-vampires.vampires-traits\");\n let vampireTraitsIndex = await vampireTraits.getIndex();\n console.log(vampireTraitsIndex )\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitAge = vampireTraitsIndex.find(trait => trait.name == \"Age\")._id;\n let traitClaw = vampireTraitsIndex.find(trait => trait.name == \"Claw\")._id;\n let traitCurse = vampireTraitsIndex.find(trait => trait.name == \"Night's Curse\")._id;\n console.log(traitAge, traitClaw, traitCurse);\n\n // Now build Trait locations\n let fromLocationAge = `Compendium.wfrp4e-vampires.vampires-traits.${traitAge}`;\n let fromLocationClaw = `Compendium.wfrp4e-vampires.vampires-traits.${traitClaw}`;\n let fromLocationCurse = `Compendium.wfrp4e-vampires.vampires-traits.${traitCurse}`;\n \n const age = await fromUuid(fromLocationAge);\n age.data.data.specification.value = \"1 day\";\n\n const claw = await fromUuid(fromLocationClaw);\n claw.data.data.specification.value = 3;\n\n const curse = await fromUuid(fromLocationCurse);\n curse.data.data.specification.value = \"Independent\";\n\n const createData = [age.data, claw.data, curse.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetVampireTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"V4IiUCpU3JFyH2J3"}
|
|
{"name":"Strigoi Vampire Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.Xqt5QR2ctlrwdF4R"}},"scope":"global","command":"async function getVampireTraits() {\n // First load the Vampire Traits pack index\n let vampireTraits = game.packs.get(\"wfrp4e-vampires.vampires-traits\");\n let vampireTraitsIndex = await vampireTraits.getIndex();\n console.log(vampireTraitsIndex )\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitAge = vampireTraitsIndex.find(trait => trait.name == \"Age\")._id;\n let traitClaw = vampireTraitsIndex.find(trait => trait.name == \"Claw\")._id;\n let traitCurse = vampireTraitsIndex.find(trait => trait.name == \"Night's Curse\")._id;\n console.log(traitAge, traitClaw, traitCurse);\n\n // Now build Trait locations\n let fromLocationAge = `Compendium.wfrp4e-vampires.vampires-traits.${traitAge}`;\n let fromLocationClaw = `Compendium.wfrp4e-vampires.vampires-traits.${traitClaw}`;\n let fromLocationCurse = `Compendium.wfrp4e-vampires.vampires-traits.${traitCurse}`;\n \n const age = await fromUuid(fromLocationAge);\n age.data.data.specification.value = \"1 day\";\n\n const claw = await fromUuid(fromLocationClaw);\n claw.data.data.specification.value = 3;\n\n const curse = await fromUuid(fromLocationCurse);\n curse.data.data.specification.value = \"Strigoi\";\n\n const createData = [age.data, claw.data, curse.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetVampireTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"WCjXEdURZQl88cag"}
|
|
{"name":"Lahmian Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.MvDnGZG3sbRKHmWW"}},"scope":"global","command":"async function getTraits() {\n // First load the Traits pack index\n let coreTraits = game.packs.get(\"wfrp4e-core.traits\");\n let coreTraitsIndex = await coreTraits.getIndex();\n console.log(coreTraitsIndex)\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitBite = coreTraitsIndex.find(trait => trait.name == \"Bite\")._id;\n let traitDarkVision = coreTraitsIndex.find(trait => trait.name == \"Dark Vision\")._id;\n let traitFear = coreTraitsIndex.find(trait => trait.name == \"Fear\")._id;\n let traitPainless = coreTraitsIndex.find(trait => trait.name == \"Painless\")._id;\n let traitUndead = coreTraitsIndex.find(trait => trait.name == \"Undead\")._id;\n let traitVampiric = coreTraitsIndex.find(trait => trait.name == \"Vampiric\")._id;\n \n\n // Now build Trait locations\n let fromLocationBite = `Compendium.wfrp4e-core.traits.${traitBite}`;\n let fromLocationDarkVision = `Compendium.wfrp4e-core.traits.${traitDarkVision}`;\n let fromLocationFear = `Compendium.wfrp4e-core.traits.${traitFear}`;\n let fromLocationPainless = `Compendium.wfrp4e-core.traits.${traitPainless}`;\n let fromLocationUndead = `Compendium.wfrp4e-core.traits.${traitUndead}`;\n let fromLocationVampiric = `Compendium.wfrp4e-core.traits.${traitVampiric}`;\n \n // Now get the Traits and adapt them where necessary\n const bite = await fromUuid(fromLocationBite);\n bite.data.data.specification.value = 3;\n \n const darkVision = await fromUuid(fromLocationDarkVision);\n \n const fear = await fromUuid(fromLocationFear);\n fear.data.data.specification.value = 1;\n \n const painless = await fromUuid(fromLocationPainless);\n \n const undead = await fromUuid(fromLocationUndead);\n \n const vampiric = await fromUuid(fromLocationVampiric);\n\n const createData = [bite.data, darkVision.data, fear.data, painless.data, undead.data, vampiric.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"YO0SiTp0FiENkK9r"}
|
|
{"name":"Blood Dragon Stats","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.gHvcVhtZ11tEwEyn"}},"scope":"global","command":"async function getStats() {\n // Find the selected actor\n let actorSelected = actor;\n console.log(actorSelected);\n\n // Then define the characteristic changes for this Bloodline\n let updates = {\n\t\"data.characteristics.ws.modifier\": actorSelected.data.data.characteristics.ws.modifier += 10,\n \"data.characteristics.bs.modifier\": actorSelected.data.data.characteristics.bs.modifier += 10,\n\t\"data.characteristics.s.modifier\": actorSelected.data.data.characteristics.s.modifier += 10,\n\t\"data.characteristics.t.modifier\": actorSelected.data.data.characteristics.t.modifier += 10,\n\t\"data.characteristics.i.modifier\": actorSelected.data.data.characteristics.i.modifier += 10,\n\t\"data.characteristics.ag.modifier\": actorSelected.data.data.characteristics.ag.modifier += 10,\n\t\"data.characteristics.wp.modifier\": actorSelected.data.data.characteristics.wp.modifier += 20,\n\t\"data.status.fate.value\": 0,\n\t\"data.status.resilience.value\": 0,\n\t\"data.details.move.value\": 6\n };\n \n // Then update the actor\n actorSelected.update(updates);\n}\n\ngetStats()","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"ZFQ1SBXCaZrHWj2v"}
|
|
{"name":"Necrarch Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.HrRWamPjUZCiLKAQ"}},"scope":"global","command":"async function getTraits() {\n // First load the Traits pack index\n let coreTraits = game.packs.get(\"wfrp4e-core.traits\");\n let coreTraitsIndex = await coreTraits.getIndex();\n console.log(coreTraitsIndex)\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitBite = coreTraitsIndex.find(trait => trait.name == \"Bite\")._id;\n let traitDarkVision = coreTraitsIndex.find(trait => trait.name == \"Dark Vision\")._id;\n let traitFear = coreTraitsIndex.find(trait => trait.name == \"Fear\")._id;\n let traitPainless = coreTraitsIndex.find(trait => trait.name == \"Painless\")._id;\n let traitUndead = coreTraitsIndex.find(trait => trait.name == \"Undead\")._id;\n let traitVampiric = coreTraitsIndex.find(trait => trait.name == \"Vampiric\")._id;\n \n\n // Now build Trait locations\n let fromLocationBite = `Compendium.wfrp4e-core.traits.${traitBite}`;\n let fromLocationDarkVision = `Compendium.wfrp4e-core.traits.${traitDarkVision}`;\n let fromLocationFear = `Compendium.wfrp4e-core.traits.${traitFear}`;\n let fromLocationPainless = `Compendium.wfrp4e-core.traits.${traitPainless}`;\n let fromLocationUndead = `Compendium.wfrp4e-core.traits.${traitUndead}`;\n let fromLocationVampiric = `Compendium.wfrp4e-core.traits.${traitVampiric}`;\n \n // Now get the Traits and adapt them where necessary\n const bite = await fromUuid(fromLocationBite);\n bite.data.data.specification.value = 3;\n \n const darkVision = await fromUuid(fromLocationDarkVision);\n \n const fear = await fromUuid(fromLocationFear);\n fear.data.data.specification.value = 1;\n \n const painless = await fromUuid(fromLocationPainless);\n \n const undead = await fromUuid(fromLocationUndead);\n \n const vampiric = await fromUuid(fromLocationVampiric);\n\n const createData = [bite.data, darkVision.data, fear.data, painless.data, undead.data, vampiric.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"bksNOtjb6F1NcFGH"}
|
|
{"name":"Von Carstein Stats","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.57nECWkDYuEQoCia"}},"scope":"global","command":"async function getStats() {\n // Find the selected actor\n let actorSelected = actor;\n console.log(actorSelected);\n\n // Then define the characteristic changes for this Bloodline\n let updates = {\n\t\"data.characteristics.ws.modifier\": actorSelected.data.data.characteristics.ws.modifier += 10,\n\t\"data.characteristics.s.modifier\": actorSelected.data.data.characteristics.s.modifier += 10,\n\t\"data.characteristics.t.modifier\": actorSelected.data.data.characteristics.t.modifier += 10,\n\t\"data.characteristics.i.modifier\": actorSelected.data.data.characteristics.i.modifier += 10,\n\t\"data.characteristics.ag.modifier\": actorSelected.data.data.characteristics.ag.modifier += 10,\n\t\"data.characteristics.wp.modifier\": actorSelected.data.data.characteristics.wp.modifier += 20,\n\t\"data.characteristics.fel.modifier\": actorSelected.data.data.characteristics.fel.modifier += 10,\n\t\"data.status.fate.value\": 0,\n\t\"data.status.resilience.value\": 0,\n\t\"data.details.move.value\": 6\n };\n \n // Then update the actor\n actorSelected.update(updates);\n}\n\ngetStats()","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"fDuwZ9HBJCdzOUKI"}
|
|
{"name":"Strigoi Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.rvMUbOskxsXYYIcv"}},"scope":"global","command":"async function getTraits() {\n // First load the Traits pack index\n let coreTraits = game.packs.get(\"wfrp4e-core.traits\");\n let coreTraitsIndex = await coreTraits.getIndex();\n console.log(coreTraitsIndex)\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitBite = coreTraitsIndex.find(trait => trait.name == \"Bite\")._id;\n let traitDarkVision = coreTraitsIndex.find(trait => trait.name == \"Dark Vision\")._id;\n let traitFear = coreTraitsIndex.find(trait => trait.name == \"Fear\")._id;\n let traitPainless = coreTraitsIndex.find(trait => trait.name == \"Painless\")._id;\n let traitUndead = coreTraitsIndex.find(trait => trait.name == \"Undead\")._id;\n let traitVampiric = coreTraitsIndex.find(trait => trait.name == \"Vampiric\")._id;\n \n\n // Now build Trait locations\n let fromLocationBite = `Compendium.wfrp4e-core.traits.${traitBite}`;\n let fromLocationDarkVision = `Compendium.wfrp4e-core.traits.${traitDarkVision}`;\n let fromLocationFear = `Compendium.wfrp4e-core.traits.${traitFear}`;\n let fromLocationPainless = `Compendium.wfrp4e-core.traits.${traitPainless}`;\n let fromLocationUndead = `Compendium.wfrp4e-core.traits.${traitUndead}`;\n let fromLocationVampiric = `Compendium.wfrp4e-core.traits.${traitVampiric}`;\n \n // Now get the Traits and adapt them where necessary\n const bite = await fromUuid(fromLocationBite);\n bite.data.data.specification.value = 3;\n \n const darkVision = await fromUuid(fromLocationDarkVision);\n \n const fear = await fromUuid(fromLocationFear);\n fear.data.data.specification.value = 1;\n \n const painless = await fromUuid(fromLocationPainless);\n \n const undead = await fromUuid(fromLocationUndead);\n \n const vampiric = await fromUuid(fromLocationVampiric);\n\n const createData = [bite.data, darkVision.data, fear.data, painless.data, undead.data, vampiric.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"iWj30aVLXl1SgulI"}
|
|
{"name":"Von Carstein Traits","permission":{"default":0,"kHr5wGqy2Rw4go1y":3},"type":"script","flags":{"core":{"sourceId":"Macro.MA1v9RvFUFPG6U0t"}},"scope":"global","command":"async function getTraits() {\n // First load the Traits pack index\n let coreTraits = game.packs.get(\"wfrp4e-core.traits\");\n let coreTraitsIndex = await coreTraits.getIndex();\n console.log(coreTraitsIndex)\n\n // Then find the selected actor\n let actorSelected = actor;\n console.log(actorSelected)\n\n // Now find the traits we want from this pack\n let traitBite = coreTraitsIndex.find(trait => trait.name == \"Bite\")._id;\n let traitDarkVision = coreTraitsIndex.find(trait => trait.name == \"Dark Vision\")._id;\n let traitFear = coreTraitsIndex.find(trait => trait.name == \"Fear\")._id;\n let traitPainless = coreTraitsIndex.find(trait => trait.name == \"Painless\")._id;\n let traitUndead = coreTraitsIndex.find(trait => trait.name == \"Undead\")._id;\n let traitVampiric = coreTraitsIndex.find(trait => trait.name == \"Vampiric\")._id;\n \n\n // Now build Trait locations\n let fromLocationBite = `Compendium.wfrp4e-core.traits.${traitBite}`;\n let fromLocationDarkVision = `Compendium.wfrp4e-core.traits.${traitDarkVision}`;\n let fromLocationFear = `Compendium.wfrp4e-core.traits.${traitFear}`;\n let fromLocationPainless = `Compendium.wfrp4e-core.traits.${traitPainless}`;\n let fromLocationUndead = `Compendium.wfrp4e-core.traits.${traitUndead}`;\n let fromLocationVampiric = `Compendium.wfrp4e-core.traits.${traitVampiric}`;\n \n // Now get the Traits and adapt them where necessary\n const bite = await fromUuid(fromLocationBite);\n bite.data.data.specification.value = 3;\n \n const darkVision = await fromUuid(fromLocationDarkVision);\n \n const fear = await fromUuid(fromLocationFear);\n fear.data.data.specification.value = 1;\n \n const painless = await fromUuid(fromLocationPainless);\n \n const undead = await fromUuid(fromLocationUndead);\n \n const vampiric = await fromUuid(fromLocationVampiric);\n\n const createData = [bite.data, darkVision.data, fear.data, painless.data, undead.data, vampiric.data];\n return actorSelected.createEmbeddedEntity(\"OwnedItem\", createData);\n}\n\ngetTraits();","author":"kHr5wGqy2Rw4go1y","img":"modules/wfrp4e-core/icons/traits/trait.png","actorIds":[],"_id":"kIB1ppand7q6vfuI"}
|