Skip to content

Commit

Permalink
bugfix: correct loot dropping from "watchers" and fixed gems duping. (s…
Browse files Browse the repository at this point in the history
  • Loading branch information
Daeberdir authored and Etrnlmelancholy committed Jan 3, 2024
1 parent b316fd6 commit 460382c
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 32 deletions.
2 changes: 1 addition & 1 deletion code/modules/mining/lavaland/loot/colossus_loot.dm
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@
activation_sound = 'sound/magic/timeparadox2.ogg'
var/list/banned_items_typecache = list(/obj/item/storage, /obj/item/implant, /obj/item/implanter, /obj/item/disk/nuclear,
/obj/item/projectile, /obj/item/spellbook, /obj/item/clothing/mask/facehugger, /obj/item/contractor_uplink,
/obj/item/dice/d20/fate)
/obj/item/dice/d20/fate, /obj/item/gem)

/obj/machinery/anomalous_crystal/refresher/New()
..()
Expand Down
60 changes: 29 additions & 31 deletions code/modules/mob/living/simple_animal/hostile/mining/basilisk.dm
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,16 @@
crusher_loot = /obj/item/crusher_trophy/watcher_wing
loot = list()
butcher_results = list(/obj/item/stack/ore/diamond = 2, /obj/item/stack/sheet/sinew = 2, /obj/item/stack/sheet/bone = 1)

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/random/Initialize(mapload)
var/jewelry_loot = null

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/death(gibbed)
if(!fromtendril && jewelry_loot)
if(prob(30))
var/obj/gem = new jewelry_loot(loc)
deathmessage = "spits out a [gem.name] as it dies!"
jewelry_loot = null
. = ..()
if(prob(40)) //60 for classic, 20/20 for magma and ice
if(prob(50))
new /mob/living/simple_animal/hostile/asteroid/basilisk/watcher/magmawing(loc)
else
new /mob/living/simple_animal/hostile/asteroid/basilisk/watcher/icewing(loc)
return INITIALIZE_HINT_QDEL
deathmessage = initial(deathmessage)

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/magmawing
name = "magmawing watcher"
Expand All @@ -105,6 +106,7 @@
light_power = 2.5
light_color = LIGHT_COLOR_LAVA
projectiletype = /obj/item/projectile/temp/basilisk/magmawing
jewelry_loot = /obj/item/gem/magma
crusher_loot = /obj/item/crusher_trophy/blaster_tubes/magma_wing
crusher_drop_mod = 60

Expand All @@ -119,9 +121,28 @@
health = 170
projectiletype = /obj/item/projectile/temp/basilisk/icewing
butcher_results = list(/obj/item/stack/ore/diamond = 5, /obj/item/stack/sheet/bone = 1) //No sinew; the wings are too fragile to be usable
jewelry_loot = /obj/item/gem/fdiamond
crusher_loot = /obj/item/crusher_trophy/watcher_wing/ice_wing
crusher_drop_mod = 60

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/random/Initialize(mapload)
. = ..()
if(prob(40)) //60 for classic, 20/20 for magma and ice
if(prob(50))
new /mob/living/simple_animal/hostile/asteroid/basilisk/watcher/magmawing(loc)
else
new /mob/living/simple_animal/hostile/asteroid/basilisk/watcher/icewing(loc)
return INITIALIZE_HINT_QDEL

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/tendril
fromtendril = TRUE

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/icewing/tendril
fromtendril = TRUE

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/magmawing/tendril
fromtendril = TRUE

/obj/item/projectile/watcher
name = "stunning blast"
icon_state = "temp_0"
Expand Down Expand Up @@ -172,26 +193,3 @@
var/mob/living/L = target
if(istype(L))
L.apply_status_effect(/datum/status_effect/freon/watcher)

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/tendril
fromtendril = TRUE

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/icewing/tendril
fromtendril = TRUE

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/magmawing/tendril
fromtendril = TRUE

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/icewing/death(gibbed)
if(prob(30) && !fromtendril)
new /obj/item/gem/fdiamond(loc)
deathmessage = "spits out a diamond as it dies!"
. = ..()
deathmessage = initial(deathmessage)

/mob/living/simple_animal/hostile/asteroid/basilisk/watcher/magmawing/death(gibbed)
if(prob(30) && !fromtendril)
new /obj/item/gem/magma(loc)
deathmessage = "spits out a golden gem as it dies!"
. = ..()
deathmessage = initial(deathmessage)

0 comments on commit 460382c

Please sign in to comment.