Adds default toolbox for drones, Moves drone hud to drone hud file, ticks drone hud file.

This commit is contained in:
Remie Richards
2014-09-21 20:39:29 +01:00
parent fab3e201eb
commit be079897e1
4 changed files with 19 additions and 91 deletions
-85
View File
@@ -31,88 +31,3 @@
mymob.client.screen += list(blobpwrdisplay, blobhealthdisplay)
/datum/hud/proc/drone_hud(ui_style = 'icons/mob/screen_midnight.dmi')
adding = list()
var/obj/screen/using
var/obj/screen/inventory/inv_box
using = new /obj/screen()
using.name = "drop"
using.icon = ui_style
using.icon_state = "act_drop"
using.screen_loc = ui_drone_drop
using.layer = 19
adding += using
mymob.pullin = new /obj/screen()
mymob.pullin.icon = ui_style
mymob.pullin.icon_state = "pull0"
mymob.pullin.name = "pull"
mymob.pullin.screen_loc = ui_drone_pull
adding += mymob.pullin
inv_box = new /obj/screen/inventory()
inv_box.name = "r_hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_r_inactive"
if(mymob && !mymob.hand) //Hand being true means the LEFT hand is active
inv_box.icon_state = "hand_r_active"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
inv_box.layer = 19
r_hand_hud_object = inv_box
adding += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "l_hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_l_inactive"
if(mymob && mymob.hand) //Hand being true means the LEFT hand is active
inv_box.icon_state = "hand_l_active"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
inv_box.layer = 19
l_hand_hud_object = inv_box
adding += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "internal storage"
inv_box.icon = ui_style
inv_box.icon_state = "suit_storage"
inv_box.screen_loc = ui_drone_storage
inv_box.slot_id = "drone_storage_slot"
inv_box.layer = 19
adding += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "head/mask"
inv_box.icon = ui_style
inv_box.icon_state = "mask"
inv_box.screen_loc = ui_drone_head
inv_box.slot_id = slot_head
inv_box.layer = 19
adding += inv_box
using = new /obj/screen/inventory()
using.name = "hand"
using.icon = ui_style
using.icon_state = "swap_1_m"
using.screen_loc = ui_swaphand1
using.layer = 19
adding += using
using = new /obj/screen/inventory()
using.name = "hand"
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
using.layer = 19
adding += using
mymob.zone_sel = new /obj/screen/zone_sel()
mymob.zone_sel.icon = ui_style
mymob.zone_sel.update_icon()
mymob.client.screen = null
mymob.client.screen += adding
@@ -83,3 +83,18 @@
new /obj/item/stack/cable_coil(src,30,color)
new /obj/item/weapon/wirecutters(src)
new /obj/item/device/multitool(src)
/obj/item/weapon/storage/toolbox/drone
name = "mechanical toolbox"
icon_state = "blue"
item_state = "toolbox_blue"
/obj/item/weapon/storage/toolbox/drone/New()
..()
new /obj/item/weapon/screwdriver(src)
new /obj/item/weapon/wrench(src)
new /obj/item/weapon/weldingtool(src)
new /obj/item/weapon/crowbar(src)
new /obj/item/stack/cable_coil(src,30,color)
new /obj/item/weapon/wirecutters(src)
new /obj/item/device/multitool(src)
@@ -38,7 +38,7 @@
var/light_on = 0
var/obj/item/internal_storage //Drones can store one item, of any size/type in their body
var/obj/item/head
var/obj/item/default_storage //If this exists, it will spawn in internal storage
var/obj/item/default_storage = /obj/item/weapon/storage/toolbox/drone //If this exists, it will spawn in internal storage
var/obj/item/default_hatmask //If this exists, it will spawn in the hat/mask slot if it can fit
@@ -71,7 +71,7 @@
switch(d_input)
if("Reactivate")
if(!client)
D << "<span class='notice'>This drone's OS has blue screened...</span>"
D << "<span class='notice'>This drone's OS has blue screened, there is no point in repairing them.</span>"
return
D.visible_message("<span class='notice'>[D] begins to reactivate [src].</span>")
if(do_after(user,30,needhand = 1))
@@ -182,10 +182,7 @@
src << laws
/mob/living/simple_animal/drone/verb/toggle_light()
set category = "Drone"
set name = "Toggle drone light"
/mob/living/simple_animal/drone/proc/toggle_light()
if(light_on)
AddLuminosity(-4)
else
+1
View File
@@ -76,6 +76,7 @@
#include "code\_onclick\hud\ai.dm"
#include "code\_onclick\hud\alien.dm"
#include "code\_onclick\hud\alien_larva.dm"
#include "code\_onclick\hud\drones.dm"
#include "code\_onclick\hud\hud.dm"
#include "code\_onclick\hud\human.dm"
#include "code\_onclick\hud\monkey.dm"