- This wiki is out of date, use the continuation of this wiki instead
Scroll
From FenixWiki
Contents |
Definition
STRUCT[9] Scroll
Scroll is a global variable struct array, containing information about the current state of the ten available scrolls (0..9). It is used to influence the settings of a scroll window, initiated by start_scroll().
Members of one Struct
Member name | - Description |
INT x0 | - The X-coordinate of the foreground graphic.* |
INT y0 | - The Y-coordinate of the foreground graphic.* |
INT x1 | - The X-coordinate of the the background graphic.* |
INT y1 | - The Y-coordinate of the the background graphic.* |
INT z | - The Z-coordinate of the scroll window (default: 512). |
INT camera | - The processID of the process to be followed (default: 0).** |
INT ratio | - The ratio in percent the foreground will move related to the background (default: 200).**,*** |
INT speed | - The maximum speed of the foreground, 0 for no limit (default: 0).** |
INT region1 | - The region in which the scroll won't move, -1 for none (default: -1).** |
INT region2 | - The region in which the maximum speed is ignored, -1 for none (default: -1).** |
INT flags1 | - The bit flags for the foreground graphic. |
INT flags2 | - The bit flags for the background graphic. |
INT follow | - The scrollID of the scroll window to follow, -1 means none (default: -1). |
INT[6] reserved | - Seven reserved integers. |
* | - These fields become read only when the scroll window is in automatic mode. |
** | - These fields only make sense when the scroll window is in automatic mode. |
*** | - The ratio is in percent: 200 means the background moves twice as slow. |
Notes
There are two main method of controlling a scroll window. One is the manual way, thus changing the values of the x0,y0,x1 and y1 manually. This mode is used when the camera field is not set (is 0). When it is set with a processID, the scroll window is in automatic mode and will follow that process' coordinates and will try to keep it centered. This can be influenced by other members of the scroll struct. The foreground is the plane to be controlled and the background moves relative to the foreground.
Example
Global variables | |
• Argc • Argv • Cdinfo • Dump_type • Fading • Fileinfo • Fps • Frame_time • Full_screen • Graph_mode • Mouse • Os_id • Restore_type • Scale_mode • Scroll • Sound_channels • Sound_freq • Sound_mode • Text_flags • Text_z • Timer • |