This commit is contained in:
kevinz000
2017-08-29 09:59:57 -07:00
1535 changed files with 71790 additions and 86062 deletions

View File

@@ -234,8 +234,8 @@
UpdateButtonIcon()
/datum/action/item_action/toggle_unfriendly_fire/UpdateButtonIcon(status_only = FALSE)
if(istype(target, /obj/item/weapon/hierophant_club))
var/obj/item/weapon/hierophant_club/H = target
if(istype(target, /obj/item/hierophant_club))
var/obj/item/hierophant_club/H = target
if(H.friendly_fire_check)
button_icon_state = "vortex_ff_off"
name = "Toggle Friendly Fire \[OFF\]"
@@ -264,8 +264,8 @@
button_icon_state = "vortex_recall"
/datum/action/item_action/vortex_recall/IsAvailable()
if(istype(target, /obj/item/weapon/hierophant_club))
var/obj/item/weapon/hierophant_club/H = target
if(istype(target, /obj/item/hierophant_club))
var/obj/item/hierophant_club/H = target
if(H.teleporting)
return 0
return ..()
@@ -351,7 +351,7 @@
name = "Toggle Jetpack Stabilization"
/datum/action/item_action/jetpack_stabilization/IsAvailable()
var/obj/item/weapon/tank/jetpack/J = target
var/obj/item/tank/jetpack/J = target
if(!istype(J) || !J.on)
return 0
return ..()
@@ -431,7 +431,7 @@
name = "Create Throwing Stars (1E)"
desc = "Creates some throwing stars"
button_icon_state = "throwingstar"
icon_icon = 'icons/obj/weapons.dmi'
icon_icon = 'icons/obj/items_and_weapons.dmi'
/datum/action/item_action/ninjanet
name = "Energy Net (20E)"
@@ -443,7 +443,7 @@
name = "Recall Energy Katana (Variable Cost)"
desc = "Teleports the Energy Katana linked to this suit to its wearer, cost based on distance."
button_icon_state = "energy_katana"
icon_icon = 'icons/obj/weapons.dmi'
icon_icon = 'icons/obj/items_and_weapons.dmi'
/datum/action/item_action/ninja_stealth
name = "Toggle Stealth"

View File

@@ -320,11 +320,11 @@
//Spawn and equip documents
var/mob/living/carbon/human/mob = owner.current
var/obj/item/weapon/folder/syndicate/folder
var/obj/item/folder/syndicate/folder
if(owner == SSticker.mode.exchange_red)
folder = new/obj/item/weapon/folder/syndicate/red(mob.loc)
folder = new/obj/item/folder/syndicate/red(mob.loc)
else
folder = new/obj/item/weapon/folder/syndicate/blue(mob.loc)
folder = new/obj/item/folder/syndicate/blue(mob.loc)
var/list/slots = list (
"backpack" = slot_in_backpack,

View File

@@ -188,7 +188,7 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master",
if(form == BLOOD_LIZARD && SOULVALUE < BLOOD_THRESHOLD)
regress_humanoid()
if(SOULVALUE < 0)
remove_spells()
give_appropriate_spells()
to_chat(owner.current, "<span class='warning'>As punishment for your failures, all of your powers except contract creation have been revoked.")
/datum/antagonist/devil/proc/regress_humanoid()
@@ -408,7 +408,7 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master",
reviveNumber += LOSS_PER_DEATH
update_hud()
if(body)
body.revive(1,0)
body.revive(TRUE, TRUE) //Adminrevive also recovers organs, preventing someone from resurrecting without a heart.
if(istype(body.loc, /obj/effect/dummy/slaughter/))
body.forceMove(get_turf(body))//Fixes dying while jaunted leaving you permajaunted.
if(istype(body, /mob/living/carbon/true_devil))
@@ -437,8 +437,8 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master",
var/mob/living/carbon/human/H = owner.current
H.equip_to_slot_or_del(new /obj/item/clothing/under/lawyer/black(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/laceup(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/briefcase(H), slot_hands)
H.equip_to_slot_or_del(new /obj/item/weapon/pen(H), slot_l_store)
H.equip_to_slot_or_del(new /obj/item/storage/briefcase(H), slot_hands)
H.equip_to_slot_or_del(new /obj/item/pen(H), slot_l_store)
if(SOULVALUE >= BLOOD_THRESHOLD)
H.set_species(/datum/species/lizard, 1)
H.underwear = "Nude"

View File

@@ -29,7 +29,7 @@
qdel(H.gloves)
var/obj/item/clothing/suit/space/space_ninja/theSuit = new(H)
var/obj/item/weapon/dash/energy_katana/EK = new(H)
var/obj/item/dash/energy_katana/EK = new(H)
theSuit.energyKatana = EK
H.equip_to_slot_or_del(new /obj/item/device/radio/headset(H), slot_ears)
@@ -42,12 +42,12 @@
H.equip_to_slot_or_del(new /obj/item/clothing/glasses/night(H), slot_glasses)
H.equip_to_slot_or_del(EK, slot_belt)
H.equip_to_slot_or_del(new /obj/item/device/flashlight(H), slot_r_store)
H.equip_to_slot_or_del(new /obj/item/weapon/grenade/plastic/x4(H), slot_l_store)
H.equip_to_slot_or_del(new /obj/item/weapon/tank/internals/emergency_oxygen(H), slot_s_store)
H.equip_to_slot_or_del(new /obj/item/weapon/tank/jetpack/carbondioxide(H), slot_back)
H.equip_to_slot_or_del(new /obj/item/grenade/plastic/x4(H), slot_l_store)
H.equip_to_slot_or_del(new /obj/item/tank/internals/emergency_oxygen(H), slot_s_store)
H.equip_to_slot_or_del(new /obj/item/tank/jetpack/carbondioxide(H), slot_back)
theSuit.randomize_param()
var/obj/item/weapon/implant/explosive/E = new/obj/item/weapon/implant/explosive(H)
var/obj/item/implant/explosive/E = new/obj/item/implant/explosive(H)
E.implant(H)
return 1

View File

@@ -141,7 +141,7 @@
afterDraw()
/obj/effect/ebeam
mouse_opacity = 0
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
anchored = TRUE
var/datum/beam/owner

View File

@@ -27,17 +27,21 @@ Stands have a lot of procs which mimic mob procs. Rather than inserting hooks fo
### Vars
1. `/datum/var/list/datum_components` (private)
* Lazy list of all components a datum has (TODO: Make this a typecache with longer paths overwriting shorter ones maybe? It'd be weird)
* Lazy associated list of type -> component/list of components.
1. `/datum/component/var/enabled` (protected, boolean)
* If the component is enabled. If not, it will not react to signals
* TRUE by default
* `TRUE` by default
1. `/datum/component/var/dupe_mode` (protected, enum)
* How multiple components of the exact same type are handled when added to the datum.
* How duplicate component types are handled when added to the datum.
* `COMPONENT_DUPE_HIGHLANDER` (default): Old component will be deleted, new component will first have `/datum/component/proc/InheritComponent(datum/component/old, FALSE)` on it
* `COMPONENT_DUPE_ALLOWED`: The components will be treated as seperate, `GetComponent()` will return the first added
* `COMPONENT_DUPE_ALLOWED`: The components will be treated as separate, `GetComponent()` will return the first added
* `COMPONENT_DUPE_UNIQUE`: New component will be deleted, old component will first have `/datum/component/proc/InheritComponent(datum/component/new, TRUE)` on it
1. `/datum/component/var/dupe_type` (protected, type)
* Definition of a duplicate component type
* `null` means exact match on `type`
* Any other type means that and all subtypes
1. `/datum/component/var/list/signal_procs` (private)
* Associated lazy list of signals -> callbacks that will be run when the parent datum recieves that signal
* Associated lazy list of signals -> `/datum/callback`s that will be run when the parent datum recieves that signal
1. `/datum/component/var/datum/parent` (protected, read-only)
* The datum this component belongs to
@@ -52,10 +56,12 @@ Stands have a lot of procs which mimic mob procs. Rather than inserting hooks fo
1. `GET_COMPONENT(varname, component_type)` OR `GET_COMPONENT_FROM(varname, component_type, src)`
* Shorthand for `var/component_type/varname = src.GetComponent(component_type)`
1. `/datum/proc/AddComponent(component_type(type), ...) -> datum/component` (public, final)
* Creates an instance of `component_type` in the datum and passes `...` to it's `New()` call
* Creates an instance of `component_type` in the datum and passes `...` to its `Initialize()` call
* Sends the `COMSIG_COMPONENT_ADDED` signal to the datum
* All components a datum owns are deleted with the datum
* Returns the component that was created. Or the old component in a dupe situation where `COMPONENT_DUPE_UNIQUE` was set
1. `/datum/proc/LoadComponent(component_type(type), ...) -> datum/component` (public, final)
* Equivalent to calling `GetComponent(component_type)` where, if the result would be `null`, returns `AddComponent(component_type, ...)` instead
1. `/datum/proc/ComponentActivated(datum/component/C)` (abstract)
* Called on a component's `parent` after a signal recieved causes it to activate. `src` is the parameter
* Will only be called if a component's callback returns `TRUE`
@@ -66,16 +72,24 @@ Stands have a lot of procs which mimic mob procs. Rather than inserting hooks fo
1. `/datum/proc/SendSignal(signal, ...)` (public, final)
* Call to send a signal to the components of the target datum
* Extra arguments are to be specified in the signal definition
1. `/datum/component/New(datum/parent, ...)` (protected, virtual)
* Forwarded the arguments from `AddComponent()`
1. `/datum/component/Destroy()` (virtual)
1. `/datum/component/New(datum/parent, ...)` (private, final)
* Runs internal setup for the component
* Extra arguments are passed to `Initialize()`
1. `/datum/component/Initialize(...)` (abstract, no-sleep)
* Called by `New()` with the same argments excluding `parent`
* Component does not exist in `parent`'s `datum_components` list yet, although `parent` is set and may be used
* Signals will not be recieved while this function is running
* Component may be deleted after this function completes without being attached
1. `/datum/component/Destroy()` (virtual, no-sleep)
* Sends the `COMSIG_COMPONENT_REMOVING` signal to the parent datum if the `parent` isn't being qdeleted
* Properly removes the component from `parent` and cleans up references
1. `/datum/component/proc/InheritComponent(datum/component/C, i_am_original(boolean))` (abstract)
1. `/datum/component/proc/InheritComponent(datum/component/C, i_am_original(boolean))` (abstract, no-sleep)
* Called on a component when a component of the same type was added to the same parent
* See `/datum/component/var/dupe_mode`
* `C`'s type will always be the same of the called component
1. `/datum/component/proc/OnTransfer(datum/new_parent)` (abstract)
1. `/datum/component/proc/AfterComponentActivated()` (abstract)
* Called on a component that was activated after it's `parent`'s `ComponentActivated()` is called
1. `/datum/component/proc/OnTransfer(datum/new_parent)` (abstract, no-sleep)
* Called before the new `parent` is assigned in `TakeComponent()`, after the remove signal, before the added signal
* Allows the component to react to ownership transfers
1. `/datum/component/proc/_RemoveNoSignal()` (private, final)
@@ -91,9 +105,4 @@ Stands have a lot of procs which mimic mob procs. Rather than inserting hooks fo
* Called when a component recieves any signal and is enabled
* Default implementation looks if the signal is registered and runs the appropriate proc
### See signals and their arguments in __DEFINES\components.dm
## Examples
Material Containers: #29268 (Too many GetComponent calls, but not bad)
Slips: #00000 (PR DIS)
Powercells: (TODO)
### See/Define signals and their arguments in __DEFINES\components.dm

View File

@@ -1,22 +1,36 @@
/datum/component
var/enabled = TRUE
var/dupe_mode = COMPONENT_DUPE_HIGHLANDER
var/dupe_type
var/list/signal_procs
var/datum/parent
/datum/component/New(datum/P, ...)
parent = P
var/list/arguments = args.Copy()
arguments.Cut(1, 2)
Initialize(arglist(arguments))
var/dm = dupe_mode
if(dm != COMPONENT_DUPE_ALLOWED)
var/datum/component/old = P.GetExactComponent(type)
var/dt = dupe_type
var/datum/component/old
if(!dt)
old = P.GetExactComponent(type)
else
old = P.GetComponent(dt)
if(old)
switch(dm)
if(COMPONENT_DUPE_UNIQUE)
old.InheritComponent(src, TRUE)
parent = null //prevent COMPONENT_REMOVING signal
qdel(src)
return
if(COMPONENT_DUPE_HIGHLANDER)
InheritComponent(old, FALSE)
qdel(old)
if(COMPONENT_DUPE_UNIQUE)
old.InheritComponent(src, TRUE)
qdel(src)
return
//let the others know
P.SendSignal(COMSIG_COMPONENT_ADDED, src)
//lazy init the parent's dc list
@@ -26,7 +40,7 @@
//set up the typecache
var/our_type = type
for(var/I in _GetInverseTypeListExceptRoot(our_type))
for(var/I in _GetInverseTypeList(our_type))
var/test = dc[I]
if(test) //already another component of this type here
var/list/components_of_type
@@ -50,7 +64,8 @@
else //only component of this type, no list
dc[I] = src
parent = P
/datum/component/proc/Initialize(...)
return
/datum/component/Destroy()
enabled = FALSE
@@ -66,7 +81,7 @@
if(P)
var/list/dc = P.datum_components
var/our_type = type
for(var/I in _GetInverseTypeListExceptRoot(our_type))
for(var/I in _GetInverseTypeList(our_type))
var/list/components_of_type = dc[I]
if(islist(components_of_type)) //
var/list/subtracted = components_of_type - src
@@ -110,23 +125,35 @@
/datum/component/proc/OnTransfer(datum/new_parent)
return
/datum/component/proc/_GetInverseTypeListExceptRoot(our_type_cached)
var/datum/component/current_type = our_type_cached
. = list()
/datum/component/proc/AfterComponentActivated()
return
/datum/component/proc/_GetInverseTypeList(current_type)
. = list(current_type)
while (current_type != /datum/component)
. += current_type
current_type = type2parent(current_type)
. += current_type
/datum/proc/SendSignal(sigtype, ...)
var/list/comps = datum_components
. = FALSE
for(var/I in comps)
var/datum/component/C = I
if(!C.enabled)
continue
if(C.ReceiveSignal(arglist(args)))
if(!comps)
return
var/target = comps[/datum/component]
if(!islist(target))
var/datum/component/C = target
if(C.enabled && C.ReceiveSignal(arglist(args)))
ComponentActivated(C)
. = TRUE
C.AfterComponentActivated()
return TRUE
else
for(var/I in target)
var/datum/component/C = I
if(!C.enabled)
continue
if(C.ReceiveSignal(arglist(args)))
ComponentActivated(C)
. = TRUE
/datum/proc/ComponentActivated(datum/component/C)
return
@@ -165,6 +192,11 @@
var/datum/component/C = new nt(arglist(args))
return QDELING(C) ? GetComponent(new_type) : C
/datum/proc/LoadComponent(component_type, ...)
. = GetComponent(component_type)
if(!.)
return AddComponent(arglist(args))
/datum/proc/TakeComponent(datum/component/C)
if(!C)
return

View File

@@ -1,18 +1 @@
diff a/code/datums/components/component.dm b/code/datums/components/component.dm (rejected hunks)
@@ -22,8 +22,7 @@
//lazy init the parent's dc list
var/list/dc = P.datum_components
if(!dc)
- dc = list()
- P.datum_components = dc
+ P.datum_components = dc = list()
//set up the typecache
var/our_type = type
@@ -179,4 +178,4 @@
helicopter.SendSignal(COMSIG_COMPONENT_REMOVING, C)
C.OnTransfer(src)
C.parent = src
- SendSignal(COMSIG_COMPONENT_ADDED, C)
\ No newline at end of file
+ SendSignal(COMSIG_COMPONENT_ADDED, C)
-

View File

@@ -0,0 +1,21 @@
/datum/component/slippery
var/intensity
var/lube_flags
var/mob/slip_victim
/datum/component/slippery/Initialize(_intensity, _lube_flags = NONE)
intensity = max(_intensity, 0)
lube_flags = _lube_flags
if(ismovableatom(parent))
RegisterSignal(COMSIG_MOVABLE_CROSSED, .proc/Slip)
else
RegisterSignal(COMSIG_ATOM_ENTERED, .proc/Slip)
/datum/component/slippery/proc/Slip(atom/movable/AM)
var/mob/victim = AM
if(istype(victim) && !victim.is_flying() && victim.slip(intensity, parent, lube_flags))
slip_victim = victim
return TRUE
/datum/component/slippery/AfterComponentActivated()
slip_victim = null

View File

@@ -210,8 +210,8 @@
if(!C)
C = H.client
var/image = get_id_photo(H, C)
var/obj/item/weapon/photo/photo_front = new()
var/obj/item/weapon/photo/photo_side = new()
var/obj/item/photo/photo_front = new()
var/obj/item/photo/photo_side = new()
photo_front.photocreate(null, icon(image, dir = SOUTH))
photo_side.photocreate(null, icon(image, dir = WEST))

View File

@@ -22,10 +22,16 @@
continue
qdel(timer)
var/list/dc = datum_components
for(var/I in dc)
var/datum/component/C = I
C._RemoveNoSignal()
qdel(C)
if(dc)
var/all_components = dc[/datum/component]
if(islist(all_components))
for(var/I in all_components)
var/datum/component/C = I
C._RemoveNoSignal()
qdel(C)
else
var/datum/component/C = all_components
C._RemoveNoSignal()
qdel(C)
dc.Cut()
return QDEL_HINT_QUEUE
return QDEL_HINT_QUEUE

View File

@@ -43,7 +43,7 @@
SSdisease.active_diseases += DD //Add it to the active diseases list, now that it's actually in a mob and being processed.
//Copy properties over. This is so edited diseases persist.
var/list/skipped = list("affected_mob","holder","carrier","stage","type","parent_type","vars","transformed")
var/list/skipped = list("affected_mob","holder","carrier","stage","type","parent_type","vars","transformed","symptoms")
for(var/V in DD.vars)
if(V in skipped)
continue
@@ -92,7 +92,7 @@
switch(target_zone)
if(1)
if(isobj(H.head) && !istype(H.head, /obj/item/weapon/paper))
if(isobj(H.head) && !istype(H.head, /obj/item/paper))
Cl = H.head
passed = prob((Cl.permeability_coefficient*100) - 1)
if(passed && isobj(H.wear_mask))

View File

@@ -57,9 +57,7 @@
symptoms = GenerateSymptoms(0, 2)
else
for(var/datum/symptom/S in D.symptoms)
var/datum/symptom/new_symp = new S.type
new_symp.name = S.name
new_symp.neutered = S.neutered
var/datum/symptom/new_symp = S.Copy()
symptoms += new_symp
Refresh()

View File

@@ -19,7 +19,7 @@
to_chat(affected_mob, "<span class='danger'>You feel a slight shock course through your body.</span>")
if(prob(2))
for(var/obj/M in orange(2,affected_mob))
if(!M.anchored && (M.flags & CONDUCT))
if(!M.anchored && (M.flags_1 & CONDUCT_1))
step_towards(M,affected_mob)
for(var/mob/living/silicon/S in orange(2,affected_mob))
if(isAI(S))
@@ -32,7 +32,7 @@
to_chat(affected_mob, "<span class='danger'>You feel like clowning around.</span>")
if(prob(4))
for(var/obj/M in orange(4,affected_mob))
if(!M.anchored && (M.flags & CONDUCT))
if(!M.anchored && (M.flags_1 & CONDUCT_1))
var/i
var/iter = rand(1,2)
for(i=0,i<iter,i++)
@@ -51,7 +51,7 @@
to_chat(affected_mob, "<span class='danger'>You query upon the nature of miracles.</span>")
if(prob(8))
for(var/obj/M in orange(6,affected_mob))
if(!M.anchored && (M.flags & CONDUCT))
if(!M.anchored && (M.flags_1 & CONDUCT_1))
var/i
var/iter = rand(1,3)
for(i=0,i<iter,i++)

View File

@@ -78,7 +78,7 @@ STI KALY - blind
else
var/mob/living/carbon/H = affected_mob
if(prob(chance))
var/obj/item/weapon/staff/S = new(H)
var/obj/item/staff/S = new(H)
if(!H.put_in_hands(S))
qdel(S)

View File

@@ -38,7 +38,7 @@
msg = replace_pronoun(user, msg)
var/mob/living/L = user
for(var/obj/item/weapon/implant/I in L.implants)
for(var/obj/item/implant/I in L.implants)
I.trigger(key, L)
if(!msg)

View File

@@ -149,10 +149,10 @@
/datum/teleport/instant/science/setPrecision(aprecision)
..()
if(istype(teleatom, /obj/item/weapon/storage/backpack/holding))
if(istype(teleatom, /obj/item/storage/backpack/holding))
precision = rand(1,100)
var/list/bagholding = teleatom.search_contents_for(/obj/item/weapon/storage/backpack/holding)
var/list/bagholding = teleatom.search_contents_for(/obj/item/storage/backpack/holding)
if(bagholding.len)
precision = max(rand(1,100)*bagholding.len,100)
if(isliving(teleatom))

View File

@@ -27,7 +27,7 @@
var/config_max_users = 0
var/config_min_users = 0
var/voteweight = 1
var/allow_custom_shuttles = "yes"
/datum/map_config/New(filename = "data/next_map.json", default_to_box, delete_after)
if(default_to_box)
return
@@ -44,12 +44,12 @@
if(!json)
log_world("Could not open map_config: [filename]")
return
json = file2text(json)
if(!json)
log_world("map_config is not text: [filename]")
return
json = json_decode(json)
if(!json)
log_world("map_config is not json: [filename]")
@@ -58,7 +58,7 @@
if(!ValidateJSON(json))
log_world("map_config failed to validate for above reason: [filename]")
return
config_filename = filename
map_name = json["map_name"]
@@ -66,6 +66,7 @@
map_file = json["map_file"]
minetype = json["minetype"]
allow_custom_shuttles = json["allow_custom_shuttles"]
var/list/jtcl = json["transition_config"]
@@ -74,7 +75,7 @@
for(var/I in jtcl)
transition_config[TransitionStringToEnum(I)] = TransitionStringToEnum(jtcl[I])
defaulted = FALSE
#define CHECK_EXISTS(X) if(!istext(json[X])) { log_world(X + "missing from json!"); return; }
@@ -84,6 +85,7 @@
CHECK_EXISTS("map_file")
CHECK_EXISTS("minetype")
CHECK_EXISTS("transition_config")
CHECK_EXISTS("allow_custom_shuttles")
var/path = GetFullMapPath(json["map_path"], json["map_file"])
if(!fexists(path))
@@ -92,7 +94,7 @@
if(json["transition_config"] != "default")
if(!islist(json["transition_config"]))
log_world("transition_config is not a list!")
log_world("transition_config is not a list!")
return
var/list/jtcl = json["transition_config"]

View File

@@ -181,13 +181,13 @@
to_chat(usr, "<b><i>In addition, by having your throw mode on when being attacked, you enter an active defense mode where you have a chance to block and sometimes even counter attacks done to you.</i></b>")
/obj/item/weapon/cqc_manual
/obj/item/cqc_manual
name = "old manual"
desc = "A small, black manual. There are drawn instructions of tactical hand-to-hand combat."
icon = 'icons/obj/library.dmi'
icon_state ="cqcmanual"
/obj/item/weapon/cqc_manual/attack_self(mob/living/carbon/human/user)
/obj/item/cqc_manual/attack_self(mob/living/carbon/human/user)
if(!istype(user) || !user)
return
to_chat(user, "<span class='boldannounce'>You remember the basics of CQC.</span>")

View File

@@ -93,14 +93,14 @@
to_chat(usr, "<span class='notice'>Throwback</span>: Disarm Harm Disarm. Throws the target and an item at them.")
to_chat(usr, "<span class='notice'>The Plasma Fist</span>: Harm Disarm Disarm Disarm Harm. Knocks the brain out of the opponent and gibs their body.")
/obj/item/weapon/plasma_fist_scroll
/obj/item/plasma_fist_scroll
name = "frayed scroll"
desc = "An aged and frayed scrap of paper written in shifting runes. There are hand-drawn illustrations of pugilism."
icon = 'icons/obj/wizard.dmi'
icon_state ="scroll2"
var/used = 0
/obj/item/weapon/plasma_fist_scroll/attack_self(mob/user)
/obj/item/plasma_fist_scroll/attack_self(mob/user)
if(!ishuman(user))
return
if(!used)

View File

@@ -154,13 +154,13 @@
to_chat(usr, "<span class='notice'>Head Kick</span>: Disarm Harm Harm. Decent damage, forces opponent to drop item in hand.")
to_chat(usr, "<span class='notice'>Elbow Drop</span>: Harm Disarm Harm Disarm Harm. Opponent must be on the ground. Deals huge damage, instantly kills anyone in critical condition.")
/obj/item/weapon/sleeping_carp_scroll
/obj/item/sleeping_carp_scroll
name = "mysterious scroll"
desc = "A scroll filled with strange markings. It seems to be drawings of some sort of martial art."
icon = 'icons/obj/wizard.dmi'
icon_state = "scroll2"
/obj/item/weapon/sleeping_carp_scroll/attack_self(mob/living/carbon/human/user)
/obj/item/sleeping_carp_scroll/attack_self(mob/living/carbon/human/user)
if(!istype(user) || !user)
return
var/message = "<span class='sciradio'>You have learned the ancient martial art of the Sleeping Carp! Your hand-to-hand combat has become much more effective, and you are now able to deflect any projectiles \
@@ -173,7 +173,7 @@
new /obj/effect/decal/cleanable/ash(get_turf(src))
qdel(src)
/obj/item/weapon/twohanded/bostaff
/obj/item/twohanded/bostaff
name = "bo staff"
desc = "A long, tall staff made of polished wood. Traditionally used in ancient old-Earth martial arts. Can be wielded to both kill and incapacitate."
force = 10
@@ -184,17 +184,17 @@
throwforce = 20
throw_speed = 2
attack_verb = list("smashed", "slammed", "whacked", "thwacked")
icon = 'icons/obj/weapons.dmi'
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "bostaff0"
lefthand_file = 'icons/mob/inhands/weapons/staves_lefthand.dmi'
righthand_file = 'icons/mob/inhands/weapons/staves_righthand.dmi'
block_chance = 50
/obj/item/weapon/twohanded/bostaff/update_icon()
/obj/item/twohanded/bostaff/update_icon()
icon_state = "bostaff[wielded]"
return
/obj/item/weapon/twohanded/bostaff/attack(mob/target, mob/living/user)
/obj/item/twohanded/bostaff/attack(mob/target, mob/living/user)
add_fingerprint(user)
if((CLUMSY in user.disabilities) && prob(50))
to_chat(user, "<span class ='warning'>You club yourself over the head with [src].</span>")
@@ -243,7 +243,7 @@
else
return ..()
/obj/item/weapon/twohanded/bostaff/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
/obj/item/twohanded/bostaff/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
if(wielded)
return ..()
return 0

View File

@@ -438,11 +438,11 @@
add_logs(A, D, "cinched")
return 1
/obj/item/weapon/storage/belt/champion/wrestling
/obj/item/storage/belt/champion/wrestling
name = "Wrestling Belt"
var/datum/martial_art/wrestling/style = new
/obj/item/weapon/storage/belt/champion/wrestling/equipped(mob/user, slot)
/obj/item/storage/belt/champion/wrestling/equipped(mob/user, slot)
if(!ishuman(user))
return
if(slot == slot_belt)
@@ -450,7 +450,7 @@
style.teach(H,1)
return
/obj/item/weapon/storage/belt/champion/wrestling/dropped(mob/user)
/obj/item/storage/belt/champion/wrestling/dropped(mob/user)
if(!ishuman(user))
return
var/mob/living/carbon/human/H = user

View File

@@ -223,7 +223,7 @@
name = "Metal"
id = MAT_METAL
sheet_type = /obj/item/stack/sheet/metal
coin_type = /obj/item/weapon/coin/iron
coin_type = /obj/item/coin/iron
/datum/material/glass
name = "Glass"
@@ -234,31 +234,31 @@
name = "Silver"
id = MAT_SILVER
sheet_type = /obj/item/stack/sheet/mineral/silver
coin_type = /obj/item/weapon/coin/silver
coin_type = /obj/item/coin/silver
/datum/material/gold
name = "Gold"
id = MAT_GOLD
sheet_type = /obj/item/stack/sheet/mineral/gold
coin_type = /obj/item/weapon/coin/gold
coin_type = /obj/item/coin/gold
/datum/material/diamond
name = "Diamond"
id = MAT_DIAMOND
sheet_type = /obj/item/stack/sheet/mineral/diamond
coin_type = /obj/item/weapon/coin/diamond
coin_type = /obj/item/coin/diamond
/datum/material/uranium
name = "Uranium"
id = MAT_URANIUM
sheet_type = /obj/item/stack/sheet/mineral/uranium
coin_type = /obj/item/weapon/coin/uranium
coin_type = /obj/item/coin/uranium
/datum/material/plasma
name = "Solid Plasma"
id = MAT_PLASMA
sheet_type = /obj/item/stack/sheet/mineral/plasma
coin_type = /obj/item/weapon/coin/plasma
coin_type = /obj/item/coin/plasma
/datum/material/bluespace
name = "Bluespace Mesh"
@@ -269,7 +269,7 @@
name = "Bananium"
id = MAT_BANANIUM
sheet_type = /obj/item/stack/sheet/mineral/bananium
coin_type = /obj/item/weapon/coin/clown
coin_type = /obj/item/coin/clown
/datum/material/titanium
name = "Titanium"

View File

@@ -271,7 +271,7 @@
var/list/all_contents = traitor_mob.GetAllContents()
var/obj/item/device/pda/PDA = locate() in all_contents
var/obj/item/device/radio/R = locate() in all_contents
var/obj/item/weapon/pen/P = locate() in all_contents //including your PDA-pen!
var/obj/item/pen/P = locate() in all_contents //including your PDA-pen!
var/obj/item/uplink_loc
@@ -1038,7 +1038,7 @@
if("takeequip")
var/list/L = current.get_contents()
for(var/obj/item/weapon/pen/gang/pen in L)
for(var/obj/item/pen/gang/pen in L)
qdel(pen)
for(var/obj/item/device/gangtool/gangtool in L)
qdel(gangtool)

View File

@@ -101,7 +101,7 @@
H.update_action_buttons_icon()
if(implants)
for(var/implant_type in implants)
var/obj/item/weapon/implant/I = new implant_type(H)
var/obj/item/implant/I = new implant_type(H)
I.implant(H, null, silent=TRUE)
H.update_body()

View File

@@ -35,8 +35,8 @@
/datum/recipe
var/list/reagents_list // example: = list("berryjuice" = 5) // do not list same reagent twice
var/list/items // example: =list(/obj/item/weapon/crowbar, /obj/item/weapon/welder) // place /foo/bar before /foo
var/result //example: = /obj/item/weapon/reagent_containers/food/snacks/donut
var/list/items // example: =list(/obj/item/crowbar, /obj/item/welder) // place /foo/bar before /foo
var/result //example: = /obj/item/reagent_containers/food/snacks/donut
var/time = 100 // 1/10 part of second

View File

@@ -255,7 +255,7 @@
///////////////BOATS////////////
/datum/riding/boat
keytype = /obj/item/weapon/oar
keytype = /obj/item/oar
/datum/riding/boat/handle_ride(mob/user, direction)
var/turf/next = get_step(ridden, direction)
@@ -416,10 +416,10 @@
/obj/item/riding_offhand
name = "offhand"
icon = 'icons/obj/weapons.dmi'
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "offhand"
w_class = WEIGHT_CLASS_HUGE
flags = ABSTRACT | DROPDEL | NOBLUDGEON
flags_1 = ABSTRACT_1 | DROPDEL_1 | NOBLUDGEON_1
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
var/mob/living/carbon/rider
var/mob/living/ridden

10
code/datums/riding.dm.rej Normal file
View File

@@ -0,0 +1,10 @@
diff a/code/datums/riding.dm b/code/datums/riding.dm (rejected hunks)
@@ -419,7 +419,7 @@
icon = 'icons/obj/items_and_weapons.dmi.dmi'
icon_state = "offhand"
w_class = WEIGHT_CLASS_HUGE
- flags = ABSTRACT | DROPDEL | NOBLUDGEON
+ flags_1 = ABSTRACT_1 | DROPDEL_1 | NOBLUDGEON_1
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
var/mob/living/carbon/rider
var/mob/living/ridden

View File

@@ -192,7 +192,7 @@
/datum/status_effect/his_grace/tick()
bloodlust = 0
var/graces = 0
for(var/obj/item/weapon/his_grace/HG in owner.held_items)
for(var/obj/item/his_grace/HG in owner.held_items)
if(HG.bloodthirst > bloodlust)
bloodlust = HG.bloodthirst
if(HG.awakened)

View File

@@ -85,7 +85,7 @@
alerttooltipstyle = "hisgrace"
/datum/status_effect/his_wrath/tick()
for(var/obj/item/weapon/his_grace/HG in owner.held_items)
for(var/obj/item/his_grace/HG in owner.held_items)
qdel(src)
return
owner.adjustBruteLoss(0.1)
@@ -139,6 +139,20 @@
if(owner.m_intent == MOVE_INTENT_WALK)
owner.toggle_move_intent()
/datum/status_effect/geis_tracker
id = "geis_tracker"
duration = -1
alert_type = null
var/obj/structure/destructible/clockwork/geis_binding/binding
/datum/status_effect/geis_tracker/on_creation(mob/living/new_owner, obj/structure/destructible/clockwork/geis_binding/new_binding)
. = ..()
if(.)
binding = new_binding
/datum/status_effect/geis_tracker/tick()
if(QDELETED(binding))
qdel(src)
/datum/status_effect/maniamotor
id = "maniamotor"
@@ -243,9 +257,9 @@
status_type = STATUS_EFFECT_REPLACE
alert_type = null
var/mutable_appearance/marked_underlay
var/obj/item/weapon/twohanded/required/kinetic_crusher/hammer_synced
var/obj/item/twohanded/required/kinetic_crusher/hammer_synced
/datum/status_effect/crusher_mark/on_creation(mob/living/new_owner, obj/item/weapon/twohanded/required/kinetic_crusher/new_hammer_synced)
/datum/status_effect/crusher_mark/on_creation(mob/living/new_owner, obj/item/twohanded/required/kinetic_crusher/new_hammer_synced)
. = ..()
if(.)
hammer_synced = new_hammer_synced

View File

@@ -13,16 +13,16 @@
/datum/wires/explosive/c4
holder_type = /obj/item/weapon/grenade/plastic/c4
holder_type = /obj/item/grenade/plastic/c4
randomize = TRUE //Same behaviour since no wire actually disarms it
/datum/wires/explosive/c4/interactable(mob/user)
var/obj/item/weapon/grenade/plastic/c4/P = holder
var/obj/item/grenade/plastic/c4/P = holder
if(P.open_panel)
return TRUE
/datum/wires/explosive/c4/explode()
var/obj/item/weapon/grenade/plastic/c4/P = holder
var/obj/item/grenade/plastic/c4/P = holder
P.explode()
@@ -73,8 +73,8 @@
/datum/wires/explosive/gibtonite
holder_type = /obj/item/weapon/twohanded/required/gibtonite
holder_type = /obj/item/twohanded/required/gibtonite
/datum/wires/explosive/gibtonite/explode()
var/obj/item/weapon/twohanded/required/gibtonite/P = holder
var/obj/item/twohanded/required/gibtonite/P = holder
P.GibtoniteReaction(null, 2)

View File

@@ -3,7 +3,7 @@
/proc/is_wire_tool(obj/item/I)
if(istype(I, /obj/item/device/multitool))
return TRUE
if(istype(I, /obj/item/weapon/wirecutters))
if(istype(I, /obj/item/wirecutters))
return TRUE
if(istype(I, /obj/item/device/assembly))
var/obj/item/device/assembly/A = I
@@ -227,7 +227,7 @@
var/obj/item/I = L.get_active_held_item()
switch(action)
if("cut")
if(istype(I, /obj/item/weapon/wirecutters) || IsAdminGhost(usr))
if(istype(I, /obj/item/wirecutters) || IsAdminGhost(usr))
playsound(holder, I.usesound, 20, 1)
cut_color(target_wire)
. = TRUE