Hàm Add Xu tùy chỉnh.

Admin

Administrator
Reg
28 Thg 10 2024
Bài viết
386
Điểm t.tác
8
Điểm
18
Hàm Add Xu tùy chỉnh. Nhập bao nhiêu nhận bấy nhiêu

Code:
-- Add Xu
function GMSYS:AddXu2GM()
    local zAccount = GetAccount();
    if GMSYS.ActivateGM[zAccount] then
        GMSYS:_CallUiAskNum("Nhập số Xu",GMSYS.AddTienDong2GM,9999);
    else
        Msg2Player("Bạn không phải GM.")
    end
end

function GMSYS:AddTienDong2GM(nCashInput)
    if nCashInput then
                --AddItemID(nCashInput)
        for i=1,nCashInput do AddItemID(4,417) end
        GMSYS:Log("dulieu/GM_GETXU.txt",format("%s\t%s\t%s\t%d\t%d\tNhận "..nCashInput.." Xu bởi chức năng GM.",GetLocalDate("%m/%d/%Y_%H:%M:%S"),GetAccount(),GetName(),GetLevel(),GetLastFactionNumber()));
    else
        Msg2Player("<color=pink>Vui lòng nhập số Xu cần lấy!")
        return GMSYS:AddXu2GM();
    end
end
 
Bên trên
AdBlock Detected

We get it, advertisements are annoying!

Sure, ad-blocking software does a great job at blocking ads, but it also blocks useful features of our website. For the best site experience please disable your AdBlocker.

I've Disabled AdBlock    No Thanks