Jump to content

X-SHADOW

Members
  • Posts

    721
  • Joined

  • Last visited

Everything posted by X-SHADOW

  1. for fixing this code if ( guiGridListGetSelectedItem( guiElement2 ) == guiElement, guiElement5 ) and ( guiGridListGetSelectedItem( guiElement2 ) == guiElement, guiElement6 ) then use the code i post
  2. Congratulations then must the mta function be updated in wiki page lol . Thank's For Jaysds1 For Fix the problem
  3. can you pm me the full script ?
  4. i dont get what you mean you want if you type /sell every player can buy? and when you type / buy every player can sell ?
  5. Jaysds1 takePlayerMoney won't Work ClientSide
  6. function buy() local x,y,z = getElementPosition(source) local colshape1 = createColSphere(x-3,y+3,z-4,10) local players = getElementsWithinColShape ( colshape1, "player" ) for i,seller in ipairs(players) do if getElementData(seller, "SellingArms") == true then if isElementWithinMarker(source, thearmsmark[seller]) then setElementData(source,"BuyingArmsFrom", getPlayerName(seller)) triggerClientEvent("showarmspanelARMS", source) destroyElement(colshape1) end end end end
  7. There was error here i fixed it try it now local marker = createMarker( 1552.4996337891, -1677.3264160156, 15.1953125, "Cylinder", 1.5, 0, 0, 255, 150) GUIEditor_Button = {} GUIEditor_Memo = {} GUIEditor_Label = {} function guiMyCwindow(w,h,t) local x,y = guiGetScreenSize() return guiCreateWindow((x-w)/2,(y-h)/2,w,h,t,false) end windowjob = guiMyCwindow(301,250,"SAPD agent") guiSetVisible(windowjob, false) GUIEditor_Button[1] = guiCreateButton(22,200,108,35,"Take job",false,windowjob) GUIEditor_Label[1] = guiCreateLabel(193,-103,5,5,"",false,windowjob) GUIEditor_Button[2] = guiCreateButton(179,200,110,36,"Cancel",false,windowjob) GUIEditor_Memo[1] = guiCreateMemo(19,33,273,100,"To take SAPD job, press Take job.\n\nIf you don't want to, press Cancel.",false,windowjob) guiEditSetReadOnly(GUIEditor_Memo[1],true) function SAPDjob(hitElement) if getElementType(hitElement) == "player" and (hitElement == localPlayer) then if not guiGetVisible(windowjob) then guiSetVisible(windowjob, true) showCursor(true) end end end addEventHandler("onClientMarkerHit", marker, SAPDjob) function FBIjobleave(leaveElement) if getElementType(leaveElement) == "player" and (leaveElement == localPlayer) then if guiGetVisible(windowjob) then guiSetVisible(windowjob, false) showCursor(false) end end end addEventHandler("onClientMarkerLeave", marker, SAPDjobleave) function joinTeam() triggerServerEvent("setSAPD",localPlayer) guiSetVisible(windowjob, false) showCursor(false) end addEventHandler("onClientGUIClick", GUIEditor_Button[1] , joinTeam, false) function removeSAPDWindow() guiSetVisible(windowjob, false) showCursor(false) end addEventHandler("onClientGUIClick", GUIEditor_Button[2] , removeSAPDWindow, false) -------- addEventHandler("onClientPlayerDamage", localPlayer, function(attacker, weapon, bodypart, loss) team = getPlayerTeam(attacker) if (attacker and getElementType(attacker) == "player" and weapon == 3 and team and getTeamName(team) == "SAPD") then -- Checks if the player is using spray and is into Medic team cancelEvent() -- Cancels the damage cause by the spray if (not isTimer(pause)) then triggerServerEvent("police:arrest", localPlayer, attacker) -- Calls the Server Event pause = setTimer(function() end, 1000, 1) -- Makes a timer for the function so it won't fully heal in the first time end end end)
  8. yes takePlayerMoney is serverSide to work it wont work clientSide Use my script if you press button 1 then take 5000 and do your work ..
  9. show the full code to help you
  10. there is automatic translations i think by php call remote google transslator .
  11. i have this script you want it ?
  12. i think its means when you enter the server and download the files gamemode starts but the gamemode files wont be save in your pc
  13. Why you use Client insted of source ?
  14. X-SHADOW

    GUI Help

    Ok Thank's Man for This
  15. Client-Side local Marker = createMarker ( 1007.4000244141, -2302.6999511719, 12.10000038147, "cylinder", 1.29999995, 255, 0, 0, 255 ) addEventHandler('onClientMarkerHit', Marker,function(hitPlayer) if (hitPlayer == localPlayer) then guiSetVisible(GUIEditor_Window[1], true) showCursor(true) end end) function CreateGUIWindow() GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Memo = {} GUIEditor_Image = {} GUIEditor_Window[1] = guiCreateWindow(502,268,480,290,"Buy Ticket",false) GUIEditor_Image[1] = guiCreateStaticImage(240,20,229,261,"images/space.png",false,GUIEditor_Window[1]) GUIEditor_Button[1] = guiCreateButton(9,251,91,30,"Buy Ticket",false,GUIEditor_Window[1]) GUIEditor_Button[2] = guiCreateButton(155,251,69,30,"Exit",false,GUIEditor_Window[1]) GUIEditor_Memo[1] = guiCreateMemo(15,20,219,221,"=====|MoonTrip|=====\nWelcome to the\" MoonTrip\", the moon trip is wonderful trip full of mystery stuff and nice gravitation,You'll find the absolute fun but try to find fun enough \nbecause time is only 10 minutes you will find above signs should find it in different areas, each one under 5k have a nice time\n====|Ticket|====\nMoon 50,000$=====|MoonTrip|====",false,GUIEditor_Window[1]) guiSetVisible(GUIEditor_Window[1], false) addEventHandler("onClientResourceStart", getRootElement(), CreateGUIWindow) addEventHandler('onClientMarkerHit', Marker,function() if ( source == GUIEditor_Button[1] ) then triggerServerEvent('SetM', localPlayer) elseif ( source == GUIEditor_Button[2]) then guiSetVisible(GUIEditor_Window[1],false) guiSetInputEnabled(false) showCursor(false) end end) end Server-Side addEvent('setM', true) addEventHandler('SetM', root, function() takePlayerMoney(source, 5000) end)
  16. Note: Using this function client side (not recommended) will not change a players money server side.
  17. if you want gui dont disappear then remove guisetVisble form line 56 and 57.
  18. X-SHADOW

    GUI Help

    For example like this? function example () button = guiCreateButton ( 10,4,3) (if source == button ) then triggerServerEvent( 'blablabla', localPlayer) addEventHandler("onClientGUIClick",button,example,false) end
  19. lol Nice script its so easy to Make Rate 5/5
  20. you want if press button 5 hide gui and move him to LPK Team and move him to LPK place ?
  21. i put this ( if source == blabla ) and getLocalPlayer() to localPlayer
  22. Client-Side GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Memo = {} GUIEditor_Label = {} GUIEditor_Window[1] = guiCreateWindow(0.3037,0.75,0.4185,0.1817,"GUI Spawns",true) guiWindowSetMovable(GUIEditor_Window[1],false) guiWindowSetSizable(GUIEditor_Window[1],false) GUIEditor_Button[1] = guiCreateButton(9,59,97,33,"Hombre",false,GUIEditor_Window[1]) GUIEditor_Button[2] = guiCreateButton(121,59,97,33,"Mujer",false,GUIEditor_Window[1]) GUIEditor_Button[3] = guiCreateButton(230,59,93,33,"Clan ODST",false,GUIEditor_Window[1]) GUIEditor_Label[1] = guiCreateLabel(14,26,240,26,"Elige tu Spawn",false,GUIEditor_Window[1]) guiSetFont(GUIEditor_Label[1],"clear-normal") GUIEditor_Button[4] = guiCreateButton(370,-3363,0,600,"",false,GUIEditor_Window[1]) GUIEditor_Button[5] = guiCreateButton(332,59,87,33,"[LPK] Clan",false,GUIEditor_Window[1]) GUIEditor_Label[2] = guiCreateLabel(198,30,218,15,"BioHaZard Hell Zombies GUI",false,GUIEditor_Window[1]) guiSetFont(GUIEditor_Label[2],"default-bold-small") GUIEditor_Window[2] = guiCreateWindow(0.4121,0.575,0.1943,0.18,"Info Spawn",true) guiWindowSetMovable(GUIEditor_Window[2],false) guiWindowSetSizable(GUIEditor_Window[2],false) GUIEditor_Memo[1] = guiCreateMemo(9,22,181,77,"",false,GUIEditor_Window[2]) guiMemoSetReadOnly(GUIEditor_Memo[1],true) guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],false) showCursor(false) addEvent("onVisibleSpawnGUI",true) addEventHandler("onVisibleSpawnGUI", localPlayer, function() guiSetVisible(GUIEditor_Window[1], true) guiSetVisible(GUIEditor_Window[2], true) showCursor(true) end ) addEventHandler("onClientGUIClick", root, function() addEventHandler("onClientPedWeaponFire", getRootElement()) if source == GUIEditor_Button[1] then guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],false) showCursor(false) triggerServerEvent ("spawnPlayer_hombre",localPlayer,"Hombre") elseif (source == GUIEditor_Button[2]) then guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],false) showCursor(false) triggerServerEvent ("spawnPlayer_mujer",localPlayer,"Mujer") elseif (source == GUIEditor_Button[3]) then guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],false) showCursor(false) triggerServerEvent ("spawnPlayer_odst",localPlayer,"ODST") elseif( source == GUIEditor_Button[5]) then guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],false) showCursor(false) triggerServerEvent ("spawnPlayer_LPK",localPlayer,"LPK") end end ) addEventHandler("onClientPlayerWasted",localPlayer, function() guiSetVisible(GUIEditor_Window[1],true) guiSetVisible(GUIEditor_Window[2],true) showCursor(true) end ) function mostrarspawn() guiSetVisible (GUIEditor_Window[1],true) guiSetVisible (GUIEditor_Window[2],true) showCursor (true) addEventHandler("onClientPedWeaponFire", getRootElement(), cancelEvent) end addEvent("spawng", true) addEventHandler("spawng",localPlayer, mostrarspawn) addEventHandler("onClientMouseEnter", root, function() if (source == GUIEditor_Button[1]) then guiSetText(GUIEditor_Memo[1], "Aprieta este boton si eres Hombre y no tienes ningun clan en especifico") elseif (source == GUIEditor_Button[2]) then guiSetText(GUIEditor_Memo[1], "Aprieta este boton si eres Mujer y no tienes ningun clan en especifico") elseif (source == GUIEditor_Button[3]) then guiSetText(GUIEditor_Memo[1], "Solo si eres de ODST clan Aprieta este boton sino es posible ser kickeado") elseif (source == GUIEditor_Button[5]) then guiSetText(GUIEditor_Memo[1], "LPK Latins Pro Killers Clan Privado Solo Para Pro Killers") end end) addEventHandler("onClientMouseLeave", root, function() if (source == GUIEditor_Button[1]) then guiSetText(GUIEditor_Memo[1], "") elseif (source == GUIEditor_Button[2]) then guiSetText(GUIEditor_Memo[1], "") elseif (source == GUIEditor_Button[3]) then guiSetText(GUIEditor_Memo[1], "") elseif (source == GUIEditor_Button[5]) then guiSetText(GUIEditor_Memo[1], "") end end) addEvent("setTheText", true) addEventHandler("setTheText", localPlayer, function() guiSetText(GUIEditor_Memo[1], "No Eres del Clan") end ) and i think maybe you have to remove guisetMemoReadOnly
  23. yes i fixed the erros with lua script edtor but i dont know how to fix this isuue .
  24. X-SHADOW

    GUI Help

    like i have 9 buy button right ? i want make a tabl with them and make them work with out if ( source == '' ) then elseif ( source == '' ) then
×
×
  • Create New...