Перейти к содержанию

Vehicle::getColorRGB

Материал из RAGE MP Wiki Archive
Версия от 16:48, 15 января 2018; imported>Randomz (Example)
(разн.) ← Предыдущая версия | Текущая версия (разн.) | Следующая версия → (разн.)

This function used to get the vehicle RGB body color. Returns null if never set explicitly.

Syntax

<syntaxhighlight lang="javascript"> Array vehicle.getColorRGB(int slot); </syntaxhighlight>

Required Arguments

  • slot: The color you want to get. (valid is 0 or 1)

Example

<syntaxhighlight lang="javascript"> let primaryColor = vehicle.getColorRGB(0); let secondaryColor = vehicle.getColorRGB(1); // primaryColor output: [ 255, 0, 0 ] </syntaxhighlight>

See Also

Шаблон:Vehicle block