Jump to content

ViRuZGamiing

Members
  • Posts

    1,050
  • Joined

  • Last visited

Everything posted by ViRuZGamiing

  1. You'll need one of the 2; • MySQL (Suggested) • SaveScript A Savescript works too but most servers uses MySQL Databases.
  2. Do you pay per script? Im not know with everything but maybe i can script something.
  3. Problem with cursor: [20:37:39] SCRIPT ERROR: car-click\cursor.lua:6: ')' expected (to close '(' at l ine 1) near 'end' [20:37:39] ERROR: Loading script failed: car-click\cursor.lua:6: ')' expected (t o close '(' at line 1) near 'end'
  4. If I add the cursor bindKey "m" will it work?
  5. You're Welcome I just tried it, the bind "m" doesn't show cursor and if I try with F8's or Chat's Cursor it won't give a weapon. Yes it's Client Sided debug: bad argument @ getElementType
  6. Indeed, thanks WASSIm. !
  7. I understand and I guess your new aswell... just if your not sure skip it Thank for trying bro!
  8. Sack I wrote a , this doesn't end the code. @WASSIm. can you get the onVehicleClick code in my code and let it do if getVehicleName == 523 or 598 or 596 or 597 or 599 then Then this code bindKey ("m", "down", -- binds M key to toggle cursor state function() showCursor( not isCursorShowing() ) end) addEventHandler("onClientVehicleEnter", function (thePlayer, local playerTeam = getPlayerTeam ( source ) -- get the player's team if ( playerTeam ) == Police then -- checks if it's Police giveWeapon ( thePlayer, 23, 200 ) -- If Team is Police then gives the player a gun end end
  9. Maybe: local id = getElementModel ( theVehicle ) onClientClick and if id == Car'sID then -- At Car'sID some ID could be writen. Could this work?
  10. Hello, What's the function for clicking a car? I searched for onVehicleClick but it doesn't exist. At the moment I have a short part for the cursor to be visible. bindKey ("b", "down", -- binds B key to toggle cursor state function() showCursor( not isCursorShowing() ) end)
  11. isn't it .dff and .txd? .txt is a text file.
  12. local screenWidth,screenHeight = guiGetScreenSize() -- Get screen resolution. function dxDraw ( ) dxDrawImage ( Fill in like your requirements ) end function bindKey ( ) bindKey ( "F7", "down", dxDraw ) -- bind the player's F7 down key end I'm still a noob but this is a bit of help I think... I don't know how to set the visibility on dxDraw's I recently learned how to make GUI's.
  13. I think it's the Flashlight script attached to the head.
  14. it does i have a server side
  15. Is this correct? local X = 0.375 local Y = 0.375 local Width = 0.25 local Height = 0.25 heal = guiCreateWindow(X, Y, Width, Height, "Heal yourself", true) button = guiCreateButton( 0.7, 0.1, 0.2, 0.1, "Heal!", true, heal ) x = guiCreateButton( 0.7, 0.1, 0.2, 0.1, "x", true, heal ) guiSetVisible ( heal, false ) function changeVisibility ( ) guiSetVisible (heal, not guiGetVisible ( heal ) ) showCursor (guiGetVisible(heal)) end addCommandHandler("heal", changeVisibility) triggerServerEvent ( "onClientGUIClick", button, heal) function closeGui ( ) guiSetVisible (heal, not guiGetVisible ( heal ) ) showCursor (guiGetVisible(heal)) end addEventHandler ("onClientGUIClick",x,closeGui,false)
  16. This is done on a Reallife Server where I played on... so I'll suggest to use that.
  17. Okay another Question: I've added the last part (yes as text not code) but how can I attach the button to the right upper corner of the GUI? Like on a Windows Program the left upper red "X" to close the Program (GUI) The button (button) needs to be in the middle. 50% up-down 50% left-right local X = 0.375 local Y = 0.375 local Width = 0.25 local Height = 0.25 heal = guiCreateWindow(X, Y, Width, Height, "Heal yourself", true) button = guiCreateButton( 0.7, 0.1, 0.2, 0.1, "Heal!", true ) guiSetVisible ( heal, false ) function changeVisibility ( ) guiSetVisible (heal, not guiGetVisible ( heal ) ) showCursor (guiGetVisible(heal)) end addCommandHandler("heal", changeVisibility) triggerServerEvent ( "onClientGUIClick", button, heal) --[[ Close Button Test x = guiCreateButton( 0.7, 0.1, 0.2, 0.1, "Output!", true ) function closeGui ( ) guiSetVisible (heal, not guiGetVisible ( heal ) ) showCursor (guiGetVisible(heal)) end addEventHandler ("onClientGUIClick",x,closeGui,false) --]]
  18. I suggest to use this: Example: -- create our hill area local hillArea = createColRectangle ( -2171.0678710938, 678.17950439453, 15, 15 ) local hillRadar = createRadarArea ( -2183.5678710938, 705.67950439453, 40, -40, 0, 255, 0, 175 ) -- add hill_Enter as a handler for when a player enters the hill area function hill_Enter ( thePlayer, matchingDimension ) -- announce to everyone that the player entered the hill (you could remove this) if (getElementType(thePlayer) == "player") then outputChatBox( getPlayerName(thePlayer) .. " entered the zone!", getRootElement(), 255, 255, 109 ) setRadarAreaFlashing ( hillRadar, true ) --Sorry but I never use KillPed setElementHealth ( thePlayer, -100) end end addEventHandler ( "onColShapeHit", hillArea, hill_Enter ) -- add hill_Enter as a handler for when a player leaves the hill area function hill_Exit ( thePlayer, matchingDimension ) -- check if the player is not dead if (getElementType(thePlayer) == "player") then if isPedDead ( thePlayer ) ~= true then -- if he was alive, announce to everyone that the player has left the hill outputChatBox ( getPlayerName(thePlayer) .. " left the zone!", getRootElement(), 255, 255, 109 ) setRadarAreaFlashing ( hillRadar, false ) end end end addEventHandler ( "onColShapeLeave", hillArea, hill_Exit ) You can change your coordinates to yours
  19. onVehicleEnter is good enough for a Noob Scripter
  20. An resource as example: https://community.multitheftauto.com/index.php?p= ... ls&id=4083
  21. --Use this getElementModel setVehicleLocked isVehicleLocked Maybe "outputChatbox" or a "DxDraw"
  22. That's SA-MP and it uses other animations.
  23. Thank you very much for explaining that
  24. Okay can you tell what I did wrong so I can learn something about my mistake +Why the f*ck you say Signature Thief too me! Everyone can take it There is no Copyright on it so it's no theft. ++ I've reported that Document too Google as Insulting and took a screenshot
×
×
  • Create New...