1 // ----------------------------------------------------------------------------
3 // ----------------------------------------------------------------------------
7 static char *VB_Name = "modDisplay";
10 int ScreenScrollXPos, ScreenScrollYPos;
11 int ScreenPosition, data_h_Xtmp, data_h_Ytmp;
13 int ShowRedDiskCounter, ShowPanel;
15 boolean NoDisplayFlag;
17 long DisplayMinX, DisplayMaxX, DisplayWidth;
18 long DisplayMinY, DisplayMaxY, DisplayHeight;
21 int subDisplayInfotronsNeeded()
23 int subDisplayInfotronsNeeded;
26 return subDisplayInfotronsNeeded;
30 MainForm.lblInfoCount.Caption = InfotronsNeeded;
31 MainForm.lblInfoCount.Refresh;
35 return subDisplayInfotronsNeeded;
38 int subDisplayPlayingTime()
40 int subDisplayPlayingTime;
43 return subDisplayPlayingTime;
50 if (NoDisplayFlag || ! LevelLoaded)
51 return subDisplayLevel;
54 MainForm.DisplayLevel();
57 return subDisplayLevel;
60 void subDisplayPanel()
64 int subCheckRestoreRedDiskCountDisplay()
66 int subCheckRestoreRedDiskCountDisplay;
69 return subCheckRestoreRedDiskCountDisplay;
71 if (ShowRedDiskCounter == 0)
72 return subCheckRestoreRedDiskCountDisplay;
74 ShowRedDiskCounter = ShowRedDiskCounter - 1;
75 if (ShowRedDiskCounter == 0)
79 MainForm.lblRedDiskCount.Caption = 0;
80 MainForm.lblRedDiskCount.Refresh;
85 return subCheckRestoreRedDiskCountDisplay;
88 void subDisplayRedDiskCount()
95 MainForm.lblRedDiskCount.Caption = RedDiskCount;
96 MainForm.lblRedDiskCount.Refresh;
99 ShowRedDiskCounter = 0x46;
102 void ScrollTo(int X, int Y)
111 X = ScrollDelta * (X / ScrollDelta);
112 X = Max(X, ScrollMinX);
113 X = Min(X, ScrollMaxX);
114 Y = ScrollDelta * (Y / ScrollDelta);
115 Y = Max(Y, ScrollMinY);
116 Y = Min(Y, ScrollMaxY);
119 Stage.ScrollTo(X, Y);
122 void ScrollTowards(int X, int Y)
131 X = ScrollDelta * (X / ScrollDelta);
132 X = Max(X, ScrollMinX);
133 X = Min(X, ScrollMaxX);
134 Y = ScrollDelta * (Y / ScrollDelta);
135 Y = Max(Y, ScrollMinY);
136 Y = Min(Y, ScrollMaxY);
139 Stage.ScrollTowards(X, Y, 2 * Stretch);
142 void SoftScrollTo(int X, int Y, long TimeMS, int FPS)
151 X = ScrollDelta * (X / ScrollDelta);
152 X = Max(X, ScrollMinX);
153 X = Min(X, ScrollMaxX);
154 Y = ScrollDelta * (Y / ScrollDelta);
155 Y = Max(Y, ScrollMinY);
156 Y = Min(Y, ScrollMaxY);
159 Stage.SoftScrollTo(X, Y, TimeMS, FPS);