mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-23 01:59:43 +01:00
Indicate what special roomnames are in the levels
This just adds booleans roomname_special to the level classes in preparation for the localization system to use them. This commit is part of rewritten history of the localization branch. The original (unsquashed) commit history can be found here: https://github.com/Dav999-v/VVVVVV/tree/localization-orig
This commit is contained in:
parent
0ed2cb1bc0
commit
f8fd51fc95
12 changed files with 35 additions and 0 deletions
|
@ -13,6 +13,8 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
warpx = false;
|
warpx = false;
|
||||||
warpy = false;
|
warpy = false;
|
||||||
|
|
||||||
|
roomname_special = false;
|
||||||
|
|
||||||
switch(t)
|
switch(t)
|
||||||
{
|
{
|
||||||
#if !defined(MAKEANDPLAY)
|
#if !defined(MAKEANDPLAY)
|
||||||
|
@ -156,6 +158,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpy = true;
|
warpy = true;
|
||||||
roomname = "glitch";
|
roomname = "glitch";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -206,6 +209,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpy = true;
|
warpy = true;
|
||||||
roomname = "glitch";
|
roomname = "glitch";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -254,6 +258,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpy = true;
|
warpy = true;
|
||||||
roomname = "change";
|
roomname = "change";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -304,6 +309,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpy = true;
|
warpy = true;
|
||||||
roomname = "change";
|
roomname = "change";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -351,6 +357,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpy = true;
|
warpy = true;
|
||||||
roomname = "change";
|
roomname = "change";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -508,6 +515,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpy = true;
|
warpy = true;
|
||||||
roomname = "glitch";
|
roomname = "glitch";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -954,6 +962,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpx = true;
|
warpx = true;
|
||||||
roomname = "change";
|
roomname = "change";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1004,6 +1013,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
warpx = true;
|
warpx = true;
|
||||||
roomname = "change";
|
roomname = "change";
|
||||||
|
roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -2603,6 +2613,7 @@ const short* finalclass::loadlevel(int rx, int ry)
|
||||||
{
|
{
|
||||||
static const short contents[1200] = {0};
|
static const short contents[1200] = {0};
|
||||||
roomname = "Outer Space";
|
roomname = "Outer Space";
|
||||||
|
roomname_special = true;
|
||||||
|
|
||||||
//game.test = true;
|
//game.test = true;
|
||||||
//game.teststring = "ERROR: Map not found in Final Area";
|
//game.teststring = "ERROR: Map not found in Final Area";
|
||||||
|
|
|
@ -7,6 +7,7 @@ public:
|
||||||
const short* loadlevel(int rx, int ry);
|
const short* loadlevel(int rx, int ry);
|
||||||
|
|
||||||
const char* roomname;
|
const char* roomname;
|
||||||
|
bool roomname_special;
|
||||||
bool warpx, warpy;
|
bool warpx, warpy;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,7 @@ const short* labclass::loadlevel(int rx, int ry)
|
||||||
const short* result;
|
const short* result;
|
||||||
rcol = 0;
|
rcol = 0;
|
||||||
roomname = "";
|
roomname = "";
|
||||||
|
roomname_special = false;
|
||||||
|
|
||||||
switch(t)
|
switch(t)
|
||||||
{
|
{
|
||||||
|
|
|
@ -7,6 +7,7 @@ public:
|
||||||
const short* loadlevel(int rx, int ry);
|
const short* loadlevel(int rx, int ry);
|
||||||
|
|
||||||
const char* roomname;
|
const char* roomname;
|
||||||
|
bool roomname_special;
|
||||||
int rcol;
|
int rcol;
|
||||||
};
|
};
|
||||||
#endif /* LABCLASS_H */
|
#endif /* LABCLASS_H */
|
||||||
|
|
|
@ -83,6 +83,8 @@ mapclass::mapclass(void)
|
||||||
|
|
||||||
setroomname("");
|
setroomname("");
|
||||||
hiddenname = "";
|
hiddenname = "";
|
||||||
|
|
||||||
|
roomname_special = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char roomname_static[SCREEN_WIDTH_CHARS];
|
static char roomname_static[SCREEN_WIDTH_CHARS];
|
||||||
|
@ -1536,6 +1538,8 @@ void mapclass::loadlevel(int rx, int ry)
|
||||||
warpy = true;
|
warpy = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
roomname_special = false;
|
||||||
|
|
||||||
switch(t)
|
switch(t)
|
||||||
{
|
{
|
||||||
#if !defined(MAKEANDPLAY)
|
#if !defined(MAKEANDPLAY)
|
||||||
|
@ -1547,6 +1551,7 @@ void mapclass::loadlevel(int rx, int ry)
|
||||||
const short* tmap = otherlevel.loadlevel(rx, ry);
|
const short* tmap = otherlevel.loadlevel(rx, ry);
|
||||||
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
||||||
setroomname(otherlevel.roomname);
|
setroomname(otherlevel.roomname);
|
||||||
|
roomname_special = otherlevel.roomname_special;
|
||||||
hiddenname = otherlevel.hiddenname;
|
hiddenname = otherlevel.hiddenname;
|
||||||
tileset = otherlevel.roomtileset;
|
tileset = otherlevel.roomtileset;
|
||||||
break;
|
break;
|
||||||
|
@ -1556,6 +1561,7 @@ void mapclass::loadlevel(int rx, int ry)
|
||||||
const short* tmap = lablevel.loadlevel(rx, ry);
|
const short* tmap = lablevel.loadlevel(rx, ry);
|
||||||
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
||||||
setroomname(lablevel.roomname);
|
setroomname(lablevel.roomname);
|
||||||
|
roomname_special = lablevel.roomname_special;
|
||||||
tileset = 1;
|
tileset = 1;
|
||||||
background = 2;
|
background = 2;
|
||||||
graphics.rcol = lablevel.rcol;
|
graphics.rcol = lablevel.rcol;
|
||||||
|
@ -1603,6 +1609,7 @@ void mapclass::loadlevel(int rx, int ry)
|
||||||
const short* tmap = warplevel.loadlevel(rx, ry);
|
const short* tmap = warplevel.loadlevel(rx, ry);
|
||||||
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
||||||
setroomname(warplevel.roomname);
|
setroomname(warplevel.roomname);
|
||||||
|
roomname_special = warplevel.roomname_special;
|
||||||
tileset = 1;
|
tileset = 1;
|
||||||
background = 3;
|
background = 3;
|
||||||
graphics.rcol = warplevel.rcol;
|
graphics.rcol = warplevel.rcol;
|
||||||
|
@ -1621,6 +1628,7 @@ void mapclass::loadlevel(int rx, int ry)
|
||||||
const short* tmap = spacestation2.loadlevel(rx, ry);
|
const short* tmap = spacestation2.loadlevel(rx, ry);
|
||||||
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
||||||
setroomname(spacestation2.roomname);
|
setroomname(spacestation2.roomname);
|
||||||
|
roomname_special = spacestation2.roomname_special;
|
||||||
tileset = 0;
|
tileset = 0;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1629,6 +1637,7 @@ void mapclass::loadlevel(int rx, int ry)
|
||||||
const short* tmap = finallevel.loadlevel(rx, ry);
|
const short* tmap = finallevel.loadlevel(rx, ry);
|
||||||
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
||||||
setroomname(finallevel.roomname);
|
setroomname(finallevel.roomname);
|
||||||
|
roomname_special = finallevel.roomname_special;
|
||||||
tileset = 1;
|
tileset = 1;
|
||||||
background = 3;
|
background = 3;
|
||||||
graphics.backgrounddrawn = false;
|
graphics.backgrounddrawn = false;
|
||||||
|
@ -1788,6 +1797,7 @@ void mapclass::loadlevel(int rx, int ry)
|
||||||
const short* tmap = finallevel.loadlevel(rx, ry);
|
const short* tmap = finallevel.loadlevel(rx, ry);
|
||||||
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
copy_short_to_int(contents, tmap, SDL_arraysize(contents));
|
||||||
setroomname(finallevel.roomname);
|
setroomname(finallevel.roomname);
|
||||||
|
roomname_special = finallevel.roomname_special;
|
||||||
tileset = 2;
|
tileset = 2;
|
||||||
if (rx == 108)
|
if (rx == 108)
|
||||||
{
|
{
|
||||||
|
|
|
@ -114,6 +114,7 @@ public:
|
||||||
|
|
||||||
|
|
||||||
const char* roomname;
|
const char* roomname;
|
||||||
|
bool roomname_special;
|
||||||
const char* hiddenname;
|
const char* hiddenname;
|
||||||
|
|
||||||
//Special tower stuff
|
//Special tower stuff
|
||||||
|
|
|
@ -15,6 +15,7 @@ const short* otherlevelclass::loadlevel(int rx, int ry)
|
||||||
t = rx + (ry * 100);
|
t = rx + (ry * 100);
|
||||||
const short* result;
|
const short* result;
|
||||||
roomname = "";
|
roomname = "";
|
||||||
|
roomname_special = false;
|
||||||
hiddenname = "Dimension VVVVVV";
|
hiddenname = "Dimension VVVVVV";
|
||||||
|
|
||||||
switch(t)
|
switch(t)
|
||||||
|
|
|
@ -7,6 +7,7 @@ public:
|
||||||
const short* loadlevel(int rx, int ry);
|
const short* loadlevel(int rx, int ry);
|
||||||
|
|
||||||
const char* roomname;
|
const char* roomname;
|
||||||
|
bool roomname_special;
|
||||||
const char* hiddenname;
|
const char* hiddenname;
|
||||||
|
|
||||||
int roomtileset;
|
int roomtileset;
|
||||||
|
|
|
@ -17,6 +17,7 @@ const short* spacestation2class::loadlevel(int rx, int ry)
|
||||||
|
|
||||||
const short* result;
|
const short* result;
|
||||||
roomname = "Untitled room";
|
roomname = "Untitled room";
|
||||||
|
roomname_special = false;
|
||||||
|
|
||||||
switch(t)
|
switch(t)
|
||||||
{
|
{
|
||||||
|
@ -2556,10 +2557,12 @@ const short* spacestation2class::loadlevel(int rx, int ry)
|
||||||
if(game.nodeathmode)
|
if(game.nodeathmode)
|
||||||
{
|
{
|
||||||
roomname = "I Can't Believe You Got This Far";
|
roomname = "I Can't Believe You Got This Far";
|
||||||
|
roomname_special = true;
|
||||||
}
|
}
|
||||||
else if (game.intimetrial)
|
else if (game.intimetrial)
|
||||||
{
|
{
|
||||||
roomname = "Imagine Spikes There, if You Like";
|
roomname = "Imagine Spikes There, if You Like";
|
||||||
|
roomname_special = true;
|
||||||
}
|
}
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
|
@ -3625,6 +3628,7 @@ const short* spacestation2class::loadlevel(int rx, int ry)
|
||||||
{
|
{
|
||||||
static const short contents[1200] = {0};
|
static const short contents[1200] = {0};
|
||||||
roomname = "Outer Space";
|
roomname = "Outer Space";
|
||||||
|
roomname_special = true;
|
||||||
obj.fatal_bottom();
|
obj.fatal_bottom();
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -6,6 +6,7 @@ class spacestation2class
|
||||||
public:
|
public:
|
||||||
const short* loadlevel(int rx, int ry);
|
const short* loadlevel(int rx, int ry);
|
||||||
const char* roomname;
|
const char* roomname;
|
||||||
|
bool roomname_special;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* SPACESTATION2_H */
|
#endif /* SPACESTATION2_H */
|
||||||
|
|
|
@ -20,6 +20,7 @@ const short* warpclass::loadlevel(int rx, int ry)
|
||||||
warpy = false;
|
warpy = false;
|
||||||
|
|
||||||
roomname = "Untitled room";
|
roomname = "Untitled room";
|
||||||
|
roomname_special = false;
|
||||||
|
|
||||||
switch(t)
|
switch(t)
|
||||||
{
|
{
|
||||||
|
@ -1130,6 +1131,7 @@ const short* warpclass::loadlevel(int rx, int ry)
|
||||||
{
|
{
|
||||||
static const short contents[1200] = {0};
|
static const short contents[1200] = {0};
|
||||||
//roomname = "Outer Space";
|
//roomname = "Outer Space";
|
||||||
|
//roomname_special = true;
|
||||||
result = contents;
|
result = contents;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,7 @@ class warpclass
|
||||||
public:
|
public:
|
||||||
const short* loadlevel(int rx, int ry);
|
const short* loadlevel(int rx, int ry);
|
||||||
const char* roomname;
|
const char* roomname;
|
||||||
|
bool roomname_special;
|
||||||
int rcol;
|
int rcol;
|
||||||
bool warpx, warpy;
|
bool warpx, warpy;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue