Difference between revisions of "0165"

From GTAMods Wiki
Jump to navigation Jump to search
m
(extended colors)
Line 11: Line 11:
 
:: Color (0 to 6, [[#Blip colors|see below]])
 
:: Color (0 to 6, [[#Blip colors|see below]])
  
This opcode changes the color of the blip. The color of the blip is determined by a predefined list and whether the blip is [[0166|dim]]. Values outside the available range of colors will produce a black blip. The opcode has no effect on sprites.
+
This opcode changes the color of the blip. The color of the blip is determined by a predefined list and whether the blip is [[0166|dim]]. [[#Extended colors|See below]] for values outside the range of the list. The opcode has no effect on sprites.
  
 
== Blip colors ==
 
== Blip colors ==
Line 47: Line 47:
 
|style="background-color: #007F7F; color: white;" |#007F7F
 
|style="background-color: #007F7F; color: white;" |#007F7F
 
|}
 
|}
 +
 +
== Extended colors ==
 +
It is possible to use any color in the RGB color space as the color of the blip. The color parameter accepts any value in RGBA, allowing values between 7 and {{Hint|0xFFFFFFFF|4,294,967,295}}. The opacity is ignored by the game and the blip's dim property does not affect the color. The following example creates an orange blip at the center of the world.
 +
<syntaxhighlight lang="scm">
 +
018A: 0@ = create_checkpoint_at 0.0 0.0 0.0
 +
0165: set_marker 0@ color_to 0xFF8000FF
 +
</syntaxhighlight>
  
 
== Keywords ==
 
== Keywords ==

Revision as of 05:15, 1 September 2015

GTA III Vice City San Andreas CHANGE_BLIP_COLOUR


Description

Changes the blip color

Syntax

0165: set_marker [blip handle] color_to [int]

Parameter

[blip handle]
The handle of the blip
[int]
Color (0 to 6, see below)

This opcode changes the color of the blip. The color of the blip is determined by a predefined list and whether the blip is dim. See below for values outside the range of the list. The opcode has no effect on sprites.

Blip colors

The following lists all blip colors available in GTA III and Vice City. The first color is the normal color and the second is the dimmed color.

Color Enum Hex
0 RED #712B49
#7F0000
1 GREEN #5FA06A
#007F00
2 BLUE #80A7F3
#00007F
3 WHITE #E1E1E1
#7F7F7F
4 YELLOW #FFFF00
#7F7F00
5 PURPLE #FF00FF
#7F007F
6 CYAN #00FFFF
#007F7F

Extended colors

It is possible to use any color in the RGB color space as the color of the blip. The color parameter accepts any value in RGBA, allowing values between 7 and 0xFFFFFFFF. The opacity is ignored by the game and the blip's dim property does not affect the color. The following example creates an orange blip at the center of the world.

018A: 0@ = create_checkpoint_at 0.0 0.0 0.0
0165: set_marker 0@ color_to 0xFF8000FF

Keywords

set, change, marker, blip, color, colour