LUACN论坛

 找回密码
 加入我们

QQ登录

只需一步,快速开始

搜索
热搜: YJWOW MagicStone BoL
查看: 96|回复: 1

[wowbee] 求大神翻译翻译

[复制链接]
发表于 2022-11-25 23:16:57 | 显示全部楼层 |阅读模式
哪位大神能帮忙翻译翻译!!
function WowBeeHelper_ProjectUpdateName(self,text,icon,del)
        local i;
        if table.getn(self.TextList)<1 then
                --WowBee.Helper=WowBee.Helper or {};
                --WowBee.Helper.List=WowBee.Helper.List or {};
        end
        if(not del)then
                if text and type(text)=="string" and text~="" then
                        for i=1, table.getn(WowBee.Helper.List) do
                                if WowBee.Helper.List[i].Name==text then
                               
                                        --#1 Change Selected Scheme
                                        if(icon)then
                                                if(icon=="Interface\\Icons\\INV_Misc_QuestionMark")then
                                                        icon=nil;
                                                end
                                        WowBee.Helper.List[i].Icon=icon;
                                        end
                                        WowBee.Helper.Current=WowBee.Helper.List[i].Name;
                                        lib.Scheme:Update();
                                        WowBeeHelper_SetStatus(string.format(L["SCHEME_STATUS_CHANGE"],text));
                                        return;
                                end
                        end
                       
                        --#2 Create a Scheme
                        if(icon=="Interface\\Icons\\INV_Misc_QuestionMark")then
                                icon=nil;
                        end
                        table.insert(WowBee.Helper.List,{Name=text,Icon=icon,Items={}});
                        WowBee.Helper.Current=text;
                        lib.Scheme:Update();
                        WowBeeHelper_SetStatus(string.format(L["SCHEME_STATUS_NEW"],text));
                        return;
                elseif text=="" then
                        WowBee.Helper.Current=nil;
                        return;
                end
        end
        --#3 Delete a Scheme
        if text and type(text)=="string" and text~="" then
                for i=1, table.getn(WowBee.Helper.List) do
                        if WowBee.Helper.List[i].Name==text then
                                table.remove(WowBee.Helper.List,i);
                                WowBee.Helper.Current=nil;
                                lib.Scheme:Update();
                                WowBeeHelper_SetStatus(string.format(L["SCHEME_STATUS_DELETE_FINISH"],text));
                                return;
                        end
                end
        end
end

回复

使用道具 举报

发表于 2022-12-5 14:55:49 | 显示全部楼层
大神要累死了,看这么多代码
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 加入我们

本版积分规则

小黑屋|手机版|Archiver|LUACN论坛

GMT+8, 2024-5-4 05:36 AM , Processed in 0.035011 second(s), 15 queries , Gzip On, Redis On.

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表