Merge branch 'master' of https://github.com/ParadiseSS13/Paradise into BookClub

This commit is contained in:
Aurorablade
2016-06-21 07:42:29 -04:00
486 changed files with 11086 additions and 7936 deletions
+3 -1
View File
@@ -1 +1,3 @@
#define CLICKCATCHER_PLANE -99
#define CLICKCATCHER_PLANE -99
#define HUD_PLANE 90
+1 -1
View File
@@ -45,7 +45,7 @@
if(modifiers["middle"])
MiddleClickOn(A)
if(controlled_mech) //Are we piloting a mech? Placed here so the modifiers are not overridden.
controlled_mech.click_action(A, src) //Override AI normal click behavior.
controlled_mech.click_action(A, src, params) //Override AI normal click behavior.
return
if(modifiers["shift"])
ShiftClickOn(A)
+5 -59
View File
@@ -74,7 +74,7 @@
if(!locate(/turf) in list(A,A.loc)) // Prevents inventory from being drilled
return
var/obj/mecha/M = loc
return M.click_action(A,src)
return M.click_action(A, src, params)
if(restrained())
changeNext_move(CLICK_CD_HANDCUFFED) //Doing shit in cuffs shall be vey slow
@@ -167,9 +167,8 @@
animals lunging, etc.
*/
/mob/proc/RangedAttack(var/atom/A, var/params)
if(ishuman(src) && (istype(src:gloves, /obj/item/clothing/gloves/color/yellow/power)) && a_intent == I_HARM)
PowerGlove(A)
if(!mutations.len) return
if(!mutations.len)
return
if((LASER in mutations) && a_intent == I_HARM)
LaserEyes(A) // moved into a proc below
return
@@ -319,61 +318,8 @@
LE.current = T
LE.yo = U.y - T.y
LE.xo = U.x - T.x
spawn(1)
LE.process()
LE.fire()
/mob/proc/PowerGlove(atom/A)
return
/mob/living/carbon/human/PowerGlove(atom/A)
var/obj/item/clothing/gloves/color/yellow/power/G = src:gloves
var/time = 100
var/turf/T = get_turf(src)
var/turf/U = get_turf(A)
var/obj/structure/cable/cable = locate() in T
if(!cable || !istype(cable))
to_chat(src, "<span class='warning'>There is no cable here to power the gloves.</span>")
return
if(world.time < G.next_shock)
to_chat(src, "<span class='warning'>[G] aren't ready to shock again!</span>")
return
src.visible_message("<span class='warning'>[name] fires an arc of electricity!</span>", \
"<span class='warning'>You fire an arc of electricity!</span>", \
"You hear the loud crackle of electricity!")
var/datum/powernet/PN = cable.get_powernet()
var/available = 0
var/obj/item/projectile/beam/lightning/L = new /obj/item/projectile/beam/lightning/(get_turf(src))
if(PN)
available = PN.avail
L.damage = PN.get_electrocute_damage()
if(available >= 5000000)
L.damage = 205
if(L.damage >= 200)
time = 200
else if(L.damage >= 100)
time = 150
var/datum/effect/system/spark_spread/s = new /datum/effect/system/spark_spread
s.set_up(5, 1, src)
s.start()
if(L.damage <= 0)
qdel(L)
if(L)
playsound(get_turf(src), 'sound/effects/eleczap.ogg', 75, 1)
L.tang = L.adjustAngle(get_angle(U,T))
L.icon = midicon
L.icon_state = "[L.tang]"
L.firer = usr
L.def_zone = get_organ_target()
L.original = src
L.current = U
L.starting = U
L.yo = U.y - T.y
L.xo = U.x - T.x
spawn( 1 )
L.process()
next_move = world.time + 12
G.next_shock = world.time + time
// Simple helper to face what you clicked on, in case it should be needed in more than one place
/mob/proc/face_atom(var/atom/A)
@@ -419,4 +365,4 @@
else
var/turf/T = screen_loc2turf(modifiers["screen-loc"], get_turf(usr))
T.Click(location, control, params)
return 1
return 1
+26 -1
View File
@@ -40,4 +40,29 @@
newObject.loc = get_turf(A)
to_chat(user, "<span class='notice'>You release the power you had stored up, summoning \a [newObject.name]! </span>")
usr.loc.visible_message("<span class='notice'>[user] waves \his hand and summons \a [newObject.name]</span>")
..()
..()
/datum/middleClickOverride/power_gloves
var/last_shocked = 0
var/shock_delay = 120
/datum/middleClickOverride/power_gloves/onClick(var/atom/A, var/mob/living/user)
if(user.incapacitated())
return
if(world.time < last_shocked + shock_delay)
to_chat(user, "<span class='warning'>The gloves are still recharging.</span>")
return
if(!isliving(A))
to_chat(user, "<span class='warning'>Shocking an inanimate object would be pointless.</span>")
return
var/mob/living/L = A
var/turf/T = get_turf(user)
var/obj/structure/cable/C = locate() in T
if(!C || !istype(C))
to_chat(user, "<span class='warning'>There is no cable here to power the gloves.</span>")
return
user.visible_message("<span class='warning'>[user.name] fires an arc of electricity at [L]!</span>", "<span class='warning'>You fire an arc of electricity at [L]!</span>", "You hear the loud crackle of electricity!")
var/datum/powernet/PN = C.get_powernet()
user.Beam(L,icon_state="lightning[rand(1,12)]",icon='icons/effects/effects.dmi',time=5)
electrocute_mob(L, PN, user)
last_shocked = world.time
+15 -1
View File
@@ -217,11 +217,25 @@
check_flags = AB_CHECK_RESTRAINED|AB_CHECK_STUNNED|AB_CHECK_LYING|AB_CHECK_ALIVE|AB_CHECK_INSIDE
/datum/action/item_action/CheckRemoval(mob/living/user)
return !(target in user)
return get(target, /mob/living) != user
/datum/action/item_action/hands_free
check_flags = AB_CHECK_ALIVE|AB_CHECK_INSIDE
// for clothing accessories like holsters
/datum/action/item_action/accessory
check_flags = AB_CHECK_RESTRAINED|AB_CHECK_STUNNED|AB_CHECK_LYING|AB_CHECK_ALIVE
/datum/action/item_action/accessory/Checks()
. = ..()
if(!.)
return 0
if(target.loc == owner)
return 1
if(istype(target.loc, /obj/item/clothing/under) && target.loc.loc == owner)
return 1
return 0
///prset for organ actions
/datum/action/item_action/organ_action
check_flags = AB_CHECK_ALIVE
-1
View File
@@ -186,4 +186,3 @@
to_chat(usr, "<span class ='info'>Switched HUD mode. Press F12 to toggle.</span>")
else
to_chat(usr, "<span class ='warning'>This mob type does not use a HUD.</span>")
+1
View File
@@ -209,6 +209,7 @@
else
A.screen_loc = "CENTER+[x]:16,SOUTH+[y]:7"
A.layer = 20
A.plane = HUD_PLANE
x++
if(x == 4)
+2
View File
@@ -10,9 +10,11 @@
name = ""
icon = 'icons/mob/screen_gen.dmi'
layer = 20
plane = HUD_PLANE
unacidable = 1
var/obj/master = null //A reference to the object in the slot. Grabs or items, generally.
var/datum/hud/hud = null
appearance_flags = NO_CLIENT_COLOR
/obj/screen/Destroy()
master = null
+1 -2
View File
@@ -369,8 +369,7 @@
A.current = T
A.yo = U.y - T.y
A.xo = U.x - T.x
spawn( 1 )
A.process()
A.fire()
usr.next_move = world.time + 6
return
+1
View File
@@ -69,6 +69,7 @@ var/const/tk_maxrange = 15
//item_state = null
w_class = 10.0
layer = 20
plane = HUD_PLANE
var/last_throw = 0
var/atom/movable/focus = null