载入中...
搜索中...
未找到
Pure cell/world projection helpers for GridConfig. 更多...
#include "common/Export.h"#include "grid/GridConfig.h"#include <cstdint>#include <functional>#include <vector>命名空间 | |
| namespace | eve |
| Build metadata (engine git commit, build time, third-party version). | |
| namespace | eve::grid |
函数 | |
| void | eve::grid::cellToWorld (const GridConfig &cfg, int cx, int cy, float &px, float &py) |
| Maps a cell to planar coordinates (px, py). On XY plane these are world (x, y); on XZ plane they are world (x, z). | |
| float | eve::grid::cellToDepthY (const GridConfig &cfg, int cx, int cy) |
| 2D sort key (cell foot Y), matching map::tileToDepthY semantics. Unused on the XZ plane. | |
| void | eve::grid::worldToCell (const GridConfig &cfg, float px, float py, int &cx, int &cy, int mapW=1, int mapH=1) |
| Maps planar coordinates to the nearest cell. Staggered/hex layouts use a bounded nearest-neighbor search; mapW/mapH bound the search range (Tiled-compatible pick semantics). | |
| void | eve::grid::foreachRotatedFootprint (int w, int h, const std::vector< uint8_t > &mask, int steps, bool hexMode, const std::function< void(int lx, int ly)> &fn) |
| Enumerates local cells of a rotated footprint. | |
| void | eve::grid::rotatedFootprintSize (int w, int h, const std::vector< uint8_t > &mask, int steps, bool hexMode, int &outW, int &outH) |
| Axis-aligned size of a footprint after rotation. | |
详细描述
Pure cell/world projection helpers for GridConfig.
在文件 GridProjection.h 中定义.