Added short and long rest and Temp points

Updated Force and Tech Points on Short and Long Rests along with Temporary points.

Also added class powercasting to migration
This commit is contained in:
supervj 2021-02-09 02:14:10 -05:00
parent 932c96ba4a
commit b5ecde7f0c
5 changed files with 105 additions and 24 deletions

12
sw5e.js
View file

@ -195,16 +195,16 @@ Hooks.once("ready", function() {
// Determine whether a system migration is required and feasible
if ( !game.user.isGM ) return;
const currentVersion = game.settings.get("sw5e", "systemMigrationVersion");
const NEEDS_MIGRATION_VERSION = "1.2.1";
const NEEDS_MIGRATION_VERSION = "R1-A1";
const COMPATIBLE_MIGRATION_VERSION = 0.80;
const needsMigration = currentVersion && isNewerVersion(NEEDS_MIGRATION_VERSION, currentVersion);
if ( !needsMigration ) return;
//if ( !needsMigration ) return;
// Perform the migration
if ( currentVersion && isNewerVersion(COMPATIBLE_MIGRATION_VERSION, currentVersion) ) {
const warning = `Your SW5e system data is from too old a Foundry version and cannot be reliably migrated to the latest version. The process will be attempted, but errors may occur.`;
ui.notifications.error(warning, {permanent: true});
}
//if ( currentVersion && isNewerVersion(COMPATIBLE_MIGRATION_VERSION, currentVersion) ) {
// const warning = `Your SW5e system data is from too old a Foundry version and cannot be reliably migrated to the latest version. The process will be attempted, but errors may occur.`;
// ui.notifications.error(warning, {permanent: true});
//}
migrations.migrateWorld();
});