@@ -172,7 +172,7 @@ Sector::finish_construction(bool editable)
172
172
}
173
173
174
174
SpawnPointMarker*
175
- Sector::get_spawn_point (const std::string& spawnpoint)
175
+ Sector::get_spawn_point (const std::string& spawnpoint) const
176
176
{
177
177
SpawnPointMarker* sp = nullptr ;
178
178
for (auto & spawn_point : get_objects_by_type<SpawnPointMarker>()) {
@@ -186,7 +186,7 @@ Sector::get_spawn_point(const std::string& spawnpoint)
186
186
}
187
187
188
188
Vector
189
- Sector::get_spawn_point_position (const std::string& spawnpoint)
189
+ Sector::get_spawn_point_position (const std::string& spawnpoint) const
190
190
{
191
191
SpawnPointMarker* sp = get_spawn_point (spawnpoint);
192
192
if (sp)
@@ -317,11 +317,11 @@ Sector::deactivate()
317
317
Rectf
318
318
Sector::get_active_region () const
319
319
{
320
- Camera& camera = get_camera ();
320
+ auto cam_translation = get_camera (). get_translation ();
321
321
return Rectf (
322
- camera. get_translation () - Vector (1600 , 1200 ),
323
- camera. get_translation () + Vector (1600 , 1200 ) + Vector (static_cast <float >(SCREEN_WIDTH),
324
- static_cast <float >(SCREEN_HEIGHT)));
322
+ cam_translation - Vector (1600 , 1200 ),
323
+ cam_translation + Vector (1600 , 1200 ) + Vector (static_cast <float >(SCREEN_WIDTH),
324
+ static_cast <float >(SCREEN_HEIGHT)));
325
325
}
326
326
327
327
int
0 commit comments