mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-24 04:27:35 +01:00
Made all current wizard + genetic spells a subtype of spell/wizard (Since they use the same action button row)
This commit is contained in:
+18
-18
@@ -48,7 +48,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
var/icon_power_button
|
||||
var/power_button_name
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/cast_check(skipcharge = 0,mob/user = usr) //checks if the spell can be cast based on its settings; skipcharge is used when an additional cast_check is called inside the spell
|
||||
/obj/effect/proc_holder/spell/wizard/proc/cast_check(skipcharge = 0,mob/user = usr) //checks if the spell can be cast based on its settings; skipcharge is used when an additional cast_check is called inside the spell
|
||||
|
||||
if(!(src in user.spell_list))
|
||||
user << "<span class='warning'>You shouldn't have this spell! Something's wrong.</span>"
|
||||
@@ -77,7 +77,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
if(istype(usr.wear_mask, /obj/item/clothing/mask/muzzle))
|
||||
usr << "Mmmf mrrfff!"
|
||||
return 0
|
||||
var/obj/effect/proc_holder/spell/noclothes/spell = locate() in user.spell_list
|
||||
var/obj/effect/proc_holder/spell/wizard/noclothes/spell = locate() in user.spell_list
|
||||
if(clothes_req && !(spell && istype(spell)))//clothes check
|
||||
if(!istype(usr, /mob/living/carbon/human))
|
||||
usr << "You aren't a human, Why are you trying to cast a human spell, silly non-human? Casting human spells is for humans."
|
||||
@@ -103,7 +103,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
|
||||
return 1
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/invocation(mob/user = usr) //spelling the spell out and setting it on recharge/reducing charges amount
|
||||
/obj/effect/proc_holder/spell/wizard/proc/invocation(mob/user = usr) //spelling the spell out and setting it on recharge/reducing charges amount
|
||||
switch(invocation_type)
|
||||
if("shout")
|
||||
if(prob(50))//Auto-mute? Fuck that noise
|
||||
@@ -116,26 +116,26 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
else
|
||||
user.whisper(replacetext(invocation," ","`"))
|
||||
|
||||
/obj/effect/proc_holder/spell/New()
|
||||
/obj/effect/proc_holder/spell/wizard/New()
|
||||
..()
|
||||
|
||||
charge_counter = charge_max
|
||||
|
||||
/obj/effect/proc_holder/spell/Click()
|
||||
/obj/effect/proc_holder/spell/wizard/Click()
|
||||
if(cast_check())
|
||||
choose_targets()
|
||||
return 1
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/choose_targets(mob/user = usr) //depends on subtype - /targeted or /aoe_turf
|
||||
/obj/effect/proc_holder/spell/wizard/proc/choose_targets(mob/user = usr) //depends on subtype - /targeted or /aoe_turf
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/start_recharge()
|
||||
/obj/effect/proc_holder/spell/wizard/proc/start_recharge()
|
||||
while(charge_counter < charge_max)
|
||||
sleep(1)
|
||||
charge_counter++
|
||||
usr.update_power_buttons()
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/perform(list/targets, recharge = 1, mob/user = usr) //if recharge is started is important for the trigger spells
|
||||
/obj/effect/proc_holder/spell/wizard/proc/perform(list/targets, recharge = 1, mob/user = usr) //if recharge is started is important for the trigger spells
|
||||
before_cast(targets)
|
||||
invocation()
|
||||
user.attack_log += text("\[[time_stamp()]\] <font color='red'>[user.real_name] ([user.ckey]) cast the spell [name].</font>")
|
||||
@@ -148,7 +148,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
cast(targets)
|
||||
after_cast(targets)
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/before_cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/proc/before_cast(list/targets)
|
||||
if(overlay)
|
||||
for(var/atom/target in targets)
|
||||
var/location
|
||||
@@ -164,7 +164,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
spawn(overlay_lifespan)
|
||||
del(spell)
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/after_cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/proc/after_cast(list/targets)
|
||||
for(var/atom/target in targets)
|
||||
var/location
|
||||
if(istype(target,/mob/living))
|
||||
@@ -188,13 +188,13 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
smoke.start()
|
||||
usr.update_power_buttons()
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/proc/cast(list/targets)
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/critfail(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/proc/critfail(list/targets)
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/revert_cast(mob/user = usr) //resets recharge or readds a charge
|
||||
/obj/effect/proc_holder/spell/wizard/proc/revert_cast(mob/user = usr) //resets recharge or readds a charge
|
||||
switch(charge_type)
|
||||
if("recharge")
|
||||
charge_counter = charge_max
|
||||
@@ -205,7 +205,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/proc/adjust_var(mob/living/target = usr, type, amount) //handles the adjustment of the var when the spell is used. has some hardcoded types
|
||||
/obj/effect/proc_holder/spell/wizard/proc/adjust_var(mob/living/target = usr, type, amount) //handles the adjustment of the var when the spell is used. has some hardcoded types
|
||||
switch(type)
|
||||
if("bruteloss")
|
||||
target.adjustBruteLoss(amount)
|
||||
@@ -225,15 +225,15 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
target.vars[type] += amount //I bear no responsibility for the runtimes that'll happen if you try to adjust non-numeric or even non-existant vars
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted //can mean aoe for mobs (limited/unlimited number) or one target mob
|
||||
/obj/effect/proc_holder/spell/wizard/targeted //can mean aoe for mobs (limited/unlimited number) or one target mob
|
||||
var/max_targets = 1 //leave 0 for unlimited targets in range, 1 for one selectable target in range, more for limited number of casts (can all target one guy, depends on target_ignore_prev) in range
|
||||
var/target_ignore_prev = 1 //only important if max_targets > 1, affects if the spell can be cast multiple times at one person from one cast
|
||||
var/include_user = 0 //if it includes usr in the target list
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf //affects all turfs in view or range (depends)
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf //affects all turfs in view or range (depends)
|
||||
var/inner_radius = -1 //for all your ring spell needs
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/choose_targets(mob/user = usr)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/choose_targets(mob/user = usr)
|
||||
var/list/targets = list()
|
||||
|
||||
switch(max_targets)
|
||||
@@ -280,7 +280,7 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/choose_targets(mob/user = usr)
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/choose_targets(mob/user = usr)
|
||||
var/list/targets = list()
|
||||
|
||||
for(var/turf/target in view_or_range(range,user,selection_type))
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
/obj/effect/proc_holder/spell/targeted/area_teleport
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/area_teleport
|
||||
name = "Area teleport"
|
||||
desc = "This spell teleports you to a type of area of your selection."
|
||||
|
||||
var/randomise_selection = 0 //if it lets the usr choose the teleport loc or picks it from the list
|
||||
var/invocation_area = 1 //if the invocation appends the selected area
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/area_teleport/perform(list/targets, recharge = 1)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/area_teleport/perform(list/targets, recharge = 1)
|
||||
var/thearea = before_cast(targets)
|
||||
if(!thearea || !cast_check(1))
|
||||
revert_cast()
|
||||
@@ -17,7 +17,7 @@
|
||||
cast(targets,thearea)
|
||||
after_cast(targets)
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/area_teleport/before_cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/area_teleport/before_cast(list/targets)
|
||||
var/A = null
|
||||
|
||||
if(!randomise_selection)
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
return thearea
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/area_teleport/cast(list/targets,area/thearea)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/area_teleport/cast(list/targets,area/thearea)
|
||||
for(var/mob/living/target in targets)
|
||||
var/list/L = list()
|
||||
for(var/turf/T in get_area_turfs(thearea.type))
|
||||
@@ -65,7 +65,7 @@
|
||||
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/area_teleport/invocation(area/chosenarea = null)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/area_teleport/invocation(area/chosenarea = null)
|
||||
if(!invocation_area || !chosenarea)
|
||||
..()
|
||||
else
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/charge
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/charge
|
||||
name = "Charge"
|
||||
desc = "This spell can be used to charge up spent magical artifacts, among other things."
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
include_user = 1
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/charge/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/charge/cast(list/targets)
|
||||
for(var/mob/living/user in targets)
|
||||
var/list/hand_items = list(user.get_active_hand(),user.get_inactive_hand())
|
||||
var/charged_item = null
|
||||
@@ -23,7 +23,7 @@
|
||||
if(G.affecting)
|
||||
var/mob/M = G.affecting
|
||||
if(M.spell_list.len != 0)
|
||||
for(var/obj/effect/proc_holder/spell/S in M.spell_list)
|
||||
for(var/obj/effect/proc_holder/spell/wizard/S in M.spell_list)
|
||||
S.charge_counter = S.charge_max
|
||||
M <<"<span class='notice'>you feel raw magic flowing through you, it feels good!</span>"
|
||||
else
|
||||
|
||||
@@ -1,26 +0,0 @@
|
||||
/obj/effect/proc_holder/spell/targeted/embiggen
|
||||
name = "Embiggen"
|
||||
desc = "Make sure everyone knows you're there!"
|
||||
charge_max = 600
|
||||
|
||||
clothes_req = 0
|
||||
stat_allowed = 0
|
||||
invocation_type = "none"
|
||||
range = -1
|
||||
selection_type = "range"
|
||||
|
||||
icon_power_button = "genetic_view"
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/remoteview/cast(list/targets)
|
||||
if(!ishuman(usr))
|
||||
return
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
var/matrix/M = matrix()
|
||||
M.Scale(2)
|
||||
target.transform = M
|
||||
|
||||
spawn(300)
|
||||
M = matrix()
|
||||
target.transform = M
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure
|
||||
name = "Conjure"
|
||||
desc = "This spell conjures objs of the specified types in range."
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
//should have format of list("emagged" = 1,"name" = "Wizard's Justicebot"), for example
|
||||
var/delay = 1//Go Go Gadget Inheritance
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/cast(list/targets)
|
||||
|
||||
for(var/turf/T in targets)
|
||||
if(T.density && !summon_ignore_density)
|
||||
@@ -57,7 +57,7 @@
|
||||
|
||||
return
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/summonEdSwarm //test purposes
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/summonEdSwarm //test purposes
|
||||
name = "Dispense Wizard Justice"
|
||||
desc = "This spell dispenses wizard justice."
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
//////////////////////////////Construct Spells/////////////////////////
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/construct/lesser
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/construct/lesser
|
||||
charge_max = 1800
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/floor
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/floor
|
||||
name = "Floor Construction"
|
||||
desc = "This spell constructs a cult floor"
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
summon_type = list(/turf/simulated/floor/engine/cult)
|
||||
centcom_cancast = 0 //Stop crashing the server by spawning turfs on transit tiles
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/wall
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/wall
|
||||
name = "Lesser Construction"
|
||||
desc = "This spell constructs a cult wall"
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
summon_type = list(/turf/simulated/wall/cult)
|
||||
centcom_cancast = 0 //Stop crashing the server by spawning turfs on transit tiles
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/wall/reinforced
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/wall/reinforced
|
||||
name = "Greater Construction"
|
||||
desc = "This spell constructs a reinforced metal wall"
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
|
||||
summon_type = list(/turf/simulated/wall/r_wall)
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/soulstone
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/soulstone
|
||||
name = "Summon Soulstone"
|
||||
desc = "This spell reaches into Nar-Sie's realm, summoning one of the legendary fragments across time and space"
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
summon_type = list(/obj/item/device/soulstone)
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/lesserforcewall
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/lesserforcewall
|
||||
name = "Shield"
|
||||
desc = "This spell creates a temporary forcefield to shield yourself and allies from incoming fire"
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
summon_lifespan = 200
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/ethereal_jaunt/shift
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/ethereal_jaunt/shift
|
||||
name = "Phase Shift"
|
||||
desc = "This spell allows you to pass through walls"
|
||||
|
||||
@@ -88,7 +88,7 @@
|
||||
centcom_cancast = 0 //Stop people from getting to centcom
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/projectile/magic_missile/lesser
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/projectile/magic_missile/lesser
|
||||
name = "Lesser Magic Missile"
|
||||
desc = "This spell fires several, slow moving, magic projectiles at nearby targets."
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/dumbfire
|
||||
/obj/effect/proc_holder/spell/wizard/dumbfire
|
||||
|
||||
var/projectile_type = ""
|
||||
var/activate_on_collision = 1
|
||||
@@ -20,7 +20,7 @@
|
||||
var/proj_lifespan = 100 //in deciseconds * proj_step_delay
|
||||
var/proj_step_delay = 1 //lower = faster
|
||||
|
||||
/obj/effect/proc_holder/spell/dumbfire/choose_targets(mob/user = usr)
|
||||
/obj/effect/proc_holder/spell/wizard/dumbfire/choose_targets(mob/user = usr)
|
||||
|
||||
var/turf/T = get_turf(usr)
|
||||
for(var/i = 1; i < range; i++)
|
||||
@@ -30,16 +30,16 @@
|
||||
T = new_turf
|
||||
perform(list(T))
|
||||
|
||||
/obj/effect/proc_holder/spell/dumbfire/cast(list/targets, mob/user = usr)
|
||||
/obj/effect/proc_holder/spell/wizard/dumbfire/cast(list/targets, mob/user = usr)
|
||||
|
||||
for(var/turf/target in targets)
|
||||
spawn(0)
|
||||
var/obj/effect/proc_holder/spell/targeted/projectile
|
||||
var/obj/effect/proc_holder/spell/wizard/targeted/projectile
|
||||
if(istext(proj_type))
|
||||
var/projectile_type = text2path(proj_type)
|
||||
projectile = new projectile_type(user)
|
||||
if(istype(proj_type,/obj/effect/proc_holder/spell))
|
||||
projectile = new /obj/effect/proc_holder/spell/targeted/trigger(user)
|
||||
projectile = new /obj/effect/proc_holder/spell/wizard/targeted/trigger(user)
|
||||
projectile:linked_spells += proj_type
|
||||
projectile.icon = proj_icon
|
||||
projectile.icon_state = proj_icon_state
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
/obj/effect/proc_holder/spell/targeted/emplosion
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/emplosion
|
||||
name = "Emplosion"
|
||||
desc = "This spell emplodes an area."
|
||||
|
||||
var/emp_heavy = 2
|
||||
var/emp_light = 3
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/emplosion/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/emplosion/cast(list/targets)
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
empulse(target.loc, emp_heavy, emp_light)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/ethereal_jaunt
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/ethereal_jaunt
|
||||
name = "Ethereal Jaunt"
|
||||
desc = "This spell creates your ethereal form, temporarily making you invisible and able to pass through walls."
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
icon_power_button = "spell_jaunt"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/ethereal_jaunt/cast(list/targets) //magnets, so mostly hardcoded
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/ethereal_jaunt/cast(list/targets) //magnets, so mostly hardcoded
|
||||
for(var/mob/living/target in targets)
|
||||
spawn(0)
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/explosion
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/explosion
|
||||
name = "Explosion"
|
||||
desc = "This spell explodes an area."
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
var/ex_heavy = 2
|
||||
var/ex_light = 3
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/explosion/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/explosion/cast(list/targets)
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
explosion(target.loc,ex_severe,ex_heavy,ex_light)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/genetic
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/genetic
|
||||
name = "Genetic"
|
||||
desc = "This spell inflicts a set of mutations and disabilities upon the target."
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
6th bit - ?
|
||||
*/
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/genetic/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/genetic/cast(list/targets)
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
for(var/x in mutations)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/horsemask
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/horsemask
|
||||
name = "Curse of the Horseman"
|
||||
desc = "This spell triggers a curse on a target, causing them to wield an unremovable horse head mask. They will speak like a horse! Any masks they are wearing will be disintegrated. This spell does not require robes."
|
||||
school = "transmutation"
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
icon_power_button = "spell_horse"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/horsemask/cast(list/targets, mob/user = usr)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/horsemask/cast(list/targets, mob/user = usr)
|
||||
if(!targets.len)
|
||||
user << "<span class='notice'>No target found in range.</span>"
|
||||
return
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler
|
||||
name = "Inflict Handler"
|
||||
desc = "This spell blinds and/or destroys/damages/heals and/or weakens/stuns the target."
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
var/summon_type = null //this will put an obj at the target's location
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/cast(list/targets)
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
switch(destroys)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/aoe_turf/knock
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/knock
|
||||
name = "Knock"
|
||||
desc = "This spell opens nearby doors and does not require wizard garb."
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
|
||||
icon_power_button = "spell_knock"
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/knock/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/knock/cast(list/targets)
|
||||
for(var/turf/T in targets)
|
||||
for(var/obj/machinery/door/door in T.contents)
|
||||
spawn(1)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/mind_transfer
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/mind_transfer
|
||||
name = "Mind Transfer"
|
||||
desc = "This spell allows the user to switch bodies with a target."
|
||||
|
||||
@@ -25,7 +25,7 @@ Urist: I don't feel like figuring out how you store object spells so I'm leaving
|
||||
Make sure spells that are removed from spell_list are actually removed and deleted when mind transfering.
|
||||
Also, you never added distance checking after target is selected. I've went ahead and did that.
|
||||
*/
|
||||
/obj/effect/proc_holder/spell/targeted/mind_transfer/cast(list/targets,mob/user = usr)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/mind_transfer/cast(list/targets,mob/user = usr)
|
||||
if(!targets.len)
|
||||
user << "No mind found."
|
||||
return
|
||||
@@ -61,7 +61,7 @@ Also, you never added distance checking after target is selected. I've went ahea
|
||||
|
||||
//SPELL LOSS BEGIN
|
||||
//NOTE: The caster must ALWAYS keep mind transfer, even when other spells are lost.
|
||||
var/obj/effect/proc_holder/spell/targeted/mind_transfer/m_transfer = locate() in user.spell_list//Find mind transfer directly.
|
||||
var/obj/effect/proc_holder/spell/wizard/targeted/mind_transfer/m_transfer = locate() in user.spell_list//Find mind transfer directly.
|
||||
var/list/checked_spells = user.spell_list
|
||||
checked_spells -= m_transfer //Remove Mind Transfer from the list.
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/projectile
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/projectile
|
||||
name = "Projectile"
|
||||
desc = "This spell summons projectiles which try to hit the targets."
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
var/proj_trail_icon = 'icons/obj/wizard.dmi'
|
||||
var/proj_trail_icon_state = "trail"
|
||||
|
||||
var/proj_type = "/obj/effect/proc_holder/spell/targeted" //IMPORTANT use only subtypes of this
|
||||
var/proj_type = "/obj/effect/proc_holder/spell/wizard/targeted" //IMPORTANT use only subtypes of this
|
||||
|
||||
var/proj_lingering = 0 //if it lingers or disappears upon hitting an obstacle
|
||||
var/proj_homing = 1 //if it follows the target
|
||||
@@ -21,16 +21,16 @@
|
||||
var/proj_lifespan = 15 //in deciseconds * proj_step_delay
|
||||
var/proj_step_delay = 1 //lower = faster
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/projectile/cast(list/targets, mob/user = usr)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/projectile/cast(list/targets, mob/user = usr)
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
spawn(0)
|
||||
var/obj/effect/proc_holder/spell/targeted/projectile
|
||||
var/obj/effect/proc_holder/spell/wizard/targeted/projectile
|
||||
if(istext(proj_type))
|
||||
var/projectile_type = text2path(proj_type)
|
||||
projectile = new projectile_type(user)
|
||||
if(istype(proj_type,/obj/effect/proc_holder/spell))
|
||||
projectile = new /obj/effect/proc_holder/spell/targeted/trigger(user)
|
||||
projectile = new /obj/effect/proc_holder/spell/wizard/targeted/trigger(user)
|
||||
projectile:linked_spells += proj_type
|
||||
projectile.icon = proj_icon
|
||||
projectile.icon_state = proj_icon_state
|
||||
|
||||
@@ -1,28 +1,28 @@
|
||||
/obj/effect/proc_holder/spell/targeted/trigger
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/trigger
|
||||
name = "Trigger"
|
||||
desc = "This spell triggers another spell or a few."
|
||||
|
||||
var/list/linked_spells = list() //those are just referenced by the trigger spell and are unaffected by it directly
|
||||
var/list/starting_spells = list() //those are added on New() to contents from default spells and are deleted when the trigger spell is deleted to prevent memory leaks
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/trigger/New()
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/trigger/New()
|
||||
..()
|
||||
|
||||
for(var/spell in starting_spells)
|
||||
var/spell_to_add = text2path(spell)
|
||||
new spell_to_add(src) //should result in adding to contents, needs testing
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/trigger/Destroy()
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/trigger/Destroy()
|
||||
for(var/spell in contents)
|
||||
del(spell)
|
||||
|
||||
..()
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/trigger/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/trigger/cast(list/targets)
|
||||
for(var/mob/living/target in targets)
|
||||
for(var/obj/effect/proc_holder/spell/spell in contents)
|
||||
for(var/obj/effect/proc_holder/spell/wizard/spell in contents)
|
||||
spell.perform(list(target),0)
|
||||
for(var/obj/effect/proc_holder/spell/spell in linked_spells)
|
||||
for(var/obj/effect/proc_holder/spell/wizard/spell in linked_spells)
|
||||
spell.perform(list(target),0)
|
||||
|
||||
return
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/turf_teleport
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/turf_teleport
|
||||
name = "Turf Teleport"
|
||||
desc = "This spell teleports the target to the turf in range."
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
var/include_space = 0 //whether it includes space tiles in possible teleport locations
|
||||
var/include_dense = 0 //whether it includes dense tiles in possible teleport locations
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/turf_teleport/cast(list/targets)
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/turf_teleport/cast(list/targets)
|
||||
for(var/mob/living/target in targets)
|
||||
var/list/turfs = new/list()
|
||||
for(var/turf/T in range(target,outer_tele_radius))
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/effect/proc_holder/spell/targeted/projectile/magic_missile
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/projectile/magic_missile
|
||||
name = "Magic Missile"
|
||||
desc = "This spell fires several, slow moving, magic projectiles at nearby targets."
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
proj_icon_state = "magicm"
|
||||
proj_name = "a magic missile"
|
||||
proj_lingering = 1
|
||||
proj_type = "/obj/effect/proc_holder/spell/targeted/inflict_handler/magic_missile"
|
||||
proj_type = "/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/magic_missile"
|
||||
|
||||
proj_lifespan = 20
|
||||
proj_step_delay = 5
|
||||
@@ -26,15 +26,15 @@
|
||||
|
||||
icon_power_button = "spell_missile"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/magic_missile
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/magic_missile
|
||||
amt_weakened = 5
|
||||
amt_dam_fire = 10
|
||||
|
||||
/obj/effect/proc_holder/spell/noclothes
|
||||
/obj/effect/proc_holder/spell/wizard/noclothes
|
||||
name = "No Clothes"
|
||||
desc = "This is a placeholder for knowing if you dont need clothes for any spell"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/genetic/mutate
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/genetic/mutate
|
||||
name = "Mutate"
|
||||
desc = "This spell causes you to turn into a hulk and gain laser vision for a short while."
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
duration = 300
|
||||
cooldown_min = 300 //25 deciseconds reduction per rank
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/disintegrate
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/disintegrate
|
||||
name = "Disintegrate"
|
||||
desc = "This spell instantly kills somebody adjacent to you with the vilest of magick."
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
|
||||
icon_power_button = "spell_disintegrate"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/smoke
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/smoke
|
||||
name = "Smoke"
|
||||
desc = "This spell spawns a cloud of choking smoke at your location and does not require wizard garb."
|
||||
|
||||
@@ -88,7 +88,7 @@
|
||||
|
||||
icon_power_button = "spell_smoke"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/emplosion/disable_tech
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/emplosion/disable_tech
|
||||
name = "Disable Tech"
|
||||
desc = "This spell disables all weapons, cameras and most other technology in range."
|
||||
charge_max = 400
|
||||
@@ -104,7 +104,7 @@
|
||||
|
||||
icon_power_button = "spell_tech"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/turf_teleport/blink
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/turf_teleport/blink
|
||||
name = "Blink"
|
||||
desc = "This spell randomly teleports you a short distance."
|
||||
|
||||
@@ -128,7 +128,7 @@
|
||||
|
||||
icon_power_button = "spell_blink"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/area_teleport/teleport
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/area_teleport/teleport
|
||||
name = "Teleport"
|
||||
desc = "This spell teleports you to a type of area of your selection."
|
||||
|
||||
@@ -146,7 +146,7 @@
|
||||
|
||||
icon_power_button = "spell_teleport"
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/forcewall
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/forcewall
|
||||
name = "Forcewall"
|
||||
desc = "This spell creates an unbreakable wall that lasts for 30 seconds and does not need wizard garb."
|
||||
|
||||
@@ -163,7 +163,7 @@
|
||||
|
||||
icon_power_button = "spell_forcewall"
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/carp
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/carp
|
||||
name = "Summon Carp"
|
||||
desc = "This spell conjures a simple carp."
|
||||
|
||||
@@ -177,7 +177,7 @@
|
||||
summon_type = list(/mob/living/simple_animal/hostile/carp)
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/construct
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/construct
|
||||
name = "Artificer"
|
||||
desc = "This spell conjures a construct which may be controlled by Shades"
|
||||
|
||||
@@ -191,7 +191,7 @@
|
||||
summon_type = list(/obj/structure/constructshell)
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/creature
|
||||
/obj/effect/proc_holder/spell/wizard/aoe_turf/conjure/creature
|
||||
name = "Summon Creature Swarm"
|
||||
desc = "This spell tears the fabric of reality, allowing horrific daemons to spill forth"
|
||||
|
||||
@@ -205,7 +205,7 @@
|
||||
|
||||
summon_type = list(/mob/living/simple_animal/hostile/creature)
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/trigger/blind
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/trigger/blind
|
||||
name = "Blind"
|
||||
desc = "This spell temporarily blinds a single person and does not require wizard garb."
|
||||
|
||||
@@ -217,19 +217,19 @@
|
||||
message = "\blue Your eyes cry out in pain!"
|
||||
cooldown_min = 50 //12 deciseconds reduction per rank
|
||||
|
||||
starting_spells = list("/obj/effect/proc_holder/spell/targeted/inflict_handler/blind","/obj/effect/proc_holder/spell/targeted/genetic/blind")
|
||||
starting_spells = list("/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/blind","/obj/effect/proc_holder/spell/wizard/targeted/genetic/blind")
|
||||
|
||||
icon_power_button = "spell_blind"
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/blind
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/blind
|
||||
amt_eye_blind = 10
|
||||
amt_eye_blurry = 20
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/genetic/blind
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/genetic/blind
|
||||
disabilities = 1
|
||||
duration = 300
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/flesh_to_stone
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/flesh_to_stone
|
||||
name = "Flesh to Stone"
|
||||
desc = "This spell turns a single person into an inert statue for a long period of time."
|
||||
|
||||
@@ -246,7 +246,7 @@
|
||||
|
||||
icon_power_button = "spell_stone"
|
||||
|
||||
/obj/effect/proc_holder/spell/dumbfire/fireball
|
||||
/obj/effect/proc_holder/spell/wizard/dumbfire/fireball
|
||||
name = "Fireball"
|
||||
desc = "This spell fires a fireball at a target and does not require wizard garb."
|
||||
|
||||
@@ -260,22 +260,22 @@
|
||||
|
||||
proj_icon_state = "fireball"
|
||||
proj_name = "a fireball"
|
||||
proj_type = "/obj/effect/proc_holder/spell/turf/fireball"
|
||||
proj_type = "/obj/effect/proc_holder/spell/wizard/turf/fireball"
|
||||
|
||||
proj_lifespan = 200
|
||||
proj_step_delay = 1
|
||||
|
||||
icon_power_button = "spell_fireball"
|
||||
|
||||
/obj/effect/proc_holder/spell/turf/fireball/cast(var/turf/T)
|
||||
/obj/effect/proc_holder/spell/wizard/turf/fireball/cast(var/turf/T)
|
||||
explosion(T, -1, 0, 2, 0)
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/fireball
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/inflict_handler/fireball
|
||||
amt_dam_brute = 20
|
||||
amt_dam_fire = 25
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/explosion/fireball
|
||||
/obj/effect/proc_holder/spell/wizard/targeted/explosion/fireball
|
||||
ex_severe = -1
|
||||
ex_heavy = 0
|
||||
ex_light = 2
|
||||
|
||||
Reference in New Issue
Block a user