anchor.diff:  
   /obj/structure/window/reinforced/unanchored
   	anchored = FALSE
  +	state = WINDOW_OUT_OF_FRAME
   
   /obj/structure/window/plasma
   	name = "plasma window"
  
positive.code: 
  /obj/structure/window/reinforced/fulltile/unanchored
  	anchored = FALSE
  
  /obj/structure/window/reinforced/tinted/fulltile
  	icon = 'icons/obj/smooth_structures/tinted_window.dmi'
  
negative.code: 
  	if(!(flags_1&NODECONSTRUCT_1) && !(reinf && state >= RWINDOW_FRAME_BOLTED))
  		if(I.tool_behaviour == TOOL_SCREWDRIVER)
  			to_chat(user, "<span class='notice'>You begin to [anchored ? "unscrew the window from":"screw the window to"] the floor...</span>")
  			if(I.use_tool(src, user, decon_speed, volume = 75, extra_checks = CALLBACK(src, .proc/check_anchored, anchored)))
  				setAnchored(!anchored)
  				to_chat(user, "<span class='notice'>You [anchored ? "fasten the window to":"unfasten the window from"] the floor.</span>")
  			return
  		else if(I.tool_behaviour == TOOL_WRENCH && !anchored)
  			to_chat(user, "<span class='notice'> You begin to disassemble [src]...</span>")
  			if(I.use_tool(src, user, decon_speed, volume = 75, extra_checks = CALLBACK(src, .proc/check_state_and_anchored, state, anchored)))
  				var/obj/item/stack/sheet/G = new glass_type(user.loc, glass_amount)
  				G.add_fingerprint(user)
  				playsound(src, 'sound/items/Deconstruct.ogg', 50, TRUE)
  				to_chat(user, "<span class='notice'>You successfully disassemble [src].</span>")
  				qdel(src)
  			return
  		else if(I.tool_behaviour == TOOL_CROWBAR && reinf && (state == WINDOW_OUT_OF_FRAME) && anchored)
  			to_chat(user, "<span class='notice'>You begin to lever the window into the frame...</span>")
  			if(I.use_tool(src, user, 100, volume = 75, extra_checks = CALLBACK(src, .proc/check_state_and_anchored, state, anchored)))
  				state = RWINDOW_SECURE
  				to_chat(user, "<span class='notice'>You pry the window into the frame.</span>")
  			return
  
  	return ..()
  
  /obj/structure/window/setAnchored(anchorvalue)
  