Merge pull request #19810 from KorPhaeron/blueprint_fix

Refactors area creation
This commit is contained in:
oranges
2016-08-15 00:01:00 +12:00
committed by GitHub
13 changed files with 69 additions and 95 deletions

View File

@@ -24,6 +24,8 @@
#define ui_lingchemdisplay "WEST:6,CENTER-1:15"
#define ui_lingstingdisplay "WEST:6,CENTER-3:11"
#define ui_crafting "12:-10,1:5"
#define ui_building "12:-10,1:21"
#define ui_devilsouldisplay "WEST:6,CENTER-1:15"
//Lower center, persistant menu

View File

@@ -51,6 +51,10 @@
using.icon = ui_style
static_inventory += using
using = new /obj/screen/inventory/area_creator
using.icon = ui_style
static_inventory += using
mymob.client.screen = list()
for(var/obj/screen/inventory/inv in (static_inventory + toggleable_inventory))

View File

@@ -95,6 +95,10 @@
using.icon = ui_style
static_inventory += using
using = new /obj/screen/inventory/area_creator
using.icon = ui_style
static_inventory += using
using = new /obj/screen/act_intent()
using.icon_state = mymob.a_intent
static_inventory += using

View File

@@ -58,6 +58,21 @@
return
M.OpenCraftingMenu()
/obj/screen/inventory/area_creator
name = "create new area"
icon = 'icons/mob/screen_midnight.dmi'
icon_state = "area_edit"
screen_loc = ui_building
/obj/screen/inventory/area_creator/Click()
if(usr.incapacitated())
return 1
var/area/A = get_area(usr)
if(!A.outdoors)
usr << "<span class='warning'>There is already a defined structure here.</span>"
return 1
create_area(usr)
/obj/screen/inventory
var/slot_id // The indentifier for the slot. It has nothing to do with ID cards.
var/icon_empty // Icon when empty. For now used only by humans.