Jump to content

IIYAMA

Moderators
  • Posts

    6,097
  • Joined

  • Last visited

  • Days Won

    218

Everything posted by IIYAMA

  1. Stop with lying about: "I have not so much time", that's all bullshit. Stop begging, that is for poor guys who do not own a device to play mta. So it is miracle that you can. Keep our lovely section clean, go request the right way at the request page. Leave the hard working scripters alone, you are making me sick.
  2. You are at the wrong section, read the rules/information about the scripting section: HERE. You can solve your problem/problems: HERE. Good luck and bye bye.
  3. + Objects can't create projectiles. Only (synced)vehicles/players can.
  4. addEventHandler("onClientPlayerDamage",localPlayer, function(attacker,weapon,bodyPart,loss) local health = getElementHealth (source) cancelEvent() end) You try finish it. If somebody else gives you the awnser, then that person is pathetic and the poster stays a noob. So pls give him a chance.
  5. ok thanks, and when for exemple a type in console : start the event onResourceStart always is triggered before the client side event onClientResourceStart?? Good question. To be honest, I do not know if the server is starting sending files before the serverside scripts has been loaded.(but I think it will start sending after.) But one thing you should know is that there is always the slow internet + the client script load time. Which is always slower.
  6. Afaik: onPlayerJoin < event serverside download the script(if he doesn't have it) load the script and as last start the script> onClientResourceStart < event clientside
  7. Must be a bug, clientside should be must better in detecting colshapes then serverside. Serverside must live from streamed data from the clients.
  8. setElementHealth or setElementModel < Works only at client elements which are NOT streamed. Streamed elements have synchronisations(serverside created: players, peds, vehicles). SetPlayerMoney doesn't gets streamed from client > server, (only server > client). so don't worry about that. @ arezu was first
  9. @ bandi94 his code + suivant = v[i+1] and v[i+1][2] or v[1] and v[1][2] -- next row data 2 previous = v[i-1] and v[i-1][2] or v[#v] and v[#v][2] -- prev row data 2
  10. Hi, I changed my serverip yesterday, how long will it take before the old server is out of the resource browser? (they have same server name)
  11. Thx mate, cookie mystery solved!
  12. Hey people, I can't find my clientside cookies any more. Folder: MTA San Andreas 1.4\mods\deathmatch\resources Is empty and I need to check one of my cookies which contains my Tiny Encryption data. Did you eat them?
  13. First. serverside + lightweight_sync your (eating, sleeping, ...) data = Secure, client performance. Never do: Because of: client crash, connection timed outs, packet loss, server crash, "onResourceStop" and anything else what might make miscommunication.
  14. it does work as long the image is also relative and adjust to the ratio.
  15. If you read all comments(especially mine), your problems would be fixed already. code + a little: local sx,sy = guiGetScreenSize() addEventHandler("onClientRender",root, function () if isPedInVehicle(localPlayer) then local veh = getPedOccupiedVehicle(localPlayer) if veh and isElement(veh) then local ch,tw = getElementHealth(veh)-250, sx*(170/1920) local ch = ch / 750 * 100 -- before the directX FUNCTIONS!!!!! dxSetAspectRatioAdjustmentEnabled (true) -- here we fix this resolution problem <<<<< -- before the directX FUNCTIONS!!!!! dxDrawRectangle(sx*(844/1920), sy*(10/1080), tw, sy*(24/1080), tocolor(0, 0, 0, 150), true) if ch >= 0 then ------------------------- HEALTH ------------------------- dxDrawRectangle(sx*(844/1920), sy*(10/1080), ch*tw/100, sy*(24/1080), tocolor(0, 0, 0, 255), true) end end end end)
  16. Missing an end. function, if, if, if = 4
  17. dxSetAspectRatioAdjustmentEnabled Must be enabled before using the render functions, not after.
  18. If you want to say something very negative, don't you think you need a bit of proof for that? Richt now you are destroying somebody his reputation, when hè is only asking for help. Next time keep it for yourself, unless you know where it is from.
  19. If the vehicle doesn't have a collision somehow, you just got yourself an infinity loop.
  20. np.
  21. On most of the pages it is there. This is probably one of the few events which has no information about that. Also you can figure out very easy if an event can be cancelled. If the event triggers before the "effect" it can be cancelled*. Doesn't count for all.* When the event triggers on the devise where the effect was created, there is more chance it can be cancelled. "onClientPlayerDamage" -- client triggers before the damage("effect") So can be cancelled. "onPlayerDamage" -- server triggers after the damage has been done. The player/his-ped might be already dead by now on the client his pc. You have to think with logic.
  22. Try: if ((tonumber(string.sub(tostring(getElementData(player,"Cash")), 2)) or 0) >= tonumber(price)) then
  23. >>>> https://wiki.multitheftauto.com/wiki/Dx ... entEnabled <<<<
  24. function getPositionFromElementOffset(element,offX,offY,offZ) local m = getElementMatrix ( element ) -- Get the matrix local x = offX * m[1][1] + offY * m[2][1] + offZ * m[3][1] + m[4][1] -- Apply transform local y = offX * m[1][2] + offY * m[2][2] + offZ * m[3][2] + m[4][2] local z = offX * m[1][3] + offY * m[2][3] + offZ * m[3][3] + m[4][3] return x, y, z -- Return the transformed point end addCommandHandler("getThisPart", function () local vehicle = getPedOccupiedVehicle ( localPlayer ) if vehicle then local x,y,z = getPositionFromElementOffset(vehicle,0,0,10)-- offset x,y,z end end) https://wiki.multitheftauto.com/wiki/GetElementMatrix
  25. math.randomseed(getTickCount ())
×
×
  • Create New...