mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-08-30 09:17:57 +00:00
embeddings:: fixed monster movement animations in euc_in_hyp
This commit is contained in:
@@ -234,6 +234,8 @@ EX }
|
||||
virtual transmatrix get_lti() { return logical_scaled_to_intermediate; }
|
||||
virtual hyperpoint base_to_logical(hyperpoint h) = 0;
|
||||
virtual hyperpoint logical_to_base(hyperpoint h) = 0;
|
||||
virtual ld anim_center_z() { return center_z(); }
|
||||
virtual hyperpoint anim_tile_center();
|
||||
|
||||
virtual bool is_euc_in_product() { return false; }
|
||||
virtual bool is_product_embedding() { return false; }
|
||||
@@ -276,6 +278,12 @@ hyperpoint embedding_method::tile_center() {
|
||||
return lzpush(z) * C0;
|
||||
}
|
||||
|
||||
hyperpoint embedding_method::anim_tile_center() {
|
||||
ld z = anim_center_z();
|
||||
if(z == 0) return C0;
|
||||
return lzpush(z) * C0;
|
||||
}
|
||||
|
||||
transmatrix embedding_method::map_relative_push(hyperpoint a) {
|
||||
auto i = actual_to_intermediate(a);
|
||||
return intermediate_to_actual_translation(i);
|
||||
@@ -522,6 +530,7 @@ struct emb_euc_in_hyp : emb_actual {
|
||||
}
|
||||
hyperpoint actual_to_base(hyperpoint h) override { return deparabolic13(h); }
|
||||
transmatrix actual_to_base(const transmatrix& T) override { hyperpoint h = deparabolic13(T * C0); return eupush(h[0], h[1]); }
|
||||
ld anim_center_z() override { return vid.depth; }
|
||||
};
|
||||
|
||||
/** sphere into a isotropic space of higher curvature */
|
||||
|
Reference in New Issue
Block a user