很多博客都有live2D的萌萌哒看板娘,手痒,所以整理了一套HTML5可以用的,注释换一下就可以用啦,最好是放到线上服务器上使用。
L2Dwidget.init({
"model": {
//萌娘
jsonPath: "model/live2d-shizuku/assets/shizuku.model.json",
//短发女生
//jsonPath: "model/live2d-epsilon2_1/assets/Epsilon2.1.model.json",
//双马尾女仆
// jsonPath: "model/live2d-haru_1/assets/haru01.model.json",
//双马尾学生装
// jsonPath: "model/live2d-haru_2/assets/haru02.model.json",
//小可爱(男)
// jsonPath: "model/live2d-haruto/assets/haruto.model.json",
//小可爱(女)
// jsonPath: "model/live2d-koharu/assets/koharu.model.json",
//傲娇学生装女
// jsonPath: "model/live2d-hibiki/assets/hibiki.model.json",
//红衣长发女生
// jsonPath: "model/live2d-izumi/assets/izumi.model.json",
//黄发制服可爱女生
// jsonPath: "model/live2d-z16/assets/z16.model.json",
//黄发女生
// jsonPath: "model/live2d-unitychan/assets/unitychan.model.json",
//可爱白猫
// jsonPath: "model/live2d-tororo/assets/tororo.model.json",
//可爱黑猫
// jsonPath: "model/live2d-hijiki/assets/hijiki.model.json",
//初音未来
// jsonPath: "model/live2d-miku/assets/miku.model.json",
//小帅哥
//jsonPath: "model/live2d-chitose/assets/chitose.model.json",
//持剑绿衣剑士
// jsonPath: "model/live2d-gf/assets/Gantzert_Felixander.model.json",
//科技感短发小女孩
// jsonPath: "model/live2d-ni-j/assets/ni-j.model.json",
//狐妖
// jsonPath: "model/live2d-nico/assets/nico.model.json",
//绿发女生
// jsonPath: "model/live2d-tsumiki/assets/tsumiki.model.json",
"scale": 1
},
"display": {
"superSample": 2,
"position": "top",
"width": 150,
"height": 300,
"hOffset": 0,
"vOffset": 0
},
"mobile": {
"show": true,
"scale": 0.5
},
"react": {
"opacityDefault": 0.7,
"opacityOnHover": 0.2
}
});
1