ID:2714027
 
Resolved
When using screen_loc with the edge keywords TOP, BOTTOM, LEFT, or RIGHT, or any combination thereof, the coordinates could be wrong if other HUD elements stretched the map (e.g., an item at "-1,-2") or when using a secondary map control.
BYOND Version:514
Operating System:N/A
Web Browser:N/A
Applies to:Dream Seeker
Status: Resolved (514.1567)

This issue has been resolved.
Descriptive Problem Summary:

When using screen_loc with the edge keywords TOP, BOTTOM, LEFT, or RIGHT, or any combination thereof, the coordinates could be wrong if other HUD elements stretched the map (e.g., an item at "-1,-2") or when using a secondary map control.

Numbered Steps to Reproduce Problem:

Code Snippet (if applicable) to Reproduce Problem:
turf
icon = 'floor.dmi'

obj
icon = 'items.dmi'
sphere/icon_state = "sphere"
cylinder/icon_state = "cylinder"
box/icon_state = "box"
pyramid/icon_state = "pyramid"
cone/icon_state = "cone"

screen48
icon = 'screen48.dmi'


mob
icon = 'smile4.dmi'

proc/MakeScreen(t, l, both, attrs)
var/obj/O = new t()
O.screen_loc = l
client?.screen += O

var/a
for(a in attrs)
try O.vars[a] = attrs[a]
catch()

if(both)
O = new t()
O.screen_loc = "map2:[l]"
client?.screen += O

for(a in attrs)
try O.vars[a] = attrs[a]
catch()

Login()
..()
MakeScreen(/obj/screen48, "TOPLEFT", 1, list("color"="#f55"))
MakeScreen(/obj/screen48, "BOTTOMRIGHT", 1, list("color"="#55f"))
MakeScreen(/obj/screen48, "TOPRIGHT", 1, list("color"=list(null,null,null,"#0f0f",null)))
MakeScreen(/obj/box, "0,-1")
MakeScreen(/obj/box, "EAST+2,NORTH+1")
MakeScreen(/obj/cone, "map2:1,1")
MakeScreen(/obj/cone, "map2:5,4")


Expected Results:

The HUD objects using edge coordinates should be positioned correctly.

Actual Results:

The objects don't appear at all, or appear in the wrong positions.
Lummox JR resolved issue with message:
When using screen_loc with the edge keywords TOP, BOTTOM, LEFT, or RIGHT, or any combination thereof, the coordinates could be wrong if other HUD elements stretched the map (e.g., an item at "-1,-2") or when using a secondary map control.