-
Posts
277 -
Joined
-
Last visited
Posts posted by DiGiTal
-
-
4 minutes ago, djharbi2 said:
I'm counting down. sample
10:00
09:59
09:58
.....explaine what u searching?
-
Hi, as i can't install mtasa. i search for a person who can help me by testing my scripts, nothing needed to know about programming, just test my script, if help needed i'll help about setup ur local server. 20% of profit will get it IF my script has been bought by someone
- 1
- 1
-
@djharbi2 explaine more?
-
-
local Window = CustomWindow.create(50, 50, 200, 200, "") Window:setTitle("Hello World")
for to use setTitle func, did i don't need to export ? like
cs=exports.nameOfRessource
then cs:createWindow?
-
2 hours ago, Mσнαмα∂ Hєℓιѕн said:
@N3xT@DiGiTal@Galactix
please don't mentione me
-
I think you should use the texture .txd files
-
DESIGN lessons has been started , with this courses you will be able to create your logos,banners , AND MORE !!
+
LUA: DATA BASE LESSON ADDED
SITE : http://tutoplayfun.ml/
- 1
-
3 minutes ago, Juuve said:
script code:
sometable = {1, 2, 3} toJSON(sometable) -- OR toJSON({1, 2, 3})
in database (with toJSON)
[[1, 2, 3]]
it gives additional box brackets
what i writte in SQL ?
in database (with toJSON)
this is the result in my db you mean?
-
14 minutes ago, TheMOG said:
Yes, you correct. With JSON.
an example ??
-
i have also added a command for to know, the name,id and positions of the car by /vehs
---- STARTS ---- Veh={} function veh(plr,cmd,modelid) local accName = getAccountName ( getPlayerAccount ( plr ) ) -- get his account name if not isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then return outputChatBox("you are not a admin to use this comand",plr) end elseif isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then x,y,z=getElementPosition(plr) x=x+5 local id=tonumber(vehicleModel) car=createVehicle(id,x,y,z) if car then setElementData(car,"Id",id) setElementData(car,"Name",getVehicleNameFromModel(id)) setElementData(car,"x",x) setElementData(car,"y",y) setElementData(car,"z",z) outputChatBox("vehicule id"..modelid.."has been created",plr) end end addCommandHandler("veh",veh) function destroy(plr,cmd) local accName = getAccountName ( getPlayerAccount ( plr ) ) -- get his account name if not isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then return outputChatBox("you are not a admin to use this comand",plr) end elseif isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then occupe=getPedOccupiedVehicle(plr) if occupe then destroyElement(occupe) end end addCommandHandler("destroy",destroy) function destroyall(plr,cmd) x1,y2,z3=getElementPosition(getElementsByType("vehicle")) for k,v in pairs(getElementPosition(getElementsByType("vehicle"))) do if x1== getElementData(car,"x") and y2==getElementData(car,"y") and z3==getElementData(car,"z") then destroy(car) else outputChatBox("error",plr) end end end addCommandHandler("destroyall",destroyall) function vehs(plr,cmd) outputChatBox(getElementData(getElementsByType("vehicle"),"Id"),plr) outputChatBox(getElementData(getElementsByType("vehicle"),"Name"),plr) outputChatBox(getElementData(getElementsByType("vehicle"),"x"),plr) outputChatBox(getElementData(getElementsByType("vehicle"),"y"),plr) outputChatBox(getElementData(getElementsByType("vehicle"),"z"),plr) end addCommandHandler("vehs",vehs)
-
How can i create a row with many data in it(like in items) i think it should be with JSON
-
function jetpack( thePlayer ) if doesPedHaveJetPack ( thePlayer ) then -- If the player have a jetpack already, remove it removePedJetPack ( thePlayer ) -- Remove the jetpack return -- And stop the function here end -- Otherwise, give him one if he has access local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) -- get his account name if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then -- Does he have access to Admin functions? if not doesPedHaveJetPack ( thePlayer ) then -- If the player doesn't have a jetpack give it. givePedJetPack ( thePlayer ) -- Give the jetpack end end end bindKey ( thePlayer, "j", "down", jetpack)
-
function fix(plr,cmd) local accName = getAccountName ( getPlayerAccount ( plr ) ) -- get his account name if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then local vehicles = getElementsByType("vehicle") for k, v in pairs(vehicles) do -- Fix the vehicle fixVehicle(vehicle) outputChatBox( "ADMIN-ALL CARS HAS BEEN FIXED") else outputChatBox( "You dont have access to this command",plr) end end end addCommandHandler( "fixall", fix)
-
you wanna the car blow or just show 5~0 without spam ?
addEventHandler( "onClientVehicleCollision", root, function () playerVehicle = getPedOccupiedVehicle ( localPlayer ) local health = getElementHealth( playerVehicle )/10 if health < 25 then countdownRec(5) end end) function countdownRec(count) while count>=0 do outputChatBox(count) count = count - 1 if (count==0) then blowVehicle(playerVehicle) break end end end
-
I can create one for you only if it's paid, pm me
-
addEventHandler( "onClientVehicleCollision", root, function () local playerVehicle = getPedOccupiedVehicle ( localPlayer ) local health = getElementHealth( playerVehicle )/10 if health < 25 then countdownRec(5) end end) function countdownRec(count) while count>=0 do outputChatBox(count) count = count - 1 if (count==0) then break end end end
-
addEventHandler( "onClientVehicleCollision", root, function () local playerVehicle = getPedOccupiedVehicle ( localPlayer ) local health = getElementHealth( playerVehicle )/10 if health < 25 then countdownRec(5) end end) function countdownRec(count) while count>=0 do outputChatBox(count) count = count - 1 end end
-
@GrubaS can u explaine more ? after 5s it output somthing ?
-
Nope, All those account are our students helped by us and keep learning, they just gives to us a feedBacks !
Our Discord can proove you the contrary !
-
7 hours ago, Behnam said:
Do you have discord ?
-
ids={} function joiner(plr) for i=1,getMaxPlayers() do if not ids[i] then ids[i] = source setElementData(source,"id",i) break end end end addEventHandler("onPlayerJoin",root,joiner) function id() for k, v in ipairs(getElementsByType("player")) do local MyID = getElementData(v,"id") if true then setPlayerName(v,"[..MyID..]..getPlayerName(v)) end end end end addEventHandler("onPlayerJoin",root,id)
-
-
no,
- Our Website : https://tutoplayfun.ml/
- Our Discord: https://discord.gg/BxkW65z
[HELP] countdown
in Scripting
Posted
?