Merge pull request #486 from BauxiteAl/PR-Branch

让`cardNameLength`可输入字符串牌名直接输出牌名字数
This commit is contained in:
Spmario233 2023-10-08 14:38:25 +08:00 committed by GitHub
commit 381211290b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -56037,7 +56037,7 @@
//Get the card name length //Get the card name length
//获取此牌的字数 //获取此牌的字数
cardNameLength:(card,player)=>{ cardNameLength:(card,player)=>{
const actualCardName=lib.actualCardName,name=get.translation(get.name(card,player)); const actualCardName=lib.actualCardName,name=get.translation(typeof card=='string'?card:get.name(card,player));
return (actualCardName.has(name)?actualCardName.get(name):name).length; return (actualCardName.has(name)?actualCardName.get(name):name).length;
}, },
//Yingbian //Yingbian