diff --git a/source/glest_game/type_instances/unit.cpp b/source/glest_game/type_instances/unit.cpp index d7c46e8ce..26794c7a9 100644 --- a/source/glest_game/type_instances/unit.cpp +++ b/source/glest_game/type_instances/unit.cpp @@ -892,7 +892,8 @@ Vec2f Unit::getFloatCenteredPos() const { throw megaglest_runtime_error(szBuf); } - return Vec2f(pos.x-0.5f+type->getSize()/2.f, pos.y-0.5f+type->getSize()/2.f); + return Vec2f(truncateDecimal(pos.x-0.5f+type->getSize()/2.f,6), + truncateDecimal(pos.y-0.5f+type->getSize()/2.f,6)); } Vec2i Unit::getCellPos() const { diff --git a/source/shared_lib/sources/platform/posix/socket.cpp b/source/shared_lib/sources/platform/posix/socket.cpp index 6e3501af3..293e34d25 100644 --- a/source/shared_lib/sources/platform/posix/socket.cpp +++ b/source/shared_lib/sources/platform/posix/socket.cpp @@ -686,7 +686,7 @@ std::vector Socket::getLocalIPAddressList() { for(int ipIdx = 0; myhostent->h_addr_list[ipIdx] != NULL; ++ipIdx) { Ip::Inet_NtoA(SockAddrToUint32((struct in_addr *)myhostent->h_addr_list[ipIdx]), myhostaddr); - //printf("ipIdx = %d [%s]\n",ipIdx,myhostaddr); + printf("ipIdx = %d [%s]\n",ipIdx,myhostaddr); if(SystemFlags::getSystemSettingType(SystemFlags::debugNetwork).enabled) SystemFlags::OutputDebug(SystemFlags::debugNetwork,"In [%s::%s Line: %d] myhostaddr = [%s]\n",__FILE__,__FUNCTION__,__LINE__,myhostaddr); if(strlen(myhostaddr) > 0 && @@ -709,6 +709,16 @@ std::vector Socket::getLocalIPAddressList() { intfTypes.push_back("vboxnet"); intfTypes.push_back("br-lan"); intfTypes.push_back("br-gest"); + intfTypes.push_back("enp0s"); + intfTypes.push_back("enp1s"); + intfTypes.push_back("enp2s"); + intfTypes.push_back("enp3s"); + intfTypes.push_back("enp4s"); + intfTypes.push_back("enp5s"); + intfTypes.push_back("enp6s"); + intfTypes.push_back("enp7s"); + intfTypes.push_back("enp8s"); + intfTypes.push_back("enp9s"); for(int intfIdx = 0; intfIdx < (int)intfTypes.size(); intfIdx++) { string intfName = intfTypes[intfIdx];