-
Posts
1,056 -
Joined
-
Last visited
Everything posted by Sasu
-
Meta?
-
Probaste mi código y no te sucede eso ? Si, lo probe haciendo utilizando un comando pero puede que sea un error del guiGetText. Lo que puedes hacer es verificar que te devuelve guiGetText haciendo outputChatBox(tostring(Texto)) luego de la funcion mencionada.
-
I still don't understand, you want to upload photos to a web from mta server? If so, then I think you can use callRemote
-
Si entras a esta pagina http://ip-api.com/json por defecto te dará información acerca de tu IP tales como tu proveedor de internet, provincia/estado en el que se encuentra, etc. Esta información te lo devuelve en formato JSON (Puedes averiguarlo en la wiki toJSON y fromJSON, ya que ahí te explica un poco, o bien puedes informarte más averiguando, el dicho: "Google es tu amigo"). Por ejemplo, esto es lo que me devuelve la pagina: {"as":"AS22927 Telefonica de Argentina","city":"Tristan Suarez","country":"Argentina","countryCode":"AR","isp":"Telefonica de Argentina","lat":-34.8926,"lon":-58.5689,"org":"Telefonica de Argentina","query":"179.37.203.209","region":"B","regionName":"Buenos Aires","status":"success","timezone":"America/Argentina/Buenos_Aires","zip":""} La ciudad, al no ser precisa, no es correcta ya que yo me encuentro como a 4 o 5 ciudades de Tristan Suarez.
-
Pues he estado buscando por google y solo encontré páginas que te dicen la provincia y una ciudad cercana (a veces puede ser algo lejana). Puedes utilizar las siguientes funciones: fromJSON fetchRemote Junto a la siguiente pagina: http://ip-api.com/json/AquiLaIP
-
No tengo ni la menor idea de si seria la manera mas eficiente pero es lo unico que llegue a encontrar. _str:gsub("(%w+)", function(w) if w == index then return value end end)
-
El mta suele traer el recurso por defecto, solo haz "start admin" en la consola siendo admin.
-
Client: addEvent( "onMusica", true ) addEventHandler( "onMusica", root,function () local x, y, z = getElementPosition(source) local soundasd = playSound3D("sonido.mp3", x, y, z) setSoundVolume(soundasd, 1.0) attachElements(soundasd, source) setSoundMinDistance(soundasd, 1) setSoundMaxDistance(soundasd, 50) end) Server: addCommandHandler("sexo", function (playerSource) setPedAnimation ( playerSource, "sex", "sex_1_cum_w", 1, true, false, false ) triggerClientEvent( "onMusica", playerSource) end)
-
Cabe aclarar que nesecitas tener el recurso "admin" encendido.
-
I'm back, try this: local CountSpeed = 100 local b = 0.001 local tick local marker = createMarker(5497.0727539063, -2612.5356445313, 7.6, "corona",6, 0, 0, 0, 0) function flying (player) if source == marker then if isPedInVehicle(player) then vehicle=getPedOccupiedVehicle(player) b = 0.001 tick = getTickCount() x,y,z = getElementVelocity(vehicle) addEventHandler ( "onClientRender", getRootElement(), MyB) setTimer (function() removeEventHandler ( "onClientRender", getRootElement(), MyB) end, 1100 , 1 ) end end end addEventHandler("onClientMarkerHit", getRootElement(), flying) function MyB ( ) if (getTickCount() - tick) >= CountSpeed then b = b + 0.024 tick = getTickCount() end setElementVelocity(vehicle, x,y,b) end
-
local sm = {} sm.moov = 0 sm.object1,sm.object2 = nil,nil local function removeCamHandler() if(sm.moov == 1)then sm.moov = 0 end end local function camRender() if (sm.moov == 1) then local x1,y1,z1 = getElementPosition(sm.object1) local x2,y2,z2 = getElementPosition(sm.object2) setCameraMatrix(x1,y1,z1,x2,y2,z2) end end addEventHandler("onClientPreRender",root,camRender) function smoothMoveCamera(x1,y1,z1,x1t,y1t,z1t,x2,y2,z2,x2t,y2t,z2t,time) if(sm.moov == 1)then return false end sm.object1 = createObject(1337,x1,y1,z1) sm.object2 = createObject(1337,x1t,y1t,z1t) setElementAlpha(sm.object1,0) setElementAlpha(sm.object2,0) setObjectScale(sm.object1,0.01) setObjectScale(sm.object2,0.01) moveObject(sm.object1,time,x2,y2,z2,0,0,0,"InOutQuad") moveObject(sm.object2,time,x2t,y2t,z2t,0,0,0,"InOutQuad") sm.moov = 1 setTimer(removeCamHandler,time,1) setTimer(destroyElement,time,1,sm.object1) setTimer(destroyElement,time,1,sm.object2) return true end function smoothMoveCamer() smoothMoveCamera(-1833.8863525391,155.25959777832,61.177501678467,-1834.4569091797,154.45721435547,61.00262451171,-1901.7043457031,488.02301025391,140.8975982666,-1901.7189941406,487.13961791992,140.4291839599,20000) end addEventHandler("onClientResourceStart", resourceRoot, smoothMoveCamer)
-
Sorry, I would test it but I'm not going to be in my home until saturday.
-
Be careful because it creates a timer every render, that's a crazy idea if we think about the eficient.
-
CountSpeed = 100 local b = 0.001 local tick marker = createMarker(5497.0727539063, -2612.5356445313, 7.6, "corona",6, 0, 0, 0, 0) function flying (player) if source == marker then if isPedInVehicle(player) then vehicle=getPedOccupiedVehicle(player) b = 0.001 tick = getTickCount() x,y,z = getElementVelocity(vehicle) addEventHandler ( "onClientRender", getRootElement(), MyB) setTimer (function() removeEventHandler ( "onClientRender", getRootElement(), MyB) end, 1100 , 1 ) end end end addEventHandler("onClientMarkerHit", getRootElement(), flying) function MyB ( ) if (getTickCount() - tick) >= CountSpeed then b = b + 0.0015 tick = getTickCount() end setElementVelocity(vehicle, x,y,b) end
-
Use the same arguments as you use in isLineOfSightClear, then processLineOfSight will you return the object element so you can use getDistanceBetweenPoints3D with their positions. Take a look at processLineOfSight
-
Use processLineOfSight instead
-
You could use getElementData too.
-
This guy informed be of a bug I also came across: Like I said: read https://wiki.multitheftauto.com/wiki/In ... leshooting I told you that I had resolved. The problem was that I was trying with mta for 32 bits as I saw in your screenshot. Anyway, this was the first time I install a server on linux.
-
Really, thanks for sharing it . I will try
-
Then you can use: dxCreateRenderTarget dxSetRenderTarget setCameraMatrix
-
http://www.w3schools.com/sql/sql_delete.asp
-
So that means that the table 'elementBackpack' doesn't create. I suppose you are trying to create the table in the same script of the function, aren't you? If not, do it global.