Antag Uplink Expansion

This commit is contained in:
Mechoid
2020-03-16 21:21:41 -07:00
committed by VirgoBot
parent a7fc7b3786
commit 487c39eab8
33 changed files with 723 additions and 28 deletions

View File

@@ -76,12 +76,17 @@
var/start_nutrition = H.nutrition
var/end_nutrition = 0
H.nutrition -= rechargeamt / 10
H.nutrition -= rechargeamt / 15
end_nutrition = H.nutrition
if(start_nutrition - max(0, end_nutrition) < rechargeamt / 10)
H.remove_blood((rechargeamt / 10) - (start_nutrition - max(0, end_nutrition)))
if(start_nutrition - max(0, end_nutrition) < rechargeamt / 15)
if(H.isSynthetic())
H.adjustToxLoss((rechargeamt / 15) - (start_nutrition - max(0, end_nutrition)))
else
H.remove_blood((rechargeamt / 15) - (start_nutrition - max(0, end_nutrition)))
power_supply.give(rechargeamt) //... to recharge 1/5th the battery
update_icon()

View File

@@ -0,0 +1,77 @@
/obj/item/weapon/gun/magnetic/gasthrower
name = "phoronthrower"
desc = "A modernized flamethrower utilizing pressurized phoron gas as both a propellant and combustion medium."
description_fluff = "A weapon designed to effectively combat the threat posed by Almachi soldiers without the danger of other forms of flamethrower."
icon_state = "gasthrower"
item_state = "bore"
wielded_item_state = "bore-wielded"
icon = 'icons/obj/railgun.dmi'
one_handed_penalty = 20
origin_tech = list(TECH_COMBAT = 5, TECH_MATERIAL = 4, TECH_ILLEGAL = 2, TECH_PHORON = 4)
w_class = ITEMSIZE_LARGE
burst = 3
burst_delay = 1
fire_sound = 'sound/weapons/towelwipe.ogg'
removable_components = TRUE
gun_unreliable = 0
load_type = /obj/item/weapon/tank
projectile_type = /obj/item/projectile/scatter/flamethrower
power_cost = 250
/obj/item/weapon/gun/magnetic/gasthrower/check_ammo()
if(!loaded || !istype(loaded, load_type))
return 0
var/obj/item/weapon/tank/Tank = loaded
Tank.air_contents.update_values() // Safety
var/turf/T = get_turf(src)
var/phoron_amt = Tank.air_contents.gas["phoron"]
var/co2_amt = Tank.air_contents.gas["carbon_dioxide"]
var/oxy_amt = Tank.air_contents.gas["oxygen"]
var/n2o_amt = Tank.air_contents.gas["sleeping_agent"]
if(isnull(co2_amt))
co2_amt = 0
if(isnull(oxy_amt))
oxy_amt = 0
if(isnull(n2o_amt))
n2o_amt = 0
var/phoron_mix_proper = TRUE
if(!phoron_amt || phoron_amt < max(0.25, 3 + co2_amt - oxy_amt - (n2o_amt / 2)))
phoron_mix_proper = FALSE
if(Tank.air_contents.return_pressure() >= T.air.return_pressure() && phoron_mix_proper)
return 1
return 0
/obj/item/weapon/gun/magnetic/gasthrower/use_ammo()
var/obj/item/weapon/tank/Tank = loaded
var/moles_to_pull = 0.25
Tank.air_contents.remove(moles_to_pull)
/obj/item/weapon/gun/magnetic/gasthrower/show_ammo(var/mob/user)
..()
if(loaded)
var/obj/item/weapon/tank/T = loaded
to_chat(user, "<span class='notice'>\The [T]'s pressure meter shows: [T.air_contents.return_pressure()] kpa.</span>")
switch(check_ammo())
if(TRUE)
to_chat(user, "<span class='notice'>\The [src]'s display registers a proper fuel mixture.</span>")
if(FALSE)
to_chat(user, "<span class='warning'>\The [src]'s display registers an improper fuel mixture.</span>")

View File

@@ -18,6 +18,7 @@
projectile_type = /obj/item/projectile/bullet/rifle/a145
accuracy = -75
scoped_accuracy = 75
ignore_visor_zoom_restriction = TRUE // Ignore the restriction on vision modifiers when using this gun's scope.
// one_handed_penalty = 90
var/bolt_open = 0

View File

@@ -95,7 +95,7 @@
var/spread_submunition_damage = FALSE // Do we assign damage to our sub projectiles based on our main projectile damage?
var/damage = 10
var/damage_type = BRUTE //BRUTE, BURN, TOX, OXY, CLONE, HALLOSS, ELECTROCUTE, BIOACID are the only things that should be in here
var/damage_type = BRUTE //BRUTE, BURN, TOX, OXY, CLONE, HALLOSS, ELECTROCUTE, BIOACID, SEARING are the only things that should be in here
var/SA_bonus_damage = 0 // Some bullets inflict extra damage on simple animals.
var/SA_vulnerability = null // What kind of simple animal the above bonus damage should be applied to. Set to null to apply to all SAs.
var/nodamage = 0 //Determines if the projectile will skip any damage inflictions

View File

@@ -266,6 +266,14 @@
flammability = 2
range = 6
/obj/item/projectile/bullet/incendiary/flamethrower/tiny
damage = 2
incendiary = 0
modifier_type_to_apply = /datum/modifier/fire/weak
modifier_duration = 20 SECONDS
range = 7
agony = 3
/* Practice rounds and blanks */
/obj/item/projectile/bullet/practice

View File

@@ -60,3 +60,13 @@
submunitions = list(
/obj/item/projectile/bullet/shotgun/ion = 3
)
/obj/item/projectile/scatter/flamethrower
damage = 5
submunition_spread_max = 100
submunition_spread_min = 30
force_max_submunition_spread = TRUE
submunitions = list(
/obj/item/projectile/bullet/incendiary/flamethrower/tiny = 7
)