mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-03-25 04:47:02 +00:00
gp::pshid is now in gpdata
This commit is contained in:
parent
78dbf6824d
commit
4013d55c27
@ -773,8 +773,6 @@ void geometry_information::generate_floorshapes() {
|
||||
|
||||
#if CAP_GP
|
||||
EX namespace gp {
|
||||
int pshid[3][8][32][32][8];
|
||||
int nextid;
|
||||
|
||||
EX void clear_plainshapes() {
|
||||
for(int m=0; m<3; m++)
|
||||
@ -782,12 +780,12 @@ EX namespace gp {
|
||||
for(int i=0; i<32; i++)
|
||||
for(int j=0; j<32; j++)
|
||||
for(int k=0; k<8; k++)
|
||||
pshid[m][sd][i][j][k] = -1;
|
||||
nextid = 0;
|
||||
cgi.gpdata->pshid[m][sd][i][j][k] = -1;
|
||||
cgi.gpdata->nextid = 0;
|
||||
}
|
||||
|
||||
void build_plainshape(int& id, gp::local_info& li, cell *c0, int siid, int sidir) {
|
||||
id = nextid++;
|
||||
id = cgi.gpdata->nextid++;
|
||||
|
||||
bool master = !(li.relative.first||li.relative.second);
|
||||
int cor = master ? S7 : SG6;
|
||||
@ -818,7 +816,7 @@ EX namespace gp {
|
||||
siid = 0;
|
||||
sidir = 0;
|
||||
}
|
||||
auto& id = pshid[siid][sidir][draw_li.relative.first&31][draw_li.relative.second&31][gmod(draw_li.total_dir, S6)];
|
||||
auto& id = cgi.gpdata->pshid[siid][sidir][draw_li.relative.first&31][draw_li.relative.second&31][gmod(draw_li.total_dir, S6)];
|
||||
if(id == -1 && sphere && isize(cgi.shFloor.b) > 0) {
|
||||
forCellEx(c1, c) if(!gmatrix0.count(c1)) return 0;
|
||||
}
|
||||
|
@ -439,6 +439,8 @@ hpcshape
|
||||
transmatrix corners;
|
||||
ld alpha;
|
||||
int area;
|
||||
int pshid[3][8][32][32][8];
|
||||
int nextid;
|
||||
};
|
||||
shared_ptr<gpdata_t> gpdata = nullptr;
|
||||
#endif
|
||||
|
@ -613,6 +613,7 @@ EX namespace gp {
|
||||
center_locs.clear();
|
||||
if(GOLDBERG) {
|
||||
if(!cgi.gpdata) cgi.gpdata = make_shared<geometry_information::gpdata_t>();
|
||||
gp::clear_plainshapes();
|
||||
int x = param.first;
|
||||
int y = param.second;
|
||||
if(S3 == 3)
|
||||
|
@ -1149,9 +1149,6 @@ void geometry_information::prepare_shapes() {
|
||||
|
||||
symmetriesAt.clear();
|
||||
allshapes.clear();
|
||||
#if CAP_GP
|
||||
gp::clear_plainshapes();
|
||||
#endif
|
||||
DEBBI(DF_POLY, ("buildpolys"));
|
||||
|
||||
if(WDIM == 3 && !hybri) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user