mirror of
				https://github.com/zenorogue/hyperrogue.git
				synced 2025-10-31 05:52:59 +00:00 
			
		
		
		
	fixed radar in euc_in_sph (no animate), radar in euc_in_product (somewhat), fixed_YZ in euc_in_sph
This commit is contained in:
		| @@ -5098,6 +5098,9 @@ EX void make_actual_view() { | ||||
|  | ||||
|       current_display->radar_transform = R * zpush(z); | ||||
|       } | ||||
|     else if(geom3::euc_in_sph()) { | ||||
|       current_display->radar_transform = inverse(View); | ||||
|       } | ||||
|     else { | ||||
|       transmatrix T = actual_view_transform * View; | ||||
|       transmatrix U = view_inverse(T); | ||||
|   | ||||
| @@ -1910,7 +1910,7 @@ EX hyperpoint vertical_vector() { | ||||
|     } | ||||
|   if(embedded_plane && geom3::same_in_same()) | ||||
|     return get_view_orientation() * lztangent(vid.wall_height); | ||||
|   if(geom3::euc_in_sl2()) { | ||||
|   if(geom3::euc_in_sl2() || geom3::euc_in_sph()) { | ||||
|     transmatrix Rot = View * map_relative_push(inverse(View) * C0); | ||||
|     return Rot * lztangent(vid.wall_height); | ||||
|     } | ||||
|   | ||||
							
								
								
									
										22
									
								
								radar.cpp
									
									
									
									
									
								
							
							
						
						
									
										22
									
								
								radar.cpp
									
									
									
									
									
								
							| @@ -54,6 +54,28 @@ pair<bool, hyperpoint> makeradar(shiftpoint h) { | ||||
|       if(d > vid.radarrange) return {false, h1}; | ||||
|       if(d) h1 = h1 * (d / (vid.radarrange + cgi.scalefactor/4) / hypot_d(3, h1)); | ||||
|       } | ||||
|     else if(geom3::euc_in_sph()) { | ||||
|       h1[0] = atan2(h.h[0], h.h[2]); | ||||
|       h1[1] = atan2(h.h[1], h.h[3]); | ||||
|       h1[2] = 0; | ||||
|       h1 = cgi.intermediate_to_logical * h1; | ||||
|       d = hypot_d(2, h1); | ||||
|       if(d > vid.radarrange) return {false, h1}; | ||||
|       if(d) h1 = h1 / (vid.radarrange + cgi.scalefactor/4); | ||||
|       } | ||||
|     else if(geom3::euc_in_product()) { | ||||
|       if(in_h2xe()) | ||||
|         h1[0] = atanh(h.h[0] / h.h[2]); | ||||
|       else | ||||
|         h1[0] = atan2(h.h[2], h.h[0]); | ||||
|       h1[2] = - zlevel(h.h) - h.shift; | ||||
|       h1[1] = 0; | ||||
|       h1[3] = 0; | ||||
|       h1 = cgi.intermediate_to_logical * h1; | ||||
|       d = hypot_d(2, h1); | ||||
|       if(d > vid.radarrange) return {false, h1}; | ||||
|       if(d) h1 = h1 / (vid.radarrange + cgi.scalefactor/4); | ||||
|       } | ||||
|     else { | ||||
|       d = hypot_d(2, h1); | ||||
|       if(d > vid.radarrange) return {false, h1}; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Zeno Rogue
					Zeno Rogue