示例#1
0
TerrainRenderer::PointF TerrainRenderer::GetBAround(const MapPoint pt, const unsigned char triangle, const unsigned char dir)
{
    PointI ptNb = GetPointAround(PointI(pt), dir);

    Point<int> offset;
    MapPoint t = ConvertCoords(ptNb, &offset);

    return GetB(t, triangle) + PointF(offset);
}
示例#2
0
TerrainRenderer::PointF TerrainRenderer::GetTerrainAround(MapPoint pt, const unsigned dir)
{
    PointI ptNb = GetPointAround(PointI(pt), dir);

    PointI offset;
    MapPoint t = ConvertCoords(ptNb, &offset);

    return GetTerrain(t) + PointF(offset);
}
示例#3
0
float TerrainRenderer::GetTerrainYAround(int x,  int y, const unsigned dir)
{
    GetPointAround(x, y, dir);

    int yo;
    MapPoint t = ConvertCoords(x, y, NULL, &yo);

    return GetTerrainY(t) + yo;
}
示例#4
0
float TerrainRenderer::GetTerrainXAround(int x,  int y, const unsigned dir)
{
    GetPointAround(x, y, dir);

    int xo;
    MapPoint t = ConvertCoords(x, y, &xo);

    return GetTerrainX(t) + xo;
}
示例#5
0
float TerrainRenderer::GetBYAround(int x, int y, const unsigned char triangle, const unsigned char dir)
{
    GetPointAround(x, y, dir);

    int yo;
    MapPoint t = ConvertCoords(x, y, NULL, &yo);

    return GetBY(t, triangle) + yo;
}
示例#6
0
float TerrainRenderer::GetBXAround(int x, int y, const unsigned char triangle, const unsigned char dir)
{
    GetPointAround(x, y, dir);

    int xo;
    MapPoint t = ConvertCoords(x, y, &xo, NULL);

    return GetBX(t, triangle) + xo;
}
float TerrainRenderer::GetTerrainYAround(int x,  int y, const unsigned dir)
{
	unsigned short tx,ty;
	
	GetPointAround(x,y,dir);

	int xo,yo;
	ConvertCoords(x,y,tx,ty,&xo,&yo);

	return GetTerrainY(tx,ty)+yo;
}
float TerrainRenderer::GetBXAround(int x, int y, const unsigned char triangle, const unsigned char dir)
{
	unsigned short tx,ty;

	GetPointAround(x,y,dir);

	int xo,yo;
	ConvertCoords(x,y,tx,ty,&xo,&yo);

	return GetBX(tx,ty,triangle)+xo;
}