Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 03/05/20 in all areas

  1. سكربت حلو بالتوفيق لك , لاكن حتى لو كان مشفر وحاط حقوقك ع اللوحة يمديه يغيرها الي له بالبرمجة :]
    2 points
  2. Yes, the math is right. You need to multiply X-size with SCREEN_X / 1920 and Y-size with SCREEN_Y / 1080
    1 point
  3. You need to scale the font size in dxDrawText. guiCreateFont's size is an Integer, so if the scaled value is 20.9, its rounded to 20.
    1 point
  4. If you enable shared, this is what will happen: <script src="file.Lua" type="shared"/> becomes <script src="file.Lua" type="client"/> <script src="file.Lua" type="server"/> The file is now used for serverside as well as clientside. But they are still loaded on 2 different applications. And as you know, you can't share your memory across the internet without taking the connection delay `ping` in consideration. The concept behind `shared` is a feature to make (utility) functionalities that work on both sides (client/server). Main purpose: Less maintenance The following content could be useful for in a shared file: https://wiki.multitheftauto.com/wiki/FindRotation https://wiki.multitheftauto.com/wiki/Table.random https://wiki.multitheftauto.com/wiki/Table.compare etc.
    1 point
  5. Tables aren't synced by default. If you create tables via shared script, they do not have same data (unless you will sync it). Take a look at this topic, might be helpful.
    1 point
  6. Shared won't work. Example: -- Client local clientTable = {} -- function onClientDataSync(serverData) clientTable = serverData end addEvent("onClientDataSync", true) addEventHandler("onClientDataSync", resourceRoot, onClientDataSync) -- function onClientReceiveVehicleData(...) local receivedData = {...} local vehicleUserdata = receivedData[1] local vehicleData = receivedData[2] clientTable[vehicleUserdata] = vehicleData outputConsole(inspect(clientTable)) end addEvent("onClientReceiveVehicleData", true) addEventHandler("onClientReceiveVehicleData", resourceRoot, onClientReceiveVehicleData) -- Server local serverTable = {} local newVehicle = createVehicle(411, 0, 0, 3) -- serverTable[newVehicle] = "Some data you want to pass" About sync: --[[Sync for everyone]] triggerClientEvent(root, "onClientReceiveVehicleData", resourceRoot, newVehicle, serverTable[newVehicle]) --[[When player latejoined - pass data f.e when he logins]] triggerClientEvent(source, "onClientDataSync", resourceRoot, serverTable)
    1 point
  7. تسسلم حبيبي ولله اذا ضميره جابه يغيرها انا مب مسامح فيه والله ولي التوفيق
    1 point
  8. في طريقه بحيث تحفظ علي حقوق مود حقك و تخليه مو مشفر + طريقه مو محميه يعني مب قويه كثير لحماية حقوق
    1 point
  9. فكرة ممتازة ولكن فكرة انه يكون مشفر ماتعتبر كويسه لان ممكن انا بطور المود واضيف له اشياء اكثر او بعدل على القائمة والاوامر + ان المود يكون مشفر بيقلل عدد الناس اللي يحملون المود لانه مشفر وغير قابل للتطوير
    1 point
  10. مود جميل , لكن لو كملتها بانك تجيب باسورد اللاعب , عشان اذا ضاعع حسابه تقدر تخبرهه بالباسورد وفالمستقبل سو تغيير كلمة زر الحساب . بالتوفيق ,
    1 point
  11. Bom dia, minha sugestão: Crie uma nova coluna no seu .db, com o nome trancado; Vai atualizando os valores com true or false, exemplo quando sair do servidor ficar true e quando voltar ao servidor e clickar em destrancar ficar false. Também recomendo que faça uma verificação com o setTimer, puxando o valor da tabela e setando no servidor; Ex: Verifica na tabela os veiculos e se estão trancados ou não, caso esteja você o tranca no jogo e caso não esteja, mantenha destrancado...
    1 point
  12. Hey guys. I've made 2 videos about adding Custom objects in MTA. Videos: Programs you'll need: 3DS Max (2009 or 2010, but if you have other It may work too!) Col Editor 2 TXD Workshop Extra stuff you'll need: GTA Scripts for 3DS Max (Put them in 3dsmax folder\Scripts) Example resource: DOWNLOAD .................. Text that you have to put in the meta file: Text that you have to put in the .Lua file (Script): addEventHandler('onClientResourceStart', resourceRoot, function() outputChatBox ( "Test") local txd = engineLoadTXD('files/yourfilename.txd',true) engineImportTXD(txd, 2052) local dff = engineLoadDFF('files/yourfilename.dff', 0) engineReplaceModel(dff, 2052) local col = engineLoadCOL('files/yourfilename.col') engineReplaceCOL(col, 2052) engineSetModelLODDistance(2052, 500) end ) P.S. My native language is not English, so I have some mistakes, but I think you'll understand the shit I'm talking
    1 point
  13. اهــنــيــكــ علــــى الســكــربــت و واصــــل بــدونـ فــوآصــل
    1 point
×
×
  • Create New...