Puts UI on it's own plane

This commit is contained in:
monster860
2016-06-06 17:12:28 -04:00
parent 4af414f1b0
commit 64ea452f20
29 changed files with 61 additions and 2 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ git:
env:
global:
- BYOND_MAJOR="510"
- BYOND_MINOR="1336"
- BYOND_MINOR="1342"
matrix:
- DM_MAPFILE="cyberiad"
- DM_MAPFILE="metastation"
+3 -1
View File
@@ -1 +1,3 @@
#define CLICKCATCHER_PLANE -99
#define CLICKCATCHER_PLANE -99
#define HUD_PLANE 90
+2
View File
@@ -187,3 +187,5 @@
else
to_chat(usr, "<span class ='warning'>This mob type does not use a HUD.</span>")
/image
plane = FLOAT_PLANE // I have no fucking clue why this isn't FLOAT_PLANE by default in BYOND.
+1
View File
@@ -209,6 +209,7 @@
else
A.screen_loc = "CENTER+[x]:16,SOUTH+[y]:7"
A.layer = 20
A.plane = HUD_PLANE
x++
if(x == 4)
+1
View File
@@ -10,6 +10,7 @@
name = ""
icon = 'icons/mob/screen_gen.dmi'
layer = 20
plane = HUD_PLANE
unacidable = 1
var/obj/master = null //A reference to the object in the slot. Grabs or items, generally.
var/datum/hud/hud = null
+1
View File
@@ -69,6 +69,7 @@ var/const/tk_maxrange = 15
//item_state = null
w_class = 10.0
layer = 20
plane = HUD_PLANE
var/last_throw = 0
var/atom/movable/focus = null
+1
View File
@@ -54,6 +54,7 @@
qdel(W)
continue
W.layer = initial(W.layer)
W.plane = initial(W.plane)
W.loc = affected_mob.loc
W.dropped(affected_mob)
var/mob/living/new_mob = new new_form(affected_mob.loc)
+1
View File
@@ -253,6 +253,7 @@ var/round_start_time = 0
cinematic.icon = 'icons/effects/station_explosion.dmi'
cinematic.icon_state = "station_intact"
cinematic.layer = 20
cinematic.plane = HUD_PLANE
cinematic.mouse_opacity = 0
cinematic.screen_loc = "1,0"
+8
View File
@@ -64,27 +64,35 @@ datum/hSB
if(P.wear_suit)
P.wear_suit.loc = P.loc
P.wear_suit.layer = initial(P.wear_suit.layer)
P.wear_suit.plane = initial(P.wear_suit.plane)
P.wear_suit = null
P.wear_suit = new/obj/item/clothing/suit/space(P)
P.wear_suit.layer = 20
P.wear_suit.plane = HUD_PLANE
if(P.head)
P.head.loc = P.loc
P.head.layer = initial(P.head.layer)
P.head.plane = initial(P.head.plane)
P.head = null
P.head = new/obj/item/clothing/head/helmet/space(P)
P.head.layer = 20
P.head.plane = HUD_PLANE
if(P.wear_mask)
P.wear_mask.loc = P.loc
P.wear_mask.layer = initial(P.wear_mask.layer)
P.wear_mask.plane = initial(P.wear_mask.plane)
P.wear_mask = null
P.wear_mask = new/obj/item/clothing/mask/gas(P)
P.wear_mask.layer = 20
P.wear_mask.plane = HUD_PLANE
if(P.back)
P.back.loc = P.loc
P.back.layer = initial(P.back.layer)
P.back.plane = initial(P.back.plane)
P.back = null
P.back = new/obj/item/weapon/tank/jetpack(P)
P.back.layer = 20
P.back.plane = HUD_PLANE
P.internal = P.back
if("hsbmetal")
var/obj/item/stack/sheet/hsb = new/obj/item/stack/sheet/metal
+2
View File
@@ -184,6 +184,7 @@
qdel(J)
H.icon = HI
H.layer = 25
H.plane = HUD_PLANE
usr.mapobjs += H
#else
@@ -308,6 +309,7 @@
H.icon = I
qdel(I)
H.layer = 25
H.plane = HUD_PLANE
usr.mapobjs += H
#endif
@@ -6,6 +6,7 @@
density = 0
anchored = 1
layer = 20 //DEBUG
plane = HUD_PLANE //DEBUG
var/health = 10
var/stage = 1
var/obj/effect/rift/originalRift = null //the originating rift of that biomass
+1
View File
@@ -12,6 +12,7 @@
density = 0
anchored = 1
layer = 50
plane = HUD_PLANE
/obj/effect/decal/chempuff
name = "chemicals"
+1
View File
@@ -31,6 +31,7 @@
icon_state = "blank"
anchored = 1
layer = 99
plane = HUD_PLANE
mouse_opacity = 0
unacidable = 1//Just to be sure.
@@ -165,10 +165,12 @@
P.loc = usr
usr.r_hand = P
P.layer = 20
P.plane = HUD_PLANE
else if(!usr.l_hand)
P.loc = usr
usr.l_hand = P
P.layer = 20
P.plane = HUD_PLANE
if(istype(usr,/mob/living/carbon/human))
usr:update_inv_l_hand()
@@ -151,6 +151,7 @@
for(var/obj/O in src.contents)
O.screen_loc = "[cx],[cy]"
O.layer = 20
O.plane = HUD_PLANE
cx++
if (cx > mx)
cx = tx
@@ -170,6 +171,7 @@
ND.sample_object.screen_loc = "[cx]:16,[cy]:16"
ND.sample_object.maptext = "<font color='white'>[(ND.number > 1)? "[ND.number]" : ""]</font>"
ND.sample_object.layer = 20
ND.sample_object.plane = HUD_PLANE
cx++
if (cx > (4+cols))
cx = 4
@@ -180,6 +182,7 @@
O.screen_loc = "[cx]:16,[cy]:16"
O.maptext = ""
O.layer = 20
O.plane = HUD_PLANE
cx++
if (cx > (4+cols))
cx = 4
@@ -337,8 +340,10 @@
W.dropped(usr)
if(ismob(new_location))
W.layer = 20
W.plane = HUD_PLANE
else
W.layer = initial(W.layer)
W.plane = initial(W.plane)
W.loc = new_location
else
W.loc = get_turf(src)
@@ -445,6 +450,7 @@
src.closer.master = src
src.closer.icon_state = "x"
src.closer.layer = 20
src.closer.plane = HUD_PLANE
orient2hud()
return
+5
View File
@@ -1205,6 +1205,7 @@
if(I)
I.loc = locker
I.layer = initial(I.layer)
I.plane = initial(I.plane)
I.dropped(M)
M.update_icons()
@@ -1266,6 +1267,7 @@
if(I)
I.loc = M.loc
I.layer = initial(I.layer)
I.plane = initial(I.plane)
I.dropped(M)
M.Paralyse(5)
@@ -1295,6 +1297,7 @@
if(I)
I.loc = M.loc
I.layer = initial(I.layer)
I.plane = initial(I.plane)
I.dropped(M)
M.Paralyse(5)
@@ -1346,6 +1349,7 @@
if(I)
I.loc = M.loc
I.layer = initial(I.layer)
I.plane = initial(I.plane)
I.dropped(M)
if(istype(M, /mob/living/carbon/human))
@@ -2264,6 +2268,7 @@
W.loc = H.loc
W.dropped(H)
W.layer = initial(W.layer)
W.plane = initial(W.plane)
//teleport person to cell
H.loc = pick(prisonwarp)
H.equip_to_slot_or_del(new /obj/item/clothing/under/color/orange(H), slot_w_uniform)
+1
View File
@@ -693,6 +693,7 @@ var/list/non_fakeattack_weapons = list(/obj/item/weapon/gun/projectile, /obj/ite
if(slots_free.len)
halitem.screen_loc = pick(slots_free)
halitem.layer = 50
halitem.plane = HUD_PLANE
switch(rand(1,6))
if(1) //revolver
halitem.icon = 'icons/obj/gun.dmi'
+1
View File
@@ -292,6 +292,7 @@
s.use(s.max_amount)
s.forceMove(loc)
s.layer = initial(s.layer)
s.plane = initial(s.plane)
/obj/machinery/mineral/ore_redemption/power_change()
..()
+4
View File
@@ -28,6 +28,7 @@
W.forceMove(src) //TODO: move to equipped?
l_hand = W
W.layer = 20 //TODO: move to equipped?
W.plane = HUD_PLANE //TODO: move to equipped?
W.equipped(src,slot_l_hand)
if(pulling == W)
stop_pulling()
@@ -43,6 +44,7 @@
W.forceMove(src)
r_hand = W
W.layer = 20
W.plane = HUD_PLANE
W.equipped(src,slot_r_hand)
if(pulling == W)
stop_pulling()
@@ -72,6 +74,7 @@
/mob/proc/put_in_hands(obj/item/W)
W.forceMove(get_turf(src))
W.layer = initial(W.layer)
W.plane = initial(W.plane)
W.dropped()
/mob/proc/drop_item_v() //this is dumb.
@@ -124,6 +127,7 @@
I.dropped(src)
if(I)
I.layer = initial(I.layer)
I.plane = initial(I.plane)
return 1
+4
View File
@@ -455,6 +455,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
for(var/obj/machinery/atmospherics/A in totalMembers)
if(!A.pipe_image)
A.pipe_image = image(A, A.loc, layer = 20, dir = A.dir) //the 20 puts it above Byond's darkness (not its opacity view)
A.pipe_image.plane = HUD_PLANE
pipes_shown += A.pipe_image
client.images += A.pipe_image
@@ -563,6 +564,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
//actually throw it!
if (item)
item.layer = initial(item.layer)
item.plane = initial(item.plane)
visible_message("\red [src] has thrown [item].")
newtonian_move(get_dir(target, src))
@@ -914,6 +916,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
W.dropped(src)
if (W)
W.layer = initial(W.layer)
W.plane = initial(W.plane)
if (legcuffed)
var/obj/item/weapon/W = legcuffed
legcuffed = null
@@ -925,6 +928,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
W.dropped(src)
if (W)
W.layer = initial(W.layer)
W.plane = initial(W.plane)
/mob/living/carbon/proc/slip(var/description, var/stun, var/weaken, var/tilesSlipped, var/walkSafely, var/slipAny)
+1
View File
@@ -49,6 +49,7 @@
target.l_hand = I
I.loc = target
I.layer = 20
I.plane = HUD_PLANE
I.add_fingerprint(target)
src.update_inv_l_hand()
src.update_inv_r_hand()
@@ -218,6 +218,7 @@
W.loc = src
W.equipped(src, slot)
W.layer = 20
W.plane = HUD_PLANE
switch(slot)
if(slot_back)
@@ -260,6 +261,7 @@
O.loc = src
r_ear = O
O.layer = 20
O.plane = HUD_PLANE
update_inv_ears(redraw_mob)
if(slot_r_ear)
r_ear = W
@@ -268,6 +270,7 @@
O.loc = src
l_ear = O
O.layer = 20
O.plane = HUD_PLANE
update_inv_ears(redraw_mob)
if(slot_glasses)
glasses = W
@@ -636,6 +636,7 @@ var/global/list/damage_icon_parts = list()
thing.loc = loc //
thing.dropped(src) //
thing.layer = initial(thing.layer)
thing.plane = initial(thing.plane)
if(update_icons) update_icons()
/mob/living/carbon/human/update_inv_wear_id(var/update_icons=1)
@@ -56,6 +56,7 @@
O.mouse_opacity = initial(O.mouse_opacity)
module_state_1 = O
O.layer = 20
O.plane = HUD_PLANE
O.screen_loc = inv1.screen_loc
contents += O
if(istype(module_state_1,/obj/item/borg/sight))
@@ -64,6 +65,7 @@
O.mouse_opacity = initial(O.mouse_opacity)
module_state_2 = O
O.layer = 20
O.plane = HUD_PLANE
O.screen_loc = inv2.screen_loc
contents += O
if(istype(module_state_2,/obj/item/borg/sight))
@@ -72,6 +74,7 @@
O.mouse_opacity = initial(O.mouse_opacity)
module_state_3 = O
O.layer = 20
O.plane = HUD_PLANE
O.screen_loc = inv3.screen_loc
contents += O
if(istype(module_state_3,/obj/item/borg/sight))
@@ -243,6 +243,7 @@
/mob/living/simple_animal/diona/put_in_hands(obj/item/W)
W.loc = get_turf(src)
W.layer = initial(W.layer)
W.plane = initial(W.plane)
W.dropped()
/mob/living/simple_animal/diona/put_in_active_hand(obj/item/W)
+1
View File
@@ -23,6 +23,7 @@
var/dancing //determines if assailant and affecting keep looking at each other. Basically a wrestling position
layer = 21
plane = HUD_PLANE
item_state = "nothing"
icon = 'icons/mob/screen_gen.dmi'
w_class = 5.0
+2
View File
@@ -398,12 +398,14 @@
h_user.unEquip(src)
B.loc = h_user
B.layer = 20
B.plane = HUD_PLANE
h_user.l_store = B
h_user.update_inv_pockets()
else if (h_user.r_store == src)
h_user.unEquip(src)
B.loc = h_user
B.layer = 20
B.plane = HUD_PLANE
h_user.r_store = B
h_user.update_inv_pockets()
else if (h_user.head == src)
+1
View File
@@ -204,6 +204,7 @@
for(var/obj/O in src)
O.loc = usr.loc
O.layer = initial(O.layer)
O.plane = initial(O.plane)
O.add_fingerprint(usr)
usr.unEquip(src)
qdel(src)
@@ -113,6 +113,7 @@ var/global/list/rad_collectors = list()
return
Z.loc = get_turf(src)
Z.layer = initial(Z.layer)
Z.plane = initial(Z.plane)
src.P = null
if(active)
toggle_power()