Skip to content

Commit

Permalink
npcs
Browse files Browse the repository at this point in the history
  • Loading branch information
skuqre committed Feb 17, 2024
1 parent 80d9ab9 commit c80dfbc
Show file tree
Hide file tree
Showing 9 changed files with 134 additions and 68 deletions.
22 changes: 21 additions & 1 deletion public/blabla-npcs.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@
["denji chainsaw man", "si_c803_01_00_s"],

["oswald", "si_c961_00_s"],
["freesia", "si_c960_00_s"],
["ruru", "si_c946_00_s"],
["bolt", "si_c933_00_s"],
["bolt junior", "si_c932_00_s"],
Expand All @@ -80,9 +81,28 @@
["mass produced purple", "si_c254_00_s"],
["mass produced white", "si_c255_00_s"],

["b-0006", "si_c962_00_s"],
["c-1002", "si_c963_00_s"],
["6000-d", "si_c964_00_s"],

["rose", "si_c971_00_s"],
["mass produced melee old", "si_c974_00_s"],
["mass produced melee", "si_c974_01_00_s"],

["timi", "si_c975_00_s"]
["timi", "si_c975_00_s"],

["hedonia member", "si_c920_00_s"],
["seimeikai member", "si_c921_00_s"],
["peony association member", "si_c922_00_s"],

["lumi", "si_c970_00_s"],
["ghost: lena", "si_c969_00_s"],
["ghost: lua", "si_c968_00_s"],
["ghost: lumi", "si_c967_00_s"],

["outer rim generic a", "si_c918_00_s"],
["outer rim generic b", "si_c919_00_s"],

["mast: old", "si_c350_old_00_s"],
["rapi: old", "si_c010_01_00_s"]
]
Binary file added public/fonts/JP-GothicMB101-Bold.ttf
Binary file not shown.
Binary file added public/fonts/JP-GothicMB101-ExtraBold.ttf
Binary file not shown.
Binary file added public/fonts/JP-GothicMB101-Regular.ttf
Binary file not shown.
121 changes: 57 additions & 64 deletions src/pages/blabla-pfps.astro
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ import '../components/GlobalStyle.astro';
import Credits from '../components/Credits.astro';
import npcs from '../../public/blabla-npcs.json'
const response = await fetch('https://api.dotgg.gg/nikke/characters/');
const jsonresponse = await response.json();
---

<html lang="en">
Expand All @@ -24,7 +21,7 @@ const jsonresponse = await response.json();
<meta name="twitter:description" content="All of the available Blabla PFPs.">
<meta name="twitter:card" content="summary_large_image">

