Bleeding edgy refresh (#303)

* not code stuff

* other things

* global vars, defines, helpers

* onclick hud stuff, orphans, world.dm

* controllers and datums

* game folder

* everything not client/mobs in modules

* client folder

* stage 1 mob stuff

* simple animal things

* silicons

* carbon things

* ayylmaos and monkeys

* hyoomahn

* icons n shit

* sprite fixes

* compile fixes

* some fixes I cherrypicked.

* qdel fixes

* forgot brain refractors
This commit is contained in:
Poojawa
2017-03-21 11:44:10 -05:00
committed by GitHub
parent 099a6c8764
commit f67e9f6d87
1476 changed files with 344416 additions and 40694 deletions
+30 -19
View File
@@ -18,7 +18,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
/obj/effect/proc_holder/proc/InterceptClickOn(mob/living/caller, params, atom/A)
if(caller.ranged_ability != src || ranged_ability_user != caller) //I'm not actually sure how these would trigger, but, uh, safety, I guess?
caller << "<span class='warning'><b>[caller.ranged_ability.name]</b> has been disabled."
to_chat(caller, "<span class='warning'><b>[caller.ranged_ability.name]</b> has been disabled.")
caller.ranged_ability.remove_ranged_ability()
return TRUE //TRUE for failed, FALSE for passed.
if(ranged_clickcd_override >= 0)
@@ -33,7 +33,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
return
if(user.ranged_ability && user.ranged_ability != src)
if(forced)
user << "<span class='warning'><b>[user.ranged_ability.name]</b> has been replaced by <b>[name]</b>."
to_chat(user, "<span class='warning'><b>[user.ranged_ability.name]</b> has been replaced by <b>[name]</b>.")
user.ranged_ability.remove_ranged_ability()
else
return
@@ -42,7 +42,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
add_mousepointer(user.client)
ranged_ability_user = user
if(msg)
ranged_ability_user << msg
to_chat(ranged_ability_user, msg)
active = TRUE
update_icon()
@@ -61,7 +61,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
ranged_ability_user.client.click_intercept = null
remove_mousepointer(ranged_ability_user.client)
if(msg)
ranged_ability_user << msg
to_chat(ranged_ability_user, msg)
ranged_ability_user = null
active = FALSE
update_icon()
@@ -126,7 +126,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
if(player_lock)
if(!user.mind || !(src in user.mind.spell_list) && !(src in user.mob_spell_list))
user << "<span class='warning'>You shouldn't have this spell! Something's wrong.</span>"
to_chat(user, "<span class='warning'>You shouldn't have this spell! Something's wrong.</span>")
return 0
else
if(!(src in user.mob_spell_list))
@@ -134,26 +134,26 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
var/turf/T = get_turf(user)
if(T.z == ZLEVEL_CENTCOM && (!centcom_cancast || ticker.mode.name == "ragin' mages")) //Certain spells are not allowed on the centcom zlevel
user << "<span class='notice'>You can't cast this spell here.</span>"
to_chat(user, "<span class='notice'>You can't cast this spell here.</span>")
return 0
if(!skipcharge)
switch(charge_type)
if("recharge")
if(charge_counter < charge_max)
user << still_recharging_msg
to_chat(user, still_recharging_msg)
return 0
if("charges")
if(!charge_counter)
user << "<span class='notice'>[name] has no charges left.</span>"
to_chat(user, "<span class='notice'>[name] has no charges left.</span>")
return 0
if(user.stat && !stat_allowed)
user << "<span class='notice'>Not when you're incapacitated.</span>"
to_chat(user, "<span class='notice'>Not when you're incapacitated.</span>")
return 0
if(!phase_allowed && istype(user.loc, /obj/effect/dummy))
user << "<span class='notice'>[name] cannot be cast unless you are completely manifested in the material plane.</span>"
to_chat(user, "<span class='notice'>[name] cannot be cast unless you are completely manifested in the material plane.</span>")
return 0
if(ishuman(user))
@@ -161,7 +161,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
var/mob/living/carbon/human/H = user
if((invocation_type == "whisper" || invocation_type == "shout") && H.is_muzzled())
user << "<span class='notice'>You can't get the words out!</span>"
to_chat(user, "<span class='notice'>You can't get the words out!</span>")
return 0
var/list/casting_clothes = typecacheof(list(/obj/item/clothing/suit/wizrobe,
@@ -173,24 +173,24 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
if(clothes_req) //clothes check
if(!is_type_in_typecache(H.wear_suit, casting_clothes))
H << "<span class='notice'>I don't feel strong enough without my robe.</span>"
to_chat(H, "<span class='notice'>I don't feel strong enough without my robe.</span>")
return 0
if(!is_type_in_typecache(H.head, casting_clothes))
H << "<span class='notice'>I don't feel strong enough without my hat.</span>"
to_chat(H, "<span class='notice'>I don't feel strong enough without my hat.</span>")
return 0
if(cult_req) //CULT_REQ CLOTHES CHECK
if(!istype(H.wear_suit, /obj/item/clothing/suit/magusred) && !istype(H.wear_suit, /obj/item/clothing/suit/space/hardsuit/cult))
H << "<span class='notice'>I don't feel strong enough without my armor.</span>"
to_chat(H, "<span class='notice'>I don't feel strong enough without my armor.</span>")
return 0
if(!istype(H.head, /obj/item/clothing/head/magus) && !istype(H.head, /obj/item/clothing/head/helmet/space/hardsuit/cult))
H << "<span class='notice'>I don't feel strong enough without my helmet.</span>"
to_chat(H, "<span class='notice'>I don't feel strong enough without my helmet.</span>")
return 0
else
if(clothes_req || human_req)
user << "<span class='notice'>This spell can only be cast by humans!</span>"
to_chat(user, "<span class='notice'>This spell can only be cast by humans!</span>")
return 0
if(nonabstract_req && (isbrain(user) || ispAI(user)))
user << "<span class='notice'>This spell can only be cast by physical beings!</span>"
to_chat(user, "<span class='notice'>This spell can only be cast by physical beings!</span>")
return 0
@@ -242,6 +242,9 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
/obj/effect/proc_holder/spell/proc/choose_targets(mob/user = usr) //depends on subtype - /targeted or /aoe_turf
return
/obj/effect/proc_holder/spell/proc/can_target(mob/living/target)
return TRUE
/obj/effect/proc_holder/spell/proc/start_recharge()
if(action)
action.UpdateButtonIcon()
@@ -255,7 +258,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
before_cast(targets)
invocation(user)
if(user && user.ckey)
user.attack_log += text("\[[time_stamp()]\] <span class='danger'>[user.real_name] ([user.ckey]) cast the spell [name].</span>")
user.log_message("<span class='danger'>cast the spell [name].</span>", INDIVIDUAL_ATTACK_LOG)
spawn(0)
if(charge_type == "recharge" && recharge)
start_recharge()
@@ -290,7 +293,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
else if(isturf(target))
location = target
if(isliving(target) && message)
target << text("[message]")
to_chat(target, text("[message]"))
if(sparks_spread)
var/datum/effect_system/spark_spread/sparks = new
sparks.set_up(sparks_amt, 0, location) //no idea what the 0 is
@@ -361,6 +364,8 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
switch(max_targets)
if(0) //unlimited
for(var/mob/living/target in view_or_range(range, user, selection_type))
if(!can_target(target))
continue
targets += target
if(1) //single target can be picked
if(range < 0)
@@ -371,6 +376,8 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
for(var/mob/living/M in view_or_range(range, user, selection_type))
if(!include_user && user == M)
continue
if(!can_target(M))
continue
possible_targets += M
//targets += input("Choose the target for the spell.", "Targeting") as mob in possible_targets
@@ -396,6 +403,8 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
else
var/list/possible_targets = list()
for(var/mob/living/target in view_or_range(range, user, selection_type))
if(!can_target(target))
continue
possible_targets += target
for(var/i=1,i<=max_targets,i++)
if(!possible_targets.len)
@@ -420,6 +429,8 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
var/list/targets = list()
for(var/turf/target in view_or_range(range,user,selection_type))
if(!can_target(target))
continue
if(!(target in view_or_range(inner_radius,user,selection_type)))
targets += target