Jump to content

Jaysds1

Members
  • Posts

    4,961
  • Joined

  • Last visited

Everything posted by Jaysds1

  1. I think i know what the error was, try this: addEventHandler("onPlayerLogin",root,function(_,acc) if not getAccountData(acc,"gangs")then return end local permission=getAccountData(acc,"permission") if not permissions[permission] then return end triggerClientEvent(source,"ganging",source,permission) outputChatBox("You've joined group ("..getPlayerGangName(source)..") as a ("..permission ..")",source,255,255,0) for _,v in ipairs(getAccounts()) do if not getPlayerGangName(v)then return end local player=getAccountPlayer(v) local accName = getAccountName(v) if player and isElement(player)then triggerClientEvent(source,"recieveingPlayers",source,"online",accName,getPlayerName(player)) else triggerClientEvent(source,"recieveingPlayers",source,"offline",accName) end end for _,v in ipairs(getElementsByType("player")) do if not getPlayerGangName(v)then return end outputChatBox("Memeber "..getPlayerName(source).." has joined the group as a " .. permission,v,0,255,0) triggerClientEvent(v,"memberLoggedIn",v,getAccountName(getPlayerAccount(source)),getPlayerName(source)) end end)
  2. Jaysds1

    Bigger Wheels

    I'm not sure, Are you using any script for the wheels to be bigger?
  3. try this: addEventHandler("onPlayerLogin",root,function(_,acc) if not getAccountData(acc,"gangs")then return end local permission=getAccountData(acc,"permission") if not permissions[permission] then return end triggerClientEvent(source,"ganging",source,permission) outputChatBox("You've joined group ("..getPlayerGangName(source)..") as a ("..permission ..")",source,255,255,0) for _,v in ipairs(getAccounts()) do if not getPlayerGangName(v)then return end local player=getAccountPlayer(v) local accName = getAccountName(getPlayerAccount(player)) if player and isElement(player)then triggerClientEvent(source,"recieveingPlayers",source,"online",accName,getPlayerName(player)) else triggerClientEvent(source,"recieveingPlayers",source,"offline",accName) end end for _,v in ipairs(getElementsByType("player")) do if not getPlayerGangName(v)then return end outputChatBox("Memeber "..getPlayerName(source).." has joined the group as a " .. permission,v,0,255,0) triggerClientEvent(v,"memberLoggedIn",v,getAccountName(getPlayerAccount(source)),getPlayerName(source)) end end)
  4. What I think you're trying to do, is when a player logs in, you want to tell his gang that he is now online. addEventHandler("onPlayerJoin",root,function() for _,v in ipairs(getElementsByType("player")) do if getPlayerGangName(v) then --btw make sure that this function is before this script outputChatBox("Memeber "..getPlayerName(source).." has joined the gang as a " .. permission,v,0,255,0) --permission isn't defined triggerClientEvent(source,"memberLoggedIn",source,getAccountName(getPlayerAccount(source)),getPlayerName(source)) end end end) If this is wrong please show us your full code or you could pm me your full code.
  5. Jaysds1

    FTP help

    000webhost.com is a website hosting service, so you can't start a server on it, even if you wanted to. You would need to find a server hosting service. Check this page: http://www.multitheftauto.com/hosters
  6. try this: local object = createObject ( 1337, 5540.6654, 1020.55122, 1240.545, 90, 0, 0 ) --creates an object setElementVelocity(object,1000,0,0) --sets the speed of the object 1000 going north --For onClientRender addEventHandler("onClientRender",root,function() local x,y,z = getElementVelocity(object) --if the object isn't moving then the x,y,z would be zero outputChatBox(x.. "," ..y..","..z) --Outputs the x,y,z speed of the object end) --timer setTimer(function() local x,y,z = getElementVelocity(object) --if the object isn't moving then the x,y,z would be zero outputChatBox(x.. "," ..y..","..z) --Outputs the x,y,z speed of the object end,1000,7) BTW, the setElementVelocity is only client-side only.
  7. Check out the events on the race resource page: https://wiki.multitheftauto.com/wiki/Resource:Race
  8. Jaysds1

    FTP help

    nah, I don't mean the whole gta game and mtasa... I mean the "server" folder located in your "MTA San Andreas 1.x" folder. BTW, Who is your ftp hosted with? You can't start a server on a web server.
  9. If you want to add a resource to your server, you would need to place the resource in this folder: "MTA San Andreas 1.x\server\mods\deathmatch\resources\". After, if your server is started then type in "refreshall", then type in "start resourceName" (the "resourceName" is the resource/folder name that you put into the "resources" folder"). If you have not started your server then start it and just type in "start resourceName". Read more about: Console Commands here: https://wiki.multitheftauto.com/wiki/Element/Console Resources here: Resources
  10. try reinstalling MTA, because the MTADiag shows that MTA couldn't find your GTA game.
  11. Jaysds1

    FTP help

    hmmm, You should be uploading the server folder to your ftp. It should be located here: "C:\Program Files\MTA San Andreas 1.x\".
  12. You could only get their username from a database but you can't get their password.
  13. Did you know it's now available for iOS? http://media.rockstargames.com/broadcas ... S_web.html http://www.rockstargames.com/videos/video/10391
  14. here, try this: client-side: voice = false disabled = true one = false tab1 = false tab2 = false addCommandHandler("voice",function() voice = not voice end) addEventHandler("onClientPlayerWasted",localPlayer, function() voice = false end) addEventHandler("onClientRender",root, function() local width,height = guiGetScreenSize() if voice then dxDrawText("Radio Machine ",1,(height/2)-80,width,height,tocolor(255,255,255,255),0.6,"bankgothic" ) if isPedInVehicle(localPlayer) then return end tab1 = true dxDrawRectangle(0,(height/2)-80,220,200,tocolor(0,0,0,70)) if not disabled then dxDrawText("(1) Roger",1,(height/2)-60,width,height,tocolor(100,150,240,255),0.6,"bankgothic" ) one = true else dxDrawText("(1) Roger",1,(height/2)-60,width,height,tocolor(100,100,100,255),0.6,"bankgothic" ) one = false end end end) function enableAll() disabled = false end function disableAll() disabled = true setTimer(enableAll, 5000, 1) end bindKey("1", "down",function() if voice then if one then local x, y, z = getElementPosition(localPlayer) if tab1 then triggerServerEvent("sendSound",localPlayer,1.1,x,y,z)--sendSound("1.1", x, y, z) end end disableAll() end end) addEvent("receiveSound",true) addEventHandler("receiveSound",root,function(sPath,sLoop) playSound(sPath,sLoop) end) server-side: addEvent("sendSound",true) addEventHandler("sendSound",root,function(sound, nX, nY, nZ) for i,_ in ipairs(getElementsByType("player"))do local pX, pY, pZ = getElementPosition(i) local dist = getDistanceBetweenPoints3D(pX, pY, pZ, nX, nY, nZ) if dist < 40 then if sound == "1.1" then triggerClientEvent("receiveSound","sounds/roger.mp3", false) end end end end)
  15. try this: voice = false disabled = true one = false tab1 = false tab2 = false addCommandHandler("voice",function() voice = not voice end) addEventHandler("onClientPlayerWasted",localPlayer, function() voice = false end) addEventHandler("onClientRender",root, function() local width,height = guiGetScreenSize() if voice then dxDrawText("Radio Machine ",1,(height/2)-80,width,height,tocolor(255,255,255,255),0.6,"bankgothic" ) if isPedInVehicle(localPlayer) then return end tab1 = true dxDrawRectangle(0,(height/2)-80,220,200,tocolor(0,0,0,70)) if not disabled then dxDrawText("(1) Roger",1,(height/2)-60,width,height,tocolor(100,150,240,255),0.6,"bankgothic" ) one = true else dxDrawText("(1) Roger",1,(height/2)-60,width,height,tocolor(100,100,100,255),0.6,"bankgothic" ) one = false end end end) function enableAll() disabled = false end function disableAll() disabled = true setTimer(enableAll, 5000, 1) end bindKey("1", "down",function() if voice then if one then local x, y, z = getElementPosition(localPlayer) if tab1 then sendSound("1.1", x, y, z) end end disableAll() end end) function sendSound (sound, nX, nY, nZ) local pX, pY, pZ = getElementPosition(getLocalPlayer()) local dist = getDistanceBetweenPoints3D(pX, pY, pZ, nX, nY, nZ) if dist < 40 then if sound == "1.1" then playSound("sounds/roger.mp3", false) end end end
  16. try this: voice = false addCommandHandler("voice", function() voice = not voice end) addEventHandler("onClientPlayerWasted", getLocalPlayer(), function() voice = false end) local width,height = guiGetScreenSize() addEventHandler("onClientRender", getRootElement(), function() if voice then tab1 = nil tab2 = nil dxDrawText("Radio Machine ",1,(height/2)-80,width,height,tocolor(255,255,255,255),0.6,"bankgothic" ) if not isPedInVehicle(getLocalPlayer()) then tab1 = 1 dxDrawRectangle(0,(height/2)-80,220,200,tocolor(0,0,0,70)) if not disabled then dxDrawText("(1) Roger",1,(height/2)-60,width,height,tocolor(100,150,240,255),0.6,"bankgothic" ) one = true else dxDrawText("(1) Roger",1,(height/2)-60,width,height,tocolor(100,100,100,255),0.6,"bankgothic" ) one = false end end end end) function disableAll() disabled = true setTimer(enableAll, 5000, 1) end function enableAll() disabled = false end function pressed1() if voice then if one == true then if tab1 then local x, y, z = getElementPosition(getLocalPlayer()) triggerEvent("sendSound", getLocalPlayer(), "1.1", x, y, z) end end disableAll() end end bindKey("1", "down", pressed1) function sendSound (sound, nX, nY, nZ) local pX, pY, pZ = getElementPosition(getLocalPlayer()) local dist = getDistanceBetweenPoints3D(pX, pY, pZ, nX, nY, nZ) if dist < 40 then if sound == "1.1" then playSound("sounds/roger.mp3", false) end end end addEventHandler("sendSound", getRootElement(), sendSound) addEvent("sendSound", true)
  17. Jaysds1

    Server dissapeared?

    Welcome back to MTA, Can you run this MTADiag, then post the pastebin url here please.
  18. Have you tried reinstalling GTA and MTA?
  19. Yes, there's a way to remove every single thing on the SA Map: viewtopic.php?f=15&t=43425&hilit=+removeWorldModel
  20. Jaysds1

    disconnected

    np, I'll try asking more about packets with the mta team in the irc for you.
  21. Jaysds1

    disconnected

    I don't know anything about packets, but it might be because of your ping...
  22. Actually, if you didn't upgrade then you can't use it for any external services. Only the local site could use it.
×
×
  • Create New...