Fixed Auto-Traitor, Emotes for pAIs, Sprite Fix, Spider Nerf

- Removed Implanted personel from traitor list
- Added AFK check for traitors - replaces one traitor every roll if a
traitor has gone AFK
- Added temp debug messages in autotraitor to ensure above function
works as intended
- Added spawn limit on giant spiders. Once the limit(20) is reached,
spiderlings will be unable to spawn into giant spiders. When the total
number of alive giant spiders goes below the limit-2 (18), spiderlings
will be able to grow into giant spiders again.
- Added option for when an admin spawns spiders from the secrets menu to
disable the spawn limit on spiders. Option only appears if the limit has
not been bypassed yet.
- Added pAI's can now emote -Requested by Dalek-
- Fixed Advanced Energy Gun Sprite
This commit is contained in:
SoundScopes
2014-07-05 12:30:23 +01:00
parent 712e6e436b
commit 2e27a4ab2b
9 changed files with 175 additions and 12 deletions
+3
View File
@@ -2070,6 +2070,9 @@
if(aliens_allowed)
create_xeno()
if("spiders")
if(!spider_limit_bypass) //Allow the admin to disable the max spider limit. Once enabled it's on for the round.
if (alert(usr, "Bypass the spider limit? This only needs to be done once", "Bypass?", "Yes", "No") == "Yes") //Let admins cause havoc if they want
spider_limit_bypass = 1
feedback_inc("admin_secrets_fun_used",1)
feedback_add_details("admin_secrets_fun_used","SL")
new /datum/event/spider_infestation
@@ -0,0 +1,102 @@
/mob/living/silicon/pai/emote(var/act,var/m_type=1,var/message = null)
/* if (findtext(act, "-", 1, null))
var/t1 = findtext(act, "-", 1, null)
param = copytext(act, t1 + 1, length(act) + 1)
act = copytext(act, 1, t1)
*/
if(findtext(act,"s",-1) && !findtext(act,"_",-2))//Removes ending s's unless they are prefixed with a '_'
act = copytext(act,1,length(act))
switch(act)
if ("me")
if (src.client)
if(client.prefs.muted & MUTE_IC)
src << "You cannot send IC messages (muted)."
return
if (src.client.handle_spam_prevention(message,MUTE_IC))
return
if (stat)
return
if(!(message))
return
else
return custom_emote(m_type, message)
if ("custom")
return custom_emote(m_type, message)
if ("salute")
message = "<B>[src]</b> displays an image of a person saluting."
m_type = 1
if ("bow")
message = "<B>[src]</B> displays an image of a person bowing."
m_type = 1
if ("clap")
message = "<B>[src]</B> displays an image of hands clapping."
m_type = 2
if ("flap")
message = "<B>[src]</B> displays an image of wings flapping."
m_type = 2
if ("aflap")
message = "<B>[src]</B> displays an image of wings flapping ANGRILY!"
m_type = 2
if ("twitch")
message = "<B>[src]</B> displays an image of a person twitching violently."
m_type = 1
if ("twitch_s")
message = "<B>[src]</B> displays an image of a person twitching."
m_type = 1
if ("nod")
message = "<B>[src]</B> displays an image of a person nodding."
m_type = 1
if("beep")
message = "<B>[src]</B> beeps."
playsound(src.loc, 'sound/machines/twobeep.ogg', 50, 0)
m_type = 1
if("ping")
message = "<B>[src]</B> pings."
playsound(src.loc, 'sound/machines/ping.ogg', 50, 0)
m_type = 1
if("buzz")
message = "<B>[src]</B> buzzes."
playsound(src.loc, 'sound/machines/buzz-sigh.ogg', 50, 0)
m_type = 1
if("law")
if (src:secHUD)
message = "<B>[src]</B> flashes its legal authorization barcode."
playsound(src.loc, 'sound/voice/biamthelaw.ogg', 50, 0)
m_type = 2
else
src << "You are not THE LAW, pal."
if("halt")
if (src:secHUD)
message = "<B>[src]</B>'s speakers skreech, \"Halt! Security!\"."
playsound(src.loc, 'sound/voice/halt.ogg', 50, 0)
m_type = 2
else
src << "You are not security."
if ("help")
src << "salute, bow, clap, flap, aflap, twitch, twitch_s, nod, beep, ping, \nbuzz, law, halt"
else
src << "\blue Unusable emote '[act]'. Say *help for a list."
if ((message && src.stat == 0))
if (m_type & 1)
for(var/mob/O in viewers(src, null))
O.show_message(message, m_type)
else
for(var/mob/O in hearers(src, null))
O.show_message(message, m_type)
return
+7 -5
View File
@@ -4,7 +4,9 @@
icon_state = "shadow"
robot_talk_understand = 0
emote_type = 2 // pAIs emotes are heard, not seen, so they can be seen through a container (eg. person)
// Good roleplayers can emote well, why not let them.
// emote_type = 2 // pAIs emotes are heard, not seen, so they can be seen through a container (eg. person)
var/network = "SS13"
var/obj/machinery/camera/current = null
@@ -76,20 +78,20 @@
..()
usr << browse_rsc('html/paigrid.png') // Go ahead and cache the interface resources as early as possible
// this function shows the information about being silenced as a pAI in the Status panel
/mob/living/silicon/pai/proc/show_silenced()
if(src.silence_time)
var/timeleft = round((silence_time - world.timeofday)/10 ,1)
stat(null, "Communications system reboot in -[(timeleft / 60) % 60]:[add_zero(num2text(timeleft % 60), 2)]")
/mob/living/silicon/pai/Stat()
..()
statpanel("Status")
if (src.client.statpanel == "Status")
show_silenced()
if (proc_holder_list.len)//Generic list for proc_holder objects.
for(var/obj/effect/proc_holder/P in proc_holder_list)
statpanel("[P.panel]","",P)
@@ -3,6 +3,7 @@
#define LAYING_EGGS 2
#define MOVING_TO_TARGET 3
#define SPINNING_COCOON 4
#define MAX_SPIDERS 20
//basic spider mob, these generally guard nests
/mob/living/simple_animal/hostile/giant_spider
@@ -35,6 +36,33 @@
move_to_delay = 6
speed = 3
/mob/living/simple_animal/hostile/giant_spider/New()
total_spiders += 1
if(total_spiders == MAX_SPIDERS)
spider_can_spawn = 0
..()
/mob/living/simple_animal/hostile/giant_spider/death()
total_spiders -= 1
if(total_spiders <= (MAX_SPIDERS - 2) && !spider_can_spawn)
spider_can_spawn = 1
if(total_spiders < 0) //Admin mess around protection
total_spiders = 0 //If it worked right we won't get -1
..()
/mob/living/simple_animal/hostile/giant_spider/Life() //Checks to see if spider has been respawned from var edits
if(stat == DEAD)
if(health > 0)
total_spiders += 1
..()
/mob/living/simple_animal/hostile/giant_spider/Del() //The other form of admin protection.
if(stat == DEAD)
..()
else
total_spiders -= 1
..()
//nursemaids - these create webs and eggs
/mob/living/simple_animal/hostile/giant_spider/nurse
desc = "Furry and black, it makes you shudder to look at it. This one has brilliant green eyes."
@@ -36,6 +36,7 @@
/obj/item/weapon/gun/energy/rifle/gun/nuclear
name = "Advanced Energy Gun"
desc = "An energy gun with an experimental miniaturized reactor."
icon = 'icons/obj/gun.dmi' //Overrides .../rifle
icon_state = "nucgun"
origin_tech = "combat=3;materials=5;powerstorage=3"