@WorldData.h 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. /******************************************************************************/
  2. /******************************************************************************/
  3. class WorldData
  4. {
  5. UID elm_id;
  6. Elm *elm;
  7. Grid<Area> grid;
  8. Str edit_path, game_path, edit_area_path, game_area_path, edit_waypoint_path, game_waypoint_path, lake_path, river_path;
  9. flt area_size;
  10. int hm_res;
  11. WorldVer *ver;
  12. Memx<Obj> objs;
  13. PathWorld path_world;
  14. PathSettings path_settings;
  15. EnvironmentPtr environment;
  16. WorldData();
  17. flt areaSize()C;
  18. int hmRes ()C;
  19. Vec2 areaToWorld(C VecI2 &xz )C; // convert Area Coordinates to World Position
  20. VecI2 worldToArea (C Vec2 &xz )C; // convert World Position to Area Coordinates
  21. VecI2 worldToArea (C Vec &pos )C; // convert World Position to Area Coordinates
  22. RectI worldToArea (C Rect &rect)C; // convert World Position to Area Coordinates
  23. RectI worldToArea (C Box &box )C; // convert World Position to Area Coordinates
  24. Area* getArea (C VecI2 &area_xy);
  25. Area* findArea (C VecI2 &area_xy);
  26. Area* findAreaLoaded(C VecI2 &area_xy);
  27. void load();
  28. void flush();
  29. void unload();
  30. };
  31. /******************************************************************************/
  32. /******************************************************************************/
  33. /******************************************************************************/