mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-24 01:00:25 +00:00
time_unit and pause_speed settings
This commit is contained in:
parent
11b70006aa
commit
6ea3cc4bcc
@ -164,7 +164,7 @@ bool ads_turn(int idelta) {
|
||||
}
|
||||
|
||||
if(paused && a[16+11]) {
|
||||
current = ads_matrix(spin(ang*degree) * xpush(mul*delta*-5) * spin(-ang*degree), 0) * current;
|
||||
current = ads_matrix(spin(ang*degree) * xpush(mul*delta*-pause_speed) * spin(-ang*degree), 0) * current;
|
||||
}
|
||||
else
|
||||
apply_lorentz(spin(ang*degree) * lorentz(0, 2, -delta*accel*mul) * spin(-ang*degree));
|
||||
|
@ -88,7 +88,7 @@ void draw_game_cell(cell *cs, ads_matrix V, ld plev) {
|
||||
}
|
||||
|
||||
if(view_proper_times) {
|
||||
string str = format(tformat, center.shift / TAU);
|
||||
string str = format(tformat, center.shift / time_unit);
|
||||
queuestr(shiftless(rgpushxto0(center.h)), .1, str, 0xFF4040, 8);
|
||||
}
|
||||
|
||||
@ -122,7 +122,7 @@ void draw_game_cell(cell *cs, ads_matrix V, ld plev) {
|
||||
0x000000FF, rock.col, PPR::LINE);
|
||||
|
||||
if(view_proper_times && rock.type != oParticle) {
|
||||
string str = format(tformat, rock.pt_main.shift / TAU);
|
||||
string str = format(tformat, rock.pt_main.shift / time_unit);
|
||||
queuestr(shiftless(rgpushxto0(rock.pt_main.h)), .1, str, 0xFFFFFF, 8);
|
||||
}
|
||||
}
|
||||
@ -243,13 +243,13 @@ void view_ads_game() {
|
||||
poly_outline = 0xFF;
|
||||
|
||||
if(view_proper_times) {
|
||||
string str = format(tformat, ship_pt / TAU);
|
||||
string str = format(tformat, ship_pt / time_unit);
|
||||
queuestr(shiftless(Id), .1, str, 0xFFFFFF, 8);
|
||||
}
|
||||
}
|
||||
|
||||
if(paused && view_proper_times) {
|
||||
string str = format(tformat, view_pt / TAU);
|
||||
string str = format(tformat, view_pt / time_unit);
|
||||
queuestr(shiftless(Id), .1, str, 0xFFFF00, 8);
|
||||
}
|
||||
}
|
||||
|
@ -8,6 +8,12 @@ ld simspeed = TAU;
|
||||
/** by how much do WAS keys accelerate */
|
||||
ld accel = 6;
|
||||
|
||||
/** cursor movement speed while paused */
|
||||
ld pause_speed = 5;
|
||||
|
||||
/** time unit for time display */
|
||||
ld time_unit = TAU;
|
||||
|
||||
/** transform world coordinates to current view coordinates */
|
||||
ads_matrix current;
|
||||
|
||||
@ -70,4 +76,6 @@ player_data pdata, max_pdata, tank_pdata;
|
||||
|
||||
bool auto_angle = true;
|
||||
|
||||
cell *starting_point;
|
||||
|
||||
}}
|
||||
|
Loading…
Reference in New Issue
Block a user