mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-24 05:38:15 +01:00
Added a "Deadman's switch" (Not really) to the signaler, shooting while standing off makes the other guy shoot, balanced stunning, added a time limit to switching hostage modes.
Signalers: Right click verb makes you ready to signal it, being shot with it in your active hand has a 80% chance to trigger it, dropping it has a 5% chance. Stunning always stuns you SOME, but armor can now lessen it (It used to be possible to not get stunned at all by being shot normally) Shooting during a mexican standoff now makes the other guy shoot you too. Added a time to how quickly you can adjust hostage things. 1.5 seconds per thing.
This commit is contained in:
@@ -19,6 +19,7 @@
|
||||
delay = 0
|
||||
airlock_wire = null
|
||||
datum/radio_frequency/radio_connection
|
||||
deadman = 0
|
||||
|
||||
proc
|
||||
signal()
|
||||
@@ -145,4 +146,23 @@
|
||||
radio_controller.remove_object(src, frequency)
|
||||
frequency = new_frequency
|
||||
radio_connection = radio_controller.add_object(src, frequency, RADIO_CHAT)
|
||||
return
|
||||
return
|
||||
|
||||
process()
|
||||
var/mob/M = src.loc
|
||||
if(!M || !ismob(M))
|
||||
if(prob(5))
|
||||
signal()
|
||||
deadman = 0
|
||||
processing_objects.Remove(src)
|
||||
else if(prob(5))
|
||||
M.visible_message("[M]'s finger twitches a bit over [src]'s signal button!")
|
||||
return
|
||||
|
||||
proc/deadman_it()
|
||||
set src in usr
|
||||
set name = "Threaten to push the button!"
|
||||
set desc = "BOOOOM!"
|
||||
deadman = 1
|
||||
processing_objects.Add(src)
|
||||
usr.visible_message("\red [usr] moves their finger over [src]'s signal button...")
|
||||
|
||||
@@ -42,9 +42,9 @@
|
||||
if(!effect || (blocked >= 2)) return 0
|
||||
switch(effecttype)
|
||||
if(STUN)
|
||||
Stun((effect - (effect*getarmor(null, "laser"))))
|
||||
Stun((effect - (min(effect*getarmor(null, "laser"), effect*(0.75 + (blocked*0.05))))))
|
||||
if(WEAKEN)
|
||||
Weaken((effect - (effect*getarmor(null, "laser"))))
|
||||
Weaken((effect - (min(effect*getarmor(null, "laser"), effect*(0.75 + (blocked*0.05))))))
|
||||
if(PARALYZE)
|
||||
Paralyse(effect/(blocked+1))
|
||||
if(IRRADIATE)
|
||||
|
||||
@@ -45,6 +45,12 @@
|
||||
|
||||
flash_weak_pain()
|
||||
|
||||
if(istype(equipped(),/obj/item/device/assembly/signaler))
|
||||
var/obj/item/device/assembly/signaler/signaler = equipped()
|
||||
if(signaler.deadman && prob(80))
|
||||
src.visible_message("\red [src] triggers their deadman's switch!")
|
||||
signaler.signal()
|
||||
|
||||
var/absorb = run_armor_check(def_zone, P.flag)
|
||||
if(absorb >= 2)
|
||||
P.on_hit(src,2)
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
unacidable = 1
|
||||
var/id = 0.0
|
||||
var/obj/master
|
||||
var/gun_click_time = -100 //I'm lazy.
|
||||
|
||||
/obj/screen/close
|
||||
name = "close"
|
||||
@@ -589,53 +590,77 @@
|
||||
usr:module_active = null
|
||||
|
||||
if("Allow Walking")
|
||||
if(gun_click_time > world.time - 15) //give them 1.5 seconds between mode changes.
|
||||
usr << "You need to wait some before you can change what they can do!"
|
||||
return
|
||||
if(!istype(usr.equipped(),/obj/item/weapon/gun))
|
||||
usr << "You need your gun in your active hand to do that!"
|
||||
return
|
||||
usr.AllowTargetMove()
|
||||
icon_state = "walking"
|
||||
name = "Disallow Walking"
|
||||
gun_click_time = world.time
|
||||
|
||||
if("Disallow Walking")
|
||||
if(gun_click_time > world.time - 15) //give them 1.5 seconds between mode changes.
|
||||
usr << "You need to wait some before you can change what they can do!"
|
||||
return
|
||||
if(!istype(usr.equipped(),/obj/item/weapon/gun))
|
||||
usr << "You need your gun in your active hand to do that!"
|
||||
return
|
||||
usr.AllowTargetMove()
|
||||
icon_state = "no_walk"
|
||||
name = "Allow Walking"
|
||||
gun_click_time = world.time
|
||||
|
||||
if("Allow Running")
|
||||
if(gun_click_time > world.time - 15) //give them 1.5 seconds between mode changes.
|
||||
usr << "You need to wait some before you can change what they can do!"
|
||||
return
|
||||
if(!istype(usr.equipped(),/obj/item/weapon/gun))
|
||||
usr << "You need your gun in your active hand to do that!"
|
||||
return
|
||||
usr.AllowTargetRun()
|
||||
icon_state = "running"
|
||||
name = "Disallow Running"
|
||||
gun_click_time = world.time
|
||||
|
||||
if("Disallow Running")
|
||||
if(gun_click_time > world.time - 15) //give them 1.5 seconds between mode changes.
|
||||
usr << "You need to wait some before you can change what they can do!"
|
||||
return
|
||||
if(!istype(usr.equipped(),/obj/item/weapon/gun))
|
||||
usr << "You need your gun in your active hand to do that!"
|
||||
return
|
||||
usr.AllowTargetRun()
|
||||
icon_state = "no_run"
|
||||
name = "Allow Running"
|
||||
gun_click_time = world.time
|
||||
|
||||
if("Allow Item Use")
|
||||
if(gun_click_time > world.time - 15) //give them 1.5 seconds between mode changes.
|
||||
usr << "You need to wait some before you can change what they can do!"
|
||||
return
|
||||
if(!istype(usr.equipped(),/obj/item/weapon/gun))
|
||||
usr << "You need your gun in your active hand to do that!"
|
||||
return
|
||||
name = "Disallow Item Use"
|
||||
icon_state = "act_throw_off"
|
||||
usr.AllowTargetClick()
|
||||
gun_click_time = world.time
|
||||
|
||||
|
||||
if("Disallow Item Use")
|
||||
if(gun_click_time > world.time - 15) //give them 1.5 seconds between mode changes.
|
||||
usr << "You need to wait some before you can change what they can do!"
|
||||
return
|
||||
if(!istype(usr.equipped(),/obj/item/weapon/gun))
|
||||
usr << "You need your gun in your active hand to do that!"
|
||||
return
|
||||
name = "Allow Item Use"
|
||||
icon_state = "no_item"
|
||||
usr.AllowTargetClick()
|
||||
gun_click_time = world.time
|
||||
|
||||
else
|
||||
DblClick()
|
||||
|
||||
@@ -181,6 +181,7 @@
|
||||
proc/TargetActed()
|
||||
var/mob/M = loc
|
||||
if(target == M) return
|
||||
usr.last_move_intent = world.time
|
||||
Fire(target,usr)
|
||||
var/dir_to_fire = sd_get_approx_dir(M,target)
|
||||
if(dir_to_fire != M.dir)
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
verb/rename_gun()
|
||||
set name = "Name Gun"
|
||||
set desc = "Click to rename your gun. If you're the detective."
|
||||
set desc = "Click to rename your gun."
|
||||
|
||||
var/mob/M = usr
|
||||
if(!M.mind) return 0
|
||||
|
||||
Reference in New Issue
Block a user