22 lines
686 B
C++
22 lines
686 B
C++
#pragma once
|
|
|
|
#include <godot_cpp/variant/dictionary.hpp>
|
|
#include <godot_cpp/variant/vector2i.hpp>
|
|
|
|
extern "C" {
|
|
#include "gen/grid.h"
|
|
}
|
|
|
|
namespace godot {
|
|
|
|
/* Pack a grid_t into a Dictionary with the shape documented in the plugin
|
|
README (terrain/liquid/flags/room_id/machine_id/surface arrays). Used by
|
|
both BrogueGen.generate() and BrogueReplay.get_grid(). Additional
|
|
metadata (rooms, machines, chokepoints, stairs) are computed and added
|
|
when add_metadata is true. */
|
|
Dictionary grid_to_dictionary(grid_t g, int seed, int depth, bool add_metadata);
|
|
|
|
/* Pack a single cell as a Dictionary. */
|
|
Dictionary cell_to_dictionary(grid_t g, int x, int y);
|
|
|
|
} // namespace godot
|