• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Lua Action freepoints

Real Vandta

Member
Joined
Jun 16, 2020
Messages
56
Solutions
1
Reaction score
11
Location
Egypt
Hello i want script lua click items give you 200 point in tfs 0.4 rev 3777


Thank you!
 
givepoints.lua

Lua:
function onUse(cid, item, fromPosition, itemEx, toPosition)
local points = 200
    db.executeQuery("UPDATE `accounts` SET `premium_points` = `premium_points` + "..points.." WHERE `id` = '" ..getPlayerAccountId(cid).. "';")
    doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, ""..points.." added successfully.")
    doRemoveItem(item.uid, 1)
return true
end

in actions.xml

XML:
<action uniqueid="15150" script="givepoints.lua"/>
 
Back
Top