mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Merge branch 'master' of https://github.com/Baystation12/Baystation12 into dev-freeze
Conflicts: code/modules/client/preferences.dm
This commit is contained in:
@@ -30,6 +30,11 @@
|
||||
projectile_type = "/obj/item/projectile/beam/stun"
|
||||
modifystate = "energystun"
|
||||
update_icon()
|
||||
if(user.l_hand == src)
|
||||
user.update_inv_l_hand()
|
||||
else
|
||||
user.update_inv_r_hand()
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -250,42 +250,25 @@ client/var
|
||||
|
||||
//These are called by the on-screen buttons, adjusting what the victim can and cannot do.
|
||||
client/proc/add_gun_icons()
|
||||
if (!usr.item_use_icon)
|
||||
usr.item_use_icon = new /obj/screen/gun/item(null)
|
||||
usr.item_use_icon.icon_state = "no_item[target_can_click]"
|
||||
usr.item_use_icon.name = "[target_can_click ? "Disallow" : "Allow"] Item Use"
|
||||
|
||||
if (!usr.gun_move_icon)
|
||||
usr.gun_move_icon = new /obj/screen/gun/move(null)
|
||||
usr.gun_move_icon.icon_state = "no_walk[target_can_move]"
|
||||
usr.gun_move_icon.name = "[target_can_move ? "Disallow" : "Allow"] Walking"
|
||||
|
||||
if (target_can_move && !usr.gun_run_icon)
|
||||
usr.gun_run_icon = new /obj/screen/gun/run(null)
|
||||
usr.gun_run_icon.icon_state = "no_run[target_can_run]"
|
||||
usr.gun_run_icon.name = "[target_can_run ? "Disallow" : "Allow"] Running"
|
||||
|
||||
screen += usr.item_use_icon
|
||||
screen += usr.gun_move_icon
|
||||
if (target_can_move)
|
||||
screen += usr.gun_run_icon
|
||||
|
||||
|
||||
|
||||
client/proc/remove_gun_icons()
|
||||
if(!usr) return 1 // Runtime prevention on N00k agents spawning with SMG
|
||||
screen -= usr.item_use_icon
|
||||
screen -= usr.gun_move_icon
|
||||
if (target_can_move)
|
||||
screen -= usr.gun_run_icon
|
||||
del usr.gun_move_icon
|
||||
del usr.item_use_icon
|
||||
del usr.gun_run_icon
|
||||
|
||||
client/verb/ToggleGunMode()
|
||||
set hidden = 1
|
||||
gun_mode = !gun_mode
|
||||
if(gun_mode)
|
||||
usr << "You will now take people captive."
|
||||
add_gun_icons()
|
||||
else
|
||||
usr << "You will now shoot where you target."
|
||||
for(var/obj/item/weapon/gun/G in usr)
|
||||
@@ -302,7 +285,7 @@ client/verb/AllowTargetMove()
|
||||
target_can_move = !target_can_move
|
||||
if(target_can_move)
|
||||
usr << "Target may now walk."
|
||||
usr.gun_run_icon = new /obj/screen/gun/run(null) //adding icon for running permission
|
||||
//usr.gun_run_icon = new /obj/screen/gun/run(null) //adding icon for running permission
|
||||
screen += usr.gun_run_icon
|
||||
else
|
||||
usr << "Target may no longer move."
|
||||
|
||||
Reference in New Issue
Block a user