Jump to content

12p

Members
  • Posts

    2,608
  • Joined

  • Last visited

Everything posted by 12p

  1. Search a video on Youtube. The way to explain isn't too simple. Remember: "A photo has more value than one thousand words", and a video...
  2. I think the idea is good. I just don't know if you can do it.
  3. set/getVehicleRotation Isn't this the same thing as set/getElementRotation, but for vehicles only?
  4. And there 2: setPedRotation getPedRotation This is for Z only but why to use them? You can easily use that with getElementRotation and setElementRotation!
  5. 12p

    Some Questions

    1. Scripting maybe? Looking on WIKI maybe? 2. What do you mean -.- 3. From my knowledge, no, isn't possible.
  6. just move the (damn) event handler down from the function like I meant on the code -.- I don't get how you can't get it. PS: I'm a bit angry -.-
  7. I think is a plagio from JesseUnit's Safe Zone.
  8. 12p

    CoD2MoD

    So few information... Maybe you modified something huh?
  9. getAlivePlayers getRandomPlayer These functions can be easily done by using table functions. I think aren't necessary and could be deleted. I know there are some more, but I don't remember them now. --------------------------- set/getPedRotation set/getVehicleRotation Why to use them? There is getElementRotation and setElementRotation!
  10. 12p

    US hosting?

    ServerFFS is the only option I know -.- All the others exist on Europe and most are cheap, but aren't good hosters enough.
  11. 1. use [lua] tags! it's even said on a sticky -.- 2. WRONG CLIENT: addEventHandler("onClientGUIClick", btnLogin, clientSubmitLogin, true) function clientSubmitLogin(button,state) if button == "left" and state == "up" then -- get the text entered in the 'username' field local username = guiGetText(edtUser) -- get the text entered in the 'password' field local password = guiGetText(edtPass) -- if the username and password both exist if username and password then -- trigger the server event 'submitLogin' and pass the username and password to it triggerServerEvent("submitLogin", getRootElement(), username, password) -- hide the gui, hide the cursor and return control to the player guiSetInputEnabled(false) guiSetVisible(wdwLogin, false) showCursor(false) else -- otherwise, output a message to the player, do not trigger the server -- and do not hide the gui outputChatBox("Please enter a username and password.") end end end 3. FIXED CLIENT: function clientSubmitLogin(button,state) if button == "left" and state == "up" then -- get the text entered in the 'username' field local username = guiGetText(edtUser) -- get the text entered in the 'password' field local password = guiGetText(edtPass) -- if the username and password both exist if username and password then -- trigger the server event 'submitLogin' and pass the username and password to it triggerServerEvent("submitLogin", getRootElement(), username, password) -- hide the gui, hide the cursor and return control to the player guiSetInputEnabled(false) guiSetVisible(wdwLogin, false) showCursor(false) else -- otherwise, output a message to the player, do not trigger the server -- and do not hide the gui outputChatBox("Please enter a username and password.") end end end addEventHandler("onClientGUIClick", btnLogin, clientSubmitLogin, true) This because...
  12. 12p

    spawnPlayer

    ERRORS: 1. If you are triggering that function, there isn't any "source" player... 2. You must specify a player to spawn when using that function calling way. In this case: spawna(player) 3. You must give a parameter to the "spawna" function, and check if "source" exists. 4. Just check the corrections that are highlighted in black. Fixed codes: addEvent("makePlayerSpawn", true) function spawna ([b]player[/b]) [b]if source then thePlayer = source else thePlayer = player end[/b] spawnPlayer ( [b]thePlayer[/b], -2650.2561035156, 22.383113861084, 27.414619445801, 90, 26 ) fadeCamera([b]thePlayer,[/b] true) setCameraTarget([b]thePlayer[/b], player) addEventHandler( "makePlayerSpawn", getRootElement(), spawna ) function onLogin ( player, user, pass ) local account = getAccount ( user, pass ) if ( account ~= false ) then if (logIn ( player, account, pass ) == true) then triggerClientEvent ( player,"hideLoginWindow", getRootElement() ) spawna([b]player[/b]) else outputChatBox ( "Login error!", player, 255, 255, 0 ) -- Output they got the details wrong. end else outputChatBox ( "Wrong username or password!", player, 255, 255, 0 ) -- Output they got the details wrong. end end
  13. 12p

    Markers

    getElementByID PS: Nº 400 POST
  14. 12p

    spawnPlayer

    show triggering.
  15. I just want to know if there is some way of to get the actual running function (because I dont have a name of that function, is running with addEventHandler). Thanks in advance.
  16. you would understand me if you know the reason... And thanks, volk, I will check and edit. EDIT: You were wrong, volk. It didn't work. Whatever, I just got the problem and solved it. Thanks anyway =)
  17. Little suggestion, JS. Next time use theFunctionHere[code]... it makes, seriously, an easier reply.
  18. res = getThisResource() addEvent ("onPlayerCallMission",true) function callMission (theMission) call (res,theMission,source) end addEventHandler ("onPlayerCallMission",getRootElement(),callMission) Simple script. I think what I'm doing it's okay, but when it triggers the event "onPlayerCallMission" it tells me "Bad Argument @ addEventHandler". That problem is in those lines. Am I doing any wrong thing?
  19. it would be cool if you use tag, not only [code]. Do that.
  20. Why do the carmods only get SUSPENDED and NOT DELETED?
  21. Then I will disable some things and maybe make some kind of custom map limit (and some more things about the spawn place)
  22. I think isn't necessary... Anybody can do it, so easily.
×
×
  • Create New...