mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-27 14:37:16 +00:00
rogueviz:: rename nodes via color file
This commit is contained in:
parent
1f834d3def
commit
71d49b7198
@ -809,6 +809,15 @@ void readcolor(const string& cfname) {
|
||||
vdata[getid(lab)].info = new string(buf); // replace with std::shared_ptr in C++111
|
||||
continue;
|
||||
}
|
||||
else if(c2 == '>') {
|
||||
char buf[600];
|
||||
int err = fscanf(f, "%500s", buf);
|
||||
if(err > 0) {
|
||||
vdata[getid(lab)].name = buf;
|
||||
for(char& ch: vdata[getid(lab)].name) if(ch == '_') ch = ' ';
|
||||
}
|
||||
continue;
|
||||
}
|
||||
else {
|
||||
ungetc(c2, f);
|
||||
char buf[600];
|
||||
|
Loading…
Reference in New Issue
Block a user