mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-26 14:39:58 +01:00
Advanced Laserpointer Feline Interaction (#32940)
* nerfs laserpointers, adds cat interaction * typo'd * fixes is_helpers * look at you, coder. panting and typoing as you code through my halls * addresses minor notes, adds iscatperson to purrbation * Replaces ON_PURRBATION define, changes to logging in laserpointer.dm * true * I forgot that its TRUE not true rest the fuck in peace * Final tweaks * Removes Stray else
This commit is contained in:
committed by
Emmett Gaines
parent
17ec621bb7
commit
ae9ba7bde5
@@ -59,6 +59,9 @@
|
||||
#define iszombie(A) (is_species(A, /datum/species/zombie))
|
||||
#define ishumanbasic(A) (is_species(A, /datum/species/human))
|
||||
|
||||
//why arent catpeople a subspecies
|
||||
#define iscatperson(A) (ishumanbasic(A) && ( A.dna.features["ears"] == "Cat" || A.dna.features["human_tail"] == "Cat") )
|
||||
|
||||
//more carbon mobs
|
||||
#define ismonkey(A) (istype(A, /mob/living/carbon/monkey))
|
||||
|
||||
|
||||
@@ -95,7 +95,7 @@
|
||||
else if(prob(50))
|
||||
severity = 0
|
||||
|
||||
//20% chance to actually hit the eyes
|
||||
//chance to actually hit the eyes depends on internal component
|
||||
if(prob(effectchance * diode.rating) && C.flash_act(severity))
|
||||
outmsg = "<span class='notice'>You blind [C] by shining [src] in their eyes.</span>"
|
||||
else
|
||||
@@ -104,13 +104,13 @@
|
||||
//robots
|
||||
else if(iscyborg(target))
|
||||
var/mob/living/silicon/S = target
|
||||
//20% chance to actually hit the sensors
|
||||
add_logs(user, S, "shone in the sensors", src)
|
||||
//chance to actually hit the eyes depends on internal component
|
||||
if(prob(effectchance * diode.rating))
|
||||
S.flash_act(affect_silicon = 1)
|
||||
S.Knockdown(rand(100,200))
|
||||
to_chat(S, "<span class='danger'>Your sensors were overloaded by a laser!</span>")
|
||||
outmsg = "<span class='notice'>You overload [S] by shining [src] at their sensors.</span>"
|
||||
add_logs(user, S, "shone in the sensors", src)
|
||||
else
|
||||
outmsg = "<span class='warning'>You fail to overload [S] by shining [src] at their sensors!</span>"
|
||||
|
||||
@@ -126,12 +126,28 @@
|
||||
|
||||
//catpeople
|
||||
for(var/mob/living/carbon/human/H in view(1,targloc))
|
||||
if(ishumanbasic(H) && (H.getorgan(/obj/item/organ/tail/cat) || H.getorgan(/obj/item/organ/ears/cat) || H.dna.features["ears"] == "Cat" || H.dna.features["human_tail"] == "Cat"))
|
||||
if(!H.incapacitated() && !H.lying)
|
||||
H.visible_message("<span class='warning'>[H] pounces on the light!</span>","<span class='userdanger'>LIGHT!</span>")
|
||||
H.Knockdown(10)
|
||||
if(!iscatperson(H) || H.incapacitated() || H.eye_blind )
|
||||
continue
|
||||
if(!H.lying)
|
||||
H.setDir(get_dir(H,targloc)) // kitty always looks at the light
|
||||
if(prob(effectchance))
|
||||
H.visible_message("<span class='warning'>[H] makes a grab for the light!</span>","<span class='userdanger'>LIGHT!</span>")
|
||||
H.Move(targloc)
|
||||
H.setDir(NORTH) //Facedown looks best imo
|
||||
add_logs(user, H, "moved with a laser pointer",src)
|
||||
else
|
||||
H.visible_message("<span class='notice'>[H] looks briefly distracted by the light.</span>","<span class = 'warning'> You're briefly tempted by the shiny light... </span>")
|
||||
else
|
||||
H.visible_message("<span class='notice'>[H] stares at the light</span>","<span class = 'warning'> You stare at the light... </span>")
|
||||
|
||||
//cats!
|
||||
for(var/mob/living/simple_animal/pet/cat/C in view(1,targloc))
|
||||
if(prob(50))
|
||||
C.visible_message("<span class='notice'>[C] pounces on the light!</span>","<span class='warning'>LIGHT!</span>")
|
||||
C.Move(targloc)
|
||||
C.resting = TRUE
|
||||
C.update_canmove()
|
||||
else
|
||||
C.visible_message("<span class='notice'>[C] looks uninterested in your games.</span>","<span class='warning'>You spot [user] shining [src] at you. How insulting!</span>")
|
||||
|
||||
//laser pointer image
|
||||
icon_state = "pointer_[pointer_icon_state]"
|
||||
|
||||
@@ -1091,9 +1091,6 @@ GLOBAL_LIST_EMPTY(custom_outfits) //Admin created outfits
|
||||
log_admin("[key_name(usr)] sent \"[input]\" as the Tip of the Round.")
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "Show Tip")
|
||||
|
||||
#define ON_PURRBATION(H) (\H.getorgan(/obj/item/organ/tail/cat) || H.getorgan(/obj/item/organ/ears/cat) || \
|
||||
H.dna.features["ears"] == "Cat" || H.dna.features["human_tail"] == "Cat")
|
||||
|
||||
/proc/mass_purrbation()
|
||||
for(var/M in GLOB.mob_list)
|
||||
if(ishumanbasic(M))
|
||||
@@ -1109,7 +1106,7 @@ GLOBAL_LIST_EMPTY(custom_outfits) //Admin created outfits
|
||||
/proc/purrbation_toggle(mob/living/carbon/human/H, silent = FALSE)
|
||||
if(!ishumanbasic(H))
|
||||
return
|
||||
if(!ON_PURRBATION(H))
|
||||
if(!iscatperson(H))
|
||||
purrbation_apply(H, silent)
|
||||
. = TRUE
|
||||
else
|
||||
@@ -1119,7 +1116,7 @@ GLOBAL_LIST_EMPTY(custom_outfits) //Admin created outfits
|
||||
/proc/purrbation_apply(mob/living/carbon/human/H, silent = FALSE)
|
||||
if(!ishuman(H))
|
||||
return
|
||||
if(ON_PURRBATION(H))
|
||||
if(iscatperson(H))
|
||||
return
|
||||
|
||||
var/obj/item/organ/ears/cat/ears = new
|
||||
@@ -1134,7 +1131,7 @@ GLOBAL_LIST_EMPTY(custom_outfits) //Admin created outfits
|
||||
/proc/purrbation_remove(mob/living/carbon/human/H, silent = FALSE)
|
||||
if(!ishuman(H))
|
||||
return
|
||||
if(!ON_PURRBATION(H))
|
||||
if(!iscatperson(H))
|
||||
return
|
||||
|
||||
var/obj/item/organ/ears/cat/ears = H.getorgan(/obj/item/organ/ears/cat)
|
||||
@@ -1173,8 +1170,6 @@ GLOBAL_LIST_EMPTY(custom_outfits) //Admin created outfits
|
||||
if(!silent)
|
||||
to_chat(H, "You are no longer a cat.")
|
||||
|
||||
#undef ON_PURRBATION
|
||||
|
||||
/client/proc/modify_goals()
|
||||
set category = "Debug"
|
||||
set name = "Modify goals"
|
||||
|
||||
Reference in New Issue
Block a user