mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-25 22:19:30 +01:00
Camera eyes have been lightly refactored (among other things...) (#87805)
## About The Pull Request * A generic /mob/eye/camera type has been made, containing everything needed to interface with a cameranet * /mob/eye/ai_eye has been refactored into a generic /mob/eye/camera instance * Advanced cameras no longer inherit from AI eyes, splitting off behaviour * Camera code has been somewhat cleaned up * Probably some more stuff I'm forgetting right now ## Big man Southport:  ## Changelog 🆑 code: made /proc/getviewsize() pure refactor: mob/eye/ai_eye has been restructured, now inheriting from a generic mob/eye/camera type refactor: advanced cameras and their subtypes are now mob/eye/camera/remote subtypes code: the cameranet no longer expects the user to be an AI eye code: remote camera eyes have had their initialization streamlined code: remote cameras handle assigning and unassigning users by themselves now code: remote cameras now use weakrefs instead of hard referencing owners and origins code: also the sentient disease is_define was removed (we don't have those anymore) fix: AI eyes no longer assign real names to themselves, fixing their orbit name /🆑 --------- Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
This commit is contained in:
@@ -204,7 +204,7 @@
|
||||
var/turf/our_turf = get_turf(src)
|
||||
detect_state = PROXIMITY_NONE
|
||||
|
||||
for(var/mob/eye/ai_eye/AI_eye as anything in GLOB.aiEyes)
|
||||
for(var/mob/eye/camera/ai/AI_eye as anything in GLOB.camera_eyes)
|
||||
if(!AI_eye.ai_detector_visible)
|
||||
continue
|
||||
|
||||
@@ -253,7 +253,7 @@
|
||||
// copied from camera chunks but we are doing a really big edge case here though
|
||||
/obj/item/multitool/ai_detect/proc/surrounding_chunks(turf/epicenter)
|
||||
. = list()
|
||||
var/static_range = /mob/eye/ai_eye::static_visibility_range
|
||||
var/static_range = /mob/eye/camera/ai::static_visibility_range
|
||||
var/x1 = max(1, epicenter.x - static_range)
|
||||
var/y1 = max(1, epicenter.y - static_range)
|
||||
var/x2 = min(world.maxx, epicenter.x + static_range)
|
||||
|
||||
Reference in New Issue
Block a user