mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-05-02 23:44:05 +00:00
rogueviz::kohonen:: animate option
This commit is contained in:
parent
5df3fe3d12
commit
e575fed606
@ -1358,8 +1358,10 @@ void neurondisttable(const string &name) {
|
|||||||
fclose(f);
|
fclose(f);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool animate = true;
|
||||||
|
|
||||||
void steps() {
|
void steps() {
|
||||||
if(!kohonen::finished()) {
|
if(kohonen::animate && !kohonen::finished()) {
|
||||||
unsigned int t = SDL_GetTicks();
|
unsigned int t = SDL_GetTicks();
|
||||||
while(SDL_GetTicks() < t+20) kohonen::step();
|
while(SDL_GetTicks() < t+20) kohonen::step();
|
||||||
setindex(false);
|
setindex(false);
|
||||||
@ -1749,6 +1751,7 @@ auto hooks4 = addHook(hooks_clearmemory, 100, clear)
|
|||||||
-> editable(0, 2, .2, "precise placement", "0 = make all visible, 1 = place ideally, n = place 1/n of the distance from center to ideal placement", 'p')
|
-> editable(0, 2, .2, "precise placement", "0 = make all visible, 1 = place ideally, n = place 1/n of the distance from center to ideal placement", 'p')
|
||||||
-> set_reaction([] { if((state & KS_NEURONS) && (state & KS_SAMPLES)) distribute_neurons(); });
|
-> set_reaction([] { if((state & KS_NEURONS) && (state & KS_SAMPLES)) distribute_neurons(); });
|
||||||
param_b(show_rings, "som_show_rings");
|
param_b(show_rings, "som_show_rings");
|
||||||
|
param_b(animate, "animate");
|
||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user