mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-18 11:36:24 +01:00
Fixes bug where the library scanner is not recognized. (#24496)
* fixes bug where scanner is not recognized * find scanner is a proc
This commit is contained in:
@@ -270,9 +270,7 @@ var/global/list/datum/cachedbook/cachedbooks // List of our cached book datums
|
||||
if(5)
|
||||
dat += "<H3>Upload a New Title</H3>"
|
||||
if(!scanner)
|
||||
for(var/obj/machinery/libraryscanner/S in range(9))
|
||||
scanner = S
|
||||
break
|
||||
findscanner(9)
|
||||
if(!scanner)
|
||||
dat += "<FONT color=red>No scanner found within wireless network range.</FONT><BR>"
|
||||
else if(!scanner.cache)
|
||||
@@ -288,6 +286,8 @@ var/global/list/datum/cachedbook/cachedbooks // List of our cached book datums
|
||||
dat += "<A href='?src=\ref[src];switchscreen=0'>(Return to main menu)</A><BR>"
|
||||
if(6)
|
||||
dat += "<h3>Post Title to Newscaster</h3>"
|
||||
if(!scanner)
|
||||
scanner = findscanner(9)
|
||||
if(!scanner)
|
||||
dat += "<FONT color=red>No scanner found within wireless network range.</FONT><BR>"
|
||||
else if(!scanner.cache)
|
||||
@@ -313,6 +313,11 @@ var/global/list/datum/cachedbook/cachedbooks // List of our cached book datums
|
||||
popup.set_title_image(user.browse_rsc_icon(src.icon, src.icon_state))
|
||||
popup.open()
|
||||
|
||||
/obj/machinery/computer/libraryconsole/bookmanagement/proc/findscanner(viewrange)
|
||||
for(var/obj/machinery/libraryscanner/S in range(viewrange))
|
||||
return S
|
||||
return null
|
||||
|
||||
/obj/machinery/computer/libraryconsole/bookmanagement/proc/print_forbidden_lore(mob/user)
|
||||
var/spook = pick("blood", "brass")
|
||||
var/turf/T = get_turf(src)
|
||||
|
||||
Reference in New Issue
Block a user