zengm-games / facesjs

A JavaScript library for generating vector-based cartoon faces

Home Page:https://zengm.com/facesjs/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Special Use for DiscordJS

Voltext opened this issue · comments

Hi,

I just found ur work that is exactly what i was looking for.
Actually im working for a huge project that's on Discord and would use some character generator as you presented.

I just look at your documentation but i don't think that can be use on Discord right ?
I wanted to know if there's any way to generate an image (or a link) that i can use to display the image, because on Discord i can't precise an HTML element.

Thank you so much.
Have a great day

Currently faces.js is designed to be used in a website, but a modified version of https://github.com/zengm-games/facesjs/blob/master/src/display.ts could output an SVG file. Or you could use do something like https://playwright.dev/docs/screenshots and use faces.js without modification.

I've never written a Discord bot, but I imagine you could either send an image directly to Discord, or maybe you'd have to upload it to some intermediate server and link to it.