hi, thanks for your reply,
no it doesn't happen only in one map, it's only happening with all the maps in core2,
the normal maps like the city map they're all working fine, but if the player wants to teleport let's say to the desert,
this where the problem occurs.
also i found that the code you posted was already there in my files and it was defined too:
#define ENABLE_GOHOME_IF_MAP_NOT_ALLOWED
void CHARACTER::WarpEnd()
{
if (test_server)
sys_log(0, "WarpEnd %s", GetName());
if (m_posWarp.x == 0 && m_posWarp.y == 0)
return;
int index = m_lWarpMapIndex;
if (index > 10000)
index /= 10000;
if (!map_allow_find(index))
{
sys_err("location %d %d not allowed to login this server", m_posWarp.x, m_posWarp.y);
#ifdef ENABLE_GOHOME_IF_MAP_NOT_ALLOWED
GoHome();
#else
GetDesc()->SetPhase(PHASE_CLOSE);
#endif
return;
}
sys_log(0, "WarpEnd %s %d %u %u", GetName(), m_lWarpMapIndex, m_posWarp.x, m_posWarp.y);
Show(m_lWarpMapIndex, m_posWarp.x, m_posWarp.y, 0);
Stop();
m_lWarpMapIndex = 0;
m_posWarp.x = m_posWarp.y = m_posWarp.z = 0;
{
// P2P Login
TPacketGGLogin p;
p.bHeader = HEADER_GG_LOGIN;
strlcpy(p.szName, GetName(), sizeof(p.szName));
p.dwPID = GetPlayerID();
p.bEmpire = GetEmpire();
p.lMapIndex = SECTREE_MANAGER::instance().GetMapIndex(GetX(), GetY());
p.bChannel = g_bChannel;
P2P_MANAGER::instance().Send(&p, sizeof(TPacketGGLogin));
}
}