Demo: vou postar breve
Interface.h
void SwitchMiniMap();
void SwitchTime();
Interface.cpp
void Interface::Work()
{
if( GetForegroundWindow() == pGameWindow )
{
if (GetKeyState(VK_F4) & 0x4000)
{
gInterface.SwitchTime();
}
if (GetKeyState(VK_F5) & 0x4000)
{
gInterface.SwitchMiniMap();
}
}
}
void Interface::SwitchMiniMap(){
if((GetTickCount() - gInterface.Data[eNULL_MAP].EventTick) < 1000 )
{
return;
}
gInterface.Data[eNULL_MAP].EventTick = GetTickCount();
if (MiniMap!=0)
{
gInterface.DrawMessage(1, "MiniMap Window [OFF]");
MiniMap = 0;
}
else
{
gInterface.DrawMessage(1, "MiniMap Window [ON]");
MiniMap = 1;
}
}
void Interface::SwitchTime()
{
if((GetTickCount() - gInterface.Data[eTIME].EventTick) < 1000 )
{
return;
}
gInterface.Data[eTIME].EventTick = GetTickCount();
if (this->Data[eTIME].OnShow)
{
gInterface.DrawMessage(1, "Time Window [OFF]");
this->Data[eTIME].OnShow = false;
}
else
{
gInterface.DrawMessage(1, "Time Window [ON]");
this->Data[eTIME].OnShow = true;
}
}
MiniMap [F5] + TimeBar [F4]
Creditos: Applayo