mirror of
https://github.com/SWG-Source/client-tools.git
synced 2026-01-15 22:04:32 -05:00
@@ -1057,6 +1057,12 @@ void CommandCppFuncsNamespace::commandFuncInstantMessageTell (Command const
|
||||
if (!player || player->getNetworkId () != actorId)
|
||||
return;
|
||||
|
||||
if(Game::isTutorial() && !Game::getPlayerObject()->isAdmin())
|
||||
{
|
||||
CuiSystemMessageManager::sendFakeSystemMessage(Unicode::narrowToWide("You cannot initiate a tell while in the tutorial."));
|
||||
return;
|
||||
}
|
||||
|
||||
Unicode::String result;
|
||||
IGNORE_RETURN(CuiInstantMessageManager::tell (params, result));
|
||||
if (!result.empty ())
|
||||
@@ -1071,6 +1077,12 @@ void CommandCppFuncsNamespace::commandFuncInstantMessageTtell (Command const
|
||||
if (!player || player->getNetworkId () != actorId)
|
||||
return;
|
||||
|
||||
if (Game::isTutorial() && !Game::getPlayerObject()->isAdmin())
|
||||
{
|
||||
CuiSystemMessageManager::sendFakeSystemMessage(Unicode::narrowToWide("You cannot initiate a tell while in the tutorial."));
|
||||
return;
|
||||
}
|
||||
|
||||
Unicode::String result;
|
||||
IGNORE_RETURN(CuiInstantMessageManager::targetedTell (params, result));
|
||||
if (!result.empty ())
|
||||
@@ -1085,6 +1097,12 @@ void CommandCppFuncsNamespace::commandFuncInstantMessageRetell (Command const
|
||||
if (!player || player->getNetworkId () != actorId)
|
||||
return;
|
||||
|
||||
if (Game::isTutorial() && !Game::getPlayerObject()->isAdmin())
|
||||
{
|
||||
CuiSystemMessageManager::sendFakeSystemMessage(Unicode::narrowToWide("You cannot initiate a tell while in the tutorial."));
|
||||
return;
|
||||
}
|
||||
|
||||
Unicode::String result;
|
||||
IGNORE_RETURN(CuiInstantMessageManager::retell (params, result));
|
||||
if (!result.empty ())
|
||||
|
||||
@@ -119,11 +119,11 @@ m_lastScrollPosY (0L)
|
||||
setState (MS_closeable);
|
||||
setState (MS_closeDeactivates);
|
||||
|
||||
// disable New/Reply/Forward button if squelched
|
||||
// disable New/Reply/Forward button if squelched or in tutorial
|
||||
const bool isSquelched = Game::isPlayerSquelched();
|
||||
m_buttonNew->SetEnabled(!isSquelched);
|
||||
m_buttonReply->SetEnabled(!isSquelched);
|
||||
m_buttonForward->SetEnabled(!isSquelched);
|
||||
m_buttonNew->SetEnabled(!isSquelched && !Game::isTutorial());
|
||||
m_buttonReply->SetEnabled(!isSquelched && !Game::isTutorial());
|
||||
m_buttonForward->SetEnabled(!isSquelched && !Game::isTutorial());
|
||||
|
||||
registerMediatorObject (*m_table, true);
|
||||
registerMediatorObject (*m_buttonNew, true);
|
||||
@@ -710,14 +710,14 @@ void SwgCuiPersistentMessageBrowser::update(float deltaTimeSecs)
|
||||
{
|
||||
CuiMediator::update(deltaTimeSecs);
|
||||
|
||||
// disable New/Reply/Forward button if squelched
|
||||
// disable New/Reply/Forward button if squelched or in tutorial
|
||||
const bool isSquelched = Game::isPlayerSquelched();
|
||||
if (m_buttonNew)
|
||||
m_buttonNew->SetEnabled(!isSquelched);
|
||||
m_buttonNew->SetEnabled(!isSquelched && !Game::isTutorial());
|
||||
if (m_buttonReply)
|
||||
m_buttonReply->SetEnabled(!isSquelched);
|
||||
m_buttonReply->SetEnabled(!isSquelched && !Game::isTutorial());
|
||||
if (m_buttonForward)
|
||||
m_buttonForward->SetEnabled(!isSquelched);
|
||||
m_buttonForward->SetEnabled(!isSquelched && !Game::isTutorial());
|
||||
}
|
||||
|
||||
//======================================================================
|
||||
|
||||
Reference in New Issue
Block a user