@rpg-engine/long-bow 0.3.98 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/long-bow.cjs.development.js +10 -5
- package/dist/long-bow.cjs.development.js.map +1 -1
- package/dist/long-bow.cjs.production.min.js +1 -1
- package/dist/long-bow.cjs.production.min.js.map +1 -1
- package/dist/long-bow.esm.js +10 -5
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/ProgressBar.tsx +3 -0
- package/src/components/Shortcuts/Shortcuts.tsx +3 -2
- package/src/components/SkillsContainer.tsx +4 -1
- package/src/components/Spellbook/Spell.tsx +1 -1
- package/src/components/Spellbook/Spellbook.tsx +2 -0
- package/src/components/Spellbook/cards/SpellInfo.tsx +6 -4
- package/src/.DS_Store +0 -0
- package/src/components/.DS_Store +0 -0
- package/src/components/NPCDialog/.DS_Store +0 -0
- package/src/components/NPCDialog/img/.DS_Store +0 -0
- package/src/mocks/.DS_Store +0 -0
- package/src/mocks/atlas/.DS_Store +0 -0
package/package.json
CHANGED
|
@@ -21,6 +21,9 @@ export const ProgressBar: React.FC<IBarProps> = ({
|
|
|
21
21
|
minWidth = 100,
|
|
22
22
|
style,
|
|
23
23
|
}) => {
|
|
24
|
+
value = Math.round(value);
|
|
25
|
+
max = Math.round(max);
|
|
26
|
+
|
|
24
27
|
const calculatePercentageValue = function(max: number, value: number) {
|
|
25
28
|
if (value > max) {
|
|
26
29
|
value = max;
|
|
@@ -71,7 +71,7 @@ export const Shortcuts: React.FC<ShortcutsProps> = ({
|
|
|
71
71
|
|
|
72
72
|
const isOnShortcutCooldown = shortcutCooldown > 0;
|
|
73
73
|
|
|
74
|
-
if (shortcuts[i]?.type === ShortcutType.Item) {
|
|
74
|
+
if (shortcuts && shortcuts[i]?.type === ShortcutType.Item) {
|
|
75
75
|
const payload = shortcuts[i]?.payload as IItem | undefined;
|
|
76
76
|
|
|
77
77
|
let itemsFromEquipment: (IItem | undefined | null)[] = [];
|
|
@@ -132,7 +132,8 @@ export const Shortcuts: React.FC<ShortcutsProps> = ({
|
|
|
132
132
|
);
|
|
133
133
|
}
|
|
134
134
|
|
|
135
|
-
const payload =
|
|
135
|
+
const payload =
|
|
136
|
+
shortcuts && (shortcuts[i]?.payload as IRawSpell | undefined); //check if shortcuts exists before using the ? operator.
|
|
136
137
|
|
|
137
138
|
const spellCooldown = !payload
|
|
138
139
|
? 0
|
|
@@ -93,6 +93,9 @@ export const SkillsContainer: React.FC<ISkillContainerProps> = ({
|
|
|
93
93
|
const output = [];
|
|
94
94
|
|
|
95
95
|
for (const [key, value] of Object.entries(skillCategory.values)) {
|
|
96
|
+
if (key === 'stamina') {
|
|
97
|
+
continue;
|
|
98
|
+
}
|
|
96
99
|
//@ts-ignore
|
|
97
100
|
const skillDetails = (skill[key] as unknown) as ISkillDetails;
|
|
98
101
|
|
|
@@ -167,7 +170,7 @@ export const SkillsContainer: React.FC<ISkillContainerProps> = ({
|
|
|
167
170
|
|
|
168
171
|
const SkillsDraggableContainer = styled(DraggableContainer)`
|
|
169
172
|
border: 1px solid black;
|
|
170
|
-
|
|
173
|
+
|
|
171
174
|
height: 90%;
|
|
172
175
|
.DraggableContainer__TitleContainer-sc-184mpyl-2 {
|
|
173
176
|
width: auto;
|
|
@@ -137,6 +137,7 @@ export const Spellbook: React.FC<ISpellbookProps> = ({
|
|
|
137
137
|
const Title = styled.h1`
|
|
138
138
|
font-size: ${uiFonts.size.large} !important;
|
|
139
139
|
margin-bottom: 0 !important;
|
|
140
|
+
|
|
140
141
|
`;
|
|
141
142
|
|
|
142
143
|
const Container = styled.div`
|
|
@@ -145,6 +146,7 @@ const Container = styled.div`
|
|
|
145
146
|
color: white;
|
|
146
147
|
display: flex;
|
|
147
148
|
flex-direction: column;
|
|
149
|
+
|
|
148
150
|
`;
|
|
149
151
|
|
|
150
152
|
const SpellList = styled.div`
|
|
@@ -44,10 +44,12 @@ export const SpellInfo: React.FC<ISpellInfoProps> = ({ spell }) => {
|
|
|
44
44
|
<div className="label">Cooldown:</div>
|
|
45
45
|
<div className="value">{cooldown}</div>
|
|
46
46
|
</Statistic>
|
|
47
|
-
|
|
48
|
-
<
|
|
49
|
-
|
|
50
|
-
|
|
47
|
+
{maxDistanceGrid && (
|
|
48
|
+
<Statistic>
|
|
49
|
+
<div className="label">Max Distance Grid:</div>
|
|
50
|
+
<div className="value">{maxDistanceGrid}</div>
|
|
51
|
+
</Statistic>
|
|
52
|
+
)}
|
|
51
53
|
<Statistic>
|
|
52
54
|
{requiredItem && (
|
|
53
55
|
<>
|
package/src/.DS_Store
DELETED
|
Binary file
|
package/src/components/.DS_Store
DELETED
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/src/mocks/.DS_Store
DELETED
|
Binary file
|
|
Binary file
|