serek123
Lua, MySql, Sql
Wiek: 27 Na forum: 4334 dni Posty: 217
Nick w MP: Serek.
Piwa : 374
Witam.
Chcia?bym aby kto? mi pom?g? z tym kodem bo po wyj?ciu z pojazdu w trakcie zdawania on nie znika i tak samo z markerami mo?na zdawa? prawo jazdy biegn?c
S
function getpos ( source )
local x , y , z = getElementPosition ( source )
outputChatBox ( "" .. x .. ", " .. y .. ", " .. z .. "" , source , 255 , 255 , 255 )
end
addCommandHandler ( "pozycja" , getpos )
function sethpnpc ()
end
setTimer ( sethpnpc , 1000 , 0 )
local marker = createMarker ( - 2033.4337158203 , - 117.67643737793 , 1034.171875 , "cylinder" , 2.0 , 255 , 0 , 0 )
setElementInterior ( marker , 3 )
function onhit ( source )
outputChatBox ( "Aby zacz?? kurs prawa jazdy wpisz /kurs" , source , 255 , 255 , 255 )
end
addEventHandler ( "onMarkerHit" , marker , onhit )
function kurs ( source )
if isElementWithinMarker ( source , marker )
then
local konto = getPlayerAccount ( source )
if not getAccountData ( konto , "prawojazdy" ) then
setElementInterior ( source , 0 )
auto = createVehicle ( 589 , - 2019.9250488281 , 457.44064331055 , 34.876052856445 , 0 , 0 , 270 )
setVehicleColor ( auto , 1 )
warpPlayerIntoVehicle ( source , auto )
-- local instruktor2 = createPed ( 57 , 0 , 0 , 0 )
-- warpPlayerIntoVehicle ( instruktor2 , auto , 1 )
triggerClientEvent ( "zdajemyprawkotrolololo" , source )
else
outputChatBox ( "Masz ju? prawo jazdy." , source , 255 , 255 , 255 )
end
end
end
addCommandHandler ( "kurs" , kurs )
function zdal ()
local nick = getPlayerName ( source )
konto = getPlayerAccount ( source )
setAccountData ( konto , "prawojazdy" , true )
end
addEvent ( "prawko.zdal" , true )
addEventHandler ( "prawko.zdal" , root , zdal )
function oblal ()
local nick = getPlayerName ( source )
end
addEvent ( "prawko.oblal" , true )
addEventHandler ( "prawko.oblal" , root , oblal )
function zabierzauto ( )
local auto = getPedOccupiedVehicle ( source )
destroyElement ( auto )
end
addEvent ( "prawkoautosadasdas" , true )
addEventHandler ( "prawkoautosadasdas" , root , zabierzauto )
function sadasdsa ( source )
konto = getPlayerAccount ( source )
setAccountData ( konto , "prawojazdy" , false )
end
addCommandHandler ( "sadsavfd343" , sadasdsa )
Ostatnio zmieniony przez MeeShuffle 2015-02-27, 07:04, w całości zmieniany 1 raz