mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-11-10 13:09:43 +01:00
Compare commits
10 commits
f06701ff90
...
b5ef10cae5
Author | SHA1 | Date | |
---|---|---|---|
|
b5ef10cae5 | ||
|
46d8599f62 | ||
|
d9fff2a8c3 | ||
|
a32fc4a307 | ||
|
afba320083 | ||
|
adbab6355b | ||
|
626aac59fb | ||
|
4d7baa9e9e | ||
|
ee0ba8a723 | ||
|
07cc5f68ac |
10 changed files with 105 additions and 100 deletions
|
@ -171,10 +171,13 @@ void Game::init(void)
|
|||
|
||||
nodeathmode = false;
|
||||
nocutscenes = false;
|
||||
ndmresultcrewrescued = 0;
|
||||
ndmresulttrinkets = 0;
|
||||
|
||||
customcol=0;
|
||||
|
||||
SDL_memset(crewstats, false, sizeof(crewstats));
|
||||
SDL_memset(ndmresultcrewstats, false, sizeof(ndmresultcrewstats));
|
||||
SDL_memset(tele_crewstats, false, sizeof(tele_crewstats));
|
||||
SDL_memset(quick_crewstats, false, sizeof(quick_crewstats));
|
||||
SDL_memset(besttimes, -1, sizeof(besttimes));
|
||||
|
@ -227,6 +230,10 @@ void Game::init(void)
|
|||
timetrialpar = 0;
|
||||
timetrialresulttime = 0;
|
||||
timetrialresultframes = 0;
|
||||
timetrialresultshinytarget = 0;
|
||||
timetrialresulttrinkets = 0;
|
||||
timetrialresultpar = 0;
|
||||
timetrialresultdeaths = 0;
|
||||
|
||||
totalflips = 0;
|
||||
hardestroom = "Welcome Aboard";
|
||||
|
@ -1288,6 +1295,7 @@ void Game::updatestate()
|
|||
break;
|
||||
case 81:
|
||||
quittomenu();
|
||||
music.play(6); //should be after quittomenu()
|
||||
state = 0;
|
||||
break;
|
||||
|
||||
|
@ -1295,8 +1303,14 @@ void Game::updatestate()
|
|||
//Time Trial Complete!
|
||||
obj.removetrigger(82);
|
||||
hascontrol = false;
|
||||
|
||||
timetrialresulttime = seconds + (minutes * 60) + (hours * 60 * 60);
|
||||
timetrialresultframes = frames;
|
||||
timetrialresulttrinkets = trinkets();
|
||||
timetrialresultshinytarget = timetrialshinytarget;
|
||||
timetrialresultpar = timetrialpar;
|
||||
timetrialresultdeaths = deathcounts;
|
||||
|
||||
timetrialrank = 0;
|
||||
if (timetrialresulttime <= timetrialpar) timetrialrank++;
|
||||
if (trinkets() >= timetrialshinytarget) timetrialrank++;
|
||||
|
@ -1309,7 +1323,7 @@ void Game::updatestate()
|
|||
besttimes[timetriallevel] = timetrialresulttime;
|
||||
bestframes[timetriallevel] = timetrialresultframes;
|
||||
}
|
||||
if (trinkets() > besttrinkets[timetriallevel] || besttrinkets[timetriallevel]==-1)
|
||||
if (timetrialresulttrinkets > besttrinkets[timetriallevel] || besttrinkets[timetriallevel]==-1)
|
||||
{
|
||||
besttrinkets[timetriallevel] = trinkets();
|
||||
}
|
||||
|
@ -1341,11 +1355,7 @@ void Game::updatestate()
|
|||
if(graphics.fademode == 1) state++;
|
||||
break;
|
||||
case 84:
|
||||
graphics.flipmode = false;
|
||||
gamestate = TITLEMODE;
|
||||
graphics.fademode = 4;
|
||||
graphics.backgrounddrawn = true;
|
||||
graphics.titlebg.tdrawback = true;
|
||||
quittomenu();
|
||||
createmenu(Menu::timetrialcomplete);
|
||||
state = 0;
|
||||
break;
|
||||
|
@ -1871,7 +1881,6 @@ void Game::updatestate()
|
|||
if(!muted && ed.levmusic>0) music.fadeMusicVolumeIn(3000);
|
||||
}
|
||||
graphics.showcutscenebars = false;
|
||||
returntomenu(Menu::levellist);
|
||||
break;
|
||||
#endif
|
||||
case 1014:
|
||||
|
@ -1896,6 +1905,7 @@ void Game::updatestate()
|
|||
}
|
||||
#endif
|
||||
quittomenu();
|
||||
music.play(6); //should be after quittomenu()
|
||||
state = 0;
|
||||
break;
|
||||
|
||||
|
@ -2852,7 +2862,6 @@ void Game::updatestate()
|
|||
{
|
||||
graphics.fademode = 2;
|
||||
companion = 0;
|
||||
returnmenu();
|
||||
state=3100;
|
||||
}
|
||||
else
|
||||
|
@ -2883,7 +2892,6 @@ void Game::updatestate()
|
|||
state++;
|
||||
graphics.fademode = 2;
|
||||
music.fadeout();
|
||||
returnmenu();
|
||||
state=3100;
|
||||
}
|
||||
else
|
||||
|
@ -2909,44 +2917,15 @@ void Game::updatestate()
|
|||
if(graphics.fademode == 1) state++;
|
||||
break;
|
||||
case 3101:
|
||||
graphics.flipmode = false;
|
||||
gamestate = TITLEMODE;
|
||||
graphics.fademode = 4;
|
||||
graphics.backgrounddrawn = true;
|
||||
graphics.titlebg.tdrawback = true;
|
||||
music.play(6);
|
||||
quittomenu();
|
||||
music.play(6); //should be after quittomenu();
|
||||
state = 0;
|
||||
break;
|
||||
|
||||
//startscript = true; newscript="returntohub";
|
||||
//state = 0;
|
||||
|
||||
/*case 3025:
|
||||
if (recording == 1) {
|
||||
//if recording the input, output it to debug here
|
||||
trace(recordstring);
|
||||
help.toclipboard(recordstring);
|
||||
}
|
||||
test = true; teststring = recordstring;
|
||||
graphics.createtextbox(" Congratulations! ", 50, 80, 164, 164, 255);
|
||||
graphics.addline("");
|
||||
graphics.addline("Your play of this level has");
|
||||
graphics.addline("been copied to the clipboard.");
|
||||
graphics.addline("");
|
||||
graphics.addline("Please consider pasting and");
|
||||
graphics.addline("sending it to me! Even if you");
|
||||
graphics.addline("made a lot of mistakes - knowing");
|
||||
graphics.addline("exactly where people are having");
|
||||
graphics.addline("trouble is extremely useful!");
|
||||
graphics.textboxcenter();
|
||||
state = 0;
|
||||
break;*/
|
||||
|
||||
case 3500:
|
||||
music.fadeout();
|
||||
state++;
|
||||
statedelay = 120;
|
||||
//state = 3511; //testing
|
||||
break;
|
||||
case 3501:
|
||||
//Game complete!
|
||||
|
@ -3243,11 +3222,8 @@ void Game::updatestate()
|
|||
if(graphics.fademode == 1) state++;
|
||||
break;
|
||||
case 3522:
|
||||
graphics.flipmode = false;
|
||||
gamestate = TITLEMODE;
|
||||
graphics.fademode = 4;
|
||||
graphics.backgrounddrawn = true;
|
||||
graphics.titlebg.tdrawback = true;
|
||||
copyndmresults();
|
||||
quittomenu();
|
||||
createmenu(Menu::nodeathmodecomplete);
|
||||
state = 0;
|
||||
break;
|
||||
|
@ -6997,9 +6973,7 @@ void Game::quittomenu()
|
|||
{
|
||||
gamestate = TITLEMODE;
|
||||
graphics.fademode = 4;
|
||||
FILESYSTEM_unmountassets(); // should be before music.play(6)
|
||||
music.play(6);
|
||||
graphics.backgrounddrawn = false;
|
||||
FILESYSTEM_unmountassets();
|
||||
graphics.titlebg.tdrawback = true;
|
||||
graphics.flipmode = false;
|
||||
//Don't be stuck on the summary screen,
|
||||
|
@ -7019,9 +6993,17 @@ void Game::quittomenu()
|
|||
returntomenu(Menu::playmodes);
|
||||
}
|
||||
else if (map.custommode)
|
||||
{
|
||||
if (map.custommodeforreal)
|
||||
{
|
||||
returntomenu(Menu::levellist);
|
||||
}
|
||||
else
|
||||
{
|
||||
//Returning from editor
|
||||
returntomenu(Menu::playerworlds);
|
||||
}
|
||||
}
|
||||
else if (save_exists() || anything_unlocked())
|
||||
{
|
||||
returntomenu(Menu::play);
|
||||
|
@ -7138,3 +7120,11 @@ void Game::mapmenuchange(const int newgamestate)
|
|||
}
|
||||
graphics.oldmenuoffset = graphics.menuoffset;
|
||||
}
|
||||
|
||||
void Game::copyndmresults()
|
||||
{
|
||||
ndmresultcrewrescued = crewrescued();
|
||||
ndmresulttrinkets = trinkets();
|
||||
ndmresulthardestroom = hardestroom;
|
||||
SDL_memcpy(ndmresultcrewstats, crewstats, sizeof(ndmresultcrewstats));
|
||||
}
|
||||
|
|
|
@ -290,11 +290,17 @@ public:
|
|||
bool nodeathmode;
|
||||
int gameoverdelay;
|
||||
bool nocutscenes;
|
||||
int ndmresultcrewrescued;
|
||||
int ndmresulttrinkets;
|
||||
std::string ndmresulthardestroom;
|
||||
void copyndmresults();
|
||||
|
||||
//Time Trials
|
||||
bool intimetrial, timetrialparlost;
|
||||
int timetrialcountdown, timetrialshinytarget, timetriallevel;
|
||||
int timetrialpar, timetrialresulttime, timetrialresultframes, timetrialrank;
|
||||
int timetrialresultshinytarget, timetrialresulttrinkets, timetrialresultpar;
|
||||
int timetrialresultdeaths;
|
||||
|
||||
int creditposition;
|
||||
int oldcreditposition;
|
||||
|
@ -304,6 +310,7 @@ public:
|
|||
|
||||
static const int numcrew = 6;
|
||||
bool crewstats[numcrew];
|
||||
bool ndmresultcrewstats[numcrew];
|
||||
|
||||
bool alarmon;
|
||||
int alarmdelay;
|
||||
|
|
|
@ -76,6 +76,7 @@ static SDL_Surface* LoadImage(const char *filename, bool noBlend = true, bool no
|
|||
}
|
||||
else
|
||||
{
|
||||
SDL_free(data);
|
||||
fprintf(stderr,"Image not found: %s\n", filename);
|
||||
SDL_assert(0 && "Image not found! See stderr.");
|
||||
return NULL;
|
||||
|
|
|
@ -2117,6 +2117,7 @@ void mapinput()
|
|||
else
|
||||
{
|
||||
game.quittomenu();
|
||||
music.play(6); //should be after game.quittomenu()
|
||||
game.fadetomenu = false;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -113,13 +113,9 @@ void gamecompletelogic2()
|
|||
game.savetele();
|
||||
music.currentsong=tmp;
|
||||
//Return to game
|
||||
graphics.titlebg.colstate = 10;
|
||||
game.gamestate = TITLEMODE;
|
||||
graphics.fademode = 4;
|
||||
FILESYSTEM_unmountassets(); // should be before music.playef(18)
|
||||
music.playef(18);
|
||||
game.returntomenu(Menu::play);
|
||||
game.quittomenu();
|
||||
game.createmenu(Menu::gamecompletecontinue);
|
||||
graphics.titlebg.colstate = 10;
|
||||
map.nexttowercolour();
|
||||
}
|
||||
}
|
||||
|
@ -449,7 +445,11 @@ void gamelogic()
|
|||
game.gethardestroom();
|
||||
//start depressing sequence here...
|
||||
if (game.gameoverdelay <= -10 && graphics.fademode==0) graphics.fademode = 2;
|
||||
if (graphics.fademode == 1) script.resetgametomenu();
|
||||
if (graphics.fademode == 1)
|
||||
{
|
||||
game.copyndmresults();
|
||||
script.resetgametomenu();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -686,22 +686,22 @@ static void menurender()
|
|||
{
|
||||
graphics.bigprint( -1, 25, "GAME OVER", tr, tg, tb, true, 3);
|
||||
|
||||
for (int i = 0; i < 6; i++)
|
||||
for (size_t i = 0; i < SDL_arraysize(game.ndmresultcrewstats); i++)
|
||||
{
|
||||
graphics.drawcrewman(169-(3*42)+(i*42), 68, i, game.crewstats[i], true);
|
||||
graphics.drawcrewman(169-(3*42)+(i*42), 68, i, game.ndmresultcrewstats[i], true);
|
||||
}
|
||||
std::string tempstring;
|
||||
tempstring = "You rescued " + help.number(game.crewrescued()) + (game.crewrescued() == 1 ? " crewmate" : " crewmates");
|
||||
tempstring = "You rescued " + help.number(game.ndmresultcrewrescued) + (game.ndmresultcrewrescued == 1 ? " crewmate" : " crewmates");
|
||||
graphics.Print(0, 100, tempstring, tr, tg, tb, true);
|
||||
|
||||
tempstring = "and found " + help.number(game.trinkets()) + (game.trinkets() == 1 ? " trinket." : " trinkets.");
|
||||
tempstring = "and found " + help.number(game.ndmresulttrinkets) + (game.ndmresulttrinkets == 1 ? " trinket." : " trinkets.");
|
||||
graphics.Print(0, 110, tempstring, tr, tg, tb, true);
|
||||
|
||||
tempstring = "You managed to reach:";
|
||||
graphics.Print(0, 145, tempstring, tr, tg, tb, true);
|
||||
graphics.Print(0, 155, game.hardestroom, tr, tg, tb, true);
|
||||
graphics.Print(0, 155, game.ndmresulthardestroom, tr, tg, tb, true);
|
||||
|
||||
switch (game.crewrescued())
|
||||
switch (game.ndmresultcrewrescued)
|
||||
{
|
||||
case 1:
|
||||
tempstring = "Keep trying! You'll get there!";
|
||||
|
@ -731,14 +731,14 @@ static void menurender()
|
|||
{
|
||||
graphics.bigprint( -1, 8, "WOW", tr, tg, tb, true, 4);
|
||||
|
||||
for (int i = 0; i < 6; i++)
|
||||
for (size_t i = 0; i < SDL_arraysize(game.ndmresultcrewstats); i++)
|
||||
{
|
||||
graphics.drawcrewman(169-(3*42)+(i*42), 68, i, game.crewstats[i], true);
|
||||
graphics.drawcrewman(169-(3*42)+(i*42), 68, i, game.ndmresultcrewstats[i], true);
|
||||
}
|
||||
std::string tempstring = "You rescued all the crewmates!";
|
||||
graphics.Print(0, 100, tempstring, tr, tg, tb, true);
|
||||
|
||||
tempstring = "And you found " + help.number(game.trinkets()) + " trinkets.";
|
||||
tempstring = "And you found " + help.number(game.ndmresulttrinkets) + " trinkets.";
|
||||
graphics.Print(0, 110, tempstring, tr, tg, tb, true);
|
||||
|
||||
graphics.Print(0, 160, "A new trophy has been awarded and", tr, tg, tb, true);
|
||||
|
@ -752,30 +752,30 @@ static void menurender()
|
|||
{
|
||||
graphics.bigprint( -1, 20, "Results", tr, tg, tb, true, 3);
|
||||
|
||||
std::string tempstring = game.resulttimestring() + " / " + game.partimestring() + ".99";
|
||||
std::string tempstring = game.resulttimestring() + " / " + game.timetstring(game.timetrialresultpar) + ".99";
|
||||
|
||||
graphics.drawspritesetcol(30, 80-15, 50, 22);
|
||||
graphics.Print(65, 80-15, "TIME TAKEN:", 255, 255, 255);
|
||||
graphics.Print(65, 90-15, tempstring, tr, tg, tb);
|
||||
if (game.timetrialresulttime <= game.timetrialpar)
|
||||
if (game.timetrialresulttime <= game.timetrialresultpar)
|
||||
{
|
||||
graphics.Print(220, 85-15, "+1 Rank!", 255, 255, 255);
|
||||
}
|
||||
|
||||
tempstring = help.String(game.deathcounts);
|
||||
tempstring = help.String(game.timetrialresultdeaths);
|
||||
graphics.drawspritesetcol(30-4, 80+20-4, 12, 22);
|
||||
graphics.Print(65, 80+20, "NUMBER OF DEATHS:", 255, 255, 255);
|
||||
graphics.Print(65, 90+20, tempstring, tr, tg, tb);
|
||||
if (game.deathcounts == 0)
|
||||
if (game.timetrialresultdeaths == 0)
|
||||
{
|
||||
graphics.Print(220, 85+20, "+1 Rank!", 255, 255, 255);
|
||||
}
|
||||
|
||||
tempstring = help.String(game.trinkets()) + " of " + help.String(game.timetrialshinytarget);
|
||||
tempstring = help.String(game.timetrialresulttrinkets) + " of " + help.String(game.timetrialresultshinytarget);
|
||||
graphics.drawspritesetcol(30, 80+55, 22, 22);
|
||||
graphics.Print(65, 80+55, "SHINY TRINKETS:", 255, 255, 255);
|
||||
graphics.Print(65, 90+55, tempstring, tr, tg, tb);
|
||||
if (game.trinkets() >= game.timetrialshinytarget)
|
||||
if (game.timetrialresulttrinkets >= game.timetrialresultshinytarget)
|
||||
{
|
||||
graphics.Print(220, 85+55, "+1 Rank!", 255, 255, 255);
|
||||
}
|
||||
|
|
|
@ -60,7 +60,7 @@ void Screen::init(const ScreenSettings& settings)
|
|||
SDL_CreateWindowAndRenderer(
|
||||
640,
|
||||
480,
|
||||
SDL_WINDOW_HIDDEN | SDL_WINDOW_RESIZABLE,
|
||||
SDL_WINDOW_HIDDEN | SDL_WINDOW_RESIZABLE | SDL_WINDOW_ALLOW_HIGHDPI,
|
||||
&m_window,
|
||||
&m_renderer
|
||||
);
|
||||
|
@ -170,7 +170,7 @@ void Screen::ResizeScreen(int x, int y)
|
|||
if (stretchMode == 1)
|
||||
{
|
||||
int winX, winY;
|
||||
SDL_GetWindowSize(m_window, &winX, &winY);
|
||||
GetWindowSize(&winX, &winY);
|
||||
int result = SDL_RenderSetLogicalSize(m_renderer, winX, winY);
|
||||
if (result != 0)
|
||||
{
|
||||
|
@ -256,7 +256,7 @@ void Screen::ResizeToNearestMultiple()
|
|||
|
||||
void Screen::GetWindowSize(int* x, int* y)
|
||||
{
|
||||
SDL_GetWindowSize(m_window, x, y);
|
||||
SDL_GetRendererOutputSize(m_renderer, x, y);
|
||||
}
|
||||
|
||||
void Screen::UpdateScreen(SDL_Surface* buffer, SDL_Rect* rect )
|
||||
|
|
|
@ -2627,11 +2627,8 @@ void scriptclass::run()
|
|||
|
||||
void scriptclass::resetgametomenu()
|
||||
{
|
||||
game.gamestate = TITLEMODE;
|
||||
graphics.flipmode = false;
|
||||
obj.entities.clear();
|
||||
graphics.fademode = 4;
|
||||
graphics.titlebg.tdrawback = true;
|
||||
game.quittomenu();
|
||||
game.createmenu(Menu::gameover);
|
||||
}
|
||||
|
||||
|
@ -3262,6 +3259,8 @@ void scriptclass::startgamemode( int t )
|
|||
hardreset();
|
||||
ed.reset();
|
||||
music.fadeout();
|
||||
map.custommode = true;
|
||||
map.custommodeforreal = false;
|
||||
|
||||
game.gamestate = EDITORMODE;
|
||||
game.jumpheld = true;
|
||||
|
@ -3595,7 +3594,6 @@ void scriptclass::hardreset()
|
|||
game.timetrialshinytarget = 0;
|
||||
game.timetrialparlost = false;
|
||||
game.timetrialpar = 0;
|
||||
game.timetrialresulttime = 0;
|
||||
|
||||
game.totalflips = 0;
|
||||
game.hardestroom = "Welcome Aboard";
|
||||
|
|
|
@ -2660,14 +2660,7 @@ void editorrender()
|
|||
fillboxabs((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),16,16,graphics.getRGB(164,164,255));
|
||||
break;
|
||||
case 10: //Checkpoints
|
||||
if(edentity[i].p1==0) //From roof
|
||||
{
|
||||
graphics.drawsprite((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),20,196,196,196);
|
||||
}
|
||||
else if(edentity[i].p1==1) //From floor
|
||||
{
|
||||
graphics.drawsprite((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),21,196,196,196);
|
||||
}
|
||||
graphics.drawsprite((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),20 + edentity[i].p1,196,196,196);
|
||||
fillboxabs((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),16,16,graphics.getRGB(164,164,255));
|
||||
break;
|
||||
case 11: //Gravity lines
|
||||
|
@ -2767,13 +2760,27 @@ void editorrender()
|
|||
graphics.Print((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8), edentity[i].scriptname, 196, 196, 255 - help.glow);
|
||||
break;
|
||||
case 18: //Terminals
|
||||
graphics.drawsprite((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8)+8,17,96,96,96);
|
||||
{
|
||||
int usethistile = edentity[i].p1;
|
||||
int usethisy = (edentity[i].y % 30) * 8;
|
||||
// Not a boolean: just swapping 0 and 1, leaving the rest alone
|
||||
if (usethistile == 0)
|
||||
{
|
||||
usethistile = 1; // Unflipped
|
||||
}
|
||||
else if (usethistile == 1)
|
||||
{
|
||||
usethistile = 0; // Flipped;
|
||||
usethisy -= 8;
|
||||
}
|
||||
graphics.drawsprite((edentity[i].x*8)- (ed.levx*40*8), usethisy + 8, usethistile + 16, 96,96,96);
|
||||
fillboxabs((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),16,24,graphics.getRGB(164,164,164));
|
||||
if(temp2==i)
|
||||
{
|
||||
graphics.bprint((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8)-8,edentity[i].scriptname,210,210,255);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 19: //Script Triggers
|
||||
fillboxabs((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),edentity[i].p1*8,edentity[i].p2*8,graphics.getRGB(255,164,255));
|
||||
fillboxabs((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),8,8,graphics.getRGB(255,255,255));
|
||||
|
@ -3627,18 +3634,11 @@ void editorlogic()
|
|||
if (graphics.fademode == 1)
|
||||
{
|
||||
//Return to game
|
||||
map.nexttowercolour();
|
||||
graphics.titlebg.colstate = 10;
|
||||
game.gamestate = TITLEMODE;
|
||||
script.hardreset();
|
||||
graphics.fademode = 4;
|
||||
music.haltdasmusik();
|
||||
FILESYSTEM_unmountassets(); // should be before music.play(6)
|
||||
music.play(6);
|
||||
map.nexttowercolour();
|
||||
game.quittomenu();
|
||||
music.play(6); //should be before game.quittomenu()
|
||||
ed.settingsmod=false;
|
||||
graphics.backgrounddrawn=false;
|
||||
game.returntomenu(Menu::playerworlds);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -5169,8 +5169,12 @@ void editorinput()
|
|||
ed.lclickdelay=1;
|
||||
}
|
||||
else if(edentity[tmp].t==10)
|
||||
{
|
||||
// If it's not textured as a checkpoint, leave it alone
|
||||
if (edentity[tmp].p1 == 0 || edentity[tmp].p1 == 1)
|
||||
{
|
||||
edentity[tmp].p1=(edentity[tmp].p1+1)%2;
|
||||
}
|
||||
ed.lclickdelay=1;
|
||||
}
|
||||
else if(edentity[tmp].t==11)
|
||||
|
@ -5199,6 +5203,12 @@ void editorinput()
|
|||
ed.lclickdelay=1;
|
||||
ed.textent=tmp;
|
||||
ed.getlin(TEXT_SCRIPT, "Enter script name:", &(edentity[ed.textent].scriptname));
|
||||
if (edentity[tmp].t == 18
|
||||
&& (edentity[tmp].p1 == 0 || edentity[tmp].p1 == 1))
|
||||
{
|
||||
// Flip the terminal, but if it's not textured as a terminal leave it alone
|
||||
edentity[tmp].p1 = (edentity[tmp].p1 + 1) % 2;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -265,8 +265,6 @@ int main(int argc, char *argv[])
|
|||
SDL_SetSurfaceBlendMode(graphics.ghostbuffer, SDL_BLENDMODE_BLEND);
|
||||
SDL_SetSurfaceAlphaMod(graphics.ghostbuffer, 127);
|
||||
|
||||
graphics.Makebfont();
|
||||
|
||||
graphics.foregroundBuffer = CREATE_SURFACE(320, 240);
|
||||
SDL_SetSurfaceBlendMode(graphics.foregroundBuffer, SDL_BLENDMODE_BLEND);
|
||||
|
||||
|
|
Loading…
Reference in a new issue