Jump to content

bandi94

Members
  • Posts

    1,037
  • Joined

  • Last visited

Everything posted by bandi94

  1. 1. modes/base.lua : line 95 Countdown.create(5, RaceMode.startNextMapSelect, text, 255, 255, 255, 0.6, 2.5 ):start() to Countdown.create(1, RaceMode.startNextMapSelect, text, 255, 255, 255, 0.6, 2.5 ):start() 2. change 3,2,1.png's to blank images
  2. Well shader's is the only way , you could try to get the name with this : https://nightly.multitheftauto.com/files/shaders/ ... _names.zip
  3. function refreshGUI() guiGridListClear(gridList) for index, player in ipairs ( getElementsByType ( 'player' ) ) do if ( player ~= localPlayer ) then guiGridListSetItemText ( gridList, guiGridListAddRow ( gridList ), 1, getPlayerName ( player ), false, false ) end end end addEventHandler( "onClientPlayerQuit", getRootElement(), refreshGUI )
  4. function showGUI ( ) local tostate = not guiGetVisible ( win ) guiSetVisible ( win, tostate ) showCursor ( tostate ) guiGridListClear(gridList) for index, player in ipairs ( getElementsByType ( 'player' ) ) do if ( player ~= localPlayer ) then guiGridListSetItemText ( gridList, guiGridListAddRow ( gridList ), 1, getPlayerName ( player ), false, false ) end end end addCommandHandler("aj",showGUI)
  5. A Concerned Citizen , KK you are good , lua.org is bad .
  6. loadstring The bad side of "loadstring" is that it can't be stopped easy , once the code is loaded you can't stop it unless you are using warpper's
  7. Then please go and tell to the LUA dev's that they write it wrong on the lua.org http://www.lua.org/pil/20.2.html Some characters, called magic characters, have special meanings when used in a pattern. The magic characters are ( ) . % + - * ? [ ^ $
  8. "loadstring" shoud be use when there are no other options , bk to stop the loaded code you need to unload EventHandlers , to do that you need warppers , with warppers you will warp your own EventHandlers to and not only the loadstring one , so there is much more work.
  9. Make the load function with triggerClientEvent. in meta.xml add only the .lua files , after manual downloaded the .dff / txd you simpli call the loading function. triggerClientEvent(player,"loadMods",player)
  10. string library have some special characters call'd "magic characters" : ( ) . % + - * ? [ ^ $ So when you are using "string.gsub(mapName, "[old]", "[OLDS]")" then "[]" are seend as magic characters and not as a character. To make string.gsub to use this "magic characters" as normal characters you need to put in front of them a "%". string.gsub(mapName, "%[old%]", "[OLDS]")
  11. Use : guiSetEnabled(background,false)
  12. bandi94

    HTML question.

    Hy. There is the "webadmin" resource. Now i wanna make something like that but i wanna a different address for the page and not the server ip:port. Mainly i wanna only data's from the server , somebody access the webpage and then there will be a list with the online player's and some account data for each online player. So i need only to send data from server->php when the php ask it. Now is there any way to change the ip:port URL to a custom one ? Or not , if there is no way then i was thinking to make 2 php scripts one hosted as resource on the server , and one on my page , and then when somebody access the page the php will call the php from the server , that php getting all the info from the server and sending it back to the php hosted on the web page. Would this work ? I am not to "pro" on php/html THX.
  13. local image = guiCreateStaticImage() setTimer(destroyElement,5000,1,image)
  14. Yes you can use 2 "addEventHandler" for one function.
  15. It is used in 3D modeling for extra object's. Like i add a spoiler on the infernus and i name it "extra1". InGame the spoiler will not be showed . To make the spoiler visible you need to use "setVehicleVariant" . This function could be using for a custom car tunning , without using "attachElement" to the car , it makes the tunning a bit easyer
  16. Go to : race/nametags.lua and delete it .
  17. bandi94

    Question

    Well , i made this with country , city . I send the IP with fetchRemote to my php , my php call a webpage that is locating the country and the city , the webpage return the 2 data to my php , and my php back to the server . But 20-30% of the time the city is returned wrong , so i would sugest that the player can chose his city.
  18. Well , i changed it to "triggerLatentClientEvent" and then with "getLatentEventStatus" i can get the "percentComplete" data from it. Thx anyway
  19. function displayPosition() local x,y,z = getElementPosition(getLocalPlayer()) outputChatBox("X:"..x.."Y:"..y.."Z:"..z,0,255,0) end addCommandHandler("pos",displayPosition) P.S : you dont need to put ";" in LUA , like in C++ indicating that is end of the line.
  20. HY. I completed a manual file download everything is working perfect. Now i wanna customize it with a download progress. It's working with : fileRead TriggerClientEvent fileWrite Now on server side i can get the file size and number of them , but i can't figure out , how can i check the file transfer state , the function on client side will be triggered in the moment when the "TriggerClientEvent" completed sending the data from "fileRead" . Is there any way to detect how much data was sended / downloaded by the client ? Or to get the download speed and from there make the math with the file size ? THX
  21. playSound3D attachElements
  22. hmm it should be show'd , check if www.game-state.eu can see it .
  23. Yes it is possbile , most common way to do that is : atan2f / atanf . Here is my old aimbot for some multiplayer FPS - game i played. The code is made in C++ , and for 3D camera , yaw/pitch/roll . This is just an exempel how could it be made. Ofc this must be edited to work on MTA , but it's a start for you what to search. D3DXVECTOR3 NewVector; NewVector.x = pClientInfo->g_pLocal->Pos.x - g_pESP.pPlayers[AimAt].Aimcords.x; NewVector.y = pClientInfo->g_pLocal->Pos.y - g_pESP.pPlayers[AimAt].Aimcords.y; NewVector.z = pClientInfo->g_pLocal->Pos.z - g_pESP.pPlayers[AimAt].Aimcords.z; float CamYaw = (float)atanf(NewVector.x/NewVector.z); if(NewVector.z > 0.0f && NewVector.x < 0.0f && CamYaw < 0.0f) CamYaw += D3DX_PI; else if(NewVector.z > 0.0f && NewVector.x > 0.0f) CamYaw += D3DX_PI; DWORD tempKey = 0; switch(AimbotKey) { default: tempKey = VK_LBUTTON; break; case 1: tempKey = VK_RBUTTON; break; case 2: tempKey = VK_SHIFT; break; } if((GetAsyncKeyState(tempKey) && !Aimbotkeyon) || (Aimbotkeyon)) { pClientInfo->g_pLocal->pitch = (float)atan2f(NewVector.y,(float)sqrt(pow(NewVector.z,2) + pow(NewVector.x,2))); pClientInfo->g_pLocal->yaw = CamYaw;
  24. What to explain better ? I asked if loadstring can load coplied lua's. (luac, luaQ)... Well i need to use it , i have no option.
  25. what is "markerpv" ? You have only : markerpv_1, markerpv_2, markerpv_3, markerpv_4 . And in "addEventHandler" you added "markerpv" .
×
×
  • Create New...