Jump to content

MRmihailZH

Members
  • Posts

    60
  • Joined

  • Last visited

Everything posted by MRmihailZH

  1. use a triple check, first whether the cursor is in a large circle, then whether the cursor is in a small circle, and whether the cursor is in a triangle x, y - cursor coordinates x1, y1, x2, y2, x3, y3 - coordinates of the angles of the triangle the function returns true if the point x, y belongs to a triangle function getPosition(x, y, x1, y1, x2, y2, x3, y3) local k = (x1 - x) * (y2 - y1) - (x2 - x1) * (y1 - y) local m = (x2 - x) * (y3 - y2) - (x3 - x2) * (y2 - y) local n = (x3 - x) * (y1 - y3) - (x1 - x3) * (y3 - y) return ((k >= 0 and m >= 0 and n >= 0) or (k <= 0 and m <= 0 and n <= 0)) end
  2. How can I download a song? @SpecT
  3. I pause the audio before setting the position
  4. How do I rewind a song if it is launched via a URL? If you use setSoundPosition, the song can be rewound only to the already loaded part of the song, and this is a maximum of 2-3 seconds
  5. Как перемотать песню, если она запущена через URL адрес? Если использовать setSoundPosition, то песню можно перемотать только на уже загруженную часть песни, а это максимум на 2-3 секунды
  6. Hi, I can make it so that you can choose which side the scrollbar will be on. That is, by default, it is on the right, but you can do it on the left.
  7. I have.png image format that has a black rectangle. How do I find out the coordinates of a black rectangle and its dimensions relative to the monitor? And whether it will be possible to remove this black rectangle. Thank you in advance for your response.
  8. У меня есть картинка .png формата, в котором есть черный прямоугольник. Как можно узнать координаты черного прямоугольника и его размеры относительно монитора? И можно ли с помощью шейдера будет убрать этот черный прямоугольника. Заранее благодарю за ответ.
  9. Да, я знаю. Аргумент стоит на true, ошибок в отладке нет. Я в тупике ?
  10. There are no errors in debugging. Added to the meta file. If you enter the following in a normal browser http://127.0.0.1:22005/resource/html.html then the file opens
  11. Yes, I know. I have true installed, but it still doesn't work.
  12. Hello, I have a problem. How do I upload the URL of a local html file? I tried typing http://mta/local/html.html but it doesn't load anything. Other links, but already on the Internet everything loads normally.
  13. Здравствуйте, у меня проблема. Как загрузить URL локального html файла? Я пробовал вводить http://mta/local/html.html но ничего не загружает. Другие ссылки, но уже в интернете все нормально загружает.
  14. Извиняюсь, я понял в чем была проблема, я задавал абсолютные координаты, а нужно относительные.
  15. Я опробовал функцию, но результата мне этого не дало. Функция возвращает false, даже когда курсор находится внутри треугольника. Может я что-то не понимаю?
  16. Помогите, пожалуйста. Есть функция isMouseInPosition, которой можно проверять, есть ли курсор в прямоугольной области. Но как узнать стоит ли курсор в треугольной области? Буду очень благодарен, если найдется человек, который поможет с этой проблемой. :3 Заранее спасибо.
  17. Как можно сделать, чтобы ped шел за игроком? Есть setPedAnalogControlState, которым можно управлять пэдом, но как сделать, чтобы он шел именно за кем-то? Как с помощью setPedCameraRotation повернуть камеру на кого-то?
  18. У меня вопрос. Можно ли доверять https://luac.multitheftauto.com/ ? То есть могут ли люди декомпилировать мой ресурс?
  19. I tried your code and nothing happens. I tried to fix something and also all to no avail.
  20. I understand this very well, but I do not want to limit it. Are there any other options?
  21. Here is the function that moves the object, I understand that instead of rotation -80, I need to write some formula that will determine how much it needs to lower / rise, but I can’t achieve such a result. Therefore, I ask for your help, thank you in advance. gateLSPD = false x, y, z = getElementPosition ( source ) if getDistanceBetweenPoints3D ( x, y, z, 1544.24707, -1631.90906, 13.38281 ) <= 2 then if gateLSPD == false then local rotX, rotY, rotZ = getElementRotation(shlagLSPD) moveObject ( shlagLSPD, 2000, 1544.6999511719, -1630.9000244141, 13.10000038147, 0, -80, 0 ) gateLSPD = true else local rotX, rotY, rotZ = getElementRotation(shlagLSPD) moveObject ( shlagLSPD, 2000, 1544.6999511719, -1630.9000244141, 13.10000038147, 0, 80, 0 ) gateLSPD = false end end
  22. Вот функция, которая двигает объект, я понимаю, что нужно вместо rotation -80 писать какую-то формулу, которая будет определять на сколько ей нужно опуститься/подняться, но я такого результата достигнуть не могу. Поэтому прошу вашей помощи, заранее благодарю. gateLSPD = false x, y, z = getElementPosition ( source ) if getDistanceBetweenPoints3D ( x, y, z, 1544.24707, -1631.90906, 13.38281 ) <= 2 then if gateLSPD == false then local rotX, rotY, rotZ = getElementRotation(shlagLSPD) moveObject ( shlagLSPD, 2000, 1544.6999511719, -1630.9000244141, 13.10000038147, 0, -80, 0 ) gateLSPD = true else local rotX, rotY, rotZ = getElementRotation(shlagLSPD) moveObject ( shlagLSPD, 2000, 1544.6999511719, -1630.9000244141, 13.10000038147, 0, 80, 0 ) gateLSPD = false end end
  23. Прошу помощи. Сервер: function onQuit() local resetPagesize = getElementData(source, "getPagesize") if resetPagesize then triggerClientEvent("resetPageXMLFromQuit", source, resetPagesize) end end addEventHandler ( "onPlayerQuit", root, onQuit ) Клиент: function resetPageXMLFromQuit(param) resetPageXML(param) end addEvent("resetPageXMLFromQuit", true) addEventHandler("resetPageXMLFromQuit", getRootElement(), resetPageXMLFromQuit) Когда игрок выходит из игры, должна запуститься функция и передать данные функции клиенту, но на триггере все обрывается. В дебаге никаких ошибок нет. Также хотел сделать на прямую на клиенте, но эвент "onClientPlayerQuit" не срабатывает на игрока. Заранее благодарю.
×
×
  • Create New...