feat: get skillname from character
This commit is contained in:
parent
3c94f9c1c6
commit
28f41fcc49
1 changed files with 14 additions and 0 deletions
|
@ -15,4 +15,18 @@ function CharacterData:getResistences()
|
|||
return self.data.resists
|
||||
end
|
||||
|
||||
function CharacterData:getSkillName(skill)
|
||||
local skilldata = core.datas:get("skills", skill)
|
||||
local name = skilldata.fullname
|
||||
|
||||
|
||||
if (skilldata.altName ~= nil) then
|
||||
if (skilldata.altName[self.simplename] ~= nil) then
|
||||
name = skilldata.altName[self.simplename]
|
||||
end
|
||||
end
|
||||
print(name)
|
||||
return name
|
||||
end
|
||||
|
||||
return CharacterData
|
||||
|
|
Loading…
Reference in a new issue