1.2.0 • Published 22 days ago

sve-card v1.2.0

Weekly downloads
-
License
ISC
Repository
github
Last release
22 days ago

sve-card

DIY Shadowverse EVOLVE card in browser.

Example

gh-pages

single card

npm.io

with showcase

npm.io

Usage

yarn add sve-card
# or
npm install sve-card

ES module

import {Card} from "./sve-card"; // SVECard project path
const canvas = document.getElementById("canvas");
const card = new Card({
    data: {
        desc: "/quick\n"
            + "お互いのリーダーに1ダメージ。\n"
            + "お互いの場にフォレストバット1体を出す。",
        craft: "Abyss",
        cardType: "Follower",
        imageSrc: "https://svgdb.me/assets/fullart/1086340100.png",
        cost: 6,
        attack: 6,
        defense: 6,
        rarity: "BR",
        race: "眷属",
        name: "眷属への贈り物",
        cardNo: "TE01-001 2023",
    },
    height: 2000,
    canvas,
    config: {
        assetPath: "./asset",
    }
});
card.draw();

Please copy asset to your static directory, ensure ./asset/image/***.png can be accessed. If you want to custom the asset path, please change config.assetPath.

In order to provide ruby annotations for japanese, this project import kuroshiro library. Copy dict files and Change config.kuroshiro.dictPath to use this feature.

Browser

<script src="./svecard.min.js"></script>
<script>
    const {Card} = SVECard;
</script>

Data Description Icon

Code日本語 中文
/actアクト横置
/quickクイック快速
/start起動起动
/fanfareファンファーレ入场曲
/lastwordラストワード谢幕曲
/attack攻撃力攻击力
/defense体力体力
/eat食事吃饭
/evo進化进化
/cost{0-9}コスト{0-9}花费{0-9}
/costxコスト10花费10
/forestエルフ妖精
/swordロイヤル皇家
/havenビショップ主教
/runeウィッチ巫师
/dragonドラゴン龙族
/abyssナイトメア梦魇
/neutralニュートラル中立

Development

yarn
yarn dev

modify examples/index.html to see result.

Thanks

  • noteRE provides card resources.
1.2.0

22 days ago

1.1.4

6 months ago

1.1.3

7 months ago

1.1.2

7 months ago

1.1.1

7 months ago

1.1.0

7 months ago

1.0.0

7 months ago