Enable saving items in extra slots

This commit is contained in:
Justin Edmund 2022-01-14 21:51:48 -08:00
parent be61dd440b
commit 868d113fae
3 changed files with 6 additions and 14 deletions

View file

@ -218,7 +218,7 @@ const Party = (props: Props) => {
function storeSummon(summon: Summon, position: number) { function storeSummon(summon: Summon, position: number) {
if (position == -1) { if (position == -1) {
setMainSummon(summon) setMainSummon(summon)
} else if (position == 4) { } else if (position == 6) {
setFriendSummon(summon) setFriendSummon(summon)
} else { } else {
// Store the grid unit summon at the correct position // Store the grid unit summon at the correct position
@ -235,7 +235,7 @@ const Party = (props: Props) => {
'summon_id': summon.id, 'summon_id': summon.id,
'position': position, 'position': position,
'main': (position == -1), 'main': (position == -1),
'friend': (position == 4) 'friend': (position == 6)
} }
}, headers) }, headers)
} }

View file

@ -53,7 +53,7 @@ const SummonGrid = (props: Props) => {
editable={props.editable} editable={props.editable}
key="grid_friend_summon" key="grid_friend_summon"
onReceiveData={receiveSummon} onReceiveData={receiveSummon}
position={4} position={6}
unitType={2} unitType={2}
summon={props.friend} summon={props.friend}
/> />
@ -83,14 +83,10 @@ const SummonGrid = (props: Props) => {
<ExtraSummons <ExtraSummons
grid={props.grid} grid={props.grid}
editable={false} editable={props.editable}
exists={false} exists={false}
offset={numSummons} offset={numSummons}
onSelect={ onSelect={props.onSelect}
function (type: GridType, summon: Summon, position: number): void {
throw new Error('Function not implemented.')
}
}
/> />
</div> </div>
) )

View file

@ -34,11 +34,7 @@ const WeaponGrid = (props: Props) => {
editable={props.editable} editable={props.editable}
exists={false} exists={false}
offset={numWeapons} offset={numWeapons}
onSelect={ onSelect={props.onSelect}
function (type: GridType, weapon: Weapon, position: number): void {
throw new Error('Function not implemented.')
}
}
/> />
) )