/
index.php
200 lines (173 loc) · 5.53 KB
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
<?php
/*
* Index Page for ScummVM
* by Jeremy Newman <jnewman@dracowulf.com>
*
*/
// set this for position of this file relative
$file_root = ".";
// load libraries
require($file_root."/include/"."incl.php");
require($file_root."/include/"."screenshots.php");
// start of html
html_header("ScummVM", '<script src="'.$file_root.'/screenshots.js" type="text/javascript"></script>');
sidebar_start();
$shownews = isset($_GET['shownews']) ? 1 : 0;
// display welcome table
// don't show this if we are in news mode
if (!$shownews)
{
// counter vars
srand((double) microtime() * 1000000);
// Make LEC games appear in 60% of total shots
$lastLECshot = 55;
$randPart = rand(0, 10);
if ($randPart < 6) {
$randImg = rand(0, $lastLECshot - 1);
} else {
$randImg = $lastLECshot + rand(0, $screenshots_count - $lastLECshot - 1);
}
echo html_round_frame_start("About ScummVM","");
?>
<script type="text/javascript">
<!--
i_jn = <?=$randImg?>;
//-->
</script>
<table width="100%" border=0 cellpadding=10 cellspacing=0>
<tr valign="top">
<td>
<h1>What is <span style="color: green">Scumm</span>VM?</h1>
<p>
ScummVM is a program which allows you to run certain classic graphical point-and-click adventure
games, provided you already have their data files. The clever part about this: ScummVM just replaces
the executables shipped with the game, allowing you to play them on systems for which they were never designed!
</p>
<p>
ScummVM lets you run these adventures: <a href="http://www.adventuresoft.com">Adventure Soft</a>'s
<i>Simon the Sorcerer</i> 1 and 2; <a href="http://www.revolution.co.uk">Revolution</a>'s
<i>Beneath A Steel Sky</i>, <i>Broken Sword 1</i> and <i>Broken Sword 2</i>;
<i>Flight of the Amazon Queen</i>;
<a href="http://www.wyrmkeep.com/ite/">Wyrmkeep</a>'s <i>Inherit the Earth</i>;
Coktel Vision's <i>Gobliiins</i>
and games based on <a href="http://www.lucasarts.com">LucasArts</a>'
<span style="color: green">SCUMM</span> <span style="color: #666666">(<i>Script Creation Utility for Maniac
Mansion</i>)</span> system. <span style="color: green">SCUMM</span> is used for many games,
including <i>Monkey Island</i>, <i>Day of the Tentacle</i>, <i>Sam and Max</i> and more.
Compatibility with supported games is continually improving, so check back often.
</p>
<p>
Among the systems on which you can play those games are Windows, Linux, Mac OS X, Dreamcast, PocketPC,
PalmOS, AmigaOS, BeOS, OS/2, PSP, PS2, SymbianOS/EPOC and many more...
</p>
<p>
Our forum and IRC channel, <a href="irc://irc.freenode.net/scummvm">#scummvm on
irc.freenode.net</a>, are open for comments and suggestions. Please read our <a href="faq.php">FAQ</a>
before posting, particularly regarding support for other adventure games.
</p>
</td>
<td>
<table border=0 cellpadding=0 cellspacing=0>
<tr><td colspan="3">
<!-- We use a height of 483 instead of 480 to workaround something which
appears to be a bug in Mozilla? -->
<a href="javascript:openWin('./screenshots/big_scummvm_'+i_jn+'.png','scummvm',640,483);"
onMouseOver="window.status='Click to View Full Size Image';return true;"
onMouseOut="window.status='';return true;"><img
src="<?=screenshot_thumb_path($randImg)?>" width="<?=$thumb_w?>" height="<?=$thumb_h?>"
style="margin: 5px"
name="img_jn" alt="Click to view Full Size"></a>
</td></tr>
<tr>
<td align=left>
<a href="javascript:scrshot_jn(<?=$screenshots_count?>,-1);"><< Previous</a>
</td>
<td></td>
<td align=right>
<a href="javascript:scrshot_jn(<?=$screenshots_count?>,+1);">Next >></a>
</td>
</tr>
</table>
</td>
</tr>
</table>
<?php
echo html_round_frame_end(" "),html_br();
}
// end of welcome table
//display News
echo html_round_frame_start("Latest Developments","");
echo html_frame_start("","100%",1,1);
// get list of news items
$news = get_files($file_root."/news","xml");
$news = array_reverse ($news);
// loop and display news
$c = 0;
while (list($key,$item) = each($news))
{
$c++;
// Load news item (it's in a pseudo XML format).
$file = $file_root."/news/".$item;
if (file_exists($file))
{
$fp = @fopen($file, "r");
$data = fread($fp, filesize($file));
@fclose($fp);
$news_date = "";
if (eregi("<DATE>(.*)</DATE>", $data, $out))
{
$news_date = $out[1];
}
$news_author = "";
if (eregi("<AUTHOR>(.*)</AUTHOR>", $data, $out))
{
$news_author = "Posted by ".$out[1];
}
$news_title = "";
if (eregi("<NAME>(.*)</NAME>", $data, $out))
{
$news_title = $out[1];
}
$news_img = "";
if (eregi("<IMG>(.*)</IMG>", $data, $out))
{
$news_img = $out[1];
}
$news_body = "";
if (eregi("<BODY>(.*)</BODY>", $data, $out))
{
$news_body = $out[1];
}
}
// Display news item
echo html_frame_tr(
html_frame_td(
'<div class="news-item">'.
'<div class="news-header">'.
'<span class="date">'.$news_date."</span>: ".
$news_title.
'</div>'.
'<span class="news-author">'.$news_author."</span> ".
$news_img.
'<div class="news-body">'.$news_body.'</div>'.
'</div>'
)
);
// Only show first five records, unless we are in "news" mode
if ($c == 4 && !$shownews)
{
echo html_frame_tr(
html_frame_td(
'<p>[<a href="?shownews=archive">More News...</a>]</p>'."\n"
)
);
break;
}
} // end of news loop
echo html_frame_end();
echo html_round_frame_end(" ");
//end of news display
// end of html
sidebar_end();
html_footer();
?>