Files
itgmania212121/src/arch/Lights/LightsDriver_SystemMessage.cpp
T

70 lines
2.1 KiB
C++
Raw Normal View History

2003-11-20 11:55:45 +00:00
#include "global.h"
#include "LightsDriver_SystemMessage.h"
#include "ScreenManager.h"
2006-09-30 08:24:05 +00:00
#include "InputMapper.h"
#include "PrefsManager.h"
2003-11-20 11:55:45 +00:00
2006-12-18 22:29:49 +00:00
REGISTER_SOUND_DRIVER_CLASS(SystemMessage);
2003-11-20 11:55:45 +00:00
LightsDriver_SystemMessage::LightsDriver_SystemMessage()
{
}
LightsDriver_SystemMessage::~LightsDriver_SystemMessage()
{
}
2004-03-23 06:11:10 +00:00
void LightsDriver_SystemMessage::Set( const LightsState *ls )
2003-11-20 11:55:45 +00:00
{
if( !PREFSMAN->m_bDebugLights )
return;
2006-01-22 01:00:06 +00:00
RString s;
2004-03-23 06:11:10 +00:00
s += LightsModeToString(LIGHTSMAN->GetLightsMode()) + "\n";
2004-03-23 06:11:10 +00:00
s += "Cabinet: ";
FOREACH_CabinetLight( cl )
2003-11-20 11:55:45 +00:00
{
2004-03-23 06:11:10 +00:00
s += ls->m_bCabinetLights[cl] ? '1' : '0';
2003-11-20 11:55:45 +00:00
}
2004-03-23 06:11:10 +00:00
s += "\n";
2004-03-30 04:32:27 +00:00
2008-04-24 09:34:01 +00:00
FOREACH_ENUM( GameController, gc )
2004-03-23 06:11:10 +00:00
{
s += ssprintf("Controller%d: ",gc+1);
2008-04-24 09:34:01 +00:00
FOREACH_ENUM( GameButton, gb )
2004-03-23 06:11:10 +00:00
{
s += ls->m_bGameButtonLights[gc][gb] ? '1' : '0';
}
s += "\n";
}
2003-11-20 11:55:45 +00:00
SCREENMAN->SystemMessageNoAnimate( s );
}
2004-05-15 22:07:41 +00:00
/*
* (c) 2003-2004 Chris Danford
* All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, and/or sell copies of the Software, and to permit persons to
* whom the Software is furnished to do so, provided that the above
* copyright notice(s) and this permission notice appear in all copies of
* the Software and that both the above copyright notice(s) and this
* permission notice appear in supporting documentation.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF
* THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS
* INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT
* OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/