improve find tool handling with GoL, can now find specific life elements
Reverts most of LBPHacker's previous commit, lol
This commit is contained in:
parent
4ff1dc0bc3
commit
25c1b13bd4
@ -1422,7 +1422,8 @@ void Renderer::render_parts()
|
||||
|
||||
if (findingElement)
|
||||
{
|
||||
if (findingElement == parts[i].type)
|
||||
if (TYP(findingElement) == parts[i].type &&
|
||||
(parts[i].type != PT_LIFE || (ID(findingElement) == parts[i].ctype)))
|
||||
{
|
||||
colr = firer = 255;
|
||||
colg = fireg = colb = fireb = 0;
|
||||
|
@ -715,7 +715,7 @@ void GameView::NotifyActiveToolsChanged(GameModel * sender)
|
||||
if (!active->GetIdentifier().Contains("_PT_"))
|
||||
ren->findingElement = 0;
|
||||
else
|
||||
ren->findingElement = sender->GetActiveTool(0)->GetToolID() & ((1 << PMAPBITS) - 1);
|
||||
ren->findingElement = sender->GetActiveTool(0)->GetToolID();
|
||||
}
|
||||
}
|
||||
|
||||
@ -1509,10 +1509,10 @@ void GameView::OnKeyPress(int key, int scan, bool repeat, bool shift, bool ctrl,
|
||||
if (ctrl)
|
||||
{
|
||||
Tool *active = c->GetActiveTool(0);
|
||||
if (!active->GetIdentifier().Contains("_PT_") || (ren->findingElement == (active->GetToolID() & ((1 << PMAPBITS) - 1))))
|
||||
if (!active->GetIdentifier().Contains("_PT_") || (ren->findingElement == active->GetToolID()))
|
||||
ren->findingElement = 0;
|
||||
else
|
||||
ren->findingElement = active->GetToolID() & ((1 << PMAPBITS) - 1);
|
||||
ren->findingElement = active->GetToolID();
|
||||
}
|
||||
else
|
||||
c->FrameStep();
|
||||
|
Reference in New Issue
Block a user