Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.

Wysłany: 2021-12-26, 16:41


m4rvelka







Wiek: 26
Na forum: 1676 dni
Posty: 1
Nick w MP: m4rvelka

Piwa: 1

Respekt: 50

Gdy pr?buj? wyp?aci? wyskakuj? b??d



Kod:

local pension = { --za 1 minute
["SAPD"] = {
[1] = 1175,
[2] = 1200,
[3] = 1225,
[4] = 1250,
[5] = 1300,
[6] = 1325,
[7] = 1350,
[8] = 1400,
[9] = 1425,
[10] = 1450,
[11] = 1500,
},
["SAFD"] = {
[1] = 1175,
[2] = 1200,
[3] = 1225,
[4] = 1250,
[5] = 1300,
[6] = 1325,
[7] = 1350,
[8] = 1400,
[9] = 1425,
[10] = 1450,
[11] = 1500,
},
["SARA"] = {
[1] = 1175,
[2] = 1200,
[3] = 1225,
[4] = 1250,
[5] = 1300,
[6] = 1325,
[7] = 1350,
[8] = 1400,
[9] = 1425,
[10] = 1450,
[11] = 1500,
},
}

local markersFactionPayment={
{-1867.68, 812.64, 35.17,0,0},
}

for i,v in ipairs(markersFactionPayment) do
local marker=createMarker(v[1], v[2], v[3]-1, "cylinder", 2, 0, 144, 255,255)
setElementInterior(marker, v[4])
setElementDimension(marker, v[5])
setElementData(marker,"marker:text","frakcje")
setElementData(marker,"marker:downtext","Odbieranie pensji")
end

addEventHandler("onMarkerHit", resourceRoot, function(el,md)
if not md or getElementType(el) ~= "player" then return end
local uid=getElementData(el,"player:uid")
if not uid then return end
local result=exports["dmta_db"]:dbGet("SELECT * FROM dmta_factions WHERE uid=? LIMIT 1;", uid)
if result and #result > 0 then
local resulted=exports["dmta_db"]:dbGet("SELECT * FROM dmta_factions WHERE faction=?", faction)
local uid = getElementData(el,"player:uid")
if #result > 0 then
if pension[result[1].faction] then
if getElementData(el,"player:workinjob") and getElementData(el,"player:workinjob") >= 1 then
local money = (pension[result[1].faction][result[1].rank] * getElementData(el,"player:workinjob"))
local money = math.floor(money*60)
exports.dmta_interface:showPlayerNotification(el, "Otrzymujesz "..money.." $ (Przepracowane: "..getElementData(el,"player:workinjob").." Minut)", "success")
givePlayerMoney(el,money)
setElementData(el,"player:workinjob",0)
else
exports.dmta_interface:showPlayerNotification(el, "Nie masz nic do odebrania!", "error")
end
end
end
end
end)




Postaw piwo autorowi tego posta
 

 
Więcej szczegółów
Wystawiono 1 piw(a):
Erczi
Wysłany: 2021-12-26, 16:44


Erczi







Wiek: 27
Na forum: 2371 dni
Posty: 17
Nick w MP: ewwe

Piwa: 4

Respekt: 50

Bump

Postaw piwo autorowi tego posta
 

 
Więcej szczegółów
Wystawiono 1 piw(a):
m4rvelka
Wysłany: 2021-12-26, 19:57


Matikmontana

Modern Stories






Wiek: 22
Na forum: 2473 dni
Posty: 423
Nick w MP: Mazeusz*

Piwa: 1015

Respekt: 130
Respekt: 130

Ostrzeżeń: 60%
Kt?ra to jest linijka z b??du?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2021-12-26, 22:31


Erczi







Wiek: 27
Na forum: 2371 dni
Posty: 17
Nick w MP: ewwe

Piwa: 4

Respekt: 50

"Matikmontana" napisał/a:

Kt?ra to jest linijka z b??du?
linijka 66

Postaw piwo autorowi tego posta
 

 
Wysłany: 2021-12-27, 22:06


NorbiTTT

Nbi#1824






Wiek: 27
Na forum: 3207 dni
Posty: 193
Nick w MP: Nbi

Piwa: 698

Respekt: 60

"Erczi" napisał/a:

"Matikmontana" napisał/a:

Kt?ra to jest linijka z b??du?
linijka 66

wklej te linijke...

Postaw piwo autorowi tego posta
 

 
Tagi: wypłata :: frakcyjna
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA Odpowiedz do tematu

Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach
Dodaj temat do Ulubionych
Wersja do druku