Jump to content

Dimos7

Members
  • Posts

    1,546
  • Joined

  • Last visited

Everything posted by Dimos7

  1. Any errors or warnings in /debugscipt 3 Also id system runing?
  2. createColRectangle attachElements setElementAlpha setElementHealth onColShapeHit
  3. addCommandHandler("fix" , function(thePlayer, cmd, target) if not ( isPlayerOnGroup ( thePlayer ) ) then outputChatBox("#ff0000[Error]: #ffffffShoma Dastresi Be In Dastoor Nadarid!", thePlayer, 255, 255, 255, true) return false end if target ~= nil then local yaru = findPlayer (target) or getPlayerFromID(target) --find player if yaru then if isPedInVehicle ( yaru ) then local mashineyaru = getPedOccupiedVehicle(yaru) local esmesh = getPlayerName(yaru) fixVehicle(mashineyaru) outputChatBox("#00ff00[Done]: #ffffffShoma Mashine #00ff00"..esmesh.." #ffffffRa Fix Kardid!", thePlayer, 255, 255, 255, true) outputChatBox("#FFFF00[Info]: #ffffffAdmin #FFFF00".. getPlayerName ( thePlayer ) .." #ffffffMashin Shoma Ra Fix Kard!", yaru, 255, 255, 255, true) else outputChatBox("#ff0000[Error]: #ffffffIn Player Ke Savare Mashin Nist!", thePlayer, 255, 255, 255, true) end else outputChatBox("#ff0000[Error]: #ffffffPlayer Peyda Nashod!", thePlayer, 255, 255, 255, true) end else outputChatBox("#00FF00Bezan : /fix <PartOfName/ID>", thePlayer, 255, 255, 255, true) end end) function findPlayer(name) local name = name and name:gsub("#%x%x%x%x%x%x", "" ):lower() or nil if name then for _, player in pairs(getElementsByType("player")) do local name_=getPlayerName(player):gsub("#%x%x%x%x%x%x", ""):lower() if name_:find(name, 1, true) then return player end end end end function getPlayerID(player) if player then local theID for id, p in pairs(getElementsByType("player")) do if p == player then theID = id end return theID end else return end end function getPlayerFromID(theID) if theID then theID = tonumber(theID) local thePlayer for id, p in pairs(getElementsByType("player")) do if theID == id then thePlayer = p end return thePlayer end else return end end A small miskate my bad
  4. addCommandHandler("fix" , function(thePlayer, cmd, target) if not ( isPlayerOnGroup ( thePlayer ) ) then outputChatBox("#ff0000[Error]: #ffffffShoma Dastresi Be In Dastoor Nadarid!", thePlayer, 255, 255, 255, true) return false end if target ~= nil then local yaru = findPlayer (target) or getPlayerFromID(target) --find player if yaru then if isPedInVehicle ( yaru ) then local mashineyaru = getPedOccupiedVehicle(yaru) local esmesh = getPlayerName(yaru) fixVehicle(mashineyaru) outputChatBox("#00ff00[Done]: #ffffffShoma Mashine #00ff00"..esmesh.." #ffffffRa Fix Kardid!", thePlayer, 255, 255, 255, true) outputChatBox("#FFFF00[Info]: #ffffffAdmin #FFFF00".. getPlayerName ( thePlayer ) .." #ffffffMashin Shoma Ra Fix Kard!", yaru, 255, 255, 255, true) else outputChatBox("#ff0000[Error]: #ffffffIn Player Ke Savare Mashin Nist!", thePlayer, 255, 255, 255, true) end else outputChatBox("#ff0000[Error]: #ffffffPlayer Peyda Nashod!", thePlayer, 255, 255, 255, true) end else outputChatBox("#00FF00Bezan : /fix <PartOfName/ID>", thePlayer, 255, 255, 255, true) end end) function findPlayer(name) local name = name and name:gsub("#%x%x%x%x%x%x", "" ):lower() or nil if name then for _, player in pairs(getElementsByType("player")) do local name_=getPlayerName(player):gsub("#%x%x%x%x%x%x", ""):lower() if name_:find(name, 1, true) then return player end end end end function getPlayerID(player) if player then local theID for id, p in pairs(getElementsByType("player")) do if p == player then theID = id end return theID end else return end end function getPlayerFromID(theID) if theID then tonumber(theID) local thePlayer for id, p in pairs(getElementsByType("player")) do if theID == id then thePlayer = p end return thePlayer end else return end end
  5. function findPlayer(name) local name = name and name:gsub("#%x%x%x%x%x%x", "" ):lower() or nil if name then for _, player in pairs(getElementsByType("player")) do local name_=getPlayerName(player):gsub("#%x%x%x%x%x%x", ""):lower() if name_:find(name, 1, true) then return player end end end end function getPlayerID(player) if player then local theID for id, p in pairs(getElementsByType("player")) do if p == player then theID = id end return theID end else return end end function getPlayerFromID(theID) if theID then tonumber(theID) local thePlayer for id, p in pairs(getElementsByType("player")) do if theID == id then thePlayer = p end return thePlayer end else return end end addCommandHandler("fix", function(thePlayer, cmd, target) if not ( isPlayerOnGroup ( thePlayer ) ) then outputChatBox("#ff0000[Error]: #ffffffShoma Dastresi Be In Dastoor Nadarid!", thePlayer, 255, 255, 255, true) return false end if targ3t ~= nil then local yaru = findPlayer (target) or getPlayerFromID(target) --find player if yaru then if isPedInVehicle ( yaru ) then local mashineyaru = getPedOccupiedVehicle(yaru) local esmesh = getPlayerName(yaru) fixVehicle(mashineyaru) outputChatBox("#00ff00[Done]: #ffffffShoma Mashine #00ff00"..esmesh.." #ffffffRa Fix Kardid!", thePlayer, 255, 255, 255, true) outputChatBox("#FFFF00[Info]: #ffffffAdmin #FFFF00".. getPlayerName ( thePlayer ) .." #ffffffMashin Shoma Ra Fix Kard!", yaru, 255, 255, 255, true) else outputChatBox("#ff0000[Error]: #ffffffIn Player Ke Savare Mashin Nist!", thePlayer, 255, 255, 255, true) end else outputChatBox("#ff0000[Error]: #ffffffPlayer Peyda Nashod!", thePlayer, 255, 255, 255, true) end else outputChatBox("#00FF00Bezan : /fix <PartOfName/ID>", thePlayer, 255, 255, 255, true) end end ) Put that together and try
  6. Show me your code
  7. Yes lisen there you have findPlayer put or getPlayerFromID and that it
  8. Simple do that function findPlayer(name) local name = name and name:gsub("#%x%x%x%x%x%x", "" ):lower() or nil if name then for _, player in pairs(getElementsByType("player")) do local name_=getPlayerName(player):gsub("#%x%x%x%x%x%x", ""):lower() if name_:find(name, 1, true) then return player end end end end function getPlayerID(player) if player then local theID for id, p in pairs(getElementsByType("player")) do if p == player then theID = id end return theID end else return end end function getPlayerFromID(theID) if theID then tonumber(theID) local thePlayer for id, p in pairs(getElementsByType("player")) do if theID == id then thePlayer = p end return thePlayer end else return end end
  9. setElementFrozen
  10. I don't think so
  11. Dimos7

    [Question]

    okay thanks pal
  12. Dimos7

    [Question]

    If make my login panel like this then i dont think use it for user panel
  13. Dimos7

    [Question]

    Hello guys i need make a login panel that be able register on a Web and can login both mta server and Web i know i need remoteCall but what else
  14. also in client side not need player gose to client direct
  15. Then you can't
  16. I Guess you can make a image of a bullet and draw it when a gun fires and make it till gos to ground
  17. Explane more please
  18. Because the server will froze till get answer from database so it better use callbacks
  19. local myMarker = createMarker( -2596.6259765625, 579.3583984375, 15.626741409302, 'cylinder', 2.0, 255, 0, 0, 150 ) local myMarker2 = createMarker( -2596.6259765625, 579.3583984375, 15.626741409302, 'cylinder', 2.0, 255, 0, 0, 150 ) function MarkerHit( hitPlayer, matchingDimension ) if isPedInVehicle(hitPlayer) then local veh =getPedOccupiedVehicle(hitPlayer) setElementPosition ( veh, posX, posY, posZ ) warpPedIntoVehicle(hitPlayer, veh) end end function MarkerHit2( hitPlayer, matchingDimension ) if isPedInVehicle(hitPlayer) then local veh = getPedOccupiedVehicle(hitPlayer) setElementPosition ( veh, posX, posY, posZ ) warpPedIntoVehicle(Hot Player, veh) end end addEventHandler( "onMarkerHit", myMarker, MarkerHit ) addEventHandler( "onMarkerHit", myMarker2, MarkerHit )
  20. What exacly you try to do post message after 30 minutes or command can used after 30 minutes?
  21. We are not here make your codes i suggestion hire someone or find someone do it for you
  22. you can create a new costum event with addEvent()
  23. Dimos7

    Trade

    add the command to Clinet side adn try again
  24. gate = Object(1337,712.61853, 659.00409, 9.94867) addEventHandler('onClientClick',root,function() if isCursorShowing() then local _,_,wx,wy,wz = getCursorPosition() gate:setPosition(wx,wy,wz) end end) Try this
  25. https://wiki.multitheftauto.com/wiki/OnClientFileDownloadComplete
×
×
  • Create New...