<style>
<style is:inline>
div.npc-table {
display: flex;
flex-wrap: wrap;
Expand Down Expand Up @@ -79,62 +76,27 @@ const jsonresponse = await response.json();
<p>All of the available Blabla PFPs are displayed here. Click their image to copy their search term.</p>

<h2>Elysion</h2>
<div class="npc-table">
{
jsonresponse.map((e) => {
if (e.manufacturer == 'Elysion') {
return <img src={"https://nikke-db-legacy.pages.dev/images/sprite/" + e.img + ".png"} alt={e.name.toLowerCase()} title={e.name.toLowerCase()} class="npc" />
}
})
}
<div class="npc-table" id="elysion">
</div>

<br>
<h2>Missilis</h2>
<div class="npc-table">
{
jsonresponse.map((e) => {
if (e.manufacturer == 'Missilis') {
return <img src={"https://nikke-db-legacy.pages.dev/images/sprite/" + e.img + ".png"} alt={e.name.toLowerCase()} title={e.name.toLowerCase()} class="npc" />
}
})
}
<div class="npc-table" id="missilis">
</div>

<br>
<h2>Tetra Line</h2>
<div class="npc-table">
{
jsonresponse.map((e) => {
if (e.manufacturer == 'Tetra') {
return <img src={"https://nikke-db-legacy.pages.dev/images/sprite/" + e.img + ".png"} alt={e.name.toLowerCase()} title={e.name.toLowerCase()} class="npc" />
}
})
}
<div class="npc-table" id="tetra">
</div>

<br>
<h2>Pilgrims</h2>
<div class="npc-table">
{
jsonresponse.map((e) => {
if (e.manufacturer == 'Pilgrim') {
return <img src={"https://nikke-db-legacy.pages.dev/images/sprite/" + e.img + ".png"} alt={e.name.toLowerCase()} title={e.name.toLowerCase()} class="npc" />
}
})
}
<div class="npc-table" id="pilgrim">
</div>

<br>
<h2>Abnormal</h2>
<div class="npc-table">
{
jsonresponse.map((e) => {
if (e.manufacturer == 'Abnormal') {
return <img src={"https://nikke-db-legacy.pages.dev/images/sprite/" + e.img + ".png"} alt={e.name.toLowerCase()} title={e.name.toLowerCase()} class="npc" />
}
})
}
<div class="npc-table" id="abnormal">
</div>

<br>
Expand All @@ -146,28 +108,59 @@ const jsonresponse = await response.json();
<p class="alert">Copied!</p>

<script>
const npcs = document.getElementsByClassName("npc");
const alert = document.getElementsByClassName("alert")[0];
var prevTimeout = null;

for (let i = 0; i < npcs.length; i++) {
npcs[i].onclick = async (e) => {
try {
await navigator.clipboard.writeText(npcs[i].alt);
alert.innerHTML = 'Copied "' + npcs[i].alt + '" to clipboard.'
alert.style.top = '16px';

if (prevTimeout != null) {
clearTimeout(prevTimeout)
const response = await fetch('https://api.dotgg.gg/nikke/characters/');
const jsonresponse = await response.json();

fetch('https://api.dotgg.gg/nikke/characters/').then((response) => {
response.json().then((jsonresponse) => {
let pfp = {}

jsonresponse.map((e) => {
if (pfp[e.manufacturer.toLowerCase()] == undefined) {
pfp[e.manufacturer.toLowerCase()] = [];
}

pfp[e.manufacturer.toLowerCase()].push({
img: "https://nikke-db-legacy.pages.dev/images/sprite/" + e.img + ".png",
name: e.name.toLowerCase()
});
});

(['elysion', 'missilis', 'tetra', 'pilgrim', 'abnormal']).forEach((s) => {
pfp[s].forEach((e) => {
const img = document.createElement("img");
img.classList.add('npc');
img.alt = e.name;
img.title = e.name;
img.src = e.img;
document.getElementById(s).appendChild(img);
});
});

const npcs = document.getElementsByClassName("npc");
const alert = document.getElementsByClassName("alert")[0];
var prevTimeout = null;

for (let i = 0; i < npcs.length; i++) {
npcs[i].onclick = async (e) => {
try {
await navigator.clipboard.writeText(npcs[i].alt);
alert.innerHTML = 'Copied "' + npcs[i].alt + '" to clipboard.'
alert.style.top = '16px';

if (prevTimeout != null) {
clearTimeout(prevTimeout)
}
prevTimeout = setTimeout(() => {
alert.style.top = '-300px';
}, 2000);
} catch (err) {

}
}
prevTimeout = setTimeout(() => {
alert.style.top = '-300px';
}, 2000);
} catch (err) {

}
}
}
});
});
</script>

<p><a href="/nikke-font-generator/blabla">go back</a></p>
Expand Down
7 changes: 6 additions & 1 deletion src/pages/credits.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,12 @@ embeddesc: The site's credits!
| [**Butch and Sundance**](https://www.dafont.com/butch-sundance.font) | Made by [Dan Zadorozny (Iconian Fonts)](https://www.iconian.com). Used on Logo Generator. Found through research. |
| [**SUIT**](https://sun.fo/suit/) | Made by the folks at [sun.fo](https://sun.fo/). Used on the Blabla Generator. |
| [**Abolition**](https://fortfoundry.com/fonts/abolition) | Made by [Mattox Shuler (Fort Foundry)](https://fortfoundry.com). Used on Boss Warning Generator. Found through research. |
| [**Voltec (demo)**](https://typefactory.co/product/voltec-futuristic-typeface/) | Made by the folks at [TypeFactory](https://typefactory.co). Used on Boss Warning Generator. Found through research. |
| [**Voltec (demo, specifically)**](https://typefactory.co/product/voltec-futuristic-typeface/) | Made by the folks at [TypeFactory](https://typefactory.co). Used on Boss Warning Generator. Found through research. |

## Unimplemented fonts
These fonts are here for future implementation.
- **Gothic MB101**: Made by [Morisawa Inc.](https://en.morisawa.co.jp). Used on Japanese language in-game.


<br>

Expand Down
34 changes: 34 additions & 0 deletions src/pages/update-log.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,40 @@ embeddesc: the update log

<br>

## hi `Feb 17, 2024`

**blabla generator**
- added npcs
- freesia (RED ASH, from RE:DASH specifically)
- b-0006 (OuteR: AUTOMATA)
- c-1002 (OuteR: AUTOMATA)
- 6000-d (OuteR: AUTOMATA)
- hedonia member (rosalina's henchmen)
- seimeikai member (sakura's henchmen)
- peony association member (moran's henchmen, or just one of the best boys, Jin)
- lumi (NEVERLAND)
- ghost: lena (NEVERLAND)
- ghost: lua (NEVERLAND)
- ghost: lumi (NEVERLAND)
- outer rim generic a
- outer rim generic b
- mast: old
- rapi: old
- updated the [blabla pfps list](/nikke-font-generator/blabla-pfps) to fetch the data on site visit rather than on compile time (sorry [nikke.gg](https://nikke.gg))

**general**
- added the Japanese font in the repository.
- it's not implemented on any of the generators yet, however, [credits are already added](/nikke-font-generator/credits).

I mainly am working on [Anisa](https://skuqre.github.io/anisa/) right now. no ideas for this site currently so /shrug<br>
I am stupid and put it as "beta" but like none of the functions are like existing so it's more of in an indev stage lolé

<br>

---

<br>

## boss warning `Jan 22, 2024`

**introducing the next tool to the roster: the boss warning generator!**
Expand Down
6 changes: 4 additions & 2 deletions src/pages/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ If you have other concerns about the site, you can contact me through:
- Reddit ([`u/ANISNO1`](https://reddit.com/u/ANISNO1))
- Discord (send a message request to `@skuqre`)

I'll attempt to address your concerns to the best of my ability.<br>
**I will only entertain concerns about this site alone.**
I'll attempt to address your concerns to the best of my ability.

**I will only entertain concerns about this site and [Anisa](https://skqure.github.io/anisa).**<br>
This applies to other NIKKE-related sites I've created as well.

<br>
12 changes: 12 additions & 0 deletions src/scripts/dialogue.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,18 @@ const myFont2 = new FontFace('PB', "url('/nikke-font-generator/fonts/Pretendard-
await myFont2.load();
document.fonts.add(myFont2);

// 1, -3
const jpEBold = new FontFace('JPEB', "url('/nikke-font-generator/fonts/JP-GothicMB101-ExtraBold.ttf')");
await jpEBold.load();
document.fonts.add(jpEBold);

// -1, -7
const jpBold = new FontFace('JPB', "url('/nikke-font-generator/fonts/JP-GothicMB101-Bold.ttf')");
await jpBold.load();
document.fonts.add(jpBold);

// adding JP fonts soon. Maybe.

let text2 = '';
let subtext2 = '';
let size = 100;
Expand Down

0 comments on commit c80dfbc

Please sign in to comment.