)
}
}
function telumaImage(index: number) {
const baseUrl = `${process.env.NEXT_PUBLIC_SIERO_IMG_URL}/weapon-keys/`
let filename = ''
let altText = ''
// If there is a grid weapon, it is a Draconic Weapon and it has keys
if (gridWeapon && gridWeapon.object.series === 3 && gridWeapon.weaponKeys) {
if (index === 0 && gridWeapon.weaponKeys[0]) {
altText = `${gridWeapon.weaponKeys[0].name[locale]}`
filename = `${gridWeapon.weaponKeys[0].slug}.png`
} else if (index === 1 && gridWeapon.weaponKeys[1]) {
altText = `${gridWeapon.weaponKeys[1].name[locale]}`
const element = gridWeapon.object.element
filename = `${gridWeapon.weaponKeys[1].slug}-${element}.png`
}
return (
)
}
}
function axImages() {
let images: JSX.Element[] = []
if (
gridWeapon &&
gridWeapon.object.ax &&
gridWeapon.ax &&
gridWeapon.ax.length > 0
) {
for (let i = 0; i < gridWeapon.ax.length; i++) {
const image = axImage(i)
if (image) images.push(image)
}
}
return images
}
// Methods: Layer element rendering
const weaponModal = () => {
if (gridWeapon) {
return (