Functoning weapons
This commit is contained in:
1 parent
747bd3eb8e
commit
2291c5d1e6
24 files changed
+1091
-167
No files matched your search
@@ -0,0 +1,27 @@
|
||||
import { prepareActiveEffectCategories } from "../helpers/utils.mjs";
|
||||
import { systemPath } from "../constants.mjs";
|
||||
import { M6ItemSheet } from "./item-sheet.mjs";
|
||||
const { api, sheets } = foundry.applications;
|
||||
|
||||
/**
|
||||
* Extend the basic ItemSheet with some very simple modifications.
|
||||
*/
|
||||
export class M6ArmorSheet extends M6ItemSheet {
|
||||
static get DEFAULT_OPTIONS() {
|
||||
return {
|
||||
...super.DEFAULT_OPTIONS, // Kopiert alle bestehenden Actions aus M6ItemSheet
|
||||
actions: {
|
||||
...super.DEFAULT_OPTIONS.actions,
|
||||
cycleEquip: this.#cycleEquip // Fügt NUR für dieses Sheet die neue Action hinzu
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
static #cycleEquip() {
|
||||
this.item.update({
|
||||
system: {
|
||||
equipped: !this.item.system.equipped
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user