You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

parseSkill.js 602 B

12345678910111213141516171819202122
  1. const Card = require('./parseCard');
  2. //分析卡片的函数,Code From https://github.com/kiootic/pad-rikuu
  3. class Skill{
  4. constructor(i,data){
  5. let skill = this;
  6. skill.id = i;
  7. skill.name = data[0];
  8. skill.description = data[1];
  9. skill.type = data[2];
  10. skill.maxLevel = data[3];
  11. skill.initialCooldown = data[4];
  12. skill.unk = data[5];
  13. skill.params = data.slice(6);
  14. switch(skill.type) {
  15. case 202: case 236: {
  16. skill.params = skill.params.map(Card.fixId);
  17. }
  18. }
  19. }
  20. }
  21. //对于Nodejs输出成模块
  22. if (typeof(module) != "undefined") module.exports = Skill;