Skip to content

Commit

Permalink
Merge pull request #1006 from wshuwshuwshi/Xylix-Patron-Miracles
Browse files Browse the repository at this point in the history
  • Loading branch information
Lutowski authored Dec 11, 2024
2 parents 2613ff3 + 965b291 commit c2c5fb9
Show file tree
Hide file tree
Showing 3 changed files with 55 additions and 0 deletions.
2 changes: 2 additions & 0 deletions code/datums/gods/patrons/divine_pantheon.dm
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@
desc = "The Laughing God, both famous and infamous for his sway over the forces of luck. Xylix is known for the inspiration of many a bards lyric. Speaks through his gift to man; the Tarot deck."
worshippers = "Gamblers, Bards, Artists, and the Silver-Tongued"
mob_traits = list(TRAIT_XYLIX)
t1 = /obj/effect/proc_holder/spell/invoked/wheel
t2 = /obj/effect/proc_holder/spell/invoked/mockery
confess_lines = list(
"ASTRATA IS MY LIGHT!",
"NOC IS NIGHT!",
Expand Down
28 changes: 28 additions & 0 deletions code/datums/status_effects/neutral.dm
Original file line number Diff line number Diff line change
Expand Up @@ -157,3 +157,31 @@
. = ..()
if(.)
listening_in = tracker

//Xylix Gambling
/datum/status_effect/wheel
id = "lucky(?)"
status_type = STATUS_EFFECT_UNIQUE
duration = 3000 //Lasts five minutes
var/wheeleffect

/datum/status_effect/wheel/on_apply()
. = ..()
wheeleffect = rand(-5,5)
owner.change_stat("fortune", wheeleffect)
switch(wheeleffect)
if(-5 to -1)
to_chat(owner, span_boldnotice("My heart sinks, I feel as though I've lost something!"))
if(0)
to_chat(owner, span_boldnotice("My heart beats, I feel as though nothing has changed at all..."))
if(1 to 5)
to_chat(owner, span_boldnotice("My heart flutters, I feel as though I won the lottery!"))

/datum/status_effect/wheel/on_remove()
. = ..()
owner.change_stat("fortune", -wheeleffect)

/atom/movable/screen/alert/status_effect/wheel
name = "Lucky(?)"
desc = "I feel different since my fortune was changed..."
icon_state = "asleep"
25 changes: 25 additions & 0 deletions code/modules/spells/roguetown/acolyte/xylix.dm
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/obj/effect/proc_holder/spell/invoked/wheel
name = "The Wheel"
releasedrain = 10
chargedrain = 0
chargetime = 3
range = 1
no_early_release = TRUE
movement_interrupt = TRUE
chargedloop = /datum/looping_sound/invokeholy
req_items = list(/obj/item/clothing/neck/roguetown/psicross)
sound = 'sound/misc/letsgogambling.ogg'
associated_skill = /datum/skill/magic/holy
antimagic_allowed = TRUE
charge_max = 5 MINUTES

/obj/effect/proc_holder/spell/invoked/wheel/cast(list/targets, mob/user = usr)
if(isliving(targets[1]))
var/mob/living/target = targets[1]
if(target.anti_magic_check(TRUE, TRUE))
return FALSE
target.apply_status_effect(/datum/status_effect/wheel)
return TRUE
revert_cast()
return FALSE

/obj/effect/proc_holder/spell/invoked/mockery
name = "Vicious Mockery"
releasedrain = 50
Expand Down

0 comments on commit c2c5fb9

Please sign in to comment.