Player::eyeColor: Difference between revisions

From RAGE Multiplayer Wiki
m (Replaced HTML with template)
m (category)
 
(One intermediate revision by one other user not shown)
Line 2: Line 2:
== Syntax ==
== Syntax ==
<pre>
<pre>
player.eyeColor;
Number player.eyeColor;
</pre>
</pre>


Line 18: Line 18:
==See Also==
==See Also==
{{Player_block}}
{{Player_block}}
[[Category:Player Appearance]]
[[Category:Server-side Property]]

Latest revision as of 13:13, 30 April 2019

Sets/gets the players eye color

Syntax

Number player.eyeColor;

Examples

This lets you set the eye color of your player and will output the value of the players eye color in the chat.

Server-Side
mp.events.addCommand('eyecolor', (player, _, id) => {
    player.eyeColor = parseInt(id);
    player.outputChatBox("Eye Color: " + eColor);
});

See Also