ES/SetElementPosition: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Created page with "__NOTOC__ {{Server client function}} Esta función cambia la posición del elemento a las coordenadas seleccionadas. ==Syntax== <syntaxhighlight lang="lua"> bool setElementPosition ( element ...")
 
No edit summary
 
(One intermediate revision by the same user not shown)
Line 106: Line 106:
==See Also==
==See Also==
{{Element functions}}
{{Element functions}}
==Traductor==
*Pekio123
[[es:setElementPosition]]

Latest revision as of 02:48, 9 December 2012

Esta función cambia la posición del elemento a las coordenadas seleccionadas.

Syntax

bool setElementPosition ( element theElement, float x, float y, float z [, bool warp = true ] )  

Argumentos obligatorios

  • theElement: El [Elemento] a mover
  • x: La coordenada X de el destino
  • y: La coordenada Y de el destino
  • z: La coordenada Z de el destino

Argumentos opcionales

  • warp: Teleportar a los jugador, esto hace que las animaciones ejecutadas en el momento de teleportacion se apaguen usar false para no paralas.

Returns

Envia true si la función se completo, false si no se completo.

Example

Click to collapse [-]
Example 1

This example adds a "setpos" command to console, which allows setting of a player's position.

function consoleSetPlayerPosition ( source, commandName, posX, posY, posZ )
	setElementPosition ( source, posX, posY, posZ )
end
addCommandHandler ( "setpos", consoleSetPlayerPosition  )
Click to expand [+]
Example 2
Click to expand [+]
Example 3

See Also

Shared


Traductor

  • Pekio123