[Cult 3.0] Fervor & Blood Magnetism, Runes XIV & XV (#19401)

* fervor&bloodmagnetism

* paths

* tome open
This commit is contained in:
DeityLink
2018-08-25 03:21:27 +02:00
committed by MadmanMartian
parent c707c264c7
commit 7f430f7fc5
14 changed files with 581 additions and 26 deletions

View File

@@ -654,6 +654,9 @@ var/list/liftable_structures = list(\
#define SEE_INVISIBLE_LEVEL_TWO 45 //Used by mobs under certain conditions. #define SEE_INVISIBLE_LEVEL_TWO 45 //Used by mobs under certain conditions.
#define INVISIBILITY_LEVEL_TWO 45 //Used by turrets inside their covers. #define INVISIBILITY_LEVEL_TWO 45 //Used by turrets inside their covers.
#define INVISIBILITY_CULTJAUNT 50 //Used by cult
#define SEE_INVISIBLE_CULTJAUNT 50 //Used by cult
#define INVISIBILITY_OBSERVER 60 //Used by Ghosts. #define INVISIBILITY_OBSERVER 60 //Used by Ghosts.
#define SEE_INVISIBLE_OBSERVER 60 //Used by Ghosts. #define SEE_INVISIBLE_OBSERVER 60 //Used by Ghosts.

View File

@@ -0,0 +1,264 @@
///////////////////////////////////////CULT RITUALS////////////////////////////////////////////////
//Effects spawned by rune spells
/obj/effect/cult_ritual
icon = 'icons/effects/effects.dmi'
icon_state = ""
anchored = 1
mouse_opacity = 0
/obj/effect/cult_ritual/cultify()
return
/obj/effect/cult_ritual/ex_act()
return
/obj/effect/cult_ritual/emp_act()
return
/obj/effect/cult_ritual/blob_act()
return
/obj/effect/cult_ritual/singularity_act()
return
///////////////////////////////////////JAUNT////////////////////////////////////////////////
//Cultists ride in those when teleporting
/obj/effect/bloodcult_jaunt
mouse_opacity = 0
icon = 'icons/effects/96x96.dmi'
icon_state ="cult_jaunt"
invisibility = INVISIBILITY_CULTJAUNT
alpha = 127
layer = NARSIE_GLOW
plane = LIGHTING_PLANE
pixel_x = -WORLD_ICON_SIZE
pixel_y = -WORLD_ICON_SIZE
animate_movement = 0
var/atom/movable/rider = null
var/turf/starting = null
var/turf/target = null
var/dist_x = 0
var/dist_y = 0
var/dx = 0
var/dy = 0
var/error = 0
var/target_angle = 0
var/override_starting_X = 0
var/override_starting_Y = 0
var/override_target_X = 0
var/override_target_Y = 0
//update_pixel stuff
var/PixelX = 0
var/PixelY = 0
var/initial_pixel_x = 0
var/initial_pixel_y = 0
var/atom/movable/overlay/landing_animation = null
var/landing = 0
/obj/effect/bloodcult_jaunt/New(var/turf/loc, var/mob/user, var/turf/destination)
..()
user.forceMove(src)
rider = user
if (ismob(rider))
var/mob/M = rider
M.see_invisible = SEE_INVISIBLE_CULTJAUNT
M.see_invisible_override = SEE_INVISIBLE_CULTJAUNT
M.apply_vision_overrides()
rider.flags |= INVULNERABLE//let's not forget to turn that off later
starting = loc
target = destination
initial_pixel_x = pixel_x
initial_pixel_y = pixel_y
//first of all, if our target is off Z-Level, we're immediately teleporting to the edge of the map closest to the target
if (target.z != z)
move_to_edge()
//quickly making sure that we're not jaunting to where we are
bump_target_check()
if (!src||!loc)
return
//next, let's rotate the jaunter's sprite to face our destination
init_angle()
//now, let's launch the jaunter at our target
init_jaunt()
/obj/effect/bloodcult_jaunt/Destroy()
if (rider)
qdel(rider)
rider = null
..()
/obj/effect/bloodcult_jaunt/cultify()
return
/obj/effect/bloodcult_jaunt/ex_act()
return
/obj/effect/bloodcult_jaunt/emp_act()
return
/obj/effect/bloodcult_jaunt/blob_act()
return
/obj/effect/bloodcult_jaunt/singularity_act()
return
/obj/effect/bloodcult_jaunt/to_bump(var/atom/A)
forceMove(get_step(loc,dir))
bump_target_check()
/obj/effect/bloodcult_jaunt/proc/move_to_edge()
var/target_x
var/target_y
var/dx = abs(target.x - world.maxx/2)
var/dy = abs(target.y - world.maxy/2)
if (dx > dy)
target_y = world.maxy/2 + rand(-4,4)
if (target.x > world.maxx/2)
target_x = world.maxx - TRANSITIONEDGE - rand(16,20)
else
target_x = TRANSITIONEDGE + rand(16,20)
else
target_x = world.maxx/2 + rand(-4,4)
if (target.y > world.maxy/2)
target_y = world.maxy - TRANSITIONEDGE - rand(16,20)
else
target_y = TRANSITIONEDGE + rand(16,20)
to_chat(world,"target at ([target.x],[target.y],[target.z]), (dx/dy)=([dx]/[dy]) so we're tp'ing at ([target_x],[target_y],[target.z])")
var/turf/T = locate(target_x,target_y,target.z)
starting = T
forceMove(T)
/obj/effect/bloodcult_jaunt/proc/init_angle()
dist_x = abs(target.x - starting.x)
dist_y = abs(target.y - starting.y)
override_starting_X = starting.x
override_starting_Y = starting.y
override_target_X = target.x
override_target_Y = target.y
if (target.x > starting.x)
dx = EAST
else
dx = WEST
if (target.y > starting.y)
dy = NORTH
else
dy = SOUTH
if(dist_x > dist_y)
error = dist_x/2 - dist_y
else
error = dist_y/2 - dist_x
target_angle = round(Get_Angle(starting,target))
if( !("[icon_state]_angle[target_angle]" in bullet_master) )//totally hijacking my own bullet code in case that wasn't already obvious.
var/icon/I = new(icon,icon_state)
I.Turn(target_angle+45)
bullet_master["[icon_state]_angle[target_angle]"] = I
icon = bullet_master["[icon_state]_angle[target_angle]"]
/obj/effect/bloodcult_jaunt/proc/update_pixel()
if(src && starting && target)
var/AX = (override_starting_X - src.x)*WORLD_ICON_SIZE
var/AY = (override_starting_Y - src.y)*WORLD_ICON_SIZE
var/BX = (override_target_X - src.x)*WORLD_ICON_SIZE
var/BY = (override_target_Y - src.y)*WORLD_ICON_SIZE
var/XXcheck = ((BX-AX)*(BX-AX))+((BY-AY)*(BY-AY))
if(!XXcheck)
return
var/XX = (((BX-AX)*(-BX))+((BY-AY)*(-BY)))/XXcheck
PixelX = round(BX+((BX-AX)*XX))
PixelY = round(BY+((BY-AY)*XX))
PixelX += initial_pixel_x
PixelY += initial_pixel_y
pixel_x = PixelX
pixel_y = PixelY
/obj/effect/bloodcult_jaunt/proc/bresenham_step(var/distA, var/distB, var/dA, var/dB)
var/dist = get_dist(src,target)
if (dist > 135)
make_bresenham_step(distA, distB, dA, dB)
if (dist > 45)
make_bresenham_step(distA, distB, dA, dB)
if (dist > 15)
make_bresenham_step(distA, distB, dA, dB)
if (dist < 10 && !landing)
landing = 1
playsound(src.target, 'sound/effects/cultjaunt_prepare.ogg', 75, 0, -3)
landing_animation = anim(target = src.target, a_icon = 'icons/effects/effects.dmi', flick_anim = "cult_jaunt_prepare", lay = SNOW_OVERLAY_LAYER, plane = EFFECTS_PLANE)
return make_bresenham_step(distA, distB, dA, dB)
/obj/effect/bloodcult_jaunt/proc/make_bresenham_step(var/distA, var/distB, var/dA, var/dB)
if(error < 0)
var/atom/step = get_step(src, dB)
if(!step)
qdel(src)
src.Move(step)
error += distA
bump_target_check()
return 0//so that bullets going in diagonals don't move twice slower
else
var/atom/step = get_step(src, dA)
if(!step)
qdel(src)
src.Move(step)
error -= distB
dir = dA
if(error < 0)
dir = dA + dB
bump_target_check()
return 1
/obj/effect/bloodcult_jaunt/proc/process_step()
var/sleeptime = 1
if(src.loc)
if(dist_x > dist_y)
sleeptime = bresenham_step(dist_x,dist_y,dx,dy)
else
sleeptime = bresenham_step(dist_y,dist_x,dy,dx)
update_pixel()
sleep(sleeptime)
/obj/effect/bloodcult_jaunt/proc/init_jaunt()
if (!rider)
qdel(src)
return
spawn while(loc)
if (ismob(rider))
var/mob/M = rider
M.delayNextAttack(3)
M.click_delayer.setDelay(3)
process_step()
/obj/effect/bloodcult_jaunt/proc/bump_target_check()
if (loc == target)
playsound(loc, 'sound/effects/cultjaunt_land.ogg', 50, 0, -3)
rider.forceMove(target)
rider.flags &= ~INVULNERABLE
if (ismob(rider))
var/mob/M = rider
M.see_invisible = SEE_INVISIBLE_LIVING
M.see_invisible_override = 0
M.apply_vision_overrides()
rider = null
if (landing_animation)
flick("cult_jaunt_land",landing_animation)
qdel(src)

View File

@@ -79,7 +79,7 @@ var/list/arcane_tomes = list()
talisman_name = "\[blood message\]" talisman_name = "\[blood message\]"
if (instance) if (instance)
talisman_name = initial(instance.name) talisman_name = initial(instance.name)
dat += {"<label> * </label><li> <a style="color:#AE250F" href='byond://?src=\ref[src];talisman=\ref[T]'>[talisman_name]</a> <a style="color:#AE250F" href='byond://?src=\ref[src];remove=\ref[T]'>(x)</a> </li>"} dat += {"<label> * </label><li> <a style="color:#AE250F" href='byond://?src=\ref[src];talisman=\ref[T]'>[talisman_name][(T.uses > 1) ? " [T.uses] uses" : ""]</a> <a style="color:#AE250F" href='byond://?src=\ref[src];remove=\ref[T]'>(x)</a> </li>"}
dat += {"</ul></b></div><div style="margin: 0px 20px;" align="justify">"} dat += {"</ul></b></div><div style="margin: 0px 20px;" align="justify">"}
@@ -128,7 +128,7 @@ var/list/arcane_tomes = list()
usr.put_in_hands(T) usr.put_in_hands(T)
usr << browse_rsc('icons/tomebg.png', "tomebg.png") usr << browse_rsc('icons/tomebg.png', "tomebg.png")
usr << browse(tome_text(), "window=arcanetome;size=512x375") usr << browse(tome_text(), "window=arcanetome;size=537x375")
/obj/item/weapon/tome/attack(var/mob/living/M, var/mob/living/user) /obj/item/weapon/tome/attack(var/mob/living/M, var/mob/living/user)
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has had the [name] used on him by [user.name] ([user.ckey])</font>") M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has had the [name] used on him by [user.name] ([user.ckey])</font>")
@@ -170,7 +170,7 @@ var/list/arcane_tomes = list()
/obj/item/weapon/tome/pickup(var/mob/user) /obj/item/weapon/tome/pickup(var/mob/user)
if(iscultist(user) && state == TOME_OPEN) if(iscultist(user) && state == TOME_OPEN)
usr << browse_rsc('icons/tomebg.png', "tomebg.png") usr << browse_rsc('icons/tomebg.png', "tomebg.png")
usr << browse(tome_text(), "window=arcanetome;size=512x375") usr << browse(tome_text(), "window=arcanetome;size=537x375")
/obj/item/weapon/tome/dropped(var/mob/user) /obj/item/weapon/tome/dropped(var/mob/user)
usr << browse(null, "window=arcanetome") usr << browse(null, "window=arcanetome")
@@ -232,7 +232,7 @@ var/list/arcane_tomes = list()
to_chat(user, "<span class='notice'>You slip \the [I] into \the [src].</span>") to_chat(user, "<span class='notice'>You slip \the [I] into \the [src].</span>")
if (state == TOME_OPEN) if (state == TOME_OPEN)
usr << browse_rsc('icons/tomebg.png', "tomebg.png") usr << browse_rsc('icons/tomebg.png', "tomebg.png")
usr << browse(tome_text(), "window=arcanetome;size=512x375") usr << browse(tome_text(), "window=arcanetome;size=537x375")
else else
to_chat(user, "<span class='warning'>This tome cannot contain any more talismans. Use or remove some first.</span>") to_chat(user, "<span class='warning'>This tome cannot contain any more talismans. Use or remove some first.</span>")
@@ -328,7 +328,7 @@ var/list/arcane_tomes = list()
var/obj/item/weapon/tome/T = loc var/obj/item/weapon/tome/T = loc
T.talismans.Remove(src) T.talismans.Remove(src)
user << browse_rsc('icons/tomebg.png', "tomebg.png") user << browse_rsc('icons/tomebg.png', "tomebg.png")
user << browse(T.tome_text(), "window=arcanetome;size=512x375") user << browse(T.tome_text(), "window=arcanetome;size=537x375")
return return
if (attuned_rune) if (attuned_rune)
@@ -614,8 +614,8 @@ var/list/arcane_tomes = list()
///////////////////////////////////////DEBUG ITEM (FOR NOW)//////////////////////////////////////////////// ///////////////////////////////////////DEBUG ITEMS////////////////////////////////////////////////
//Pamphlet: turns you into a cultist
/obj/item/weapon/bloodcult_pamphlet /obj/item/weapon/bloodcult_pamphlet
name = "cult of Nar-Sie pamphlet" name = "cult of Nar-Sie pamphlet"
desc = "Looks like a page torn from a tome. One glimpse at it surely can't hurt you." desc = "Looks like a page torn from a tome. One glimpse at it surely can't hurt you."
@@ -642,6 +642,29 @@ var/list/arcane_tomes = list()
newCultist.OnPostSetup(FALSE) newCultist.OnPostSetup(FALSE)
newCultist.Greet(GREET_PAMPHLET) newCultist.Greet(GREET_PAMPHLET)
//Jaunter: creates a pylon on spawn, lets you teleport to it on use
/obj/item/weapon/bloodcult_jaunter
name = "test jaunter"
desc = ""
icon = 'icons/obj/wizard.dmi'
icon_state ="soulstone"
var/obj/structure/bloodcult_jaunt_target/target = null
/obj/item/weapon/bloodcult_jaunter/New()
..()
target = new(loc)
/obj/item/weapon/bloodcult_jaunter/attack_self(var/mob/user)
new /obj/effect/bloodcult_jaunt(get_turf(src),user,get_turf(target))
/obj/structure/bloodcult_jaunt_target
name = "test target"
desc = ""
icon = 'icons/obj/cult.dmi'
icon_state ="pylon"
anchored = 1
density = 0
///////////////////////////////////////CULT BOX//////////////////////////////////////////////// ///////////////////////////////////////CULT BOX////////////////////////////////////////////////
/obj/item/weapon/storage/cult /obj/item/weapon/storage/cult
@@ -768,3 +791,4 @@ var/list/arcane_tomes = list()
user.equip_to_slot_or_drop(stored_slot,nslot) user.equip_to_slot_or_drop(stored_slot,nslot)
stored_gear.Remove(slot) stored_gear.Remove(slot)
qdel(src) qdel(src)

View File

@@ -60,7 +60,6 @@ var/list/uristrune_cache = list()//icon cache, so the whole blending process is
rune_list.Add(src) rune_list.Add(src)
/obj/effect/rune/Destroy() /obj/effect/rune/Destroy()
for(var/mob/living/silicon/ai/AI in player_list) for(var/mob/living/silicon/ai/AI in player_list)
if (AI.client) if (AI.client)
AI.client.images -= blood_image AI.client.images -= blood_image

View File

@@ -94,6 +94,9 @@
qdel(src) qdel(src)
/datum/rune_spell/proc/abort(var/cause) /datum/rune_spell/proc/abort(var/cause)
if (destroying_self)
return
destroying_self = 1
switch (cause) switch (cause)
if (RITUALABORT_ERASED) if (RITUALABORT_ERASED)
if (istype (spell_holder,/obj/effect/rune)) if (istype (spell_holder,/obj/effect/rune))
@@ -196,6 +199,7 @@
You may use them to trap the souls of defeated foes, or channel those the dead. You can make even better use of them after raising a forge, and placing them \ You may use them to trap the souls of defeated foes, or channel those the dead. You can make even better use of them after raising a forge, and placing them \
inside a Construct Shell, or a Cult Blade. Lastly, raising an Arcaneum will let you permanently imbue your skin with a gift from Nar Sie. Follow your purpose \ inside a Construct Shell, or a Cult Blade. Lastly, raising an Arcaneum will let you permanently imbue your skin with a gift from Nar Sie. Follow your purpose \
and you may see even more gifts come your way." and you may see even more gifts come your way."
var/turf/loc_memory = null
/datum/rune_spell/raisestructure/cast() /datum/rune_spell/raisestructure/cast()
var/obj/effect/rune/R = spell_holder var/obj/effect/rune/R = spell_holder
@@ -205,6 +209,7 @@
abort(RITUALABORT_BLOCKED) abort(RITUALABORT_BLOCKED)
return return
loc_memory = spell_holder.loc
var/mob/living/user = activator var/mob/living/user = activator
contributors.Add(user) contributors.Add(user)
update_progbar() update_progbar()
@@ -265,8 +270,8 @@
else else
cancelling-- cancelling--
if (cancelling <= 0) if (cancelling <= 0)
if(accumulated_blood && !(locate(/obj/effect/decal/cleanable/blood/splatter) in spell_holder.loc)) if(accumulated_blood && !(locate(/obj/effect/decal/cleanable/blood/splatter) in loc_memory))
var/obj/effect/decal/cleanable/blood/splatter/S = new(spell_holder.loc)//splash var/obj/effect/decal/cleanable/blood/splatter/S = new (loc_memory)//splash
S.amount = 2 S.amount = 2
abort(RITUALABORT_BLOOD) abort(RITUALABORT_BLOOD)
return return
@@ -395,19 +400,6 @@
source.abort(RITUALABORT_GONE) source.abort(RITUALABORT_GONE)
qdel(src) qdel(src)
/obj/effect/cult_ritual/cultify()
return
/obj/effect/cult_ritual/ex_act(var/severity)
return
/obj/effect/cult_ritual/emp_act()
return
/obj/effect/cult_ritual/blob_act()
return
//RUNE III //RUNE III
/datum/rune_spell/summontome /datum/rune_spell/summontome
name = "Summon Tome" name = "Summon Tome"
@@ -601,7 +593,7 @@
if (target.state == TOME_OPEN && ismob(target.loc)) if (target.state == TOME_OPEN && ismob(target.loc))
var/mob/M = target.loc var/mob/M = target.loc
M << browse_rsc('icons/tomebg.png', "tomebg.png") M << browse_rsc('icons/tomebg.png', "tomebg.png")
M << browse(target.tome_text(), "window=arcanetome;size=512x375") M << browse(target.tome_text(), "window=arcanetome;size=537x375")
else else
to_chat(activator, "<span class='warning'>This tome cannot contain any more talismans.</span>") to_chat(activator, "<span class='warning'>This tome cannot contain any more talismans.</span>")
qdel(src) qdel(src)
@@ -1443,10 +1435,12 @@ var/list/blind_victims = list()
var/mob/living/M = activator var/mob/living/M = activator
M.see_invisible_override = SEE_INVISIBLE_OBSERVER M.see_invisible_override = SEE_INVISIBLE_OBSERVER
M.apply_vision_overrides() M.apply_vision_overrides()
to_chat(M, "<span class='notice'>As the talisman disappears into dust, you find yourself able to see through the gaps in the veil. You can see and interact with the other side, for a few seconds.</span>")
anim(target = M, a_icon = 'icons/effects/160x160.dmi', a_icon_state = "rune_seer", lay = ABOVE_OBJ_LAYER, offX = -WORLD_ICON_SIZE*2, offY = -WORLD_ICON_SIZE*2, plane = OBJ_PLANE, invis = INVISIBILITY_OBSERVER, alph = 200, sleeptime = talisman_duration) anim(target = M, a_icon = 'icons/effects/160x160.dmi', a_icon_state = "rune_seer", lay = ABOVE_OBJ_LAYER, offX = -WORLD_ICON_SIZE*2, offY = -WORLD_ICON_SIZE*2, plane = OBJ_PLANE, invis = INVISIBILITY_OBSERVER, alph = 200, sleeptime = talisman_duration)
spawn(talisman_duration) spawn(talisman_duration)
M.see_invisible_override = 0 M.see_invisible_override = 0
M.apply_vision_overrides() M.apply_vision_overrides()
to_chat(M, "<span class='notice'>You can no longer discern through the veil.</span>")
qdel(src) qdel(src)
/obj/effect/cult_ritual/seer /obj/effect/cult_ritual/seer
@@ -1476,11 +1470,13 @@ var/list/blind_victims = list()
return return
caster.see_invisible_override = SEE_INVISIBLE_OBSERVER caster.see_invisible_override = SEE_INVISIBLE_OBSERVER
caster.apply_vision_overrides() caster.apply_vision_overrides()
to_chat(caster, "<span class='notice'>You find yourself able to see through the gaps in the veil. You can see and interact with the other side.</span>")
/obj/effect/cult_ritual/seer/Destroy() /obj/effect/cult_ritual/seer/Destroy()
if (caster) if (caster)
caster.see_invisible_override = 0 caster.see_invisible_override = 0
caster.apply_vision_overrides() caster.apply_vision_overrides()
to_chat(caster, "<span class='notice'>You can no longer discern through the veil.</span>")
caster = null caster = null
source = null source = null
..() ..()
@@ -1559,6 +1555,8 @@ var/list/blind_victims = list()
activator.equip_to_slot_or_drop(new_pack, slot_back) activator.equip_to_slot_or_drop(new_pack, slot_back)
activator.put_in_hands(BT) activator.put_in_hands(BT)
to_chat(activator, "<span class='notice'>Robes and gear of the followers of Nar-Sie manifests around your body. You feel empowered.</span>")
to_chat(activator, "<span class='notice'>You \a [BT] materializes in your hand, you may use it to instantly swap back into your stored clothing.</span>")
qdel(src) qdel(src)
@@ -1593,21 +1591,287 @@ var/list/blind_victims = list()
/datum/rune_spell/fervor /datum/rune_spell/fervor
name = "Fervor" name = "Fervor"
desc = "Inspire nearby cultists to purge their stuns and raise their movement speed." desc = "Inspire nearby cultists to purge their stuns and raise their movement speed."
desc_talisman = "Use to inspire nearby cultists to purge their stuns and raise their movement speed."
Act_restriction = CULT_ACT_II Act_restriction = CULT_ACT_II
invocation = "Khari'd! Gual'te nikka!" invocation = "Khari'd! Gual'te nikka!"
word1 = /datum/cultword/travel word1 = /datum/cultword/travel
word2 = /datum/cultword/technology word2 = /datum/cultword/technology
word3 = /datum/cultword/other word3 = /datum/cultword/other
page = ""
cost_invoke = 20
var/effect_range = 7
/datum/rune_spell/fervor/cast()
var/obj/effect/rune/R = spell_holder
if (istype(R))
R.one_pulse()
if (blood_pay())
for(var/mob/living/L in range(effect_range,get_turf(spell_holder)))
if(L.stat != DEAD && iscultist(L))
playsound(L, 'sound/effects/fervor.ogg', 50, 0, -2)
anim(target = L, a_icon = 'icons/effects/effects.dmi', flick_anim = "rune_fervor", lay = NARSIE_GLOW, plane = LIGHTING_PLANE, direction = L.dir)
L.oxyloss = 0
L.halloss = 0
L.paralysis = 0
L.stunned = 0
L.knockdown = 0
L.remove_jitter()
L.next_pain_time = 0
L.bodytemperature = 310
L.blinded = 0
L.eye_blind = 0
L.eye_blurry = 0
L.ear_deaf = 0
L.ear_damage = 0
L.say_mute = 0
if(istype(L, /mob/living/carbon/human))
var/mob/living/carbon/human/H = L
H.pain_shock_stage = 0
L.update_canmove()
L.stat = CONSCIOUS
L.reagents.del_reagent(HOLYWATER)
L.reagents.add_reagent(HYPERZINE,1)
qdel(spell_holder)
qdel(src)
//RUNE XV //RUNE XV
/datum/rune_spell/summoncultist /datum/rune_spell/summoncultist
name = "Summon Cultist" name = "Blood Magnetism"
desc = "Bring forth one of your fellow believers, no matter how far they are, as long as their heart beats" desc = "Bring forth one of your fellow believers, no matter how far they are, as long as their heart beats"
Act_restriction = CULT_ACT_II Act_restriction = CULT_ACT_II
invocation = "N'ath reth sh'yro eth d'rekkathnor!" invocation = "N'ath reth sh'yro eth d'rekkathnor!"
word1 = /datum/cultword/join word1 = /datum/cultword/join
word2 = /datum/cultword/other word2 = /datum/cultword/other
word3 = /datum/cultword/self word3 = /datum/cultword/self
page = ""
remaining_cost = 10
cost_upkeep = 1
var/rejoin = 0
var/mob/target = null
var/list/feet_portals = list()
var/cost_summon = 50//you probably don't want to pay that up alone
var/cost_rejoin = 15//static cost for every contributor
/datum/rune_spell/summoncultist/Destroy()
target = null
for (var/guy in feet_portals)
var/obj/O = feet_portals[guy]
qdel(O)
feet_portals -= guy
feet_portals = list()
spell_holder.overlays -= image('icons/obj/cult.dmi',"runetrigger-build")
spell_holder.overlays -= image('icons/effects/effects.dmi',"rune_summon")
..()
/datum/rune_spell/summoncultist/abort()
for (var/guy in feet_portals)
var/obj/O = feet_portals[guy]
qdel(O)
..()
/datum/rune_spell/summoncultist/cast()
var/obj/effect/rune/R = spell_holder
R.one_pulse()
rejoin = alert(activator, "Will you pull them toward you, or pull yourself toward them?","Blood Magnetism","Summon Cultist","Rejoin Cultist") == "Rejoin Cultist"
var/list/possible_targets = list()
var/datum/faction/bloodcult = find_active_faction(BLOODCULT)
for(var/datum/role/cultist/C in bloodcult.members)
var/datum/mind/M = C.antag
possible_targets.Add(M.current)
var/list/annotated_targets = list()
var/list/visible_mobs = viewers(activator)
var/i = 1
for(var/mob/M in possible_targets)
var/status = ""
if(M == activator)
status = " (You)"
else if(M in visible_mobs)
status = " (Visible)"
else if(M.isDead())
status = " (Dead)"
annotated_targets["\Roman[i]-[M.real_name][status]"] = M
i++
var/choice = input(activator, "Choose who you wish to [rejoin ? "rejoin" : "summon"]", "Blood Magnetism") as null|anything in annotated_targets
if (!choice)
qdel(src)
return
target = annotated_targets[choice]
if (!target)
qdel(src)
return
contributors.Add(activator)
update_progbar()
if (activator.client)
activator.client.images |= progbar
spell_holder.overlays += image('icons/obj/cult.dmi',"runetrigger-build")
if (!rejoin)
spell_holder.overlays += image('icons/effects/effects.dmi',"rune_summon")
else
feet_portals.Add(activator)
var/obj/effect/cult_ritual/feet_portal/P = new (activator.loc, activator, src)
feet_portals[activator] = P
to_chat(activator, "<span class='rose'>This ritual's blood toll can be substantially reduced by having multiple cultists partake in it.</span>")
spawn()
payment()
/datum/rune_spell/summoncultist/cast_talisman()//we spawn an invisible rune under our feet that works like the regular one
var/obj/effect/rune/R = new(get_turf(activator))
R.icon_state = "temp"
R.active_spell = new type(activator,R)
qdel(src)
/datum/rune_spell/summoncultist/midcast(var/mob/add_cultist)
if (add_cultist in contributors)
return
add_cultist.say(invocation)
contributors.Add(add_cultist)
if (add_cultist.client)
add_cultist.client.images |= progbar
if (rejoin)
feet_portals.Add(add_cultist)
var/obj/effect/cult_ritual/feet_portal/P = new (add_cultist.loc, add_cultist, src)
feet_portals[add_cultist] = P
/datum/rune_spell/summoncultist/abort(var/cause)
spell_holder.overlays -= image('icons/obj/cult.dmi',"runetrigger-build")
spell_holder.overlays -= image('icons/effects/effects.dmi',"rune_summon")
..()
/datum/rune_spell/summoncultist/proc/payment()//an extra payment is spent at the end of the channeling, and shared between contributors
var/failsafe = 0
while(failsafe < 1000)
failsafe++
//are our payers still here and about?
for(var/mob/living/L in contributors)
if (!iscultist(L) || !(L in range(spell_holder,1)) || (L.stat != CONSCIOUS))
if (L.client)
L.client.images -= progbar
var/obj/effect/cult_ritual/feet_portal/P = feet_portals[L]
qdel(P)
feet_portals.Remove(L)
contributors.Remove(L)
//alright then, time to pay in blood
var/amount_paid = 0
for(var/mob/living/L in contributors)
var/data = use_available_blood(L, cost_upkeep/contributors.len,contributors[L])//always 1u total per payment
if (data[BLOODCOST_RESULT] == BLOODCOST_FAILURE)//out of blood are we?
contributors.Remove(L)
var/obj/effect/cult_ritual/feet_portal/P = feet_portals[L]
qdel(P)
feet_portals.Remove(L)
else
amount_paid += data[BLOODCOST_TOTAL]
contributors[L] = data[BLOODCOST_RESULT]
make_tracker_effects(L.loc,spell_holder, 1, "soul", 3, /obj/effect/tracker/drain, 1)//visual feedback
accumulated_blood += amount_paid
//if there's no blood for over 3 seconds, the channeling fails
if (amount_paid)
cancelling = 3
else
cancelling--
if (cancelling <= 0)
if(accumulated_blood && !(locate(/obj/effect/decal/cleanable/blood/splatter) in spell_holder.loc))
var/obj/effect/decal/cleanable/blood/splatter/S = new(spell_holder.loc)//splash
S.amount = 2
abort(RITUALABORT_BLOOD)
return
if (accumulated_blood >= remaining_cost)
success()
return
update_progbar()
sleep(10)
message_admins("A rune ritual has iterated for over 1000 blood payment procs. Something's wrong there.")
/datum/rune_spell/summoncultist/proc/success()
if (rejoin)
var/list/valid_turfs = list()
for(var/turf/T in orange(target,1))
if(!T.has_dense_content())
valid_turfs.Add(T)
if (valid_turfs.len)
for(var/mob/living/L in contributors)
use_available_blood(L, cost_rejoin,contributors[L])
make_tracker_effects(L.loc,spell_holder, 1, "soul", 3, /obj/effect/tracker/drain, 3)
anim(target = L, a_icon = 'icons/effects/effects.dmi', flick_anim = "cult_jaunt_prepare", lay = SNOW_OVERLAY_LAYER, plane = EFFECTS_PLANE)
playsound(L, 'sound/effects/cultjaunt_prepare.ogg', 75, 0, -3)
spawn(10)
playsound(L, 'sound/effects/cultjaunt_land.ogg', 50, 0, -3)
new /obj/effect/bloodcult_jaunt(get_turf(L),L,pick(valid_turfs))
anim(target = L, a_icon = 'icons/effects/effects.dmi', flick_anim = "cult_jaunt_land", lay = SNOW_OVERLAY_LAYER, plane = EFFECTS_PLANE)
else
if(target.locked_to || !isturf(target.loc))
to_chat(target, "<span class='warning'>You feel that some force wants to pull you through the veil, but cannot proceed while buckled or inside something.</span>")
for(var/mob/living/L in contributors)
to_chat(activator, "<span class='warning'>The ritual failed, the target seems to be anchored to where they are.</span>")
else
for(var/mob/living/L in contributors)
use_available_blood(L, cost_summon/contributors.len,contributors[L])
make_tracker_effects(L.loc,spell_holder, 1, "soul", 3, /obj/effect/tracker/drain, 3)
anim(target = src.target, a_icon = 'icons/effects/effects.dmi', flick_anim = "cult_jaunt_prepare", lay = SNOW_OVERLAY_LAYER, plane = EFFECTS_PLANE)
var/mob/M = target//so we keep track of them after the datum is ded until we jaunt
var/turf/T = get_turf(spell_holder)
playsound(M, 'sound/effects/cultjaunt_prepare.ogg', 75, 0, -3)
spawn(10)
playsound(M, 'sound/effects/cultjaunt_land.ogg', 50, 0, -3)
new /obj/effect/bloodcult_jaunt(get_turf(M),M,T)
anim(target = M, a_icon = 'icons/effects/effects.dmi', flick_anim = "cult_jaunt_land", lay = SNOW_OVERLAY_LAYER, plane = EFFECTS_PLANE)
for(var/mob/living/L in contributors)
if (L.client)
L.client.images -= progbar
contributors.Remove(L)
if (activator && activator.client)
activator.client.images -= progbar
if (progbar)
progbar.loc = null
if (spell_holder.icon_state == "temp")
qdel(spell_holder)
else
qdel(src)
/obj/effect/cult_ritual/feet_portal
anchored = 1
icon = 'icons/effects/effects.dmi'
icon_state = "rune_rejoin"
pixel_y = -10
layer = ABOVE_OBJ_LAYER
plane = OBJ_PLANE
mouse_opacity = 0
flags = PROXMOVE
var/mob/living/caster = null
var/turf/source = null
/obj/effect/cult_ritual/feet_portal/New(var/turf/loc, var/mob/living/user, var/datum/rune_spell/seer/runespell)
..()
caster = user
source = get_turf(runespell.spell_holder)
if (!caster)
qdel(src)
return
/obj/effect/cult_ritual/feet_portal/Destroy()
caster = null
source = null
..()
/obj/effect/cult_ritual/feet_portal/HasProximity(var/atom/movable/AM)
if (!caster || caster.loc != loc)
forceMove(get_turf(caster))
//RUNE XVI //RUNE XVI
/datum/rune_spell/portalentrance /datum/rune_spell/portalentrance

View File

@@ -99,7 +99,7 @@
normalspeed = 0 //So they close fast, not letting the air to depressurize in a fucking second normalspeed = 0 //So they close fast, not letting the air to depressurize in a fucking second
/obj/machinery/door/airlock/external/cultify() /obj/machinery/door/airlock/external/cultify()
new /obj/machinery/door/mineral/wood(loc) new /obj/machinery/door/mineral/cult(loc)
..() ..()
/obj/machinery/door/airlock/glass /obj/machinery/door/airlock/glass

Binary file not shown.

Before

Width:  |  Height:  |  Size: 565 KiB

After

Width:  |  Height:  |  Size: 566 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 460 KiB

After

Width:  |  Height:  |  Size: 488 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

After

Width:  |  Height:  |  Size: 160 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

Binary file not shown.

BIN
sound/effects/fervor.ogg Normal file

Binary file not shown.

View File

@@ -288,6 +288,7 @@
#include "code\datums\gamemode\factions\bloodcult\bloodcult.dm" #include "code\datums\gamemode\factions\bloodcult\bloodcult.dm"
#include "code\datums\gamemode\factions\bloodcult\bloodcult_buildings.dm" #include "code\datums\gamemode\factions\bloodcult\bloodcult_buildings.dm"
#include "code\datums\gamemode\factions\bloodcult\bloodcult_cultify_exceptions.dm" #include "code\datums\gamemode\factions\bloodcult\bloodcult_cultify_exceptions.dm"
#include "code\datums\gamemode\factions\bloodcult\bloodcult_effects.dm"
#include "code\datums\gamemode\factions\bloodcult\bloodcult_hell_rising.dm" #include "code\datums\gamemode\factions\bloodcult\bloodcult_hell_rising.dm"
#include "code\datums\gamemode\factions\bloodcult\bloodcult_items.dm" #include "code\datums\gamemode\factions\bloodcult\bloodcult_items.dm"
#include "code\datums\gamemode\factions\bloodcult\bloodcult_mobs_and_constructs.dm" #include "code\datums\gamemode\factions\bloodcult\bloodcult_mobs_and_constructs.dm"