Skip to content
This repository has been archived by the owner on Jan 18, 2022. It is now read-only.

Commit

Permalink
Fixed #450, minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Rughalt committed Apr 4, 2021
1 parent dc63899 commit ac93985
Show file tree
Hide file tree
Showing 5 changed files with 260 additions and 238 deletions.
5 changes: 1 addition & 4 deletions module/actor/entity.js
Original file line number Diff line number Diff line change
Expand Up @@ -1555,11 +1555,10 @@ export class ActorPF extends Actor {
if (changeData[changeTarget] == null) return;
if (currentChangeTarget !== changeTarget) {
currentChangeTarget = changeTarget;
console.log('D35E | Applying Changes, blacklisting roll data, starting change type', changeTarget)

// Cleaning up roll data from blacklisted stuff for this type of change
changeRollData = this.constructor._blacklistChangeData(this.getRollData(srcData1.data), changeTarget);
}
console.log('D35E | Applying Changes, change', change.raw)


changeRollData.item = {};
Expand All @@ -1578,7 +1577,6 @@ export class ActorPF extends Actor {
temp.push(changeData[changeTarget]);

if (allChanges.length <= a + 1 || allChanges[a + 1].raw[2] !== changeTarget) {
console.log('D35E | Applying Changes, change target is different, finished change type', changeTarget)
const newData = this._applyChanges(changeTarget, temp, srcData1);
this._addDynamicData(updateData, newData, flags, Object.keys(this.data.data.abilities), srcData1, false, changeTarget);
temp = [];
Expand Down Expand Up @@ -1944,7 +1942,6 @@ export class ActorPF extends Actor {
linkData(data, updateData, "data.attributes.creatureType", getProperty(templateHD[0].data, "creatureType") || "humanoid");
}

console.log(`D35E | Setting attributes hd total | ${data1.details.level.value}`)
linkData(data, updateData, "data.attributes.hd.total", data1.details.level.value - raceLA);
//linkData(data, updateData, "data.attributes.hd.racialClass", data1.details.level.value - raceLA);

Expand Down
2 changes: 1 addition & 1 deletion module/actor/sheets/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -1848,7 +1848,7 @@ export class ActorSheetPF extends ActorSheet {
if (i.data.containerId)
containerItemsWeight.set(i.data.containerId,(containerItemsWeight.get(i.data.containerId) || 0) + Math.round(i.data.quantity * i.data.weight * weightConversion * 10) / 10)
}
containersMap.get(containerItem.id).itemsWeight = containerItemsWeight.get(containerItem.id) || 0
containersMap.get(containerItem.id).itemsWeight = Math.round((containerItemsWeight.get(containerItem.id) || 0) * 10) / 10
containersMap.get(containerItem.id).itemsWeightPercentage = Math.min(98,Math.floor(containerItemsWeight.get(containerItem.id) / containersMap.get(containerItem.id).data.capacity * 100.0))
}

Expand Down
4 changes: 2 additions & 2 deletions module/welcome-screen.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export default function renderWelcomeScreen() {
static get defaultOptions() {
const options = super.defaultOptions;
options.template = `systems/D35E/templates/welcome-screen.html`;
options.resizable = true;
options.resizable = false;
options.width = 920;
options.height = 730;
options.classes = ["welcome-screen"];
Expand Down Expand Up @@ -48,4 +48,4 @@ export default function renderWelcomeScreen() {
}

(new WelcomeScreen()).render(true);
}
}
4 changes: 2 additions & 2 deletions templates/actors/character-sheet.html
Original file line number Diff line number Diff line change
Expand Up @@ -233,8 +233,8 @@ <h1 class="charname">
</div>

{{!-- Inventory Tab --}}
<div class="tab inventory flexcol" data-group="primary" data-tab="inventory">
{{> "systems/D35E/templates/actors/parts/actor-inventory.html" sections=inventory}}
<div class="tab inventory primary-group flexcol" data-group="primary" data-tab="inventory">
{{> "systems/D35E/templates/actors/parts/actor-inventory.html" sections=inventory}}
</div>

{{!-- Features Tab --}}
Expand Down
Loading

0 comments on commit ac93985

Please sign in to comment.