mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2024-11-25 17:53:47 +00:00
remove some unused things from WorldMapRender
This commit is contained in:
parent
b7eb5777ae
commit
dff6fbfafb
2 changed files with 5 additions and 42 deletions
|
@ -119,7 +119,6 @@ protected:
|
||||||
Quad *addHintQuad1, *addHintQuad2;
|
Quad *addHintQuad1, *addHintQuad2;
|
||||||
AquariaMenuItem *helpButton;
|
AquariaMenuItem *helpButton;
|
||||||
float doubleClickTimer;
|
float doubleClickTimer;
|
||||||
Vector restoreVel;
|
|
||||||
float inputDelay;
|
float inputDelay;
|
||||||
BitmapText *areaLabel, *areaLabel2, *areaLabel3;
|
BitmapText *areaLabel, *areaLabel2, *areaLabel3;
|
||||||
WorldMapTile *originalActiveTile;
|
WorldMapTile *originalActiveTile;
|
||||||
|
@ -127,7 +126,6 @@ protected:
|
||||||
void clearVis(WorldMapTile *tile);
|
void clearVis(WorldMapTile *tile);
|
||||||
bool on;
|
bool on;
|
||||||
void onUpdate(float dt);
|
void onUpdate(float dt);
|
||||||
Quad *bg;
|
|
||||||
unsigned char *savedTexData;
|
unsigned char *savedTexData;
|
||||||
bool mb;
|
bool mb;
|
||||||
Vector lastMousePosition; // See FIXME in WorldMapRender.cpp --achurch
|
Vector lastMousePosition; // See FIXME in WorldMapRender.cpp --achurch
|
||||||
|
|
|
@ -52,11 +52,8 @@ namespace WorldMapRenderNamespace
|
||||||
const VisMethod visMethod = VIS_VERTEX;
|
const VisMethod visMethod = VIS_VERTEX;
|
||||||
WorldMapRevealMethod revMethod = REVEAL_DEFAULT;
|
WorldMapRevealMethod revMethod = REVEAL_DEFAULT;
|
||||||
|
|
||||||
std::vector<Quad *> tiles;
|
|
||||||
|
|
||||||
Quad *activeQuad=0, *lastActiveQuad=0, *originalActiveQuad=0;
|
Quad *activeQuad=0;
|
||||||
Quad *lastVisQuad=0, *visQuad=0;
|
|
||||||
WorldMapTile *lastVisTile=0;
|
|
||||||
|
|
||||||
float xMin, yMin, xMax, yMax;
|
float xMin, yMin, xMax, yMax;
|
||||||
|
|
||||||
|
@ -74,7 +71,6 @@ namespace WorldMapRenderNamespace
|
||||||
|
|
||||||
using namespace WorldMapRenderNamespace;
|
using namespace WorldMapRenderNamespace;
|
||||||
|
|
||||||
std::vector <Quad*> grid;
|
|
||||||
|
|
||||||
class GemMover;
|
class GemMover;
|
||||||
|
|
||||||
|
@ -414,7 +410,7 @@ protected:
|
||||||
typedef std::list <GemMover*> GemMovers;
|
typedef std::list <GemMover*> GemMovers;
|
||||||
GemMovers gemMovers;
|
GemMovers gemMovers;
|
||||||
|
|
||||||
typedef std::list <BeaconRender*> BeaconRenders;
|
typedef std::vector<BeaconRender*> BeaconRenders;
|
||||||
BeaconRenders beaconRenders;
|
BeaconRenders beaconRenders;
|
||||||
|
|
||||||
std::vector<Quad*> quads;
|
std::vector<Quad*> quads;
|
||||||
|
@ -425,11 +421,7 @@ void WorldMapRender::setProperTileColor(WorldMapTile *tile)
|
||||||
{
|
{
|
||||||
if (tile->q)
|
if (tile->q)
|
||||||
{
|
{
|
||||||
if (!tile->revealed)
|
tile->q->alphaMod = tile->revealed ? 0.5f : 0.0f;
|
||||||
tile->q->alphaMod = 0;
|
|
||||||
|
|
||||||
if (tile->revealed)
|
|
||||||
tile->q->alphaMod = 0.5f;
|
|
||||||
|
|
||||||
if (activeTile && (tile->layer != activeTile->layer || (tile->layer > 0 && activeTile != tile)))
|
if (activeTile && (tile->layer != activeTile->layer || (tile->layer > 0 && activeTile != tile)))
|
||||||
tile->q->alphaMod *= 0.5f;
|
tile->q->alphaMod *= 0.5f;
|
||||||
|
@ -573,11 +565,9 @@ void WorldMapRender::setVis(WorldMapTile *tile)
|
||||||
}
|
}
|
||||||
else if (visMethod == VIS_WRITE)
|
else if (visMethod == VIS_WRITE)
|
||||||
{
|
{
|
||||||
|
assert(!savedTexData);
|
||||||
savedTexData = tileDataToAlpha(tile);
|
savedTexData = tileDataToAlpha(tile);
|
||||||
}
|
}
|
||||||
|
|
||||||
lastVisQuad = tile->q;
|
|
||||||
lastVisTile = tile;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void WorldMapRender::clearVis(WorldMapTile *tile)
|
void WorldMapRender::clearVis(WorldMapTile *tile)
|
||||||
|
@ -607,11 +597,6 @@ WorldMapRender::WorldMapRender() : RenderObject(), ActionMapper()
|
||||||
editorActive=false;
|
editorActive=false;
|
||||||
mb = false;
|
mb = false;
|
||||||
activeQuad=0;
|
activeQuad=0;
|
||||||
lastActiveQuad=0;
|
|
||||||
originalActiveQuad=0;
|
|
||||||
lastVisQuad=0;
|
|
||||||
visQuad=0;
|
|
||||||
lastVisTile=0;
|
|
||||||
|
|
||||||
originalActiveTile = activeTile = 0;
|
originalActiveTile = activeTile = 0;
|
||||||
|
|
||||||
|
@ -630,8 +615,6 @@ WorldMapRender::WorldMapRender() : RenderObject(), ActionMapper()
|
||||||
|
|
||||||
lastMousePosition = core->mouse.position;
|
lastMousePosition = core->mouse.position;
|
||||||
|
|
||||||
bg = 0;
|
|
||||||
|
|
||||||
savedTexData = 0;
|
savedTexData = 0;
|
||||||
|
|
||||||
|
|
||||||
|
@ -653,8 +636,6 @@ WorldMapRender::WorldMapRender() : RenderObject(), ActionMapper()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
tiles.clear();
|
|
||||||
|
|
||||||
if(num)
|
if(num)
|
||||||
dsq->texmgr.loadBatch(&texs[0], &textodo[0], num);
|
dsq->texmgr.loadBatch(&texs[0], &textodo[0], num);
|
||||||
|
|
||||||
|
@ -678,10 +659,7 @@ WorldMapRender::WorldMapRender() : RenderObject(), ActionMapper()
|
||||||
if (tile == activeTile)
|
if (tile == activeTile)
|
||||||
activeQuad = q;
|
activeQuad = q;
|
||||||
|
|
||||||
if (revMethod == REVEAL_PARTIAL || activeQuad == q)
|
|
||||||
{
|
|
||||||
setVis(tile);
|
setVis(tile);
|
||||||
}
|
|
||||||
|
|
||||||
setProperTileColor(tile);
|
setProperTileColor(tile);
|
||||||
|
|
||||||
|
@ -692,8 +670,6 @@ WorldMapRender::WorldMapRender() : RenderObject(), ActionMapper()
|
||||||
}
|
}
|
||||||
|
|
||||||
addChild(q, PM_POINTER);
|
addChild(q, PM_POINTER);
|
||||||
|
|
||||||
tiles.push_back(q);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
shareAlphaWithChildren = 1;
|
shareAlphaWithChildren = 1;
|
||||||
|
@ -1320,9 +1296,6 @@ void WorldMapRender::toggle(bool turnON)
|
||||||
this->on = turnON;
|
this->on = turnON;
|
||||||
if (on)
|
if (on)
|
||||||
{
|
{
|
||||||
restoreVel = game->avatar->vel;
|
|
||||||
game->avatar->vel = Vector(0,0,0);
|
|
||||||
|
|
||||||
game->togglePause(true);
|
game->togglePause(true);
|
||||||
|
|
||||||
core->sound->playSfx("menu-open");
|
core->sound->playSfx("menu-open");
|
||||||
|
@ -1365,9 +1338,6 @@ void WorldMapRender::toggle(bool turnON)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bg)
|
|
||||||
bg->alpha.interpolateTo(1, 0.2f);
|
|
||||||
|
|
||||||
alpha.interpolateTo(1, 0.2f);
|
alpha.interpolateTo(1, 0.2f);
|
||||||
|
|
||||||
|
|
||||||
|
@ -1434,9 +1404,6 @@ void WorldMapRender::toggle(bool turnON)
|
||||||
|
|
||||||
core->sound->playSfx("Menu-Close");
|
core->sound->playSfx("Menu-Close");
|
||||||
|
|
||||||
if (bg)
|
|
||||||
bg->alpha.interpolateTo(0, 0.2f);
|
|
||||||
|
|
||||||
alpha.interpolateTo(0, 0.2f);
|
alpha.interpolateTo(0, 0.2f);
|
||||||
|
|
||||||
game->togglePause(false);
|
game->togglePause(false);
|
||||||
|
@ -1460,8 +1427,6 @@ void WorldMapRender::toggle(bool turnON)
|
||||||
(*i)->safeKill();
|
(*i)->safeKill();
|
||||||
}
|
}
|
||||||
beaconRenders.clear();
|
beaconRenders.clear();
|
||||||
|
|
||||||
game->avatar->vel = restoreVel;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue