Jump to content

Techial

Members
  • Posts

    67
  • Joined

  • Last visited

Everything posted by Techial

  1. By this, the text will stay there forever. You should put absolute positions, not math there.
  2. I don't know if you can cancel that event, try ejecting him instead.
  3. Use this: function idk () local X, Y, Z = 0, 3, 4 abcvehicle = createVehicle ( 432, X, Y, Z + 10 ) end addEventHandler ( "onResourceStart", getResourceRootElement(getThisResource()), idk) function abc ( thePlayer, seat, jacked ) local accname1 = getAccountName ( getPlayerAccount ( thePlayer ) ) if(accname1 == "aliarman") then outputChatBox ("Welcome to your Car", thePlayer, 255,0,0,true) else cancelEvent() end end addEventHandler("onVehicleEnter", root, abc )
  4. As stated above. function idk () local X, Y, Z = 0, 3, 4 abcvehicle = createVehicle ( 432, X, Y, Z + 10 ) end addEventHandler ( "onResourceStart", getResourceRootElement(getThisResource()), idk ) function abc ( theplayer, seat, jacked ) local accname1 = getAccountName ( getPlayerAccount ( thePlayer ) ) if(accname1 == "aliarman") then outputChatBox ("Welcome to your Car", thePlayer, 255,0,0,true) else cancelEvent() end end addEventHandler("onVehicleEnter", root, abc )
  5. As far as I know, there isn't any easier methods. Sorry but my knowledge stops here
  6. You may fade it for 3 seconds, then after 1,5 seconds you fade it out again and use dxDrawRectangle ? ------------------------------------------ Or else you could use dxDrawRectangle, and decrease the alpha untill it reaches 127,5.
  7. if(accName1=="aliarman")then
  8. Techial

    Im bad.

    Well first of all, why do you need the velocity? Second of all, did you even make this script?
  9. addEventHandler("onPlayerSpawn", getRootElement(), function() toggleControl(source,"vehicle_left", false) toggleControl(source,"vehicle_right", false) end )
  10. fadeCamera (false, 0, 127.5, 127.5, 127.5 )
  11. Techial

    Lock this

    function resetData() local account = getPlayerAccount(source) setAccountData(account, "spawned", "0") end addEventHandler("onPlayerLogin", root, resetData) local account = getPlayerAccount(source) if(tostring(getAccountData(account, "spawned"))=="0") then setAccountData(account, "spawned", "1") -- Spawn code here else outputChatBox("Sorry, you can't spawn more than 1 vehicle.", source, 255, 0, 0, true) end Pilot team marker addEventHandler("onPlayerSpawn", getRootElement(), function() for _, player in ipairs(getElementsByType("player")) do setElementVisibleTo(pilotMark, player, false) end for _, player in ipairs(getPlayersInTeam(teamPilot)) do setElementVisibleTo(pilotMark, player, true) end end )
  12. Well you could try to use setAccountData onPlayerLeave etc etc, setAccountData(accountpointer, "lastTime", tostring(timervaluepointer)) then you could load that on startup. if(not tonumber(getAccountData(accountpointer, "lastTime"))==0)then.. etc etc
  13. Så er det slik at jeg er DM Racer, og spiller på aR// og -|TG|-
  14. I think you got this guy wrong, he's not the OP. @Samer - That's actually a good question, as you can't know if he uses ACL or getAccountData / setAccountData.
  15. Techial

    Lock this

    getPedOccupiedVehicle: https://wiki.multitheftauto.com/wiki/GetPedOccupiedVehicle local playerVehicle = getPedOccupiedVehicle(thePlayer) if playerVehicle then outputChatBox("You already have a vehicle!",thePlayer, 255, 0, 0, true) else --Spawn code here end Regards, Techial.
  16. You can use setTimer, which sets a server sided value like setAccountData. (On join, it sets the players "command" data ( setAccountData(accountpointer,"command", "0") ) ) Then you can use that in a timer, I hope you understand me. You may want to read up on these: Client sided: https://wiki.multitheftauto.com/wiki/SetTimer https://wiki.multitheftauto.com/wiki/KillTimer https://wiki.multitheftauto.com/wiki/TriggerServerEvent Server sided: https://wiki.multitheftauto.com/wiki/SetAccountData Hope that helps you Regards, Techial.
  17. replaceSkins.lua function replaceSkins() local txd = engineLoadTXD("folder/example.txd") engineImportTXD(txd, 21) local dff = engineLoadDFF("folder/example.dff", 0) engineReplaceModel(dff, 21) local txd = engineLoadTXD("folder/example2.txd") engineImportTXD(txd, 22) local dff = engineLoadDFF("folder/example2.dff", 0) engineReplaceModel(dff, 22) -- Now repeat this process end addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), replaceSkins) meta.xml <meta> <script src="replaceSkins.lua" type="client" /> <file src="folder/example.txd" /> <file src="folder/example.dff" /> <file src="folder/example2.txd" /> <file src="folder/example2.dff" /> </meta> There you go, do not hestitate contacting me for further help Regards, Techial.
×
×
  • Create New...