Fixed: Servers compilation
This commit is contained in:
parent
913102bc7c
commit
cb5ffb1d05
5 changed files with 6 additions and 92 deletions
|
@ -1068,7 +1068,7 @@ NLMISC_COMMAND(accessPowo, "give access to the powo", "<uid> player_name number"
|
||||||
sint32 cell;
|
sint32 cell;
|
||||||
buildingPlayer->addUser(c, 0, ownerId, cell);
|
buildingPlayer->addUser(c, 0, ownerId, cell);
|
||||||
// c->setPowoCell(cell);
|
// c->setPowoCell(cell);
|
||||||
CBuildingManager::getInstance()->setRoomLifeTime(cell, TGameCycle(NLMISC::TGameTime(4*60*60) / CTickEventHandler::getGameTimeStep()));
|
// CBuildingManager::getInstance()->setRoomLifeTime(cell, TGameCycle(NLMISC::TGameTime(4*60*60) / CTickEventHandler::getGameTimeStep()));
|
||||||
log.displayNL("%d", cell);
|
log.displayNL("%d", cell);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -146,7 +146,6 @@
|
||||||
#include "modules/client_command_forwarder.h"
|
#include "modules/client_command_forwarder.h"
|
||||||
#include "server_share/log_character_gen.h"
|
#include "server_share/log_character_gen.h"
|
||||||
#include "server_share/log_item_gen.h"
|
#include "server_share/log_item_gen.h"
|
||||||
#include "server_share/mongo_wrapper.h"
|
|
||||||
|
|
||||||
///////////
|
///////////
|
||||||
// USING //
|
// USING //
|
||||||
|
|
|
@ -842,7 +842,7 @@ void CFeReceiveSub::handleReceivedMsg( CClientHost *clienthost )
|
||||||
{
|
{
|
||||||
// The client has neither been authenticated nor provided a user id, but is allowed to connect (dev mode)
|
// The client has neither been authenticated nor provided a user id, but is allowed to connect (dev mode)
|
||||||
nlinfo ("%s using AutoAllocUserid", _CurrentInMsg->AddrFrom.asString().c_str() );
|
nlinfo ("%s using AutoAllocUserid", _CurrentInMsg->AddrFrom.asString().c_str() );
|
||||||
string filename = CPath::standardizePath( SaveShardRoot.get() ) + CPath::standardizePath( IService::getInstance()->SaveFilesDirectory.get() ) + "auto_uid_map.bin";
|
string filename = CPath::standardizePath( SaveShardRootGameShare.get() ) + CPath::standardizePath( IService::getInstance()->SaveFilesDirectory.get() ) + "auto_uid_map.bin";
|
||||||
|
|
||||||
// Get previously allocated user ids
|
// Get previously allocated user ids
|
||||||
if ( _AutoUidMap.empty() )
|
if ( _AutoUidMap.empty() )
|
||||||
|
|
|
@ -45,9 +45,6 @@ extern CGenericXmlMsgHeaderManager GenericXmlMsgHeaderMngr;
|
||||||
|
|
||||||
extern CVariable<bool> VerboseChatManagement;
|
extern CVariable<bool> VerboseChatManagement;
|
||||||
|
|
||||||
typedef NLMISC::CTwinMap<TChanID, string> TChanTwinMap;
|
|
||||||
extern TChanTwinMap _ChanNames;
|
|
||||||
|
|
||||||
|
|
||||||
//-----------------------------------------------
|
//-----------------------------------------------
|
||||||
// cbImpulsionReadyString :
|
// cbImpulsionReadyString :
|
||||||
|
@ -1587,26 +1584,15 @@ void cbDynChatAddChan(CMessage& msgin, const string &serviceName, TServiceId ser
|
||||||
bool noBroadcast;
|
bool noBroadcast;
|
||||||
bool forwardInput;
|
bool forwardInput;
|
||||||
bool unify;
|
bool unify;
|
||||||
string name;
|
|
||||||
|
|
||||||
msgin.serial(chanID);
|
msgin.serial(chanID);
|
||||||
msgin.serial(noBroadcast);
|
msgin.serial(noBroadcast);
|
||||||
msgin.serial(forwardInput);
|
msgin.serial(forwardInput);
|
||||||
msgin.serial(unify);
|
msgin.serial(unify);
|
||||||
msgin.serial(name);
|
nlinfo("cbDynChatAddChan: add channel");
|
||||||
|
|
||||||
nlinfo("cbDynChatAddChan: add channel : %s", name.c_str());
|
|
||||||
bool res = IOS->getChatManager().getDynChat().addChan(chanID, noBroadcast, forwardInput, unify);
|
bool res = IOS->getChatManager().getDynChat().addChan(chanID, noBroadcast, forwardInput, unify);
|
||||||
if (!res)
|
if (!res) nlwarning("Couldn't add chan %s", chanID.toString().c_str());
|
||||||
nlwarning("Couldn't add chan %s", chanID.toString().c_str());
|
else nlinfo("cbDynChatAddChan: add channel %s",chanID.toString().c_str());
|
||||||
else
|
|
||||||
{
|
|
||||||
if (_ChanNames.getA(name) == NULL && _ChanNames.getB(chanID) == NULL)
|
|
||||||
_ChanNames.add(chanID, name);
|
|
||||||
else
|
|
||||||
nlwarning("Couldn't add chan %s. already added! %p %p", chanID.toString().c_str(), _ChanNames.getA(name), _ChanNames.getB(chanID));
|
|
||||||
nlinfo("cbDynChatAddChan: add channel %s",chanID.toString().c_str());
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//-----------------------------------------------
|
//-----------------------------------------------
|
||||||
|
@ -1816,23 +1802,7 @@ void cbDynChatSetHideBubble(CMessage& msgin, const string &serviceName, TService
|
||||||
chan->HideBubble = hideBubble;
|
chan->HideBubble = hideBubble;
|
||||||
}
|
}
|
||||||
|
|
||||||
void cbDynChatSetUniversalChannel(CMessage& msgin, const string &serviceName, TServiceId serviceId)
|
|
||||||
{
|
|
||||||
TChanID chanID;
|
|
||||||
bool universalChannel;
|
|
||||||
|
|
||||||
msgin.serial(chanID);
|
|
||||||
msgin.serial(universalChannel);
|
|
||||||
|
|
||||||
CChatManager &cm = IOS->getChatManager();
|
|
||||||
CDynChatChan *chan = cm.getDynChat().getChan(chanID);
|
|
||||||
if (!chan)
|
|
||||||
{
|
|
||||||
nlwarning("Unknown chan");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
chan->UniversalChannel = universalChannel;
|
|
||||||
}
|
|
||||||
|
|
||||||
void cbDynChatServiceChat(CMessage& msgin, const string &serviceName, TServiceId serviceId)
|
void cbDynChatServiceChat(CMessage& msgin, const string &serviceName, TServiceId serviceId)
|
||||||
{
|
{
|
||||||
|
@ -2102,7 +2072,6 @@ TUnifiedCallbackItem CbIOSArray[]=
|
||||||
{ "DYN_CHAT:SERVICE_CHAT", cbDynChatServiceChat }, // a service send a chat message in the channel without sender id
|
{ "DYN_CHAT:SERVICE_CHAT", cbDynChatServiceChat }, // a service send a chat message in the channel without sender id
|
||||||
{ "DYN_CHAT:SERVICE_TELL", cbDynChatServiceTell }, // a service send a chat message to a specific client in the channel without sender id
|
{ "DYN_CHAT:SERVICE_TELL", cbDynChatServiceTell }, // a service send a chat message to a specific client in the channel without sender id
|
||||||
{ "DYN_CHAT:SET_HIDE_BUBBLE", cbDynChatSetHideBubble }, // a service send a chat message to a specific client in the channel without sender id
|
{ "DYN_CHAT:SET_HIDE_BUBBLE", cbDynChatSetHideBubble }, // a service send a chat message to a specific client in the channel without sender id
|
||||||
{ "DYN_CHAT:SET_UNIVERSAL_CHANNEL", cbDynChatSetUniversalChannel },
|
|
||||||
//received from DSS
|
//received from DSS
|
||||||
{ "REQUEST_DSR", cbRequestDsr},
|
{ "REQUEST_DSR", cbRequestDsr},
|
||||||
// { "ADD_DM", cbAddDM }, // A character enter a ring session that he own
|
// { "ADD_DM", cbAddDM }, // A character enter a ring session that he own
|
||||||
|
|
|
@ -246,60 +246,6 @@ void CStringManager::clearCache(NLMISC::CLog *log)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// load the values using the george sheet
|
|
||||||
void CStringManager::TSheetInfo::readGeorges (const NLMISC::CSmartPtr<NLGEORGES::UForm> &form, const NLMISC::CSheetId &sheetId)
|
|
||||||
{
|
|
||||||
if (form)
|
|
||||||
{
|
|
||||||
SheetName = sheetId.toString();
|
|
||||||
|
|
||||||
std::string ext = NLMISC::CSheetId::fileExtensionFromType(sheetId.getSheetType());
|
|
||||||
|
|
||||||
SheetName = SheetName.substr(0, SheetName.find(ext));
|
|
||||||
// remove ending '.'
|
|
||||||
if (!SheetName.empty() && *SheetName.rbegin() == '.')
|
|
||||||
SheetName.resize(SheetName.size()-1);
|
|
||||||
|
|
||||||
std::string gender;
|
|
||||||
|
|
||||||
if (sheetId.getSheetType() == NLMISC::CSheetId::typeFromFileExtension("creature"))
|
|
||||||
{
|
|
||||||
form->getRootNode ().getValueByName (gender, "Basics.Gender");
|
|
||||||
sint genderId;
|
|
||||||
NLMISC::fromString(gender, genderId);
|
|
||||||
Gender = GSGENDER::EGender(genderId);
|
|
||||||
|
|
||||||
form->getRootNode ().getValueByName (Race, "Basics.Race");
|
|
||||||
|
|
||||||
// form->getRootNode ().getValueByName (DisplayName, "Basics.First Name");
|
|
||||||
// std::string s;
|
|
||||||
// form->getRootNode ().getValueByName (s, "Basics.CharacterName");
|
|
||||||
// if (!DisplayName.empty())
|
|
||||||
// DisplayName+=' ';
|
|
||||||
// DisplayName+=s;
|
|
||||||
|
|
||||||
form->getRootNode ().getValueByName (Profile, "Basics.Profile");
|
|
||||||
form->getRootNode ().getValueByName (ChatProfile, "Basics.ChatProfile");
|
|
||||||
}
|
|
||||||
else if (sheetId.getSheetType() == NLMISC::CSheetId::typeFromFileExtension("race_stats"))
|
|
||||||
{
|
|
||||||
form->getRootNode ().getValueByName (Race, "Race");
|
|
||||||
}
|
|
||||||
/* else if (sheetId.getType() == NLMISC::CSheetId::typeFromFileExtension("sitem"))
|
|
||||||
{
|
|
||||||
// read any item specific data
|
|
||||||
}
|
|
||||||
*/ else
|
|
||||||
{
|
|
||||||
nlwarning("CStringManager::TEntityInfo : Do not know the type of the sheet '%s'.", sheetId.toString().c_str());
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const CStringManager::CEntityWords &CStringManager::getEntityWords(TLanguages lang, STRING_MANAGER::TParamType type) const
|
const CStringManager::CEntityWords &CStringManager::getEntityWords(TLanguages lang, STRING_MANAGER::TParamType type) const
|
||||||
{
|
{
|
||||||
nlassert(lang < NB_LANGUAGES);
|
nlassert(lang < NB_LANGUAGES);
|
||||||
|
|
Loading…
Reference in a new issue