Jump to content

Platin

Members
  • Posts

    385
  • Joined

  • Last visited

Everything posted by Platin

  1. https://community.multitheftauto.com/index.php?p=resources&s=details&id=10243 - Stoled DONE
  2. dxDrawRectangle tiene un argumento que es PostGUI, debe de ser true para así se renderiza luego de cualquier GUI. Para esto también se debe de ejecutar con onClientRender y no con onClientPreRender como hacen algunos. Ejemplo: function onRender() dxDrawRectangle(0, 0, 20, 20, tocolor (0, 0, 0, 150), true --[[Este es el argumento importante]]) end addEventHandler("onClientRender", root, onRender)
  3. Esto debería de funcionar, la tabla ref esta al dope. local blips = {} addCommandHandler ( "ref", function ( player ) local x, y, z = getElementPosition ( player ) local city = getZoneName ( x, y, z ) if exports.factions:isPlayerInFaction ( player, 1 ) then getPolicias ( ) if not blips[player] then exports.chat:me ( player, "pide refuerzos por su radio." ) for i=1, #policias do local value = policias [ i ] blips [ player ] = createBlipAttachedTo ( player, 0, 3, 255, 255, 0 ) setElementVisibleTo ( blips [ player ], root, false ) setElementVisibleTo ( blips [ player ], value, true ) end exports.factions:sendMessageToFaction ( 1, "El compañero "..getPlayerName (player).." ha pedido refuerzos en "..city..". Punto marcado en el GPS.", 255, 255, 0 ) else if isElement ( blips[player] ) then destroyElement ( blips[player] ) end exports.chat:me ( player, "cancela los refuerzos por su radio." ) exports.factions:sendMessageToFaction ( 1, "El compañero "..getPlayerName (player).." ha cancelado los refuerzos.", 255, 255, 0 ) blips[player] = nil end end end )
  4. Want to remove them https://community.multitheftauto.com/index.php?p=resources&s=details&id=6356 https://community.multitheftauto.com/index.php?p=resources&s=details&id=11019 https://community.multitheftauto.com/index.php?p=resources&s=details&id=10896 (also this one that is suspended) - No, we keep them to have violations on record (its not listed or accessible anyways) DONE
  5. Only models https://community.multitheftauto.com/?p=resources&s=details&id=15414 We decided not to remove it
  6. Just try it, with the getPositionFromElementOffset() function given by the wiki on getElementMatrix I made the camera element to rotate at the same time the camera rotates, then get his front, back, right and left. Here's the code if someone wants it: -- camaraElemento is my cameraElement, is a ped in my case function getPositionFromElementOffset(element,offX,offY,offZ) -- As I said, this is from the Wiki: https://wiki.multitheftauto.com/wiki/GetElementMatrix local m = getElementMatrix(element) local x = offX * m[1][1] + offY * m[2][1] + offZ * m[3][1] + m[4][1] 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 end local rotX = math.deg(rot) -- My rotation is on rad, so i need to convert it to degress | The X isn't from X axis, is because i already had rot defined local velCam = 0.02 -- Vel of the camera moving by frame local sx, sy = getCursorPosition() local rx, ry, rz = getElementRotation(camaraElemento) if rz ~= rotX then setElementRotation(camaraElemento, 0, 0, rotX) end -- My default rot 0 == looking to the south if sy == 0 then -- top x, y, z = getPositionFromElementOffset(camaraElemento, 0, -velCam, 0) end if sy == 1 then -- down x, y, z = getPositionFromElementOffset(camaraElemento, 0, velCam, 0) end if sx == 0 then -- left x, y, z = getPositionFromElementOffset(camaraElemento, velCam, 0, 0) end if sx == 1 then -- right x, y, z = getPositionFromElementOffset(camaraElemento, -velCam, 0, 0) end setElementPosition(camaraElemento, x, y, z) It would be nice if some mod could close this topic, my problem is resolved.
  7. I'm working on a type of RTS camera style and I encounter a problem. The camera can rotate on the same axis without problem, it can zoom and thats about it, but it needed to be looking at an element. Now I'm working on a freecam mode where by getting to the edges of the screen you can move to north, east, west or south. It is easy when the camera rotation is 0, because you know that the top of the screen will be allways X cardinal position, it looked something like this: local camSpeed = 0.2 local sx, sy = getCursorPosition() local x, y, z = getElementPosition(camElement) if sy == 0 then -- top setElementPosition(camElement, x, y-camSpeed, z) end if sy == 1 then -- down setElementPosition(camElement, x, y+camSpeed, z) end if sx == 0 then -- left setElementPosition(camElement, x+camSpeed, y, z) end if sx == 1 then -- right setElementPosition(camElement, x-camSpeed, y, z) end As I said, this works fine while my rotation is 0, but when I move to something like 180º, my now top of the screen will not go to the south but rather north, so it would move like my mouse was on the bottom of the screen. The question here is if there is a algorithm that i can use to determinate how much of X and how much of Y i need to add to the position of my camElement in order to go "up" or "down"... If you didn't get what I want yet, think of The Sims 3 for example, when you put your mouse on the top of your screen you go up, whatever your rotation is, it doesn't matter, you will always go up. With the code I have I can only go UP if im facing South, on the other hand if im facing North then when my mouse is on the TOP i will go DOWN instead of UP. Hope you can help me with this one, and thanks!
  8. Recién encuentro este tema, voy a ver lo de los interiores (GTIapartments) a ver si lo puedo completar para mí servidor, gracias por el aporte Ares.
  9. Original: https://community.multitheftauto.com/index.php?p=resources&s=details&id=1474 Stolen: https://community.multitheftauto.com/?p=resources&s=details&id=14908 The guy who reupload it did some changes but i think the proper credits are not given, plus the changes are minor, plus prob didn't ask the creator. DENIED (please read https://forum.multitheftauto.com/topic/98514-community-regulations-guidelines/ as this kind of re-upload is excepted for reasons listed in the policy)
  10. Hi, I was wondering if any of you could give me some advice or some information about shaders and how they work, and also if its possible, with .png, create some textures for the game and dont remplacing any of them at all. It really would be very useful to me, because on my own I only could make some shaders that change the colors of the screen at that's all. Thank you!
  11. Platin

    Pregunta

    Muestra que es bs si no no te podremos ayudar. Si es la ventana en donde esta el label mejor!
  12. Hola, queria saber si alguien me puede facilitar la informacion de como crear una textura y ponersela a un objeto usando shaders. Seria de micho ayuda. Tambien me serviria alguna miniguia de fx que anduve jugando con eso y solo logre cambiar los float de los colores. Gracias de antemano!
  13. Tambien tienes el getAccountsBySerial para detectar si tiene alguna cuenta ya creada
  14. Creo que lo de la camara seguira pasando si o si. Podrias hacer que cuando al jugador lo dañen en la cabeza no le quite vida.
  15. Hi! I can't acces to my account on the wiki. I remember creating it with an old method, don't remember what tho. When I try to reset my password the email never reaches me. I'm 100% sure that my username is Platin and my email is [email protected], so i don't know what else to do. Someone out there could help me?
  16. http://213.239.211.214/index.php?p=resources&s=details&id=14136 Another ZDay skin modification. Should be removed.
  17. You didn't understand me. I was saying that they were thinking of giving us, the scripters, 200+ new ids for putting objects, skins, vehicles and so one.
  18. https://wiki.multitheftauto.com/index.php?title=Character_Skins&oldid=49130 See for yourself.
  19. I have a question, in the Character Skins wiki page there was a list of the new upcoming ID skins for 1.6, why do you hide it? It can be that they arent going to be in the 1.6 anymore? Thank you for answer.
  20. Agregale un setTimer a la función respawnVehicles y estaría listo.
  21. Sorry for doble-post. After one month on OVH and having TS3 and two servers of MTA, i can declare that it works perfectly. Nice ping, no network trouble and use a lot less than I expected, i think I can make like 3 servers more without problem, even more. If someone can close the topic, thank you.
×
×
  • Create New...