mirror of
https://github.com/jimathy/jim-payments.git
synced 2026-11-26 17:24:45 +00:00
Fix for Player Receiving Cash From Self
When you give someone cash it shows they received money from themself. This show show the sending players name instead.
This commit is contained in:
1 parent
0065af7c9d
commit
95459f63a8
1 file changed
+2
-2
+2
-2
@@ -233,9 +233,9 @@ RegisterServerEvent("jim-payments:server:ATM:give", function(citizen, price)
|
||||
Player.Functions.RemoveMoney('cash', amount)
|
||||
TriggerClientEvent("QBCore:Notify", source, "You gave "..Reciever.PlayerData.charinfo.firstname.." $"..cv(amount), "success")
|
||||
Reciever.Functions.AddMoney('cash', amount)
|
||||
TriggerClientEvent("QBCore:Notify", tonumber(citizen), "You got $"..cv(amount).." from "..Reciever.PlayerData.charinfo.firstname, "success")
|
||||
TriggerClientEvent("QBCore:Notify", tonumber(citizen), "You got $"..cv(amount).." from "..Player.PlayerData.charinfo.firstname, "success")
|
||||
elseif balance < amount then
|
||||
TriggerClientEvent("QBCore:Notify", source, "You don't have enough cash to give", "error")
|
||||
end
|
||||
else TriggerClientEvent('QBCore:Notify', source, "You can't give $0", 'error') end
|
||||
end)
|
||||
end)
|
||||
Reference in new issue
Block a user