e1fce3757293a3a9d3be55d89c8f6213589fe812
2 Copyright (C) Prikol Software 1996-1997
3 Copyright (C) Aleksey Volynskov 1996-1997
4 Copyright (C) <ARembo@gmail.com> 2011
6 This file is part of the Doom2D:Rembo project.
8 Doom2D:Rembo is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License version 2 as
10 published by the Free Software Foundation.
12 Doom2D:Rembo is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, see <http://www.gnu.org/licenses/> or
19 write to the Free Software Foundation, Inc.,
20 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 ///#include <process.h>
48 char main_pal
[256][3],std_pal
[256][3];
49 byte mixmap
[256][256];
52 void logo(const char *s
,...) {
62 void logo_gas(int cur
,int all
) {
69 void setgamma(int g
) {
76 std_pal
[t
][0]=gamcor
[gammaa
][main_pal
[t
][0]];
77 std_pal
[t
][1]=gamcor
[gammaa
][main_pal
[t
][1]];
78 std_pal
[t
][2]=gamcor
[gammaa
][main_pal
[t
][2]];
83 void myrandomize(void);
87 int main(int argc
, char *argv
[]) {
88 if (SDL_Init(SDL_INIT_VIDEO
)<0) ERR_failinit("Unable to init SDL: %s\n", SDL_GetError());
89 SDL_WM_SetCaption("Doom 2D v1.351", "Doom 2D");
116 pw
= "/usr/share/doom2d-rembo/doom2d.wad";
123 F_addwad("doom2d.wad");
124 CFG_args(argc
, argv
);
129 F_loadres(F_getresid("PLAYPAL"),main_pal
,0,768);
131 bright
[i
]=((int)main_pal
[i
][0]+main_pal
[i
][1]+main_pal
[i
][2])*8/(63*3);
132 F_loadres(F_getresid("MIXMAP"),mixmap
,0,0x10000);
133 F_loadres(F_getresid("COLORMAP"),clrmap
,0,256*12);
136 logo("S_init: настройка звука\n");
139 logo("V_init: настройка видео\n");
140 if(V_init()!=0) ERR_failinit("Не могу установить видеорежим VGA");
144 F_loadmus("MENU");S_startmusic(0);
158 while ((t
= SDL_GetTicks())-ticks
< DELAY
) {
161 ticks
= t
- t
% DELAY
;