mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-26 21:48:21 +01:00
Magic Overhaul
This commit is contained in:
+34
-32
@@ -26,6 +26,9 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
var/range = 7 //the range of the spell; outer radius for aoe spells
|
||||
var/message = "" //whatever it says to the guy affected by it
|
||||
var/selection_type = "view" //can be "range" or "view"
|
||||
var/spell_level = 0 //if a spell can be taken multiple times, this raises
|
||||
var/level_max = 4 //The max possible level_max is 4
|
||||
var/cooldown_min = 0 //This defines what spell quickened four timeshas as a cooldown. Make sure to set this for every spell
|
||||
|
||||
var/overlay = 0
|
||||
var/overlay_icon = 'icons/obj/wizard.dmi'
|
||||
@@ -38,49 +41,53 @@ var/list/spells = typesof(/obj/effect/proc_holder/spell) //needed for the badmin
|
||||
var/smoke_amt = 0 //cropped at 10
|
||||
|
||||
var/critfailchance = 0
|
||||
var/centcomm_cancast = 1 //Whether or not the spell should be allowed on z2
|
||||
var/centcom_cancast = 1 //Whether or not the spell should be allowed on z2
|
||||
|
||||
/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
|
||||
|
||||
if(!(src in usr.spell_list))
|
||||
usr << "\red You shouldn't have this spell! Something's wrong."
|
||||
if(!(src in user.spell_list))
|
||||
user << "<span class='warning'>You shouldn't have this spell! Something's wrong.</span>"
|
||||
return 0
|
||||
|
||||
if(usr.z == 2 && !centcomm_cancast) //Certain spells are not allowed on the centcomm zlevel
|
||||
if(user.z == 2 && !centcom_cancast) //Certain spells are not allowed on the centcom zlevel
|
||||
return 0
|
||||
|
||||
if(!skipcharge)
|
||||
switch(charge_type)
|
||||
if("recharge")
|
||||
if(charge_counter < charge_max)
|
||||
usr << "[name] is still recharging."
|
||||
user << "<span class='notice'>[name] is still recharging.</span>"
|
||||
return 0
|
||||
if("charges")
|
||||
if(!charge_counter)
|
||||
usr << "[name] has no charges left."
|
||||
user << "<span class='notice'>[name] has no charges left.</span>"
|
||||
return 0
|
||||
|
||||
if(usr.stat && !stat_allowed)
|
||||
usr << "Not when you're incapacitated."
|
||||
if(user.stat && !stat_allowed)
|
||||
user << "<span class='notice'>Not when you're incapacitated.</span>"
|
||||
return 0
|
||||
|
||||
if(ishuman(usr) || ismonkey(usr))
|
||||
if(istype(usr.wear_mask, /obj/item/clothing/mask/muzzle))
|
||||
usr << "Mmmf mrrfff!"
|
||||
if(ishuman(user))
|
||||
|
||||
var/mob/living/carbon/human/H = user
|
||||
|
||||
if(istype(H.wear_mask, /obj/item/clothing/mask/muzzle))
|
||||
user << "<span class='notice'>You can't get the words out!</span>"
|
||||
return 0
|
||||
|
||||
if(clothes_req) //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."
|
||||
return 0
|
||||
if(!istype(usr:wear_suit, /obj/item/clothing/suit/wizrobe) && !istype(user:wear_suit, /obj/item/clothing/suit/space/rig/wizard))
|
||||
usr << "I don't feel strong enough without my robe."
|
||||
return 0
|
||||
if(!istype(usr:shoes, /obj/item/clothing/shoes/sandal))
|
||||
usr << "I don't feel strong enough without my sandals."
|
||||
return 0
|
||||
if(!istype(usr:head, /obj/item/clothing/head/wizard) && !istype(user:head, /obj/item/clothing/head/helmet/space/rig/wizard))
|
||||
usr << "I don't feel strong enough without my hat."
|
||||
if(clothes_req) //clothes check
|
||||
if(!istype(H.wear_suit, /obj/item/clothing/suit/wizrobe) && !istype(H.wear_suit, /obj/item/clothing/suit/space/rig/wizard))
|
||||
H << "<span class='notice'>I don't feel strong enough without my robe.</span>"
|
||||
return 0
|
||||
if(!istype(H.shoes, /obj/item/clothing/shoes/sandal))
|
||||
H << "<span class='notice'>I don't feel strong enough without my sandals.</span>"
|
||||
return 0
|
||||
if(!istype(H.head, /obj/item/clothing/head/wizard) && !istype(H.head, /obj/item/clothing/head/helmet/space/rig/wizard))
|
||||
H << "<span class='notice'>I don't feel strong enough without my hat.</span>"
|
||||
return 0
|
||||
else
|
||||
if(clothes_req)
|
||||
user << "<span class='notice'>This spell can only be casted by humans!</span>"
|
||||
return 0
|
||||
|
||||
if(!skipcharge)
|
||||
@@ -95,22 +102,17 @@ 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
|
||||
|
||||
switch(invocation_type)
|
||||
if("shout")
|
||||
if(prob(50))//Auto-mute? Fuck that noise
|
||||
usr.say(invocation)
|
||||
user.say(invocation)
|
||||
else
|
||||
usr.say(replacetext(invocation," ","`"))
|
||||
if(usr.gender==MALE)
|
||||
playsound(usr.loc, pick('sound/misc/null.ogg','sound/misc/null.ogg'), 100, 1)
|
||||
else
|
||||
playsound(usr.loc, pick('sound/misc/null.ogg','sound/misc/null.ogg'), 100, 1)
|
||||
user.say(replacetext(invocation," ","`"))
|
||||
if("whisper")
|
||||
if(prob(50))
|
||||
usr.whisper(invocation)
|
||||
user.whisper(invocation)
|
||||
else
|
||||
usr.whisper(replacetext(invocation," ","`"))
|
||||
user.whisper(replacetext(invocation," ","`"))
|
||||
|
||||
/obj/effect/proc_holder/spell/New()
|
||||
..()
|
||||
|
||||
@@ -0,0 +1,82 @@
|
||||
/obj/effect/proc_holder/spell/targeted/charge
|
||||
name = "Charge"
|
||||
desc = "This spell can be used to charge up spent magical artifacts, among other things."
|
||||
|
||||
school = "transmutation"
|
||||
charge_max = 600
|
||||
clothes_req = 0
|
||||
invocation = "DIRI CEL"
|
||||
invocation_type = "whisper"
|
||||
range = -1
|
||||
// cooldown_min = 400 //50 deciseconds reduction per rank
|
||||
include_user = 1
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/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
|
||||
var/burnt_out = 0
|
||||
for(var/obj/item in hand_items)
|
||||
if(istype(item, /obj/item/weapon/grab))
|
||||
var/obj/item/weapon/grab/G = item
|
||||
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)
|
||||
S.charge_counter = S.charge_max
|
||||
M <<"<span class='notice'>you feel raw magic flowing through you, it feels good!</span>"
|
||||
else
|
||||
M <<"<span class='notice'>you feel very strange for a moment, but then it passes.</span>"
|
||||
burnt_out = 1
|
||||
charged_item = M
|
||||
break
|
||||
else if(istype(item, /obj/item/weapon/spellbook/oneuse))
|
||||
var/obj/item/weapon/spellbook/oneuse/I = item
|
||||
if(prob(80))
|
||||
user.visible_message("<span class='warning'>[I] catches fire!</span>")
|
||||
del(I)
|
||||
else
|
||||
I.used = 0
|
||||
charged_item = I
|
||||
break
|
||||
else if(istype(item, /obj/item/weapon/gun/magic))
|
||||
var/obj/item/weapon/gun/magic/I = item
|
||||
if(prob(80))
|
||||
I.max_charges--
|
||||
if(I.max_charges <= 0)
|
||||
I.max_charges = 0
|
||||
burnt_out = 1
|
||||
I.charges = I.max_charges
|
||||
charged_item = I
|
||||
break
|
||||
else if(istype(item, /obj/item/weapon/cell/))
|
||||
var/obj/item/weapon/cell/C = item
|
||||
if(prob(80))
|
||||
C.maxcharge -= 200
|
||||
if(C.maxcharge <= 1) //Div by 0 protection
|
||||
C.maxcharge = 1
|
||||
burnt_out = 1
|
||||
C.charge = C.maxcharge
|
||||
charged_item = C
|
||||
break
|
||||
else if(item.contents)
|
||||
var/obj/I = null
|
||||
for(I in item.contents)
|
||||
if(istype(I, /obj/item/weapon/cell/))
|
||||
var/obj/item/weapon/cell/C = I
|
||||
if(prob(80))
|
||||
C.maxcharge -= 200
|
||||
if(C.maxcharge <= 1) //Div by 0 protection
|
||||
C.maxcharge = 1
|
||||
burnt_out = 1
|
||||
C.charge = C.maxcharge
|
||||
item.update_icon()
|
||||
charged_item = item
|
||||
break
|
||||
if(!charged_item)
|
||||
user << "<span class='notice'>you feel magical power surging to your hands, but the feeling rapidly fades...</span>"
|
||||
else if(burnt_out)
|
||||
user << "<span class='caution'>[charged_item] doesn't seem to be reacting to the spell...</span>"
|
||||
else
|
||||
user << "<span class='notice'>[charged_item] suddenly feels very warm!</span>"
|
||||
@@ -30,8 +30,11 @@
|
||||
if(summon_ignore_prev_spawn_points)
|
||||
targets -= spawn_place
|
||||
if(ispath(summoned_object_type,/turf))
|
||||
if(istype(get_turf(usr),/turf/simulated/shuttle))
|
||||
usr << "\red You can't build things on shuttles!"
|
||||
break
|
||||
var/turf/O = spawn_place
|
||||
var/turf/N = summoned_object_type
|
||||
var/N = summoned_object_type
|
||||
O.ChangeTurf(N)
|
||||
else
|
||||
var/atom/summoned_object = new summoned_object_type(spawn_place)
|
||||
@@ -61,27 +64,4 @@
|
||||
summon_type = list(/obj/machinery/bot/ed209)
|
||||
summon_amt = 10
|
||||
range = 3
|
||||
newVars = list("emagged" = 1,"name" = "Wizard's Justicebot")
|
||||
|
||||
|
||||
//This was previously left in the old wizard code, not being included.
|
||||
//Wasn't sure if I should transfer it here, or to code/datums/spells.dm
|
||||
//But I decided because it is a conjuration related object it would fit better here
|
||||
//Feel free to change this, I don't know.
|
||||
/obj/effect/forcefield
|
||||
desc = "A space wizard's magic wall."
|
||||
name = "FORCEWALL"
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
icon_state = "m_shield"
|
||||
anchored = 1.0
|
||||
opacity = 0
|
||||
density = 1
|
||||
unacidable = 1
|
||||
|
||||
|
||||
bullet_act(var/obj/item/projectile/Proj, var/def_zone)
|
||||
var/turf/T = get_turf(src.loc)
|
||||
if(T)
|
||||
for(var/mob/M in T)
|
||||
Proj.on_hit(M,M.bullet_act(Proj, def_zone))
|
||||
return
|
||||
newVars = list("emagged" = 1,"name" = "Wizard's Justicebot")
|
||||
@@ -0,0 +1,101 @@
|
||||
//////////////////////////////Construct Spells/////////////////////////
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/construct/lesser
|
||||
charge_max = 1800
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/floor
|
||||
name = "Floor Construction"
|
||||
desc = "This spell constructs a cult floor"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 20
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
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
|
||||
name = "Lesser Construction"
|
||||
desc = "This spell constructs a cult wall"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 100
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
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
|
||||
name = "Greater Construction"
|
||||
desc = "This spell constructs a reinforced metal wall"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 300
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
centcom_cancast = 0 //Stop crashing the server by spawning turfs on transit tiles
|
||||
delay = 50
|
||||
|
||||
summon_type = list(/turf/simulated/wall/r_wall)
|
||||
|
||||
/obj/effect/proc_holder/spell/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"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 3000
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
|
||||
summon_type = list(/obj/item/device/soulstone)
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/lesserforcewall
|
||||
name = "Shield"
|
||||
desc = "This spell creates a temporary forcefield to shield yourself and allies from incoming fire"
|
||||
|
||||
school = "transmutation"
|
||||
charge_max = 300
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
summon_type = list(/obj/effect/forcefield)
|
||||
summon_lifespan = 200
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/ethereal_jaunt/shift
|
||||
name = "Phase Shift"
|
||||
desc = "This spell allows you to pass through walls"
|
||||
|
||||
school = "transmutation"
|
||||
charge_max = 200
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = -1
|
||||
include_user = 1
|
||||
phaseshift = 1
|
||||
jaunt_duration = 50 //in deciseconds
|
||||
centcom_cancast = 0 //Stop people from getting to centcom
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/projectile/magic_missile/lesser
|
||||
name = "Lesser Magic Missile"
|
||||
desc = "This spell fires several, slow moving, magic projectiles at nearby targets."
|
||||
|
||||
school = "evocation"
|
||||
charge_max = 400
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
proj_lifespan = 10
|
||||
max_targets = 6
|
||||
@@ -64,7 +64,7 @@
|
||||
break
|
||||
|
||||
var/mob/living/L = locate(/mob/living) in range(projectile, proj_trigger_range) - usr
|
||||
if(L)
|
||||
if(L && L.stat != DEAD)
|
||||
projectile.cast(L.loc)
|
||||
break
|
||||
|
||||
|
||||
@@ -8,8 +8,9 @@
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = -1
|
||||
cooldown_min = 100 //50 deciseconds reduction per rank
|
||||
include_user = 1
|
||||
centcomm_cancast = 0 //Prevent people from getting to centcomm
|
||||
centcom_cancast = 0 //Prevent people from getting to centcom
|
||||
|
||||
var phaseshift = 0
|
||||
var/jaunt_duration = 50 //in deciseconds
|
||||
@@ -27,6 +28,9 @@
|
||||
animation.icon_state = "liquify"
|
||||
animation.layer = 5
|
||||
animation.master = holder
|
||||
target.ExtinguishMob()
|
||||
if(target.buckled)
|
||||
target.buckled.unbuckle()
|
||||
if(phaseshift == 1)
|
||||
animation.dir = target.dir
|
||||
flick("phase_shift",animation)
|
||||
|
||||
@@ -18,13 +18,11 @@
|
||||
/obj/effect/proc_holder/spell/targeted/genetic/cast(list/targets)
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
for(var/x in mutations)
|
||||
target.mutations.Add(x)
|
||||
target.mutations.Add(mutations)
|
||||
target.disabilities |= disabilities
|
||||
target.update_mutations() //update target's mutation overlays
|
||||
spawn(duration)
|
||||
for(var/x in mutations)
|
||||
target.mutations.Remove(x)
|
||||
target.mutations.Remove(mutations)
|
||||
target.disabilities &= ~disabilities
|
||||
target.update_mutations()
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
invocation = "KN'A FTAGHU, PUCK 'BTHNK!"
|
||||
invocation_type = "shout"
|
||||
range = 7
|
||||
cooldown_min = 30 //30 deciseconds reduction per rank
|
||||
selection_type = "range"
|
||||
var/list/compatible_mobs = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
|
||||
|
||||
@@ -34,6 +35,7 @@
|
||||
magichead.voicechange = 1 //NEEEEIIGHH
|
||||
target.visible_message( "<span class='danger'>[target]'s face lights up in fire, and after the event a horse's head takes its place!</span>", \
|
||||
"<span class='danger'>Your face burns up, and shortly after the fire you realise you have the face of a horse!</span>")
|
||||
target.equip_to_slot(magichead, slot_wear_mask)
|
||||
target.drop_from_inventory(target.wear_mask)
|
||||
target.equip_to_slot_if_possible(magichead, slot_wear_mask, 1, 1)
|
||||
|
||||
flick("e_flash", target.flash)
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
|
||||
var/destroys = "none" //can be "none", "gib" or "disintegrate"
|
||||
|
||||
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)
|
||||
|
||||
for(var/mob/living/target in targets)
|
||||
@@ -56,4 +58,7 @@
|
||||
target.Stun(amt_stunned)
|
||||
|
||||
target.eye_blind += amt_eye_blind
|
||||
target.eye_blurry += amt_eye_blurry
|
||||
target.eye_blurry += amt_eye_blurry
|
||||
//summoning
|
||||
if(summon_type)
|
||||
new summon_type(target.loc, target)
|
||||
@@ -8,6 +8,7 @@
|
||||
invocation = "AULIE OXIN FIERA"
|
||||
invocation_type = "whisper"
|
||||
range = 3
|
||||
cooldown_min = 20 //20 deciseconds reduction per rank
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/knock/cast(list/targets)
|
||||
for(var/turf/T in targets)
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
invocation = "GIN'YU CAPAN"
|
||||
invocation_type = "whisper"
|
||||
range = 1
|
||||
cooldown_min = 200 //100 deciseconds reduction per rank
|
||||
var/list/protected_roles = list("Wizard","Changeling","Cultist") //which roles are immune to the spell
|
||||
var/list/compatible_mobs = list(/mob/living/carbon/human,/mob/living/carbon/monkey) //which types of mobs are affected by the spell. NOTE: change at your own risk
|
||||
var/base_spell_loss_chance = 20 //base probability of the wizard losing a spell in the process
|
||||
|
||||
@@ -57,6 +57,9 @@
|
||||
else
|
||||
step(projectile,dir)
|
||||
|
||||
if(!projectile) // step and step_to sleeps so we'll have to check again.
|
||||
break
|
||||
|
||||
if(!proj_lingering && projectile.loc == current_loc) //if it didn't move since last time
|
||||
del(projectile)
|
||||
break
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
invocation = "FORTI GY AMA"
|
||||
invocation_type = "shout"
|
||||
range = 7
|
||||
cooldown_min = 90 //15 deciseconds reduction per rank
|
||||
|
||||
max_targets = 0
|
||||
|
||||
@@ -42,6 +43,7 @@
|
||||
|
||||
mutations = list(LASER, HULK)
|
||||
duration = 300
|
||||
cooldown_min = 300 //25 deciseconds reduction per rank
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/disintegrate
|
||||
name = "Disintegrate"
|
||||
@@ -53,6 +55,7 @@
|
||||
invocation = "EI NATH"
|
||||
invocation_type = "shout"
|
||||
range = 1
|
||||
cooldown_min = 200 //100 deciseconds reduction per rank
|
||||
|
||||
destroys = "gib_brain"
|
||||
|
||||
@@ -70,6 +73,7 @@
|
||||
invocation_type = "none"
|
||||
range = -1
|
||||
include_user = 1
|
||||
cooldown_min = 20 //25 deciseconds reduction per rank
|
||||
|
||||
smoke_spread = 2
|
||||
smoke_amt = 10
|
||||
@@ -83,6 +87,7 @@
|
||||
invocation_type = "shout"
|
||||
range = -1
|
||||
include_user = 1
|
||||
cooldown_min = 200 //50 deciseconds reduction per rank
|
||||
|
||||
emp_heavy = 6
|
||||
emp_light = 10
|
||||
@@ -98,6 +103,8 @@
|
||||
invocation_type = "none"
|
||||
range = -1
|
||||
include_user = 1
|
||||
cooldown_min = 5 //4 deciseconds reduction per rank
|
||||
|
||||
|
||||
smoke_spread = 1
|
||||
smoke_amt = 10
|
||||
@@ -105,7 +112,7 @@
|
||||
inner_tele_radius = 0
|
||||
outer_tele_radius = 6
|
||||
|
||||
centcomm_cancast = 0 //prevent people from getting to centcomm
|
||||
centcom_cancast = 0 //prevent people from getting to centcom
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/area_teleport/teleport
|
||||
name = "Teleport"
|
||||
@@ -118,6 +125,7 @@
|
||||
invocation_type = "shout"
|
||||
range = -1
|
||||
include_user = 1
|
||||
cooldown_min = 200 //100 deciseconds reduction per rank
|
||||
|
||||
smoke_spread = 1
|
||||
smoke_amt = 5
|
||||
@@ -132,6 +140,7 @@
|
||||
invocation = "TARCOL MINTI ZHERI"
|
||||
invocation_type = "whisper"
|
||||
range = 0
|
||||
cooldown_min = 50 //12 deciseconds reduction per rank
|
||||
|
||||
summon_type = list("/obj/effect/forcefield")
|
||||
summon_lifespan = 300
|
||||
@@ -189,6 +198,7 @@
|
||||
invocation = "STI KALY"
|
||||
invocation_type = "whisper"
|
||||
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")
|
||||
|
||||
@@ -200,16 +210,32 @@
|
||||
disabilities = 1
|
||||
duration = 300
|
||||
|
||||
/obj/effect/proc_holder/spell/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."
|
||||
|
||||
school = "transmutation"
|
||||
charge_max = 600
|
||||
clothes_req = 1
|
||||
range = 2
|
||||
invocation = "STAUN EI"
|
||||
invocation_type = "shout"
|
||||
amt_stunned = 2//just exists to make sure the statue "catches" them
|
||||
cooldown_min = 200 //100 deciseconds reduction per rank
|
||||
|
||||
summon_type = "/obj/structure/closet/statue"
|
||||
|
||||
/obj/effect/proc_holder/spell/dumbfire/fireball
|
||||
name = "Fireball"
|
||||
desc = "This spell fires a fireball at a target and does not require wizard garb."
|
||||
|
||||
school = "evocation"
|
||||
charge_max = 100
|
||||
charge_max = 60
|
||||
clothes_req = 0
|
||||
invocation = "ONI SOMA"
|
||||
invocation_type = "shout"
|
||||
range = 20
|
||||
cooldown_min = 20 //10 deciseconds reduction per rank
|
||||
|
||||
proj_icon_state = "fireball"
|
||||
proj_name = "a fireball"
|
||||
@@ -219,7 +245,7 @@
|
||||
proj_step_delay = 1
|
||||
|
||||
/obj/effect/proc_holder/spell/turf/fireball/cast(var/turf/T)
|
||||
explosion(T, -1, 1, 2, 3)
|
||||
explosion(T, -1, 0, 2, 3, 0, flame_range = 2)
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/inflict_handler/fireball
|
||||
@@ -230,98 +256,4 @@
|
||||
ex_severe = -1
|
||||
ex_heavy = -1
|
||||
ex_light = 2
|
||||
ex_flash = 5
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//////////////////////////////Construct Spells/////////////////////////
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/construct/lesser
|
||||
charge_max = 1800
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/floor
|
||||
name = "Floor Construction"
|
||||
desc = "This spell constructs a cult floor"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 20
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
summon_type = list(/turf/simulated/floor/engine/cult)
|
||||
centcomm_cancast = 0 //Stop crashing the server by spawning turfs on transit tiles
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/wall
|
||||
name = "Leser Construction"
|
||||
desc = "This spell constructs a cult wall"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 100
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
summon_type = list(/turf/simulated/wall/cult)
|
||||
centcomm_cancast = 0 //Stop crashing the server by spawning turfs on transit tiles
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/wall/reinforced
|
||||
name = "Greater Construction"
|
||||
desc = "This spell constructs a reinforced metal wall"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 300
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
centcomm_cancast = 0 //Stop crashing the server by spawning turfs on transit tiles
|
||||
delay = 50
|
||||
|
||||
summon_type = list(/turf/simulated/wall/r_wall)
|
||||
|
||||
/obj/effect/proc_holder/spell/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"
|
||||
|
||||
school = "conjuration"
|
||||
charge_max = 3000
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
|
||||
summon_type = list(/obj/item/device/soulstone)
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/lesserforcewall
|
||||
name = "Shield"
|
||||
desc = "This spell creates a temporary forcefield to shield yourself and allies from incoming fire"
|
||||
|
||||
school = "transmutation"
|
||||
charge_max = 300
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
summon_type = list(/obj/effect/forcefield)
|
||||
summon_lifespan = 50
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/ethereal_jaunt/shift
|
||||
name = "Phase Shift"
|
||||
desc = "This spell allows you to pass through walls"
|
||||
|
||||
school = "transmutation"
|
||||
charge_max = 200
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = -1
|
||||
include_user = 1
|
||||
phaseshift = 1
|
||||
jaunt_duration = 50 //in deciseconds
|
||||
centcomm_cancast = 0 //Stop people from getting to centcomm
|
||||
ex_flash = 5
|
||||
@@ -0,0 +1,206 @@
|
||||
|
||||
/////////Apprentice Contract//////////
|
||||
|
||||
/obj/item/weapon/contract
|
||||
name = "contract"
|
||||
desc = "A magic contract previously signed by an apprentice. In exchange for instruction in the magical arts, they are bound to answer your call for aid."
|
||||
icon = 'icons/obj/wizard.dmi'
|
||||
icon_state ="scroll2"
|
||||
throw_speed = 1
|
||||
throw_range = 5
|
||||
w_class = 1.0
|
||||
var/used = 0
|
||||
flags = FPRINT | TABLEPASS
|
||||
|
||||
|
||||
/obj/item/weapon/contract/attack_self(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
var/dat
|
||||
if(used)
|
||||
dat = "<B>You have already summoned your apprentice.</B><BR>"
|
||||
else
|
||||
dat = "<B>Contract of Apprenticeship:</B><BR>"
|
||||
dat += "<I>Using this contract, you may summon an apprentice to aid you on your mission.</I><BR>"
|
||||
dat += "<I>If you are unable to establish contact with your apprentice, you can feed the contract back to the spellbook to refund your points.</I><BR>"
|
||||
dat += "<B>Which school of magic is your apprentice studying?:</B><BR>"
|
||||
dat += "<A href='byond://?src=\ref[src];school=destruction'>Destruction</A><BR>"
|
||||
dat += "<I>Your apprentice is skilled in offensive magic. They know Magic Missile and Fireball.</I><BR>"
|
||||
dat += "<A href='byond://?src=\ref[src];school=bluespace'>Bluespace Manipulation</A><BR>"
|
||||
dat += "<I>Your apprentice is able to defy physics, melting through solid objects and travelling great distances in the blink of an eye. They know Teleport and Ethereal Jaunt.</I><BR>"
|
||||
dat += "<A href='byond://?src=\ref[src];school=healing'>Healing</A><BR>"
|
||||
dat += "<I>Your apprentice is training to cast spells that will aid your survival. They know Forcewall and Charge and come with a Staff of Healing.</I><BR>"
|
||||
dat += "<A href='byond://?src=\ref[src];school=robeless'>Robeless</A><BR>"
|
||||
dat += "<I>Your apprentice is training to cast spells without their robes. They know Knock and Mindswap.</I><BR>"
|
||||
user << browse(dat, "window=radio")
|
||||
onclose(user, "radio")
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/contract/Topic(href, href_list)
|
||||
..()
|
||||
var/mob/living/carbon/human/H = usr
|
||||
|
||||
if(H.stat || H.restrained())
|
||||
return
|
||||
if(!istype(H, /mob/living/carbon/human))
|
||||
return 1
|
||||
|
||||
if(loc == H || (in_range(src, H) && istype(loc, /turf)))
|
||||
H.set_machine(src)
|
||||
if(href_list["school"])
|
||||
if (used)
|
||||
H << "You already used this contract!"
|
||||
return
|
||||
var/list/candidates = get_candidates(BE_WIZARD)
|
||||
if(candidates.len)
|
||||
src.used = 1
|
||||
var/client/C = pick(candidates)
|
||||
new /obj/effect/effect/harmless_smoke(H.loc)
|
||||
var/mob/living/carbon/human/M = new/mob/living/carbon/human(H.loc)
|
||||
M.key = C.key
|
||||
M << "<B>You are the [H.real_name]'s apprentice! You are bound by magic contract to follow their orders and help them in accomplishing their goals."
|
||||
switch(href_list["school"])
|
||||
if("destruction")
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/targeted/projectile/magic_missile(M)
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/dumbfire/fireball(M)
|
||||
M << "<B>Your service has not gone unrewarded, however. Studying under [H.real_name], you have learned powerful, destructive spells. You are able to cast magic missile and fireball."
|
||||
if("bluespace")
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/targeted/area_teleport/teleport(M)
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/targeted/ethereal_jaunt(M)
|
||||
M << "<B>Your service has not gone unrewarded, however. Studying under [H.real_name], you have learned reality bending mobility spells. You are able to cast teleport and ethereal jaunt."
|
||||
if("healing")
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/targeted/charge(M)
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/forcewall(M)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/gun/magic/staff/healing(M), slot_r_hand)
|
||||
M << "<B>Your service has not gone unrewarded, however. Studying under [H.real_name], you have learned livesaving survival spells. You are able to cast charge and forcewall."
|
||||
if("robeless")
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/knock(M)
|
||||
M.spell_list += new /obj/effect/proc_holder/spell/targeted/mind_transfer(M)
|
||||
M << "<B>Your service has not gone unrewarded, however. Studying under [H.real_name], you have learned stealthy, robeless spells. You are able to cast knock and mindswap."
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset(M), slot_l_ear)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/lightpurple(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/sandal(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/wizrobe(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/wizard(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack(M), slot_back)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/box(M), slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/teleportation_scroll/apprentice(M), slot_r_store)
|
||||
var/wizard_name_first = pick(wizard_first)
|
||||
var/wizard_name_second = pick(wizard_second)
|
||||
var/randomname = "[wizard_name_first] [wizard_name_second]"
|
||||
var/newname = copytext(sanitize(input(M, "You are the wizard's apprentice. Would you like to change your name to something else?", "Name change", randomname) as null|text),1,MAX_NAME_LEN)
|
||||
|
||||
if (!newname)
|
||||
newname = randomname
|
||||
M.mind.name = newname
|
||||
M.real_name = newname
|
||||
M.name = newname
|
||||
var/datum/objective/protect/new_objective = new /datum/objective/protect
|
||||
new_objective.owner = M:mind
|
||||
new_objective:target = H:mind
|
||||
new_objective.explanation_text = "Protect [H.real_name], the wizard."
|
||||
M.mind.objectives += new_objective
|
||||
ticker.mode.traitors += M.mind
|
||||
M.mind.special_role = "apprentice"
|
||||
|
||||
else
|
||||
H << "Unable to reach your apprentice! You can either attack the spellbook with the contract to refund your points, or wait and try again later."
|
||||
return
|
||||
|
||||
|
||||
///////////////////////////Veil Render//////////////////////
|
||||
|
||||
/obj/item/weapon/veilrender
|
||||
name = "veil render"
|
||||
desc = "A wicked curved blade of alien origin, recovered from the ruins of a vast city."
|
||||
icon = 'icons/obj/wizard.dmi'
|
||||
icon_state = "render"
|
||||
item_state = "render"
|
||||
flags = FPRINT | TABLEPASS
|
||||
force = 15
|
||||
throwforce = 10
|
||||
w_class = 3
|
||||
var/charged = 1
|
||||
|
||||
/obj/effect/rend
|
||||
name = "tear in the fabric of reality"
|
||||
desc = "You should run now"
|
||||
icon = 'icons/obj/biomass.dmi'
|
||||
icon_state = "rift"
|
||||
density = 1
|
||||
unacidable = 1
|
||||
anchored = 1.0
|
||||
|
||||
/obj/effect/rend/New()
|
||||
spawn(50)
|
||||
new /obj/machinery/singularity/narsie/wizard(get_turf(src))
|
||||
del(src)
|
||||
return
|
||||
return
|
||||
|
||||
/obj/item/weapon/veilrender/attack_self(mob/user as mob)
|
||||
if(charged == 1)
|
||||
new /obj/effect/rend(get_turf(usr))
|
||||
charged = 0
|
||||
visible_message("\red <B>[src] hums with power as [usr] deals a blow to reality itself!</B>")
|
||||
else
|
||||
user << "\red The unearthly energies that powered the blade are now dormant."
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/veilrender/vealrender
|
||||
name = "veal render"
|
||||
desc = "A wicked curved blade of alien origin, recovered from the ruins of a vast farm."
|
||||
|
||||
/obj/item/weapon/veilrender/vealrender/attack_self(mob/user as mob)
|
||||
if(charged)
|
||||
new /obj/effect/rend/cow(get_turf(usr))
|
||||
charged = 0
|
||||
visible_message("\red <B>[src] hums with power as [usr] deals a blow to hunger itself!</B>")
|
||||
else
|
||||
user << "\red The unearthly energies that powered the blade are now dormant."
|
||||
|
||||
/obj/effect/rend/cow
|
||||
desc = "Reverberates with the sound of ten thousand moos."
|
||||
var/cowsleft = 20
|
||||
|
||||
/obj/effect/rend/cow/New()
|
||||
processing_objects.Add(src)
|
||||
return
|
||||
|
||||
/obj/effect/rend/cow/process()
|
||||
if(locate(/mob) in loc) return
|
||||
new /mob/living/simple_animal/cow(loc)
|
||||
cowsleft--
|
||||
if(cowsleft <= 0)
|
||||
del src
|
||||
|
||||
/obj/effect/rend/cow/attackby(obj/item/I as obj, mob/user as mob)
|
||||
if(istype(I, /obj/item/weapon/nullrod))
|
||||
visible_message("\red <b>[I] strikes a blow against \the [src], banishing it!</b>")
|
||||
spawn(1)
|
||||
del src
|
||||
return
|
||||
..()
|
||||
|
||||
|
||||
/////////////////////////////////////////Scrying///////////////////
|
||||
|
||||
/obj/item/weapon/scrying
|
||||
name = "scrying orb"
|
||||
desc = "An incandescent orb of otherworldly energy, staring into it gives you vision beyond mortal means."
|
||||
icon = 'icons/obj/projectiles.dmi'
|
||||
icon_state ="bluespace"
|
||||
throw_speed = 7
|
||||
throw_range = 15
|
||||
throwforce = 15
|
||||
damtype = BURN
|
||||
force = 15
|
||||
flags = FPRINT | TABLEPASS
|
||||
hitsound = 'sound/items/welder2.ogg'
|
||||
|
||||
/obj/item/weapon/scrying/attack_self(mob/user as mob)
|
||||
user << "\blue You can see...everything!"
|
||||
visible_message("\red <B>[usr] stares into [src], their eyes glazing over.</B>")
|
||||
user.ghostize(1)
|
||||
return
|
||||
@@ -1,62 +1,113 @@
|
||||
|
||||
|
||||
/mob/proc/rightandwrong()
|
||||
usr << "<B>You summoned guns!</B>"
|
||||
message_admins("[key_name_admin(usr, 1)] summoned guns!")
|
||||
/mob/proc/rightandwrong(var/summon_type) //0 = Summon Guns, 1 = Summon Magic
|
||||
usr << "<B>You summoned [summon_type ? "magic" : "guns"]!</B>"
|
||||
message_admins("[key_name_admin(usr, 1)] summoned [summon_type ? "magic" : "guns"]!")
|
||||
for(var/mob/living/carbon/human/H in player_list)
|
||||
if(H.stat == 2 || !(H.client)) continue
|
||||
if(is_special_character(H)) continue
|
||||
if(H.mind)
|
||||
if(H.mind.special_role == "Wizard" || H.mind.special_role == "apprentice") continue
|
||||
if(prob(25))
|
||||
ticker.mode.traitors += H.mind
|
||||
H.mind.special_role = "traitor"
|
||||
var/datum/objective/survive/survive = new
|
||||
survive.owner = H.mind
|
||||
H.mind.objectives += survive
|
||||
H.attack_log += "\[[time_stamp()]\] <font color='red'>Was made into a survivor, and trusts no one!</font>"
|
||||
H << "<B>You are the survivor! Your own safety matters above all else, trust no one and kill anyone who gets in your way. However, armed as you are, now would be the perfect time to settle that score or grab that pair of yellow gloves you've been eyeing...</B>"
|
||||
var/obj_count = 1
|
||||
for(var/datum/objective/OBJ in H.mind.objectives)
|
||||
H << "<B>Objective #[obj_count]</B>: [OBJ.explanation_text]"
|
||||
obj_count++
|
||||
var/randomize = pick("taser","egun","laser","revolver","detective","smg","nuclear","deagle","gyrojet","pulse","silenced","cannon","doublebarrel","shotgun","combatshotgun","mateba","smg","uzi","crossbow","saw")
|
||||
switch (randomize)
|
||||
if("taser")
|
||||
new /obj/item/weapon/gun/energy/taser(get_turf(H))
|
||||
if("egun")
|
||||
new /obj/item/weapon/gun/energy/gun(get_turf(H))
|
||||
if("laser")
|
||||
new /obj/item/weapon/gun/energy/laser(get_turf(H))
|
||||
if("revolver")
|
||||
new /obj/item/weapon/gun/projectile/revolver(get_turf(H))
|
||||
if("detective")
|
||||
new /obj/item/weapon/gun/projectile/revolver/detective(get_turf(H))
|
||||
if("smg")
|
||||
new /obj/item/weapon/gun/projectile/automatic/c20r(get_turf(H))
|
||||
if("nuclear")
|
||||
new /obj/item/weapon/gun/energy/gun/nuclear(get_turf(H))
|
||||
if("deagle")
|
||||
new /obj/item/weapon/gun/projectile/automatic/deagle/camo(get_turf(H))
|
||||
if("gyrojet")
|
||||
new /obj/item/weapon/gun/projectile/automatic/gyropistol(get_turf(H))
|
||||
if("pulse")
|
||||
new /obj/item/weapon/gun/energy/pulse_rifle(get_turf(H))
|
||||
if("silenced")
|
||||
new /obj/item/weapon/gun/projectile/automatic/pistol(get_turf(H))
|
||||
new /obj/item/weapon/silencer(get_turf(H))
|
||||
if("cannon")
|
||||
new /obj/item/weapon/gun/energy/lasercannon(get_turf(H))
|
||||
if("doublebarrel")
|
||||
new /obj/item/weapon/gun/projectile/revolver/doublebarrel/(get_turf(H))
|
||||
if("shotgun")
|
||||
new /obj/item/weapon/gun/projectile/shotgun/(get_turf(H))
|
||||
if("combatshotgun")
|
||||
new /obj/item/weapon/gun/projectile/shotgun/combat(get_turf(H))
|
||||
if("mateba")
|
||||
new /obj/item/weapon/gun/projectile/revolver/mateba(get_turf(H))
|
||||
if("smg")
|
||||
new /obj/item/weapon/gun/projectile/automatic(get_turf(H))
|
||||
if("uzi")
|
||||
new /obj/item/weapon/gun/projectile/automatic/mini_uzi(get_turf(H))
|
||||
if("crossbow")
|
||||
new /obj/item/weapon/gun/energy/crossbow(get_turf(H))
|
||||
if("saw")
|
||||
new /obj/item/weapon/gun/projectile/automatic/l6_saw(get_turf(H))
|
||||
var/randomizeguns = pick("taser","egun","laser","revolver","detective","smg","nuclear","deagle","gyrojet","pulse","silenced","cannon","doublebarrel","shotgun","combatshotgun","mateba","smg","uzi","crossbow","saw")
|
||||
var/randomizemagic = pick("fireball","smoke","blind","mindswap","forcewall","knock","horsemask","charge","wandnothing", "wanddeath", "wandresurrection", "wandpolymorph", "wandteleport", "wanddoor", "wandfireball", "staffchange", "staffanimation", "staffhealing", "armor", "scrying")
|
||||
if(!summon_type)
|
||||
switch (randomizeguns)
|
||||
if("taser")
|
||||
new /obj/item/weapon/gun/energy/taser(get_turf(H))
|
||||
if("egun")
|
||||
new /obj/item/weapon/gun/energy/gun(get_turf(H))
|
||||
if("laser")
|
||||
new /obj/item/weapon/gun/energy/laser(get_turf(H))
|
||||
if("revolver")
|
||||
new /obj/item/weapon/gun/projectile/revolver(get_turf(H))
|
||||
if("detective")
|
||||
new /obj/item/weapon/gun/projectile/revolver/detective(get_turf(H))
|
||||
if("smg")
|
||||
new /obj/item/weapon/gun/projectile/automatic/c20r(get_turf(H))
|
||||
if("nuclear")
|
||||
new /obj/item/weapon/gun/energy/gun/nuclear(get_turf(H))
|
||||
if("deagle")
|
||||
new /obj/item/weapon/gun/projectile/automatic/deagle/camo(get_turf(H))
|
||||
if("gyrojet")
|
||||
new /obj/item/weapon/gun/projectile/automatic/gyropistol(get_turf(H))
|
||||
if("pulse")
|
||||
new /obj/item/weapon/gun/energy/pulse_rifle(get_turf(H))
|
||||
if("silenced")
|
||||
new /obj/item/weapon/gun/projectile/automatic/pistol(get_turf(H))
|
||||
new /obj/item/weapon/silencer(get_turf(H))
|
||||
if("cannon")
|
||||
new /obj/item/weapon/gun/energy/lasercannon(get_turf(H))
|
||||
if("doublebarrel")
|
||||
new /obj/item/weapon/gun/projectile/revolver/doublebarrel(get_turf(H))
|
||||
if("shotgun")
|
||||
new /obj/item/weapon/gun/projectile/shotgun/(get_turf(H))
|
||||
if("combatshotgun")
|
||||
new /obj/item/weapon/gun/projectile/shotgun/combat(get_turf(H))
|
||||
if("mateba")
|
||||
new /obj/item/weapon/gun/projectile/revolver/mateba(get_turf(H))
|
||||
if("smg")
|
||||
new /obj/item/weapon/gun/projectile/automatic(get_turf(H))
|
||||
if("uzi")
|
||||
new /obj/item/weapon/gun/projectile/automatic/mini_uzi(get_turf(H))
|
||||
if("crossbow")
|
||||
new /obj/item/weapon/gun/energy/crossbow(get_turf(H))
|
||||
if("saw")
|
||||
new /obj/item/weapon/gun/projectile/automatic/l6_saw(get_turf(H))
|
||||
else
|
||||
switch (randomizemagic)
|
||||
if("fireball")
|
||||
new /obj/item/weapon/spellbook/oneuse/fireball(get_turf(H))
|
||||
if("smoke")
|
||||
new /obj/item/weapon/spellbook/oneuse/smoke(get_turf(H))
|
||||
if("blind")
|
||||
new /obj/item/weapon/spellbook/oneuse/blind(get_turf(H))
|
||||
if("mindswap")
|
||||
new /obj/item/weapon/spellbook/oneuse/mindswap(get_turf(H))
|
||||
if("forcewall")
|
||||
new /obj/item/weapon/spellbook/oneuse/forcewall(get_turf(H))
|
||||
if("knock")
|
||||
new /obj/item/weapon/spellbook/oneuse/knock(get_turf(H))
|
||||
if("horsemask")
|
||||
new /obj/item/weapon/spellbook/oneuse/horsemask(get_turf(H))
|
||||
if("charge")
|
||||
new /obj/item/weapon/spellbook/oneuse/charge(get_turf(H))
|
||||
if("wandnothing")
|
||||
new /obj/item/weapon/gun/magic/wand(get_turf(H))
|
||||
if("wanddeath")
|
||||
new /obj/item/weapon/gun/magic/wand/death(get_turf(H))
|
||||
if("wandresurrection")
|
||||
new /obj/item/weapon/gun/magic/wand/resurrection(get_turf(H))
|
||||
if("wandpolymorph")
|
||||
new /obj/item/weapon/gun/magic/wand/polymorph(get_turf(H))
|
||||
if("wandteleport")
|
||||
new /obj/item/weapon/gun/magic/wand/teleport(get_turf(H))
|
||||
if("wanddoor")
|
||||
new /obj/item/weapon/gun/magic/wand/door(get_turf(H))
|
||||
if("staffchange")
|
||||
new /obj/item/weapon/gun/magic/staff/change(get_turf(H))
|
||||
if("staffanimation")
|
||||
new /obj/item/weapon/gun/magic/staff/animate(get_turf(H))
|
||||
if("staffhealing")
|
||||
new /obj/item/weapon/gun/magic/staff/healing(get_turf(H))
|
||||
if("armor")
|
||||
new /obj/item/clothing/suit/space/rig/wizard(get_turf(H))
|
||||
new /obj/item/clothing/head/helmet/space/rig/wizard(get_turf(H))
|
||||
if("scrying")
|
||||
new /obj/item/weapon/scrying(get_turf(H))
|
||||
if (!(XRAY in H.mutations))
|
||||
H.mutations.Add(XRAY)
|
||||
H.sight |= (SEE_MOBS|SEE_OBJS|SEE_TURFS)
|
||||
H.see_in_dark = 8
|
||||
H.see_invisible = SEE_INVISIBLE_LEVEL_TWO
|
||||
H << "\blue The walls suddenly disappear."
|
||||
|
||||
@@ -18,10 +18,11 @@
|
||||
return ..()
|
||||
if(istype(M, /mob/living/carbon/human/dummy))
|
||||
return..()
|
||||
|
||||
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has had their soul captured with [src.name] by [user.name] ([user.ckey])</font>")
|
||||
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to capture the soul of [M.name] ([M.ckey])</font>")
|
||||
msg_admin_attack("[user.name] ([user.ckey]) used the [src.name] to capture the soul of [M.name] ([M.ckey]) (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[user.x];Y=[user.y];Z=[user.z]'>JMP</a>)")
|
||||
|
||||
log_attack("<font color='red'>[user.name] ([user.ckey]) used the [src.name] to capture the soul of [M.name] ([M.ckey])</font>")
|
||||
|
||||
|
||||
transfer_soul("VICTIM", M, user)
|
||||
return
|
||||
@@ -173,9 +174,8 @@
|
||||
ticker.mode.cult+=Z.mind
|
||||
ticker.mode.update_cult_icons_added(Z.mind)
|
||||
del(T)
|
||||
Z << "<B>You are playing a Juggernaut. Though slow, you can withstand extreme punishment, and rip apart enemies and walls alike.</B>"
|
||||
Z << "<B>You are a Juggernaut. Though slow, your shell can withstand extreme punishment, create shield walls and even deflect energy weapons, and rip apart enemies and walls alike.</B>"
|
||||
Z << "<B>You are still bound to serve your creator, follow their orders and help them complete their goals at all costs.</B>"
|
||||
Z.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/lesserforcewall(Z)
|
||||
Z.cancel_camera()
|
||||
del(C)
|
||||
|
||||
@@ -189,9 +189,8 @@
|
||||
ticker.mode.cult+=Z.mind
|
||||
ticker.mode.update_cult_icons_added(Z.mind)
|
||||
del(T)
|
||||
Z << "<B>You are playing a Wraith. Though relatively fragile, you are fast, deadly, and even able to phase through walls.</B>"
|
||||
Z << "<B>You are a Wraith. Though relatively fragile, you are fast, deadly, and even able to phase through walls.</B>"
|
||||
Z << "<B>You are still bound to serve your creator, follow their orders and help them complete their goals at all costs.</B>"
|
||||
Z.spell_list += new /obj/effect/proc_holder/spell/targeted/ethereal_jaunt/shift(Z)
|
||||
Z.cancel_camera()
|
||||
del(C)
|
||||
|
||||
@@ -205,12 +204,8 @@
|
||||
ticker.mode.cult+=Z.mind
|
||||
ticker.mode.update_cult_icons_added(Z.mind)
|
||||
del(T)
|
||||
Z << "<B>You are playing an Artificer. You are incredibly weak and fragile, but you are able to construct fortifications, repair allied constructs (by clicking on them), and even create new constructs</B>"
|
||||
Z << "<B>You are an Artificer. You are incredibly weak and fragile, but you are able to construct fortifications, use magic missile, repair allied constructs (by clicking on them), </B><I>and most important of all create new constructs</I><B> (Use your Artificer spell to summon a new construct shell and Summon Soulstone to create a new soulstone).</B>"
|
||||
Z << "<B>You are still bound to serve your creator, follow their orders and help them complete their goals at all costs.</B>"
|
||||
Z.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/construct/lesser(Z)
|
||||
Z.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/wall(Z)
|
||||
Z.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/floor(Z)
|
||||
Z.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/soulstone(Z)
|
||||
Z.cancel_camera()
|
||||
del(C)
|
||||
else
|
||||
|
||||
@@ -12,6 +12,19 @@
|
||||
var/max_uses = 5
|
||||
var/op = 1
|
||||
|
||||
/obj/item/weapon/spellbook/attackby(obj/item/O as obj, mob/user as mob)
|
||||
if(istype(O, /obj/item/weapon/contract))
|
||||
var/obj/item/weapon/contract/contract = O
|
||||
if(contract.used)
|
||||
user << "The contract has been used, you can't get your points back now."
|
||||
else
|
||||
user << "You feed the contract back into the spellbook, refunding your points."
|
||||
src.max_uses++
|
||||
src.uses++
|
||||
del (O)
|
||||
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/spellbook/attack_self(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
@@ -24,39 +37,89 @@
|
||||
dat += "<HR>"
|
||||
dat += "<B>Memorize which spell:</B><BR>"
|
||||
dat += "<I>The number after the spell name is the cooldown time.</I><BR>"
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=magicmissile'>Magic Missile</A> (10)<BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=magicmissile'>Magic Missile</A> (15)<BR>"
|
||||
dat += "<I>This spell fires several, slow moving, magic projectiles at nearby targets. If they hit a target, it is paralyzed and takes minor damage.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=fireball'>Fireball</A> (10)<BR>"
|
||||
//dat += "<A href='byond://?src=\ref[src];spell_choice=disintegrate'>Disintegrate</A> (60)<BR>"
|
||||
dat += "<I>This spell fires a fireball in the direction you're facing and does not require wizard garb. Be careful not to fire it at people that are standing next to you.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=disintegrate'>Disintegrate</A> (60)<BR>"
|
||||
dat += "<I>This spell instantly kills somebody adjacent to you with the vilest of magick. It has a long cooldown.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=disabletech'>Disable Technology</A> (60)<BR>"
|
||||
dat += "<I>This spell disables all weapons, cameras and most other technology in range.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=smoke'>Smoke</A> (10)<BR>"
|
||||
dat += "<I>This spell spawns a cloud of choking smoke at your location and does not require wizard garb.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=blind'>Blind</A> (30)<BR>"
|
||||
dat += "<I>This spell temporarly blinds a single person and does not require wizard garb.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=mindswap'>Mind Transfer</A> (60)<BR>"
|
||||
dat += "<I>This spell allows the user to switch bodies with a target. Careful to not lose your memory in the process.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=forcewall'>Forcewall</A> (10)<BR>"
|
||||
dat += "<I>This spell creates an unbreakable wall that lasts for 30 seconds and does not need wizard garb.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=blink'>Blink</A> (2)<BR>"
|
||||
dat += "<I>This spell randomly teleports you a short distance. Useful for evasion or getting into areas if you have patience.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=teleport'>Teleport</A> (60)<BR>"
|
||||
dat += "<I>This spell teleports you to a type of area of your selection. Very useful if you are in danger, but has a decent cooldown, and is unpredictable.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=mutate'>Mutate</A> (60)<BR>"
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=etherealjaunt'>Ethereal Jaunt</A> (60)<BR>"
|
||||
dat += "<I>This spell causes you to turn into a hulk and gain telekinesis for a short while.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=etherealjaunt'>Ethereal Jaunt</A> (30)<BR>"
|
||||
dat += "<I>This spell creates your ethereal form, temporarily making you invisible and able to pass through walls.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=knock'>Knock</A> (10)<BR>"
|
||||
dat += "<I>This spell opens nearby doors and does not require wizard garb.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=horseman'>Curse of the Horseman</A> (15)<BR>"
|
||||
// if(op)
|
||||
// dat += "<A href='byond://?src=\ref[src];spell_choice=summonguns'>Summon Guns</A> (One time use, global spell)<BR>"
|
||||
dat += "<I>This spell will curse a person to wear an unremovable horse mask (it has glue on the inside) and speak like a horse. It does not require wizard garb.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=fleshtostone'>Flesh to Stone</A> (60)<BR>"
|
||||
dat += "<I>This spell will curse a person to immediately turn into an unmoving statue. The effect will eventually wear off if the statue is not destroyed.</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=summonguns'>Summon Guns</A> (One time use, global spell)<BR>"
|
||||
dat += "<I>Nothing could possibly go wrong with arming a crew of lunatics just itching for an excuse to kill eachother. Just be careful not to get hit in the crossfire!</I><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=summonmagic'>Summon Magic</A> (One time use, global spell)<BR>"
|
||||
dat += "<I>Share the wonders of magic with the crew and show them why they aren't to be trusted with it at the same time.</I><BR>"
|
||||
|
||||
dat += "<HR>"
|
||||
dat += "<B>Artefacts:</B><BR>"
|
||||
dat += "Powerful items imbued with eldritch magics. Summoning one will count towards your maximum number of spells.<BR>"
|
||||
dat += "It is recommended that only experienced wizards attempt to wield such artefacts.<BR>"
|
||||
dat += "<HR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=staffchange'>Staff of Change</A><BR>"
|
||||
dat += "<I>An artefact that spits bolts of coruscating energy which cause the target's very form to reshape itself.</I><BR>"
|
||||
dat += "<HR>"
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=mentalfocus'>Mental Focus</A><BR>"
|
||||
dat += "<HR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=soulstone'>Six Soul Stone Shards and the spell Artificer</A><BR>"
|
||||
dat += "<I>Soul Stone Shards are ancient tools capable of capturing and harnessing the spirits of the dead and dying. The spell Artificer allows you to create arcane machines for the captured souls to pilot.</I><BR>"
|
||||
dat += "<HR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=armor'>Mastercrafted Armor Set</A><BR>"
|
||||
dat += "<I>An artefact suit of armor that allows you to cast spells while providing more protection against attacks and the void of space.</I><BR>"
|
||||
dat += "<HR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=staffanimation'>Staff of Animation</A><BR>"
|
||||
dat += "<I>An arcane staff capable of shooting bolts of eldritch energy which cause inanimate objects to come to life. This magic doesn't affect machines.</I><BR>"
|
||||
dat += "<HR>"
|
||||
if(op)
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=rememorize'>Re-memorize Spells</A><BR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=contract'>Contract of Apprenticeship</A><BR>"
|
||||
dat += "<I>A magical contract binding an apprentice wizard to your service, using it will summon them to your side.</I><BR>"
|
||||
dat += "<HR>"
|
||||
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=scrying'>Scrying Orb</A><BR>"
|
||||
dat += "<I>An incandescent orb of crackling energy, using it will allow you to ghost while alive, allowing you to spy upon the station with ease. In addition, buying it will permanently grant you x-ray vision.</I><BR>"
|
||||
|
||||
dat += "<HR>"
|
||||
dat += "<A href='byond://?src=\ref[src];spell_choice=rememorize'>Re-memorize Spells</A><BR>"
|
||||
user << browse(dat, "window=radio")
|
||||
onclose(user, "radio")
|
||||
return
|
||||
@@ -70,6 +133,10 @@
|
||||
if(!istype(H, /mob/living/carbon/human))
|
||||
return 1
|
||||
|
||||
if(H.mind.special_role == "apprentice")
|
||||
temp = "If you got caught sneaking a peak from your teacher's spellbook, you'd likely be expelled from the Wizard Academy. Better not."
|
||||
return
|
||||
|
||||
if(loc == H || (in_range(src, H) && istype(loc, /turf)))
|
||||
H.set_machine(src)
|
||||
if(href_list["spell_choice"])
|
||||
@@ -86,14 +153,36 @@
|
||||
uses--
|
||||
/*
|
||||
*/
|
||||
var/list/available_spells = list(magicmissile = "Magic Missile", fireball = "Fireball", disintegrate = "Disintegrate", disabletech = "Disable Tech", smoke = "Smoke", blind = "Blind", mindswap = "Mind Transfer", forcewall = "Forcewall", blink = "Blink", teleport = "Teleport", mutate = "Mutate", etherealjaunt = "Ethereal Jaunt", knock = "Knock", horseman = "Curse of the Horseman", summonguns = "Summon Guns", staffchange = "Staff of Change", mentalfocus = "Mental Focus", soulstone = "Six Soul Stone Shards and the spell Artificer", armor = "Mastercrafted Armor Set", staffanimate = "Staff of Animation")
|
||||
var/list/available_spells = list(magicmissile = "Magic Missile", fireball = "Fireball", disintegrate = "Disintegrate", disabletech = "Disable Tech", smoke = "Smoke", blind = "Blind", mindswap = "Mind Transfer", forcewall = "Forcewall", blink = "Blink", teleport = "Teleport", mutate = "Mutate", etherealjaunt = "Ethereal Jaunt", knock = "Knock", horseman = "Curse of the Horseman", fleshtostone = "Flesh to Stone", summonguns = "Summon Guns", summonmagic = "Summon Magic", staffchange = "Staff of Change", soulstone = "Six Soul Stone Shards and the spell Artificer", armor = "Mastercrafted Armor Set", staffanimate = "Staff of Animation")
|
||||
var/already_knows = 0
|
||||
for(var/obj/effect/proc_holder/spell/aspell in H.spell_list)
|
||||
if(available_spells[href_list["spell_choice"]] == aspell.name)
|
||||
if(available_spells[href_list["spell_choice"]] == initial(aspell.name))
|
||||
already_knows = 1
|
||||
temp = "You already know that spell."
|
||||
uses++
|
||||
break
|
||||
if(aspell.spell_level >= aspell.level_max)
|
||||
temp = "This spell cannot be improved further."
|
||||
uses++
|
||||
break
|
||||
else
|
||||
aspell.name = initial(aspell.name)
|
||||
aspell.spell_level++
|
||||
aspell.charge_max = round(initial(aspell.charge_max) - aspell.spell_level * (initial(aspell.charge_max) - aspell.cooldown_min)/ aspell.level_max)
|
||||
if(aspell.charge_max < aspell.charge_counter)
|
||||
aspell.charge_counter = aspell.charge_max
|
||||
switch(aspell.spell_level)
|
||||
if(1)
|
||||
temp = "You have improved [aspell.name] into Efficient [aspell.name]."
|
||||
aspell.name = "Efficient [aspell.name]"
|
||||
if(2)
|
||||
temp = "You have further improved [aspell.name] into Quickened [aspell.name]."
|
||||
aspell.name = "Quickened [aspell.name]"
|
||||
if(3)
|
||||
temp = "You have further improved [aspell.name] into Free [aspell.name]."
|
||||
aspell.name = "Free [aspell.name]"
|
||||
if(4)
|
||||
temp = "You have further improved [aspell.name] into Instant [aspell.name]."
|
||||
aspell.name = "Instant [aspell.name]"
|
||||
if(aspell.spell_level >= aspell.level_max)
|
||||
temp += " This spell cannot be strengthened any further."
|
||||
/*
|
||||
*/
|
||||
if(!already_knows)
|
||||
@@ -101,79 +190,83 @@
|
||||
if("magicmissile")
|
||||
feedback_add_details("wizard_spell_learned","MM") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/projectile/magic_missile(H)
|
||||
temp = "This spell fires several, slow moving, magic projectiles at nearby targets. If they hit a target, it is paralyzed and takes minor damage."
|
||||
temp = "You have learned magic missile."
|
||||
if("fireball")
|
||||
feedback_add_details("wizard_spell_learned","FB") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/dumbfire/fireball(H)
|
||||
temp = "This spell fires a fireball in the direction you're facing and does not require wizard garb. Be careful not to fire it at people that are standing next to you."
|
||||
temp = "You have learned fireball."
|
||||
if("disintegrate")
|
||||
feedback_add_details("wizard_spell_learned","DG") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/inflict_handler/disintegrate(H)
|
||||
temp = "This spell instantly kills somebody adjacent to you with the vilest of magick. It has a long cooldown."
|
||||
temp = "You have learned disintegrate."
|
||||
if("disabletech")
|
||||
feedback_add_details("wizard_spell_learned","DT") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/emplosion/disable_tech(H)
|
||||
temp = "This spell disables all weapons, cameras and most other technology in range."
|
||||
temp = "You have learned disable technology."
|
||||
if("smoke")
|
||||
feedback_add_details("wizard_spell_learned","SM") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/smoke(H)
|
||||
temp = "This spell spawns a cloud of choking smoke at your location and does not require wizard garb."
|
||||
temp = "You have learned smoke."
|
||||
if("blind")
|
||||
feedback_add_details("wizard_spell_learned","BD") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/trigger/blind(H)
|
||||
temp = "This spell temporarly blinds a single person and does not require wizard garb."
|
||||
temp = "You have learned blind."
|
||||
if("mindswap")
|
||||
feedback_add_details("wizard_spell_learned","MT") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/mind_transfer(H)
|
||||
temp = "This spell allows the user to switch bodies with a target. Careful to not lose your memory in the process."
|
||||
temp = "You have learned mindswap."
|
||||
if("forcewall")
|
||||
feedback_add_details("wizard_spell_learned","FW") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/forcewall(H)
|
||||
temp = "This spell creates an unbreakable wall that lasts for 30 seconds and does not need wizard garb."
|
||||
temp = "You have learned forcewall."
|
||||
if("blink")
|
||||
feedback_add_details("wizard_spell_learned","BL") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/turf_teleport/blink(H)
|
||||
temp = "This spell randomly teleports you a short distance. Useful for evasion or getting into areas if you have patience."
|
||||
temp = "You have learned blink."
|
||||
if("teleport")
|
||||
feedback_add_details("wizard_spell_learned","TP") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/area_teleport/teleport(H)
|
||||
temp = "This spell teleports you to a type of area of your selection. Very useful if you are in danger, but has a decent cooldown, and is unpredictable."
|
||||
temp = "You have learned teleport."
|
||||
if("mutate")
|
||||
feedback_add_details("wizard_spell_learned","MU") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/genetic/mutate(H)
|
||||
temp = "This spell causes you to turn into a hulk and gain telekinesis for a short while."
|
||||
temp = "You have learned mutate."
|
||||
if("etherealjaunt")
|
||||
feedback_add_details("wizard_spell_learned","EJ") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/ethereal_jaunt(H)
|
||||
temp = "This spell creates your ethereal form, temporarily making you invisible and able to pass through walls."
|
||||
temp = "You have learned ethereal jaunt."
|
||||
if("knock")
|
||||
feedback_add_details("wizard_spell_learned","KN") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/knock(H)
|
||||
temp = "This spell opens nearby doors and does not require wizard garb."
|
||||
temp = "You have learned knock."
|
||||
if("horseman")
|
||||
feedback_add_details("wizard_spell_learned","HH") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/horsemask(H)
|
||||
temp = "This spell will curse a person to wear an unremovable horse mask (it has glue on the inside) and speak like a horse. It does not require a wizard garb. Do note the curse will disintegrate the target's current mask if they are wearing one."
|
||||
temp = "You have learned curse of the horseman."
|
||||
if("fleshtostone")
|
||||
feedback_add_details("wizard_spell_learned","FS") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/targeted/inflict_handler/flesh_to_stone(H)
|
||||
temp = "You have learned flesh to stone."
|
||||
if("summonguns")
|
||||
feedback_add_details("wizard_spell_learned","SG") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.rightandwrong()
|
||||
H.rightandwrong(0)
|
||||
max_uses--
|
||||
temp = "Nothing could possibly go wrong with arming a crew of lunatics just itching for an excuse to kill eachother. Just be careful not to get hit in the crossfire!"
|
||||
temp = "You have cast summon guns."
|
||||
if("summonmagic")
|
||||
feedback_add_details("wizard_spell_learned","SM") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
H.rightandwrong(1)
|
||||
max_uses--
|
||||
temp = "You have cast summon magic."
|
||||
if("staffchange")
|
||||
feedback_add_details("wizard_spell_learned","ST") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
new /obj/item/weapon/gun/energy/staff(get_turf(H))
|
||||
temp = "An artefact that spits bolts of coruscating energy which cause the target's very form to reshape itself"
|
||||
max_uses--
|
||||
if("mentalfocus")
|
||||
feedback_add_details("wizard_spell_learned","MF") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
new /obj/item/weapon/gun/energy/staff/focus(get_turf(H))
|
||||
temp = "An artefact that channels the will of the user into destructive bolts of force."
|
||||
new /obj/item/weapon/gun/magic/staff/change(get_turf(H))
|
||||
temp = "You have purchased a staff of change."
|
||||
max_uses--
|
||||
if("soulstone")
|
||||
feedback_add_details("wizard_spell_learned","SS") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
new /obj/item/weapon/storage/belt/soulstone/full(get_turf(H))
|
||||
H.spell_list += new /obj/effect/proc_holder/spell/aoe_turf/conjure/construct(H)
|
||||
temp = "Soul Stone Shards are ancient tools capable of capturing and harnessing the spirits of the dead and dying. The spell Artificer allows you to create arcane machines for the captured souls to pilot."
|
||||
temp = "You have purchased a belt full of soulstones and have learned the artificer spell."
|
||||
max_uses--
|
||||
if("armor")
|
||||
feedback_add_details("wizard_spell_learned","HS") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
@@ -181,12 +274,28 @@
|
||||
new /obj/item/clothing/gloves/purple(get_turf(H))//To complete the outfit
|
||||
new /obj/item/clothing/suit/space/rig/wizard(get_turf(H))
|
||||
new /obj/item/clothing/head/helmet/space/rig/wizard(get_turf(H))
|
||||
temp = "An artefact suit of armor that allows you to cast spells while providing more protection against attacks and the void of space."
|
||||
temp = "You have purchased a suit of wizard armor."
|
||||
max_uses--
|
||||
if("staffanimation")
|
||||
feedback_add_details("wizard_spell_learned","SA") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
new /obj/item/weapon/gun/energy/staff/animate(get_turf(H))
|
||||
temp = "An artefact that spits bolts of life-force which causes objects which are hit by it to animate and come to life! This magic doesn't affect machines."
|
||||
new /obj/item/weapon/gun/magic/staff/animate(get_turf(H))
|
||||
temp = "You have purchased a staff of animation."
|
||||
max_uses--
|
||||
if("contract")
|
||||
feedback_add_details("wizard_spell_learned","CT") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
new /obj/item/weapon/contract(get_turf(H))
|
||||
temp = "You have purchased a contract of apprenticeship."
|
||||
max_uses--
|
||||
if("scrying")
|
||||
feedback_add_details("wizard_spell_learned","SO") //please do not change the abbreviation to keep data processing consistent. Add a unique id to any new spells
|
||||
new /obj/item/weapon/scrying(get_turf(H))
|
||||
if (!(XRAY in H.mutations))
|
||||
H.mutations.Add(XRAY)
|
||||
H.sight |= (SEE_MOBS|SEE_OBJS|SEE_TURFS)
|
||||
H.see_in_dark = 8
|
||||
H.see_invisible = SEE_INVISIBLE_LEVEL_TWO
|
||||
H << "\blue The walls suddenly disappear."
|
||||
temp = "You have purchased a scrying orb, and gained x-ray vision."
|
||||
max_uses--
|
||||
else
|
||||
if(href_list["temp"])
|
||||
@@ -194,3 +303,154 @@
|
||||
attack_self(H)
|
||||
|
||||
return
|
||||
|
||||
//Single Use Spellbooks//
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse
|
||||
var/spell = /obj/effect/proc_holder/spell/targeted/projectile/magic_missile //just a placeholder to avoid runtimes if someone spawned the generic
|
||||
var/spellname = "sandbox"
|
||||
var/used = 0
|
||||
name = "spellbook of "
|
||||
uses = 1
|
||||
max_uses = 1
|
||||
desc = "This template spellbook was never meant for the eyes of man..."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/New()
|
||||
..()
|
||||
name += spellname
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/attack_self(mob/user as mob)
|
||||
var/obj/effect/proc_holder/spell/S = new spell
|
||||
for(var/obj/effect/proc_holder/spell/knownspell in user.spell_list)
|
||||
if(knownspell.type == S.type)
|
||||
if(user.mind)
|
||||
if(user.mind.special_role == "apprentice" || user.mind.special_role == "Wizard")
|
||||
user <<"<span class='notice'>You're already far more versed in this spell than this flimsy how-to book can provide.</span>"
|
||||
else
|
||||
user <<"<span class='notice'>You've already read this one.</span>"
|
||||
return
|
||||
if(used)
|
||||
recoil(user)
|
||||
else
|
||||
user.spell_list += S
|
||||
user <<"<span class='notice'>you rapidly read through the arcane book. Suddenly you realize you understand [spellname]!</span>"
|
||||
onlearned(user)
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/proc/recoil(mob/user as mob)
|
||||
user.visible_message("<span class='warning'>[src] glows in a black light!</span>")
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/proc/onlearned(mob/user as mob)
|
||||
used = 1
|
||||
user.visible_message("<span class='caution'>[src] glows dark for a second!</span>")
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/attackby()
|
||||
return
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/fireball
|
||||
spell = /obj/effect/proc_holder/spell/dumbfire/fireball
|
||||
spellname = "fireball"
|
||||
icon_state ="bookfireball"
|
||||
desc = "This book feels warm to the touch."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/fireball/recoil(mob/user as mob)
|
||||
..()
|
||||
explosion(user.loc, -1, 0, 2, 3, 0, flame_range = 2)
|
||||
del(src)
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/smoke
|
||||
spell = /obj/effect/proc_holder/spell/targeted/smoke
|
||||
spellname = "smoke"
|
||||
icon_state ="booksmoke"
|
||||
desc = "This book is overflowing with the dank arts."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/smoke/recoil(mob/user as mob)
|
||||
..()
|
||||
user <<"<span class='caution'>Your stomach rumbles...</span>"
|
||||
if(user.nutrition)
|
||||
user.nutrition -= 200
|
||||
if(user.nutrition <= 0)
|
||||
user.nutrition = 0
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/blind
|
||||
spell = /obj/effect/proc_holder/spell/targeted/trigger/blind
|
||||
spellname = "blind"
|
||||
icon_state ="bookblind"
|
||||
desc = "This book looks blurry, no matter how you look at it."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/blind/recoil(mob/user as mob)
|
||||
..()
|
||||
user <<"<span class='warning'>You go blind!</span>"
|
||||
user.eye_blind = 10
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/mindswap
|
||||
spell = /obj/effect/proc_holder/spell/targeted/mind_transfer
|
||||
spellname = "mindswap"
|
||||
icon_state ="bookmindswap"
|
||||
desc = "This book's cover is pristine, though its pages look ragged and torn."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/mindswap/onlearned()
|
||||
spellname = pick("fireball","smoke","blind","forcewall","knock","horses","charge")
|
||||
icon_state = "book[spellname]"
|
||||
name = "spellbook of [spellname]" //Note, desc doesn't change by design
|
||||
..()
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/mindswap/recoil(mob/user as mob)
|
||||
..()
|
||||
user <<"<span class='warning'>You suddenly don't feel like yourself!</span>"
|
||||
wabbajack(user)
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/forcewall
|
||||
spell = /obj/effect/proc_holder/spell/aoe_turf/conjure/forcewall
|
||||
spellname = "forcewall"
|
||||
icon_state ="bookforcewall"
|
||||
desc = "This book has a dedication to mimes everywhere inside the front cover."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/forcewall/recoil(mob/user as mob)
|
||||
..()
|
||||
user <<"<span class='warning'>You suddenly feel very solid!</span>"
|
||||
var/obj/structure/closet/statue/S = new /obj/structure/closet/statue(user.loc, user)
|
||||
S.timer = 30
|
||||
user.drop_item()
|
||||
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/knock
|
||||
spell = /obj/effect/proc_holder/spell/aoe_turf/knock
|
||||
spellname = "knock"
|
||||
icon_state ="bookknock"
|
||||
desc = "This book is hard to hold closed properly."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/knock/recoil(mob/user as mob)
|
||||
..()
|
||||
user <<"<span class='warning'>You're knocked down!</span>"
|
||||
user.Stun(20)
|
||||
user.Weaken(20)
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/horsemask
|
||||
spell = /obj/effect/proc_holder/spell/targeted/horsemask
|
||||
spellname = "horses"
|
||||
icon_state ="bookhorses"
|
||||
desc = "This book is more horse than your mind has room for."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/horsemask/recoil(mob/living/carbon/user as mob)
|
||||
if(istype(user, /mob/living/carbon/human))
|
||||
user <<"<font size='15' color='red'><b>HOR-SIE HAS RISEN</b></font>"
|
||||
var/obj/item/clothing/mask/horsehead/magichead = new /obj/item/clothing/mask/horsehead
|
||||
magichead.canremove = 0 //curses!
|
||||
magichead.flags_inv = null //so you can still see their face
|
||||
magichead.voicechange = 1 //NEEEEIIGHH
|
||||
user.drop_from_inventory(user.wear_mask)
|
||||
user.equip_to_slot_if_possible(magichead, slot_wear_mask, 1, 1)
|
||||
del(src)
|
||||
else
|
||||
user <<"<span class='notice'>I say thee neigh</span>"
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/charge
|
||||
spell = /obj/effect/proc_holder/spell/targeted/charge
|
||||
spellname = "charging"
|
||||
icon_state ="bookcharge"
|
||||
desc = "This book is made of 100% post-consumer wizard."
|
||||
|
||||
/obj/item/weapon/spellbook/oneuse/charge/recoil(mob/user as mob)
|
||||
..()
|
||||
user <<"<span class='warning'>[src] suddenly feels very warm!</span>"
|
||||
empulse(src, 1, 1)
|
||||
@@ -1,39 +0,0 @@
|
||||
/obj/item/weapon/veilrender
|
||||
name = "veil render"
|
||||
desc = "A wicked curved blade of alien origin, recovered from the ruins of a vast city."
|
||||
icon = 'icons/obj/wizard.dmi'
|
||||
icon_state = "render"
|
||||
item_state = "render"
|
||||
flags = FPRINT | TABLEPASS
|
||||
force = 15
|
||||
throwforce = 10
|
||||
w_class = 3
|
||||
var/charged = 1
|
||||
|
||||
|
||||
/obj/effect/rend
|
||||
name = "Tear in the fabric of reality"
|
||||
desc = "You should run now"
|
||||
icon = 'icons/obj/biomass.dmi'
|
||||
icon_state = "rift"
|
||||
density = 1
|
||||
unacidable = 1
|
||||
anchored = 1.0
|
||||
|
||||
|
||||
/obj/effect/rend/New()
|
||||
spawn(50)
|
||||
new /obj/machinery/singularity/narsie/wizard(get_turf(src))
|
||||
del(src)
|
||||
return
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/veilrender/attack_self(mob/user as mob)
|
||||
if(charged == 1)
|
||||
new /obj/effect/rend(get_turf(usr))
|
||||
charged = 0
|
||||
visible_message("\red <B>[src] hums with power as [usr] deals a blow to reality itself!</B>")
|
||||
else
|
||||
user << "\red The unearthly energies that powered the blade are now dormant"
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
/datum/game_mode
|
||||
var/list/datum/mind/wizards = list()
|
||||
|
||||
@@ -18,7 +17,6 @@
|
||||
var/const/waittime_l = 600 //lower bound on time before intercept arrives (in tenths of seconds)
|
||||
var/const/waittime_h = 1800 //upper bound on time before intercept arrives (in tenths of seconds)
|
||||
|
||||
|
||||
/datum/game_mode/wizard/announce()
|
||||
world << "<B>The current game mode is - Wizard!</B>"
|
||||
world << "<B>There is a \red SPACE WIZARD\black on the station. You can't let him achieve his objective!</B>"
|
||||
@@ -31,6 +29,7 @@
|
||||
if(possible_wizards.len==0)
|
||||
return 0
|
||||
var/datum/mind/wizard = pick(possible_wizards)
|
||||
|
||||
wizards += wizard
|
||||
modePlayer += wizard
|
||||
wizard.assigned_role = "MODE" //So they aren't chosen for other jobs.
|
||||
@@ -41,15 +40,16 @@
|
||||
return 0
|
||||
return 1
|
||||
|
||||
|
||||
/datum/game_mode/wizard/pre_setup()
|
||||
for(var/datum/mind/wizard in wizards)
|
||||
wizard.current.loc = pick(wizardstart)
|
||||
for(var/datum/mind/wiz in wizards)
|
||||
wiz.current.loc = pick(wizardstart)
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
/datum/game_mode/wizard/post_setup()
|
||||
for(var/datum/mind/wizard in wizards)
|
||||
log_game("[wizard.key] (ckey) has been selected as a Wizard")
|
||||
forge_wizard_objectives(wizard)
|
||||
//learn_basic_spells(wizard.current)
|
||||
equip_wizard(wizard.current)
|
||||
@@ -86,7 +86,7 @@
|
||||
escape_objective.owner = wizard
|
||||
wizard.objectives += escape_objective
|
||||
|
||||
if(61 to 100)
|
||||
if(61 to 85)
|
||||
var/datum/objective/assassinate/kill_objective = new
|
||||
kill_objective.owner = wizard
|
||||
kill_objective.find_target()
|
||||
@@ -169,8 +169,7 @@
|
||||
wizard_mob.equip_to_slot_or_del(new /obj/item/clothing/head/wizard(wizard_mob), slot_head)
|
||||
if(wizard_mob.backbag == 2) wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack(wizard_mob), slot_back)
|
||||
if(wizard_mob.backbag == 3) wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel_norm(wizard_mob), slot_back)
|
||||
if(wizard_mob.backbag == 4) wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(wizard_mob), slot_back)
|
||||
wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/storage/box(wizard_mob), slot_in_backpack)
|
||||
wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(wizard_mob), slot_in_backpack)
|
||||
// wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/scrying_gem(wizard_mob), slot_l_store) For scrying gem.
|
||||
wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/teleportation_scroll(wizard_mob), slot_r_store)
|
||||
wizard_mob.equip_to_slot_or_del(new /obj/item/weapon/spellbook(wizard_mob), slot_r_hand)
|
||||
@@ -188,6 +187,7 @@
|
||||
return ..()
|
||||
|
||||
var/wizards_alive = 0
|
||||
var/traitors_alive = 0
|
||||
for(var/datum/mind/wizard in wizards)
|
||||
if(!istype(wizard.current,/mob/living/carbon))
|
||||
continue
|
||||
@@ -195,7 +195,15 @@
|
||||
continue
|
||||
wizards_alive++
|
||||
|
||||
if (wizards_alive)
|
||||
if(!wizards_alive)
|
||||
for(var/datum/mind/traitor in traitors)
|
||||
if(!istype(traitor.current,/mob/living/carbon))
|
||||
continue
|
||||
if(traitor.current.stat==2)
|
||||
continue
|
||||
traitors_alive++
|
||||
|
||||
if (wizards_alive || traitors_alive)
|
||||
return ..()
|
||||
else
|
||||
finished = 1
|
||||
@@ -213,18 +221,18 @@
|
||||
|
||||
/datum/game_mode/proc/auto_declare_completion_wizard()
|
||||
if(wizards.len)
|
||||
var/text = "<FONT size = 2><B>The wizards/witches were:</B></FONT>"
|
||||
var/text = "<br><font size=3><b>the wizards/witches were:</b></font>"
|
||||
|
||||
for(var/datum/mind/wizard in wizards)
|
||||
|
||||
text += "<br>[wizard.key] was [wizard.name] ("
|
||||
text += "<br><b>[wizard.key]</b> was <b>[wizard.name]</b> ("
|
||||
if(wizard.current)
|
||||
if(wizard.current.stat == DEAD)
|
||||
text += "died"
|
||||
else
|
||||
text += "survived"
|
||||
if(wizard.current.real_name != wizard.name)
|
||||
text += " as [wizard.current.real_name]"
|
||||
text += " as <b>[wizard.current.real_name]</b>"
|
||||
else
|
||||
text += "body destroyed"
|
||||
text += ")"
|
||||
@@ -247,6 +255,15 @@
|
||||
else
|
||||
text += "<br><font color='red'><B>The wizard has failed!</B></font>"
|
||||
feedback_add_details("wizard_success","FAIL")
|
||||
if(wizard.current && wizard.current.spell_list)
|
||||
text += "<br><B>[wizard.name] used the following spells: </B>"
|
||||
var/i = 1
|
||||
for(var/obj/effect/proc_holder/spell/S in wizard.current.spell_list)
|
||||
text += "[S.name]"
|
||||
if(wizard.current.spell_list.len > i)
|
||||
text += ", "
|
||||
i++
|
||||
text += "<br>"
|
||||
|
||||
world << text
|
||||
return 1
|
||||
|
||||
@@ -29,8 +29,6 @@ obj/machinery/recharger/attackby(obj/item/weapon/G as obj, mob/user as mob)
|
||||
if (istype(G, /obj/item/weapon/gun/energy/gun/nuclear) || istype(G, /obj/item/weapon/gun/energy/crossbow))
|
||||
user << "<span class='notice'>Your gun's recharge port was removed to make room for a miniaturized reactor.</span>"
|
||||
return
|
||||
if (istype(G, /obj/item/weapon/gun/energy/staff))
|
||||
return
|
||||
if(istype(G,/obj/item/device/laptop))
|
||||
var/obj/item/device/laptop/L = G
|
||||
if(!L.stored_computer.battery)
|
||||
|
||||
@@ -225,7 +225,7 @@
|
||||
if(3)
|
||||
A = new /obj/item/projectile/beam/pulse( loc )
|
||||
if(4)
|
||||
A = new /obj/item/projectile/change( loc )
|
||||
A = new /obj/item/projectile/magic/change( loc )
|
||||
if(5)
|
||||
A = new /obj/item/projectile/beam/lastertag/blue( loc )
|
||||
if(6)
|
||||
|
||||
@@ -11,6 +11,11 @@
|
||||
throw_range = 20
|
||||
origin_tech = "bluespace=4"
|
||||
|
||||
/obj/item/weapon/teleportation_scroll/apprentice
|
||||
name = "lesser scroll of teleportation"
|
||||
uses = 1
|
||||
origin_tech = "bluespace 2"
|
||||
|
||||
/obj/item/weapon/teleportation_scroll/attack_self(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
var/dat = "<B>Teleportation Scroll:</B><BR>"
|
||||
|
||||
@@ -0,0 +1,145 @@
|
||||
/obj/structure/closet/statue
|
||||
name = "statue"
|
||||
desc = "An incredibly lifelike marble carving"
|
||||
icon = 'icons/obj/statue.dmi'
|
||||
icon_state = "human_male"
|
||||
density = 1
|
||||
anchored = 1
|
||||
flags = FPRINT
|
||||
health = 0 //destroying the statue kills the mob within
|
||||
var/intialTox = 0 //these are here to keep the mob from taking damage from things that logically wouldn't affect a rock
|
||||
var/intialFire = 0 //it's a little sloppy I know but it was this or the GODMODE flag. Lesser of two evils.
|
||||
var/intialBrute = 0
|
||||
var/intialOxy = 0
|
||||
var/timer = 240 //eventually the person will be freed
|
||||
|
||||
/obj/structure/closet/statue/New(loc, var/mob/living/L)
|
||||
|
||||
if(ishuman(L) || ismonkey(L) || iscorgi(L))
|
||||
if(L.buckled)
|
||||
L.buckled = 0
|
||||
L.anchored = 0
|
||||
if(L.client)
|
||||
L.client.perspective = EYE_PERSPECTIVE
|
||||
L.client.eye = src
|
||||
L.loc = src
|
||||
L.sdisabilities += MUTE
|
||||
health = L.health + 100 //stoning damaged mobs will result in easier to shatter statues
|
||||
intialTox = L.getToxLoss()
|
||||
intialFire = L.getFireLoss()
|
||||
intialBrute = L.getBruteLoss()
|
||||
intialOxy = L.getOxyLoss()
|
||||
if(ishuman(L))
|
||||
name = "statue of [L.name]"
|
||||
if(L.gender == "female")
|
||||
icon_state = "human_female"
|
||||
else if(ismonkey(L))
|
||||
name = "statue of a monkey"
|
||||
icon_state = "monkey"
|
||||
else if(iscorgi(L))
|
||||
name = "statue of a corgi"
|
||||
icon_state = "corgi"
|
||||
desc = "If it takes forever, I will wait for you..."
|
||||
|
||||
if(health == 0) //meaning if the statue didn't find a valid target
|
||||
del(src)
|
||||
return
|
||||
|
||||
processing_objects.Add(src)
|
||||
..()
|
||||
|
||||
/obj/structure/closet/statue/process()
|
||||
timer--
|
||||
for(var/mob/living/M in src) //Go-go gadget stasis field
|
||||
M.setToxLoss(intialTox)
|
||||
M.adjustFireLoss(intialFire - M.getFireLoss())
|
||||
M.adjustBruteLoss(intialBrute - M.getBruteLoss())
|
||||
M.setOxyLoss(intialOxy)
|
||||
if (timer <= 0)
|
||||
dump_contents()
|
||||
processing_objects.Remove(src)
|
||||
del(src)
|
||||
|
||||
/obj/structure/closet/statue/dump_contents()
|
||||
|
||||
for(var/obj/O in src)
|
||||
O.loc = src.loc
|
||||
|
||||
for(var/mob/living/M in src)
|
||||
M.loc = src.loc
|
||||
M.sdisabilities -= MUTE
|
||||
M.take_overall_damage((M.health - health - 100),0) //any new damage the statue incurred is transfered to the mob
|
||||
if(M.client)
|
||||
M.client.eye = M.client.mob
|
||||
M.client.perspective = MOB_PERSPECTIVE
|
||||
|
||||
|
||||
|
||||
/obj/structure/closet/statue/open()
|
||||
return
|
||||
|
||||
|
||||
|
||||
/obj/structure/closet/statue/open()
|
||||
return
|
||||
|
||||
|
||||
/obj/structure/closet/statue/close()
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/toggle()
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/bullet_act(var/obj/item/projectile/Proj)
|
||||
health -= Proj.damage
|
||||
if(health <= 0)
|
||||
for(var/mob/M in src)
|
||||
shatter(M)
|
||||
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/attack_animal(mob/living/simple_animal/user as mob)
|
||||
if(user.wall_smash)
|
||||
for(var/mob/M in src)
|
||||
shatter(M)
|
||||
|
||||
/obj/structure/closet/statue/blob_act()
|
||||
for(var/mob/M in src)
|
||||
shatter(M)
|
||||
|
||||
/obj/structure/closet/statue/meteorhit(obj/O as obj)
|
||||
if(O.icon_state == "flaming")
|
||||
for(var/mob/M in src)
|
||||
M.meteorhit(O)
|
||||
shatter(M)
|
||||
|
||||
/obj/structure/closet/statue/attackby(obj/item/I as obj, mob/user as mob)
|
||||
health -= I.force
|
||||
visible_message("\red [user] strikes [src] with [I].")
|
||||
if(health <= 0)
|
||||
for(var/mob/M in src)
|
||||
shatter(M)
|
||||
|
||||
|
||||
|
||||
/obj/structure/closet/statue/MouseDrop_T()
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/relaymove()
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/attack_hand()
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/verb_toggleopen()
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/update_icon()
|
||||
return
|
||||
|
||||
/obj/structure/closet/statue/proc/shatter(mob/user as mob)
|
||||
if (user)
|
||||
user.dust()
|
||||
dump_contents()
|
||||
visible_message("\red [src] shatters!. ")
|
||||
del(src)
|
||||
@@ -26,7 +26,7 @@
|
||||
update_icon()
|
||||
|
||||
/obj/structure/bookcase/attackby(obj/O as obj, mob/user as mob)
|
||||
if(istype(O, /obj/item/weapon/book))
|
||||
if(istype(O, /obj/item/weapon/book) || istype(O, /obj/item/weapon/spellbook))
|
||||
user.drop_item()
|
||||
O.loc = src
|
||||
update_icon()
|
||||
|
||||
@@ -2,14 +2,14 @@
|
||||
// if(!skip) //ugly, but easy
|
||||
// message_admins("Skip Check Passed")
|
||||
if(in_throw_mode && !get_active_hand()) //empty active hand and we're in throw mode
|
||||
message_admins("In Throw Mode and active hand check passed")
|
||||
// message_admins("In Throw Mode and active hand check passed")
|
||||
if(canmove && !restrained())
|
||||
message_admins("Restrained/moving check passed")
|
||||
// message_admins("Restrained/moving check passed")
|
||||
if(istype(AM, /obj/item))
|
||||
message_admins("Item check passed")
|
||||
// message_admins("Item check passed")
|
||||
var/obj/item/I = AM
|
||||
if(isturf(I.loc))
|
||||
message_admins("Turf check passed")
|
||||
// message_admins("Turf check passed")
|
||||
put_in_active_hand(I)
|
||||
visible_message("<span class='warning'>[src] catches [I]!</span>")
|
||||
throw_mode_off()
|
||||
|
||||
@@ -195,4 +195,10 @@ var/global/list/protected_objects = list(/obj/structure/table, /obj/structure/ca
|
||||
if(istype(L))
|
||||
if(prob(15))
|
||||
L.Weaken(1)
|
||||
L.visible_message("<span class='danger'>\the [src] knocks down \the [L]!</span>")
|
||||
L.visible_message("<span class='danger'>\the [src] knocks down \the [L]!</span>")
|
||||
|
||||
/mob/living/simple_animal/hostile/mimic/copy/proc/ChangeOwner(var/mob/owner)
|
||||
if(owner != creator)
|
||||
LoseTarget()
|
||||
creator = owner
|
||||
faction = "\ref[owner]"
|
||||
@@ -45,6 +45,11 @@
|
||||
proc/special_check(var/mob/M) //Placeholder for any special checks, like detective's revolver.
|
||||
return 1
|
||||
|
||||
|
||||
proc/shoot_with_empty_chamber(mob/living/user as mob|obj)
|
||||
user << "<span class='warning'>*click*</span>"
|
||||
return
|
||||
|
||||
emp_act(severity)
|
||||
for(var/obj/O in contents)
|
||||
O.emp_act(severity)
|
||||
|
||||
@@ -26,48 +26,6 @@
|
||||
charge_cost = 100
|
||||
projectile_type = "/obj/item/projectile/energy/declone"
|
||||
|
||||
obj/item/weapon/gun/energy/staff
|
||||
name = "staff of change"
|
||||
desc = "An artefact that spits bolts of coruscating energy which cause the target's very form to reshape itself"
|
||||
icon = 'icons/obj/gun.dmi'
|
||||
icon_state = "staffofchange"
|
||||
item_state = "staffofchange"
|
||||
fire_sound = 'sound/weapons/emitter.ogg'
|
||||
flags = FPRINT | TABLEPASS | CONDUCT
|
||||
slot_flags = SLOT_BACK
|
||||
w_class = 4.0
|
||||
charge_cost = 200
|
||||
projectile_type = "/obj/item/projectile/change"
|
||||
origin_tech = null
|
||||
clumsy_check = 0
|
||||
var/charge_tick = 0
|
||||
|
||||
|
||||
New()
|
||||
..()
|
||||
processing_objects.Add(src)
|
||||
|
||||
|
||||
Del()
|
||||
processing_objects.Remove(src)
|
||||
..()
|
||||
|
||||
|
||||
process()
|
||||
charge_tick++
|
||||
if(charge_tick < 4) return 0
|
||||
charge_tick = 0
|
||||
if(!power_supply) return 0
|
||||
power_supply.give(200)
|
||||
return 1
|
||||
|
||||
update_icon()
|
||||
return
|
||||
/obj/item/weapon/gun/energy/staff/animate
|
||||
name = "staff of animation"
|
||||
desc = "An artefact that spits bolts of life-force which causes objects which are hit by it to animate and come to life! This magic doesn't affect machines."
|
||||
projectile_type = "/obj/item/projectile/animate"
|
||||
charge_cost = 100
|
||||
|
||||
/obj/item/weapon/gun/energy/floragun
|
||||
name = "floral somatoray"
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
/obj/item/weapon/gun/magic
|
||||
name = "staff of nothing"
|
||||
desc = "This staff is boring to watch because even though it came first you've seen everything it can do in other staves for years."
|
||||
icon = 'icons/obj/gun.dmi'
|
||||
icon_state = "staffofnothing"
|
||||
item_state = "staff"
|
||||
fire_sound = 'sound/weapons/emitter.ogg'
|
||||
flags = FPRINT | TABLEPASS | CONDUCT
|
||||
w_class = 5
|
||||
var/projectile_type = "/obj/item/projectile/magic"
|
||||
var/max_charges = 6
|
||||
var/charges = 0
|
||||
var/recharge_rate = 4
|
||||
var/charge_tick = 0
|
||||
var/can_charge = 1
|
||||
origin_tech = null
|
||||
clumsy_check = 0
|
||||
|
||||
/obj/item/weapon/gun/magic/emp_act(severity)
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/magic/process_chambered()
|
||||
if(in_chamber) return 1
|
||||
if(!charges) return 0
|
||||
if(!projectile_type) return 0
|
||||
in_chamber = new projectile_type(src)
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/gun/magic/afterattack(atom/target as mob, mob/living/user as mob, flag)
|
||||
..()
|
||||
if(charges && !in_chamber && !flag) charges--
|
||||
|
||||
/obj/item/weapon/gun/magic/New()
|
||||
..()
|
||||
charges = max_charges
|
||||
if(can_charge) processing_objects.Add(src)
|
||||
|
||||
|
||||
/obj/item/weapon/gun/magic/Del()
|
||||
if(can_charge) processing_objects.Remove(src)
|
||||
..()
|
||||
|
||||
|
||||
/obj/item/weapon/gun/magic/process()
|
||||
charge_tick++
|
||||
if(charge_tick < recharge_rate || charges >= max_charges) return 0
|
||||
charge_tick = 0
|
||||
charges++
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/gun/magic/update_icon()
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/magic/shoot_with_empty_chamber(mob/living/user as mob|obj)
|
||||
user << "<span class='warning'>The [name] whizzles quietly.<span>"
|
||||
return
|
||||
@@ -0,0 +1,23 @@
|
||||
obj/item/weapon/gun/magic/staff/
|
||||
slot_flags = SLOT_BACK
|
||||
|
||||
obj/item/weapon/gun/magic/staff/change
|
||||
name = "staff of change"
|
||||
desc = "An artefact that spits bolts of coruscating energy which cause the target's very form to reshape itself"
|
||||
projectile_type = "/obj/item/projectile/magic/change"
|
||||
icon_state = "staffofchange"
|
||||
item_state = "staffofchange"
|
||||
|
||||
obj/item/weapon/gun/magic/staff/animate
|
||||
name = "staff of animation"
|
||||
desc = "An artefact that spits bolts of life-force which causes objects which are hit by it to animate and come to life! This magic doesn't affect machines."
|
||||
projectile_type = "/obj/item/projectile/magic/animate"
|
||||
icon_state = "staffofanimation"
|
||||
item_state = "staffofanimation"
|
||||
|
||||
obj/item/weapon/gun/magic/staff/healing
|
||||
name = "staff of healing"
|
||||
desc = "An artefact that spits bolts of restoring magic which can remove ailments of all kinds and even raise the dead."
|
||||
projectile_type = "/obj/item/projectile/magic/resurrection"
|
||||
icon_state = "staffofhealing"
|
||||
item_state = "staffofhealing"
|
||||
@@ -0,0 +1,135 @@
|
||||
/obj/item/weapon/gun/magic/wand/
|
||||
name = "wand of nothing"
|
||||
desc = "It's not just a stick, it's a MAGIC stick!"
|
||||
projectile_type = "/obj/item/projectile/magic"
|
||||
icon_state = "wand6"
|
||||
item_state = "wand"
|
||||
w_class = 2
|
||||
can_charge = 0
|
||||
max_charges = 100 //100, 50, 50, 34 (max charge distribution by 25%ths)
|
||||
var/variable_charges = 1
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/New()
|
||||
if(prob(75) && variable_charges) //25% chance of listed max charges, 50% chance of 1/2 max charges, 25% chance of 1/3 max charges
|
||||
if(prob(33))
|
||||
max_charges = Ceiling(max_charges / 3)
|
||||
else
|
||||
max_charges = Ceiling(max_charges / 2)
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/examine()
|
||||
..()
|
||||
usr << "Has [charges] charge\s remaining."
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/attack_self(mob/living/user as mob)
|
||||
if(charges)
|
||||
zap_self(user)
|
||||
else
|
||||
user << "<span class='caution'>The [name] whizzles quietly.<span>"
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/attack(atom/target as mob, mob/living/user as mob)
|
||||
if(target == user)
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/afterattack(atom/target as mob, mob/living/user as mob)
|
||||
if(target == user)
|
||||
if(charges)
|
||||
zap_self(user)
|
||||
else
|
||||
user << "<span class='caution'>The [name] whizzles quietly.<span>"
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/proc/zap_self(mob/living/user as mob)
|
||||
user.visible_message("<span class='notice'>[user] zaps \himself with [src]!</span>")
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/death
|
||||
name = "wand of death"
|
||||
desc = "This deadly wand overwhelms the victim's body with pure energy, slaying them without fail."
|
||||
projectile_type = "/obj/item/projectile/magic/death"
|
||||
icon_state = "wand4"
|
||||
max_charges = 3 //3, 2, 2, 1
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/death/zap_self(mob/living/user as mob)
|
||||
if(alert(user, "You really want to zap yourself with the wand of death?",, "Yes", "No") == "Yes" && charges && user.get_active_hand() == src && isliving(user))
|
||||
var/message ="<span class='warning'>You irradiate yourself with pure energy! "
|
||||
message += pick("Do not pass go. Do not collect 200 zorkmids.</span>","You feel more confident in your spell casting skills.</span>","You Die...</span>","Do you want your possessions identified?</span>")
|
||||
user << message
|
||||
user.adjustOxyLoss(500)
|
||||
charges--
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/resurrection
|
||||
name = "wand of resurrection"
|
||||
desc = "This wand uses healing magics to heal and revive. They are rarely utilized within the Wizard Federation for some reason."
|
||||
projectile_type = "/obj/item/projectile/magic/resurrection"
|
||||
icon_state = "wand1"
|
||||
max_charges = 3 //3, 2, 2, 1
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/resurrection/zap_self(mob/living/user as mob)
|
||||
user.setToxLoss(0)
|
||||
user.setOxyLoss(0)
|
||||
user.setCloneLoss(0)
|
||||
user.SetParalysis(0)
|
||||
user.SetStunned(0)
|
||||
user.SetWeakened(0)
|
||||
user.radiation = 0
|
||||
user.heal_overall_damage(user.getBruteLoss(), user.getFireLoss())
|
||||
user.reagents.clear_reagents()
|
||||
user << "<span class='notice'>You feel great!</span>"
|
||||
charges--
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/polymorph
|
||||
name = "wand of polymorph"
|
||||
desc = "This wand is attuned to chaos and will radically alter the victim's form."
|
||||
projectile_type = "/obj/item/projectile/magic/change"
|
||||
icon_state = "wand5"
|
||||
max_charges = 10 //10, 5, 5, 4
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/polymorph/zap_self(mob/living/user as mob)
|
||||
if(alert(user, "Your new form might not have arms to zap with... Continue?",, "Yes", "No") == "Yes" && charges && user.get_active_hand() == src && isliving(user))
|
||||
..() //because the user mob ceases to exists by the time wabbajack fully resolves
|
||||
wabbajack(user)
|
||||
charges--
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/teleport
|
||||
name = "wand of teleportation"
|
||||
desc = "This wand will wrench targets through space and time to move them somewhere else."
|
||||
projectile_type = "/obj/item/projectile/magic/teleport"
|
||||
icon_state = "wand3"
|
||||
max_charges = 10 //10, 5, 5, 4
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/teleport/zap_self(mob/living/user as mob)
|
||||
do_teleport(user, user, 10)
|
||||
var/datum/effect/effect/system/harmless_smoke_spread/smoke = new /datum/effect/effect/system/harmless_smoke_spread()
|
||||
smoke.set_up(10, 0, user.loc)
|
||||
smoke.start()
|
||||
charges--
|
||||
..()
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/door
|
||||
name = "wand of door creation"
|
||||
desc = "This particular wand can create doors in any wall for the unscrupulous wizard who shuns teleportation magics."
|
||||
projectile_type = "/obj/item/projectile/magic/door"
|
||||
icon_state = "wand0"
|
||||
max_charges = 20 //20, 10, 10, 7
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/door/zap_self()
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/fireball
|
||||
name = "wand of fireball"
|
||||
desc = "This wand shoots scorching balls of fire that explode into destructive flames."
|
||||
projectile_type = "/obj/item/projectile/magic/fireball"
|
||||
icon_state = "wand2"
|
||||
max_charges = 8 //8, 4, 4, 3
|
||||
|
||||
/obj/item/weapon/gun/magic/wand/fireball/zap_self(mob/living/user as mob)
|
||||
if(alert(user, "Zapping yourself with a wand of fireball is probably a bad idea, do it anyway?",, "Yes", "No") == "Yes" && charges && user.get_active_hand() == src && isliving(user))
|
||||
explosion(user.loc, -1, 0, 2, 3, 0, flame_range = 2)
|
||||
charges--
|
||||
..()
|
||||
@@ -0,0 +1,236 @@
|
||||
/obj/item/projectile/magic
|
||||
name = "bolt of nothing"
|
||||
icon_state = "energy"
|
||||
damage = 0
|
||||
damage_type = OXY
|
||||
nodamage = 1
|
||||
flag = "magic"
|
||||
|
||||
/obj/item/projectile/magic/death
|
||||
name = "bolt of death"
|
||||
icon_state = "pulse1_bl"
|
||||
damage = 9001
|
||||
damage_type = OXY
|
||||
nodamage = 0
|
||||
flag = "magic"
|
||||
|
||||
/obj/item/projectile/magic/fireball
|
||||
name = "bolt of fireball"
|
||||
icon_state = "fireball"
|
||||
damage = 25 //The spell fireball additionally does 20 burn, so the wand fireball is marginally less painful
|
||||
damage_type = BRUTE
|
||||
nodamage = 0
|
||||
flag = "magic"
|
||||
|
||||
/obj/item/projectile/magic/fireball/on_hit(var/target)
|
||||
var/turf/T = get_turf(target)
|
||||
explosion(T, -1, 0, 2, 3, 0, flame_range = 2)
|
||||
|
||||
/obj/item/projectile/magic/resurrection
|
||||
name = "bolt of resurrection"
|
||||
icon_state = "ion"
|
||||
damage = 0
|
||||
damage_type = OXY
|
||||
nodamage = 1
|
||||
flag = "magic"
|
||||
|
||||
/obj/item/projectile/magic/resurrection/on_hit(var/mob/living/carbon/target)
|
||||
|
||||
if(istype(target,/mob))
|
||||
var/old_stat = target.stat
|
||||
if(target.stat == DEAD)
|
||||
dead_mob_list -= target
|
||||
living_mob_list += target
|
||||
target.stat = CONSCIOUS
|
||||
target.tod = null
|
||||
target.setToxLoss(0)
|
||||
target.setOxyLoss(0)
|
||||
target.setCloneLoss(0)
|
||||
target.SetParalysis(0)
|
||||
target.SetStunned(0)
|
||||
target.SetWeakened(0)
|
||||
target.radiation = 0
|
||||
target.heal_overall_damage(target.getBruteLoss(), target.getFireLoss())
|
||||
target.reagents.clear_reagents()
|
||||
target.suiciding = 0
|
||||
if(!target.ckey)
|
||||
for(var/mob/dead/observer/ghost in player_list)
|
||||
if(target.real_name == ghost.real_name)
|
||||
ghost.reenter_corpse()
|
||||
break
|
||||
if(old_stat != DEAD)
|
||||
target << "<span class='notice'>You feel great!</span>"
|
||||
else
|
||||
target << "<span class='notice'>You rise with a start, you're alive!!!</span>"
|
||||
|
||||
/obj/item/projectile/magic/teleport
|
||||
name = "bolt of teleportation"
|
||||
icon_state = "bluespace"
|
||||
damage = 0
|
||||
damage_type = OXY
|
||||
nodamage = 1
|
||||
flag = "magic"
|
||||
var/inner_tele_radius = 0
|
||||
var/outer_tele_radius = 6
|
||||
|
||||
/obj/item/projectile/magic/teleport/on_hit(var/mob/target)
|
||||
var/teleammount = 0
|
||||
var/teleloc = target
|
||||
if(!isturf(target))
|
||||
teleloc = target.loc
|
||||
for(var/atom/movable/stuff in teleloc)
|
||||
if(!stuff.anchored && stuff.loc)
|
||||
teleammount++
|
||||
do_teleport(stuff, stuff, 10)
|
||||
var/datum/effect/effect/system/harmless_smoke_spread/smoke = new /datum/effect/effect/system/harmless_smoke_spread()
|
||||
smoke.set_up(max(round(10 - teleammount),1), 0, stuff.loc) //Smoke drops off if a lot of stuff is moved for the sake of sanity
|
||||
smoke.start()
|
||||
|
||||
/obj/item/projectile/magic/door
|
||||
name = "bolt of door creation"
|
||||
icon_state = "energy"
|
||||
damage = 0
|
||||
damage_type = OXY
|
||||
nodamage = 1
|
||||
flag = "magic"
|
||||
|
||||
/obj/item/projectile/magic/door/on_hit(var/atom/target)
|
||||
var/atom/T = target.loc
|
||||
if(isturf(target))
|
||||
if(target.density)
|
||||
new /obj/structure/mineral_door/wood(target)
|
||||
target:ChangeTurf(/turf/simulated/floor/plating)
|
||||
else if (isturf(T))
|
||||
if(T.density)
|
||||
new /obj/structure/mineral_door/wood(T)
|
||||
T:ChangeTurf(/turf/simulated/floor/plating)
|
||||
|
||||
/obj/item/projectile/magic/change
|
||||
name = "bolt of change"
|
||||
icon_state = "ice_1"
|
||||
damage = 0
|
||||
damage_type = BURN
|
||||
nodamage = 1
|
||||
flag = "magic"
|
||||
|
||||
/obj/item/projectile/magic/change/on_hit(var/atom/change)
|
||||
wabbajack(change)
|
||||
|
||||
proc/wabbajack(mob/living/M)
|
||||
if(istype(M))
|
||||
if(istype(M, /mob/living) && M.stat != DEAD)
|
||||
if(M.monkeyizing) return
|
||||
M.monkeyizing = 1
|
||||
M.canmove = 0
|
||||
M.icon = null
|
||||
M.overlays.Cut()
|
||||
M.invisibility = 101
|
||||
|
||||
if(istype(M, /mob/living/silicon/robot))
|
||||
var/mob/living/silicon/robot/Robot = M
|
||||
if(Robot.mmi) del(Robot.mmi)
|
||||
else
|
||||
for(var/obj/item/W in M)
|
||||
if(istype(W, /obj/item/weapon/implant)) //TODO: Carn. give implants a dropped() or something
|
||||
del(W)
|
||||
continue
|
||||
W.layer = initial(W.layer)
|
||||
W.loc = M.loc
|
||||
W.dropped(M)
|
||||
|
||||
var/mob/living/new_mob
|
||||
|
||||
var/randomize = pick("monkey","robot","slime","xeno","human","animal")
|
||||
switch(randomize)
|
||||
if("monkey")
|
||||
new_mob = new /mob/living/carbon/monkey(M.loc)
|
||||
new_mob.universal_speak = 1
|
||||
if("robot")
|
||||
new_mob = new /mob/living/silicon/robot(M.loc)
|
||||
new_mob.gender = M.gender
|
||||
new_mob.invisibility = 0
|
||||
new_mob.job = "Cyborg"
|
||||
var/mob/living/silicon/robot/Robot = new_mob
|
||||
Robot.mmi = new /obj/item/device/mmi(new_mob)
|
||||
Robot.mmi.transfer_identity(M) //Does not transfer key/client.
|
||||
if("slime")
|
||||
if(prob(50)) new_mob = new /mob/living/carbon/slime/adult(M.loc)
|
||||
else new_mob = new /mob/living/carbon/slime(M.loc)
|
||||
new_mob.universal_speak = 1
|
||||
if("xeno")
|
||||
if(prob(50))
|
||||
new_mob = new /mob/living/carbon/alien/humanoid/hunter(M.loc)
|
||||
else
|
||||
new_mob = new /mob/living/carbon/alien/humanoid/sentinel(M.loc)
|
||||
new_mob.universal_speak = 1
|
||||
|
||||
/*var/alien_caste = pick("Hunter","Sentinel","Drone","Larva")
|
||||
switch(alien_caste)
|
||||
if("Hunter") new_mob = new /mob/living/carbon/alien/humanoid/hunter(M.loc)
|
||||
if("Sentinel") new_mob = new /mob/living/carbon/alien/humanoid/sentinel(M.loc)
|
||||
if("Drone") new_mob = new /mob/living/carbon/alien/humanoid/drone(M.loc)
|
||||
else new_mob = new /mob/living/carbon/alien/larva(M.loc)
|
||||
new_mob.universal_speak = 1*/
|
||||
if("animal")
|
||||
var/animal = pick("parrot","corgi","crab","pug","cat","carp","bear","mushroom","tomato","mouse","chicken","cow","lizard","chick")
|
||||
switch(animal)
|
||||
if("parrot") new_mob = new /mob/living/simple_animal/parrot(M.loc)
|
||||
if("corgi") new_mob = new /mob/living/simple_animal/corgi(M.loc)
|
||||
if("crab") new_mob = new /mob/living/simple_animal/crab(M.loc)
|
||||
// if("pug") new_mob = new /mob/living/simple_animal/pug(M.loc)
|
||||
if("cat") new_mob = new /mob/living/simple_animal/cat(M.loc)
|
||||
if("carp") new_mob = new /mob/living/simple_animal/hostile/carp(M.loc)
|
||||
if("bear") new_mob = new /mob/living/simple_animal/hostile/bear(M.loc)
|
||||
if("mushroom") new_mob = new /mob/living/simple_animal/mushroom(M.loc)
|
||||
if("tomato") new_mob = new /mob/living/simple_animal/tomato(M.loc)
|
||||
if("mouse") new_mob = new /mob/living/simple_animal/mouse(M.loc)
|
||||
if("chicken") new_mob = new /mob/living/simple_animal/chicken(M.loc)
|
||||
if("cow") new_mob = new /mob/living/simple_animal/cow(M.loc)
|
||||
if("lizard") new_mob = new /mob/living/simple_animal/lizard(M.loc)
|
||||
else new_mob = new /mob/living/simple_animal/chick(M.loc)
|
||||
new_mob.universal_speak = 1
|
||||
if("human")
|
||||
new_mob = new /mob/living/carbon/human/human(M.loc)
|
||||
|
||||
var/datum/preferences/A = new() //Randomize appearance for the human
|
||||
A.copy_to(new_mob)
|
||||
|
||||
var/mob/living/carbon/human/human/H = new_mob
|
||||
// ready_dna(H)
|
||||
if(H.dna)
|
||||
H.dna.mutantrace = pick("lizard","golem","slime","plant","fly","shadow","adamantine","skeleton",8;"")
|
||||
H.update_body()
|
||||
else
|
||||
return
|
||||
|
||||
for (var/obj/effect/proc_holder/spell/S in M.spell_list)
|
||||
new_mob.spell_list += new S.type
|
||||
|
||||
new_mob.a_intent = "harm"
|
||||
if(M.mind)
|
||||
M.mind.transfer_to(new_mob)
|
||||
else
|
||||
new_mob.key = M.key
|
||||
|
||||
new_mob << "<B>Your form morphs into that of a [randomize].</B>"
|
||||
|
||||
del(M)
|
||||
return new_mob
|
||||
|
||||
/obj/item/projectile/magic/animate
|
||||
name = "bolt of animation"
|
||||
icon_state = "red_1"
|
||||
damage = 0
|
||||
damage_type = BURN
|
||||
nodamage = 1
|
||||
flag = "magic"
|
||||
|
||||
/obj/item/projectile/magic/animate/Bump(var/atom/change)
|
||||
. = ..()
|
||||
if(istype(change, /obj/item) || istype(change, /obj/structure) && !is_type_in_list(change, protected_objects))
|
||||
var/obj/O = change
|
||||
new /mob/living/simple_animal/hostile/mimic/copy(O.loc, O, firer)
|
||||
else if(istype(change, /mob/living/simple_animal/hostile/mimic/copy))
|
||||
// Change our allegiance!
|
||||
var/mob/living/simple_animal/hostile/mimic/copy/C = change
|
||||
C.ChangeOwner(firer)
|
||||
Reference in New Issue
Block a user