Merge pull request #5219 from Zuhayr/autolathe

Autolathe rewrite.
This commit is contained in:
Chinsky
2014-06-12 20:28:44 +04:00
81 changed files with 950 additions and 787 deletions
+1 -3
View File
@@ -5,9 +5,7 @@
icon_state = ""
flags = FPRINT | TABLEPASS| CONDUCT
w_class = 2.0
m_amt = 100
g_amt = 0
w_amt = 0
matter = list("metal" = 100)
throwforce = 2
throw_speed = 3
throw_range = 10
+1 -3
View File
@@ -2,9 +2,7 @@
name = "igniter"
desc = "A small electronic device able to ignite combustable substances."
icon_state = "igniter"
m_amt = 500
g_amt = 50
w_amt = 10
matter = list("metal" = 500, "glass" = 50, "waste" = 10)
origin_tech = "magnets=1"
secured = 1
+1 -3
View File
@@ -4,9 +4,7 @@
name = "infrared emitter"
desc = "Emits a visible or invisible beam and is triggered when the beam is interrupted."
icon_state = "infrared"
m_amt = 1000
g_amt = 500
w_amt = 100
matter = list("metal" = 1000, "glass" = 500, "waste" = 100)
origin_tech = "magnets=2"
wires = WIRE_PULSE
+1 -2
View File
@@ -2,8 +2,7 @@
name = "mousetrap"
desc = "A handy little spring-loaded trap for catching pesty rodents."
icon_state = "mousetrap"
m_amt = 100
w_amt = 10
matter = list("metal" = 100, "waste" = 10)
origin_tech = "combat=1"
var/armed = 0
+1 -3
View File
@@ -2,9 +2,7 @@
name = "proximity sensor"
desc = "Used for scanning and alerting when someone enters a certain proximity."
icon_state = "prox"
m_amt = 800
g_amt = 200
w_amt = 50
matter = list("metal" = 800, "glass" = 200, "waste" = 50)
origin_tech = "magnets=1"
wires = WIRE_PULSE
+1 -3
View File
@@ -3,9 +3,7 @@
desc = "Used to remotely activate devices."
icon_state = "signaller"
item_state = "signaler"
m_amt = 1000
g_amt = 200
w_amt = 100
matter = list("metal" = 1000, "glass" = 200, "waste" = 100)
origin_tech = "magnets=1"
wires = WIRE_RECEIVE | WIRE_PULSE | WIRE_RADIO_PULSE | WIRE_RADIO_RECEIVE
+2 -4
View File
@@ -2,9 +2,7 @@
name = "timer"
desc = "Used to time things. Works well with contraptions which has to count down. Tick tock."
icon_state = "timer"
m_amt = 500
g_amt = 50
w_amt = 10
matter = list("metal" = 500, "glass" = 50, "waste" = 10)
origin_tech = "magnets=1"
wires = WIRE_PULSE
@@ -20,7 +18,7 @@
activate()
if(!..()) return 0//Cooldown check
timing = !timing
update_icon()
+1 -2
View File
@@ -17,8 +17,7 @@
icon_state = "welding"
flags = (FPRINT | TABLEPASS | HEADCOVERSEYES | HEADCOVERSMOUTH)
item_state = "welding"
m_amt = 3000
g_amt = 1000
matter = list("metal" = 3000, "glass" = 1000)
var/up = 0
armor = list(melee = 10, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0)
flags_inv = (HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE)
+1 -1
View File
@@ -326,7 +326,7 @@
desc = "The message: 'Please do not be removing this beaker from the chemistry lab. If lost, return to Nashida Bisha'ra' can be seen etched into the side of this 100 unit beaker."
icon = 'icons/obj/chemical.dmi'
icon_state = "beakerlarge"
g_amt = 5000
matter = list("glass" = 5000)
volume = 100
/obj/item/weapon/reagent_containers/glass/beaker/fluff/eleanor_stone //Rkf45: Eleanor Stone
+2 -2
View File
@@ -111,7 +111,7 @@
force = 5.0
throwforce = 7.0
w_class = 2.0
m_amt = 50
matter = list("metal" = 50)
attack_verb = list("slashed", "sliced", "cut", "clawed")
@@ -214,7 +214,7 @@
throwforce = 15.0
throw_speed = 4
throw_range = 4
m_amt = 15000
matter = list("metal" = 15000)
origin_tech = "materials=2;combat=1"
attack_verb = list("chopped", "torn", "cut")
+2 -2
View File
@@ -58,7 +58,7 @@
throwforce = 4.0
item_state = "pickaxe"
w_class = 4.0
m_amt = 3750 //one sheet, but where can you make them?
matter = list("metal" = 3750)
var/digspeed = 40 //moving the delay to an item var so R&D can make improved picks. --NEO
origin_tech = "materials=1;engineering=1"
attack_verb = list("hit", "pierced", "sliced", "attacked")
@@ -155,7 +155,7 @@
throwforce = 4.0
item_state = "shovel"
w_class = 3.0
m_amt = 50
matter = list("metal" = 50)
origin_tech = "materials=1;engineering=1"
attack_verb = list("bashed", "bludgeoned", "thrashed", "whacked")
@@ -171,7 +171,7 @@
w_class = 2.0
throw_speed = 5
throw_range = 10
m_amt = 200
matter = list("metal" = 200)
origin_tech = "magnets=1;biotech=1"
var/mode = 1;
+1 -1
View File
@@ -21,7 +21,7 @@
w_class = 1.0
throw_speed = 7
throw_range = 15
m_amt = 10
matter = list("metal" = 10)
var/colour = "black" //what colour the ink is!
pressure_resistance = 2
+1 -1
View File
@@ -119,7 +119,7 @@
w_class = 2.0
flags = FPRINT | CONDUCT | TABLEPASS
slot_flags = SLOT_BELT
m_amt = 2000
matter = list("metal" = 2000)
var/pictures_max = 10
var/pictures_left = 10
var/on = 1
+1 -1
View File
@@ -9,7 +9,7 @@
w_class = 1.0
throw_speed = 7
throw_range = 15
m_amt = 60
matter = list("metal" = 60)
item_color = "cargo"
pressure_resistance = 2
attack_verb = list("stamped")
+1 -2
View File
@@ -210,8 +210,7 @@ proc/cardinalrange(var/center)
throwforce = 5
throw_speed = 1
throw_range = 2
m_amt = 100
w_amt = 2000
matter = list("metal" = 100, "waste" = 2000)
/obj/item/device/am_shielding_container/attackby(var/obj/item/I, var/mob/user)
if(istype(I, /obj/item/device/multitool) && istype(src.loc,/turf))
-13
View File
@@ -1425,17 +1425,4 @@
malfvacate(1)*/
..()
/obj/machinery/power/apc/proc/shock(mob/user, prb)
if(!prob(prb))
return 0
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(5, 1, src)
s.start()
if(isalien(user))
return 0
if (electrocute_mob(user, src, src))
return 1
else
return 0
#undef APC_UPDATE_ICON_COOLDOWN
+1 -2
View File
@@ -212,8 +212,7 @@
w_class = 2.0
throw_speed = 2
throw_range = 5
m_amt = 50
g_amt = 20
matter = list("metal" = 50, "glass" = 20)
flags = TABLEPASS | FPRINT | CONDUCT
slot_flags = SLOT_BELT
item_state = "coil"
+4 -4
View File
@@ -646,7 +646,7 @@
var/status = 0 // LIGHT_OK, LIGHT_BURNED or LIGHT_BROKEN
var/base_state
var/switchcount = 0 // number of times switched
m_amt = 60
matter = list("metal" = 60)
var/rigged = 0 // true if rigged to explode
var/brightness = 2 //how much light it gives off
@@ -656,7 +656,7 @@
icon_state = "ltube"
base_state = "ltube"
item_state = "c_tube"
g_amt = 100
matter = list("glass" = 100)
brightness = 8
/obj/item/weapon/light/tube/large
@@ -670,7 +670,7 @@
icon_state = "lbulb"
base_state = "lbulb"
item_state = "contvapour"
g_amt = 100
matter = list("glass" = 100)
brightness = 5
/obj/item/weapon/light/throw_impact(atom/hit_atom)
@@ -683,7 +683,7 @@
icon_state = "fbulb"
base_state = "fbulb"
item_state = "egg4"
g_amt = 100
matter = list("glass" = 100)
brightness = 5
// update the icon state and description of the light
@@ -50,7 +50,7 @@
/obj/machinery/containment_field/proc/shock(mob/living/user as mob)
/obj/machinery/containment_field/shock(mob/living/user as mob)
if(hasShocked)
return 0
if(!FG1 || !FG2)
+1 -1
View File
@@ -51,7 +51,7 @@
flags = FPRINT | TABLEPASS | CONDUCT
slot_flags = SLOT_BELT
item_state = "syringe_kit"
m_amt = 50000
matter = list("metal" = 50000)
throwforce = 2
w_class = 2.0
throw_speed = 4
@@ -60,7 +60,7 @@
icon_state = "gshell"
caliber = "shotgun"
projectile_type = "/obj/item/projectile/bullet"
m_amt = 12500
matter = list("metal" = 12500)
/obj/item/ammo_casing/shotgun/blank
@@ -68,7 +68,7 @@
desc = "A blank shell."
icon_state = "blshell"
projectile_type = ""
m_amt = 250
matter = list("metal" = 250)
/obj/item/ammo_casing/shotgun/beanbag
@@ -76,7 +76,7 @@
desc = "A weak beanbag shell."
icon_state = "bshell"
projectile_type = "/obj/item/projectile/bullet/weakbullet/beanbag"
m_amt = 500
matter = list("metal" = 500)
/obj/item/ammo_casing/shotgun/stunshell
@@ -84,7 +84,7 @@
desc = "A stunning shell."
icon_state = "stunshell"
projectile_type = "/obj/item/projectile/bullet/stunshot"
m_amt = 2500
matter = list("metal" = 2500)
/obj/item/ammo_casing/shotgun/dart
@@ -92,7 +92,7 @@
desc = "A dart for use in shotguns."
icon_state = "dart"
projectile_type = "/obj/item/projectile/energy/dart"
m_amt = 12500
matter = list("metal" = 12500)
/obj/item/ammo_casing/a762
desc = "A 7.62 bullet casing."
+2 -2
View File
@@ -6,7 +6,7 @@
item_state = "gun"
flags = FPRINT | TABLEPASS | CONDUCT
slot_flags = SLOT_BELT
m_amt = 2000
matter = list("metal" = 2000)
w_class = 3.0
throwforce = 5
throw_speed = 4
@@ -194,7 +194,7 @@
playsound(user, fire_sound, 10, 1)
else
playsound(user, fire_sound, 50, 1)
if(istype(in_chamber, /obj/item/projectile/beam/lastertag))
if(istype(in_chamber, /obj/item/projectile/beam/lastertag))
user.show_message("<span class = 'warning'>You feel rather silly, trying to commit suicide with a toy.</span>")
mouthshoot = 0
return
@@ -5,7 +5,7 @@
item_state = "laser"
fire_sound = 'sound/weapons/Laser.ogg'
w_class = 3.0
m_amt = 2000
matter = list("metal" = 2000)
origin_tech = "combat=3;magnets=2"
projectile_type = "/obj/item/projectile/beam"
+2 -2
View File
@@ -65,7 +65,7 @@
icon_state = "crossbow"
w_class = 2.0
item_state = "crossbow"
m_amt = 2000
matter = list("metal" = 2000)
origin_tech = "combat=2;magnets=2;syndicate=5"
silenced = 1
fire_sound = 'sound/weapons/Genhit.ogg'
@@ -103,7 +103,7 @@
desc = "A weapon favored by syndicate infiltration teams."
w_class = 4.0
force = 10
m_amt = 200000
matter = list("metal" = 200000)
projectile_type = "/obj/item/projectile/energy/bolt/large"
+1 -1
View File
@@ -9,7 +9,7 @@
caliber = "357"
origin_tech = "combat=2;materials=2"
w_class = 3.0
m_amt = 1000
matter = list("metal" = 1000)
recoil = 1
var/ammo_type = "/obj/item/ammo_casing/a357"
var/list/loaded = list()
+1 -1
View File
@@ -11,7 +11,7 @@
force = 5.0
var/list/grenades = new/list()
var/max_grenades = 3
m_amt = 2000
matter = list("metal" = 2000)
examine()
set src in view()
@@ -160,8 +160,7 @@
icon = 'icons/obj/chemical.dmi'
icon_state = "beaker"
item_state = "beaker"
m_amt = 0
g_amt = 500
matter = list("glass" = 500)
on_reagent_change()
update_icon()
@@ -205,7 +204,7 @@
name = "large beaker"
desc = "A large beaker. Can hold up to 100 units."
icon_state = "beakerlarge"
g_amt = 5000
matter = list("glass" = 5000)
volume = 100
amount_per_transfer_from_this = 10
possible_transfer_amounts = list(5,10,15,25,30,50,100)
@@ -215,7 +214,7 @@
name = "cryostasis beaker"
desc = "A cryostasis beaker that allows for chemical storage without reactions. Can hold up to 50 units."
icon_state = "beakernoreact"
g_amt = 500
matter = list("glass" = 500)
volume = 50
amount_per_transfer_from_this = 10
flags = FPRINT | TABLEPASS | OPENCONTAINER | NOREACT
@@ -224,7 +223,7 @@
name = "bluespace beaker"
desc = "A bluespace beaker, powered by experimental bluespace technology. Can hold up to 300 units."
icon_state = "beakerbluespace"
g_amt = 5000
matter = list("glass" = 5000)
volume = 300
amount_per_transfer_from_this = 10
possible_transfer_amounts = list(5,10,15,25,30,50,100,300)
@@ -235,7 +234,7 @@
name = "vial"
desc = "A small glass vial. Can hold up to 25 units."
icon_state = "vial"
g_amt = 250
matter = list("glass" = 250)
volume = 25
amount_per_transfer_from_this = 10
possible_transfer_amounts = list(5,10,15,25)
@@ -265,8 +264,7 @@
icon = 'icons/obj/janitor.dmi'
icon_state = "bucket"
item_state = "bucket"
m_amt = 200
g_amt = 0
matter = list("metal" = 200)
w_class = 3.0
amount_per_transfer_from_this = 20
possible_transfer_amounts = list(10,20,30,50,70)
@@ -280,7 +278,7 @@
user.put_in_hands(new /obj/item/weapon/bucket_sensor)
user.drop_from_inventory(src)
del(src)
update_icon()
overlays.Cut()
@@ -11,7 +11,7 @@
icon = 'icons/obj/syringe.dmi'
item_state = "syringe_0"
icon_state = "0"
g_amt = 150
matter = list("glass" = 150)
amount_per_transfer_from_this = 5
possible_transfer_amounts = null //list(5,10,15)
volume = 15
+1 -1
View File
@@ -13,7 +13,7 @@
force = 4.0
var/list/syringes = new/list()
var/max_syringes = 1
m_amt = 2000
matter = list("metal" = 2000)
/obj/item/weapon/gun/syringe/examine()
set src in view()
@@ -10,7 +10,7 @@
anchored = 0
density = 0
pressure_resistance = 5*ONE_ATMOSPHERE
m_amt = 1850
matter = list("metal" = 1850)
level = 2
var/ptype = 0
// 0=straight, 1=bent, 2=junction-j1, 3=junction-j2, 4=junction-y, 5=trunk, 6=disposal bin, 7=outlet, 8=inlet
+1 -2
View File
@@ -1721,8 +1721,7 @@ datum/design/security_hud
icon_state = "datadisk2"
item_state = "card-id"
w_class = 2.0
m_amt = 30
g_amt = 10
matter = list("metal" = 30,"glass" = 10)
var/datum/design/blueprint
/obj/item/weapon/disk/design_disk/New()
+2 -2
View File
@@ -262,8 +262,8 @@ won't update every console in existence) but it's more of a hassle to do. Also,
if(linked_destroy.loaded_item.reliability < 100 && linked_destroy.loaded_item.crit_fail)
files.UpdateDesign(linked_destroy.loaded_item.type)
if(linked_lathe) //Also sends salvaged materials to a linked protolathe, if any.
linked_lathe.m_amount += min((linked_lathe.max_material_storage - linked_lathe.TotalMaterials()), (linked_destroy.loaded_item.m_amt*linked_destroy.decon_mod))
linked_lathe.g_amount += min((linked_lathe.max_material_storage - linked_lathe.TotalMaterials()), (linked_destroy.loaded_item.g_amt*linked_destroy.decon_mod))
linked_lathe.m_amount += min((linked_lathe.max_material_storage - linked_lathe.TotalMaterials()), (linked_destroy.loaded_item.matter["metal"]*linked_destroy.decon_mod))
linked_lathe.g_amount += min((linked_lathe.max_material_storage - linked_lathe.TotalMaterials()), (linked_destroy.loaded_item.matter["glass"]*linked_destroy.decon_mod))
linked_destroy.loaded_item = null
for(var/obj/I in linked_destroy.contents)
for(var/mob/M in I.contents)
-14
View File
@@ -36,20 +36,6 @@
src.disable_wire = pick(w)
w -= src.disable_wire
/obj/machinery/r_n_d/proc/
shock(mob/user, prb)
if(stat & (BROKEN|NOPOWER)) // unpowered, no shock
return 0
if(!prob(prb))
return 0
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(5, 1, src)
s.start()
if (electrocute_mob(user, get_area(src), src, 0.7))
return 1
else
return 0
/obj/machinery/r_n_d/attack_hand(mob/user as mob)
if (shocked)
shock(user,50)
+1 -2
View File
@@ -263,8 +263,7 @@ datum/tech/robotics
icon_state = "datadisk2"
item_state = "card-id"
w_class = 2.0
m_amt = 30
g_amt = 10
matter = list("metal" = 30, "glass" = 10)
var/datum/tech/stored
/obj/item/weapon/disk/tech_disk/New()
@@ -75,8 +75,7 @@ datum
desc = "A small, open-topped glass container for delicate research samples. It sports a re-useable strip for labelling with a pen."
icon = 'icons/obj/device.dmi'
icon_state = "solution_tray"
m_amt = 0
g_amt = 5
matter = list("glass" = 5)
w_class = 2.0
amount_per_transfer_from_this = 1
possible_transfer_amounts = list(1, 2)