256 Colour Tutorial Part 2(V2.62): Difference between revisions

Line 20: Line 20:


Now, how does this function work? Read the manual first:
Now, how does this function work? Read the manual first:
  '''CyclePalette'''
<blockquote>
  CyclePalette (int start, int end)
'''CyclePalette'''<br>
  This is used for special effects, like the flowing colours on the Space
CyclePalette (int start, int end)<br><br>
  Quest 4 title screen, and the Sierra logo of the later Sierra games.
This is used for special effects, like the flowing colours on the Space Quest 4 title screen, and the Sierra logo of the later Sierra games.<br>
  The palette indexes from START to END are cycled around one slot.
The palette indexes from START to END are cycled around one slot.<br>
  Using this call in a repeatedly_execute function gives the effect of
Using this call in a repeatedly_execute function gives the effect of animation.<br><br>
  animation.
'''NOTE:''' This command only works in 256-colour games.
  '''NOTE:''' This command only works in 256-colour games.
</blockquote>
 
(You may have noticed, that I omitted a paragraph from the manual text, which was about the colours cycling in both directions. I did that because there's a bug in AGS which prevents the colour cycling in backward direction to work properly, this bug is fixed in AGS V2.71.)
(You may have noticed, that I omitted a paragraph from the manual text, which was about the colours cycling in both directions. I did that because there's a bug in AGS which prevents the colour cycling in backward direction to work properly, this bug is fixed in AGS V2.71.)