Limelight Forums
Need some code. [LUA] - Printable Version

+- Limelight Forums (https://limelightgaming.net/forums)
+-- Forum: Entertainment (https://limelightgaming.net/forums/forum-197.html)
+--- Forum: Off-Topic (https://limelightgaming.net/forums/forum-208.html)
+--- Thread: Need some code. [LUA] (/thread-9728.html)



Need some code. [LUA] - Arch.B - May 2, 2016

Hay,
I need LUA code to take 10k from a player. 
Or just a hook,
Or just a console command,

Thanks xx


RE: Need some code. [LUA] - Soviethooves - May 2, 2016

/mug 10k


RE: Need some code. [LUA] - Vaq - May 2, 2016

Code:
cider.command.add("takemoney", "a", 2, function(player, arguments)
    local target = cider.player.get( arguments[1] )
    local takeamount = cider.player.giveMoney(target, -arguments[2] )
        if (target) then
        cider.player.printMessageAll(player:Name().." took "..formatMoney(arguments[2]).." from "..target:Name()..".");
        cider.player.notify(player, "You took "..formatMoney(arguments[2]).." from player "..target:Name().."!", 0);
        cider.player.notify(target, ""..player:Name().." removed "..formatMoney(arguments[2]).." from your wallet!", 0);
        cider.player.giveMoney(target, takeamount);
    end;
end, "Admin Commands", "<player> <amount>", "Take money from a player.");
for cider


RE: Need some code. [LUA] - bimkx - May 2, 2016

context?
what gamemode


RE: Need some code. [LUA] - Arch.B - May 2, 2016

Darkrp,
DButton to take the dosh


RE: Need some code. [LUA] - Arch.B - May 2, 2016

(May 2, 2016, 02:41 AM)Soviethooves Wrote: /mug 10k

That don't work. /advert mug 10k

C'mom m8


RE: Need some code. [LUA] - bimkx - May 3, 2016

Assuming you're using ULX,
https://forums.ulyssesmod.net/index.php/topic,7871
Gotta sign up to ULX forum to get the DL link then install/execute the code to add command.