mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-23 13:07:16 +00:00
cleaner nil model conversions
This commit is contained in:
parent
cd364831f8
commit
bb26fe314c
@ -766,8 +766,12 @@ EX namespace nilv {
|
||||
return H[0] * H[1] / 2;
|
||||
}
|
||||
|
||||
EX ld convert_bonus(hyperpoint H, ld from, ld to) {
|
||||
return sym_to_heis_bonus(H) * (to - from);
|
||||
}
|
||||
|
||||
EX hyperpoint convert(hyperpoint H, ld from, ld to) {
|
||||
H[2] += sym_to_heis_bonus(H) * (to - from);
|
||||
H[2] += convert_bonus(H, from, to);
|
||||
return H;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user