Search results

Jump to navigation Jump to search
  • Returns an [[Element|element]] if it's within the specified '''distance''', ''false'' otherwise. local elements = getElementsWithinRange(Vector3(getElementPosition(player)), distance, type, getElementInterior(player), getElementDimension(p
    2 KB (273 words) - 07:37, 1 November 2023
  • local x, y, z = getElementPosition(getPedOccupiedVehicle(thePlayer) or thePlayer) ...example adds a command that outputs the rounded players current position. It's useful for [[createWater]] function.
    3 KB (336 words) - 09:30, 13 October 2023
  • ...pearing not to load them at all. Refer to the second example on that page, it's a client-side function and cannot be used next to assignLOD.}} setElementPosition(lod, getElementPosition(element))
    2 KB (225 words) - 19:07, 27 September 2023
  • {{IT/MainP}} {{IT/Funzioni client}}
    881 bytes (98 words) - 08:36, 16 December 2011
  • ...oat indicating the related angle between the first element and the second. It returns ''false'' if invalid parameters are provided. local pointX, pointY = getElementPosition(thisElement)
    4 KB (430 words) - 01:09, 4 April 2023
  • Returns ''true'' if the position is inside the radar area, ''false'' if it isn't or if any parameters are invalid. -- get the x, y coordinates from getElementPosition (z gets silently discarded)
    1 KB (147 words) - 10:26, 30 January 2022
  • ...ions:''' A table of options. It is not mandatory, but when it is provided, it must be a table. For a list of options, see the [https://github.com/kikito/ ...rns a string. The contents can change if we update the inspect library, so it is not expected to be consistent across Lua versions.
    2 KB (203 words) - 22:04, 29 January 2020
  • ...players that are within a certain range if there is minimum 1 player else it returns false. local x,y,z = getElementPosition(playerSource);
    1 KB (159 words) - 12:35, 3 October 2020
  • This function takes two sets of XY coordinates. It returns the direction from point A to point B. This can for example be used This command makes the player who enters it face the player whose name is given.
    2 KB (241 words) - 07:41, 17 February 2015
  • local px, py, pz = getElementPosition(theElement) if (hitElement == theElement) then -- If it collides with the element return true
    2 KB (188 words) - 11:27, 29 October 2023
  • ...behavior of [[isPedInVehicle]] server-sided for [[player]] elements ONLY. It checks if a specified [[player]] is actually in a [[vehicle]] and not just ...fully completed entering a [[vehicle]] and hasn't fully completed exiting it yet, ''false'' otherwise.
    2 KB (263 words) - 17:37, 27 January 2023
  • ...that holds the direction and distance between two points. In other words, it produces exactly the same result as substracting the points' coordinates an vehicle1x, vehicle1y, vehicle1z = getElementPosition ( vehicle1 )
    2 KB (268 words) - 08:30, 7 September 2019
  • ...that holds the direction and distance between two points. In other words, it produces exactly the same result as substracting the points' coordinates an This example gets the distance between two vehicles and outputs it to the chat box.
    3 KB (452 words) - 17:20, 25 February 2022
  • ...mmand that creates a M4 where the player uses it, and gives 1 clip ammo to it. local wep = createWeapon("m4", getElementPosition(localPlayer))
    1 KB (145 words) - 17:23, 23 December 2014
  • ...example checks if the object created is breakable and if it is then breaks it. local x, y, z = getElementPosition(localPlayer)
    900 bytes (112 words) - 22:23, 16 September 2016
  • ...example checks if the object created is breakable and if it is then breaks it. local x, y, z = getElementPosition(plr)
    1 KB (140 words) - 16:30, 6 August 2016
  • outputServerLog( table.concat({getElementPosition(source)}, ", ") ) ...xist but aren't supposed to be (like forbidden, where they can still spawn it through creation vulnerability, or identify which resource is hooked into (
    3 KB (300 words) - 08:22, 4 November 2020
  • It is required that the point is near enough to the local player so that it's within the area where collision data is loaded. If this is not the case, local px, py, pz = getElementPosition ( thePlayer )
    3 KB (362 words) - 05:23, 12 December 2023
  • {{Note|Disabling a peds collisions will cause some problems, such as it being unable to move or wrong rotation after creation.}} local playerX, playerY, playerZ = getElementPosition(thePlayer)
    2 KB (214 words) - 16:27, 20 January 2020
  • {{IT/MainP}} {{IT/Funzioni client}}
    1 KB (149 words) - 12:48, 3 August 2011
  • ...ator:''' the explosion's simulated creator, the [[player]] responsible for it. local pX, pY, pZ = getElementPosition ( source )
    6 KB (763 words) - 11:44, 11 January 2024
  • ...overlay grain effect. The game will draw it on top of other grain effects. It can be used to imitate an effect of radiation or electromagnetic disturbanc local x, y, z = getElementPosition( localPlayer )
    1 KB (133 words) - 01:46, 26 July 2023
  • ...ent. These events can only trigger when the client has its cursor enabled. It triggers for all three mousebuttons in both their up and down states. This example prints type of the element you clicked to chatbox when you click it.
    3 KB (348 words) - 02:56, 27 September 2018
  • [[File:DxDrawImageOnElement.png|thumb|Example of how it should looks like.|284x230px]] * ''TheElement'': The element you want to draw the image on it.
    4 KB (593 words) - 16:18, 21 July 2023
  • ...hel charge, returns the [[element]] at which it is glued to (or ''nil'' if it isn't glued to any).}} local x,y,z = getElementPosition(getLocalPlayer()) -- Get the position of the player
    2 KB (188 words) - 01:29, 10 September 2016
  • This function takes two sets of XYZ coordinates. It returns the 3D direction from point A to point B. This can for example be u This command makes the player's vehicle to rotate at vehicle near it.
    3 KB (404 words) - 14:24, 21 March 2023
  • ...a while. Because it's a client side only function, other players won't see it, so custom events or custom objects will be needed to make a fire visible t ...nd, which creates a patch of fire in the position of the player that types it.
    1 KB (209 words) - 01:53, 8 September 2021
  • ...- if visibility for root is set to false and for a player is set to true, it will be visible to the player. *'''visible:''' Whether you are making it visible or invisible to the player.
    3 KB (447 words) - 13:48, 25 December 2023
  • local px, py, pz = getElementPosition(localPlayer) -- output it to the console
    1 KB (183 words) - 16:19, 8 April 2024
  • .... It is required that the point is near enough to the local player so that it's within the area where collision data is loaded.}} local playerX, playerY, playerZ = getElementPosition (localPlayer)
    1 KB (168 words) - 15:59, 23 September 2021
  • If you use this function on vehicles with shared names, such as "police", it will return the earliest occurrence of that vehicle's ID. This will allow the player to create a vehicle by name and it's ID will be displayed in the chatbox when the vehicle is spawned.
    2 KB (290 words) - 11:29, 26 June 2014
  • ...weenPoints3D(x, y, z, getElementPosition(ele)) <= range -- returns true if it the range of the element to the main point is smaller than (or as big as) t local x, y, z = getElementPosition(player)
    2 KB (262 words) - 11:16, 29 October 2023
  • If you use this function on vehicles with shared names, such as "police", it will return the earliest occurrence of that vehicle's ID. This will allow the player to create a vehicle by name and it's model ID will be displayed in the chatbox when the vehicle is spawned.
    2 KB (318 words) - 19:53, 26 May 2017
  • This example creates a polygon colshape and show height of it with command 'getpolyheight'. local x, y = getElementPosition ( colPoly )
    2 KB (187 words) - 03:51, 1 June 2022
  • * '''weapon''': If the type is a Weapon pickup, then it represents the [[Weapon|weapon ID]] of the weapon pickup. When used with th ...ntPosition ( source ) --get the position of the person who died and define it as x, y and z
    3 KB (475 words) - 19:32, 21 May 2023
  • ...ain location. The water level is 0 in most places though it can vary (e.g. it's higher near the dam). local x, y, z = getElementPosition ( thePlayer ) -- get his position
    2 KB (300 words) - 10:19, 30 January 2022
  • ...and named ''getscale'' which creates an object and prints out the scale of it. local theObject = createObject(1337, getElementPosition(localPlayer))
    991 bytes (122 words) - 14:19, 2 February 2021
  • local x1,y1,z1 = getElementPosition(sm.object1) local x2,y2,z2 = getElementPosition(sm.object2)
    6 KB (686 words) - 10:37, 29 October 2023
  • ...want a custom weapon to take into account recoil, you will have to script it by firing at fixed coordinates.}} * '''theTarget:''' The [[element]] to shoot at. It can be a [[player]], [[ped]], [[vehicle]] or [[object]].
    4 KB (551 words) - 01:05, 16 January 2023
  • If a boolean was passed to the function, it always succeeds and returns ''true''. ...localPlayer) == 17 and getDistanceBetweenPoints3D(493.39, -22.72, 1000.68, getElementPosition(localPlayer)) < 50 and getInteriorSoundsEnabled() then
    1 KB (126 words) - 08:49, 15 June 2014
  • local x,y,z = getElementPosition ( creator ) ...tData ( claymoreCol , "type", "claymore" ) --store the type of colshape so it can be retrieved
    3 KB (429 words) - 09:26, 6 November 2023
  • ...tElementPosition (somewhere far away) and then destroyElement (which makes it explode). ...here the teargas got created, and also the teargas keeps getting warped to it. This will result in +/-60hp loss for the creator.
    2 KB (302 words) - 18:55, 7 September 2023
  • This event is triggered every time GTA renders a new frame. It is required for the DirectX drawing functions, and also useful for other cl local x, y, z = getElementPosition ( localPlayer )
    1 KB (197 words) - 11:06, 2 March 2014
  • ...ers) or detecting if a point is on the screen (though it does not check if it is actually visible, you should use [[processLineOfSight]] for that). ...ce the position can be off screen before the function returns false. Note: it's clamped down on both axies to the size of screen at the given axis*10
    2 KB (258 words) - 17:29, 2 April 2023
  • {{IT/MainP}} {{IT/Funzioni client}}
    3 KB (327 words) - 12:47, 3 August 2011
  • This element has to create a blip at the nearest garage and removes it in 10 seconds. local ex,ey,ez = getElementPosition (element)
    2 KB (186 words) - 03:42, 25 September 2018
  • This function checks in which way the cursor is currently moving, it's updated version of https://wiki.multitheftauto.com/wiki/GetCursorMoveOn. local x, y, z = getElementPosition(vehicle)
    2 KB (256 words) - 14:48, 8 June 2020
  • ...en local and said remote player (that spawned far away) during this event, it would output the distance at which they died in front of local player, e.g local x, y, z = getElementPosition(localPlayer)
    2 KB (359 words) - 03:51, 22 January 2023
  • ...tion can only remove command handlers that were added by the resource that it is called in. local x, y, z = getElementPosition ( huntedPlayer )
    3 KB (305 words) - 01:59, 9 July 2011
  • [[Image:Drawcircleonelementdemo.jpg|thumb|Example of how it should looks like.|304x250px]] * '''TheElement''': The element you want to draw the text on it.
    2 KB (204 words) - 08:13, 19 October 2022
View (previous 50 | ) (20 | 50 | 100 | 250 | 500)