HU/createBlipAttachedTo: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Created page with "__NOTOC__ {{Server client function}} This function creates a blip that is attached to an element. This blip is displayed as an icon on the client's radar and will 'fo...")
 
No edit summary
 
(18 intermediate revisions by 3 users not shown)
Line 1: Line 1:
__NOTOC__  
__NOTOC__  
{{Server client function}}
{{Shared function hu}}
This function creates a [[blip]] that is attached to an [[element]]. This blip is displayed as an icon on the client's radar and will 'follow' the element that it is attached to around.
Ez a függvény létrehoz egy [[blip]]et, amely egy elemhez van rögzítve. Ez a blip egy ikonként látható a játékos radarán, ami követi azt az elemet, amihez rögzítve lett.


==Syntax==
==Szintaxis==
<section name="Server" class="server" show="true">
<section name="Server" class="server" show="true">
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
Line 17: Line 17:
{{OOP||[[Blip]].createAttachedTo||}}
{{OOP||[[Blip]].createAttachedTo||}}


===Required Arguments===  
===Kötelező argumentumok===  
*'''elementToAttachTo:''' The [[element]] to attach the marker to.
*'''elementToAttachTo:''' Az [[element|elem]], amihez a marker rögzül.


===Optional Arguments===  
===Tetszőleges argumentumok===  
{{OptionalArg}}  
{{OptionalArg hu}}  
*'''icon:''' The icon that the radar blips should be. Valid values can be seen at [[Blip Icons]]
 
*'''size:''' The size of the radar blip. Only applicable to the ''Marker'' icon. Default value is 2. Maximum is 25.
*'''icon:''' Az icon, mely a radar blipnek lennie kell. Az érvényes értékeket megtekintheti a [[Radar Blips]] oldalon.
*'''r:''' The amount of red in the blip's color (0 - 255). Only applicable to the ''Marker'' icon. Default is 255.  
*'''size:''' A radar blip mérete. Csak a "Marker" ikonra érvényes. Az alapértelmezett érték a 2, maximum a 25.
*'''g:''' The amount of green in the blip's color (0 - 255). Only applicable to the ''Marker'' icon. Default is 0.
*'''r:''' A piros mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 255.  
*'''b:''' The amount of blue in the blip's color (0 - 255). Only applicable to the ''Marker'' icon. Default is 0.
*'''g:''' A zöld mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 0.
*'''a:''' The amount of alpha in the blip's color (0 - 255). Only applicable to the ''Marker'' icon. Default is 255.
*'''b:''' A kék mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 0.
*'''a:''' Az telítettség mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 255.
{{New feature/item|3|1.0||
{{New feature/item|3|1.0||
*'''ordering:''' This defines the blip's Z-level ordering (-32768 - 32767). Default is 0.
*'''ordering:''' Leírja a blip, Z-tengelyen való helyét (-32768 - 32767). Az alapértelmezett érték a 0.
*'''visibleDistance:''' The maximum distance from the camera at which the blip is still visible (0-65535)
*'''visibleDistance:''' A maximális távolság a kamerától, ahol a blip még mindig látható (0-65535).|HU}}
}}
<section name="Server" class="server" show="true">
<section name="Server" class="server" show="true">
*'''visibleTo:''' What elements can see the blip. Defaults to visible to everyone. See [[visibility]].
*'''visibleTo:''' Mely elemek láthatják a blipet. Alapértelmezetten mindenkinek látható. Lásd [[visibility]].
</section>
</section>


===Returns===
===Visszaadott érték===
Returns a [[blip]] if the blip was created succesfully, or ''false'' otherwise.
Visszaad egy [[blip]]et, ha sikeresen létre lett hozva, egyébként ''false''.


==Example==  
==Példa==  
<section name="Server" class="server" show="true">
<section name="Server" class="server" show="true">
This example creates a radar blip attached to a random player, visible to everyone. The blip will follow the player around as they move. This could be used for manhunt, to emphasise a random player.
Ez a példa egy blipet hoz létre, amely egy random játékoshoz van rögzítve, és mindenki számára látható. A blip követni fogja a játékost ahogy az mozog. Használható akár embervadászásra, vagy egy random játékos kiemelésére.
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
-- Pick a random player
-- Pick a random player
Line 52: Line 52:
</section>
</section>


==See Also==
==Lásd még==
{{Blip_functions}}
{{Blip_functions_hu}}


[[en:createBlipAttachedTo]]
[[en:createBlipAttachedTo]]
[[hu:createBlipAttachedTo]]
[[pt-br:createBlipAttachedTo]]
[[ru:createBlipAttachedTo]]
[[ro:createBlipAttachedTo]]
==Fordította==
* '''''[https://wiki.multitheftauto.com/wiki/User:Surge Surge]'''''

Latest revision as of 21:11, 14 June 2021

Ez a függvény létrehoz egy blipet, amely egy elemhez van rögzítve. Ez a blip egy ikonként látható a játékos radarán, ami követi azt az elemet, amihez rögzítve lett.

Szintaxis

Click to collapse [-]
Server
blip createBlipAttachedTo ( element elementToAttachTo [, int icon = 0, int size = 2, int r = 255, int g = 0, int b = 0, int a = 255, int ordering = 0, float visibleDistance = 16383.0, visibleTo = getRootElement( ) ] )
Click to collapse [-]
Client
blip createBlipAttachedTo ( element elementToAttachTo [, int icon = 0, int size = 2, int r = 255, int g = 0, int b = 0, int a = 255, int ordering = 0, float visibleDistance = 16383.0 ] )


OOP Syntax Help! I don't understand this!

Method: Blip.createAttachedTo(...)


Kötelező argumentumok

  • elementToAttachTo: Az elem, amihez a marker rögzül.

Tetszőleges argumentumok

Megjegyzés: Amikor tetszőleges paramétereket használ, előfordulhat, hogy az összes paramétert meg kell adnia, mielőtt egyet is használna. További információkért látogassa meg a tetszőleges paraméterek oldalt.

  • icon: Az icon, mely a radar blipnek lennie kell. Az érvényes értékeket megtekintheti a Radar Blips oldalon.
  • size: A radar blip mérete. Csak a "Marker" ikonra érvényes. Az alapértelmezett érték a 2, maximum a 25.
  • r: A piros mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 255.
  • g: A zöld mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 0.
  • b: A kék mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 0.
  • a: Az telítettség mennyisége a blip színében (0 - 255). Csak a "Marker" ikonra érvényes. Az alapértelmezett érték 255.
  • ordering: Leírja a blip, Z-tengelyen való helyét (-32768 - 32767). Az alapértelmezett érték a 0.
  • visibleDistance: A maximális távolság a kamerától, ahol a blip még mindig látható (0-65535).
Click to collapse [-]
Server
  • visibleTo: Mely elemek láthatják a blipet. Alapértelmezetten mindenkinek látható. Lásd visibility.

Visszaadott érték

Visszaad egy blipet, ha sikeresen létre lett hozva, egyébként false.

Példa

Click to collapse [-]
Server

Ez a példa egy blipet hoz létre, amely egy random játékoshoz van rögzítve, és mindenki számára látható. A blip követni fogja a játékost ahogy az mozog. Használható akár embervadászásra, vagy egy random játékos kiemelésére.

-- Pick a random player
function setupRandomRobber ()
	local myPlayer = getRandomPlayer ()
	-- Create a radar blip at the player's position, with a 'cash' icon and only visible to everyone (no 'visibleTo' parameter)
	local myBlip = createBlipAttachedTo ( myPlayer, 52 )
end

Lásd még

Fordította