Merge branch 'master' of github.com:Baystation12/Baystation12

This commit is contained in:
SkyMarshal
2012-01-22 16:31:23 -07:00
4 changed files with 57 additions and 2 deletions
+2 -2
View File
@@ -13,7 +13,7 @@
blobevent = 1
spawn(0)
dotheblobbaby()
spawn(3000)
spawn(15000)
blobevent = 0
spawn(rand(3000, 6000)) //Delayed announcements to keep the crew on their toes.
command_alert("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert")
@@ -29,5 +29,5 @@
if(B.z != 1)
continue
B.Life()
spawn(30)
spawn(150)
dotheblobbaby()
+35
View File
@@ -10,6 +10,9 @@ client/verb/JoinResponseTeam()
if(!send_emergency_team)
usr << "No emergency response team is currently being sent."
return
if(jobban_isbanned(usr, "Syndicate") || jobban_isbanned(usr, "Emergency Response Team") || jobban_isbanned(usr, "Security Officer"))
usr << "<font color=red><b>You are jobbanned from the emergency reponse team!"
return
if(response_team_members.len > 5) usr << "The emergency response team is already full!"
@@ -32,10 +35,42 @@ client/verb/JoinResponseTeam()
else
usr << "You need to be an observer or new player to use this."
// returns a number of dead players in %
proc/percentage_dead()
var/total = 0
var/deadcount = 0
for(var/mob/living/carbon/human/H in world) if(H.mind) // I *think* monkeys gone human don't have a mind
if(H.stat == 2) deadcount++
total++
if(total == 0) return 0
else return round(100 * deadcount / total)
// counts the number of antagonists in %
proc/percentage_antagonists()
var/total = 0
var/antagonists = 0
for(var/mob/living/carbon/human/H in world)
if(is_special_character(H) >= 1)
antagonists++
total++
if(total == 0) return 0
else return round(100 * antagonists / total)
proc/trigger_armed_response_team()
if(send_emergency_team)
return
var/send_team_chance = 20 // base chance that a team will be sent
send_team_chance += 2*percentage_dead() // the more people are dead, the higher the chance
send_team_chance += percentage_antagonists() // the more antagonists, the higher the chance
send_team_chance = min(send_team_chance, 100)
// there's only a certain chance a team will be sent
if(!prob(send_team_chance)) return
command_alert("According to our sensors, [station_name()] has entered code red. We will prepare and dispatch an emergency response team to deal with the situation.", "Command Report")
send_emergency_team = 1
+13
View File
@@ -34,3 +34,16 @@
usr << "[M.key] is a [M.client.holder.rank][M.client.stealth ? " <i>(as [M.client.fakekey])</i>" : ""]"
else if(!M.client.stealth && (M.client.holder.level != -3))
usr << "\t[M.client]"
/client/verb/active_players()
set category = "OOC"
set name = "Active Players"
var/total = 0
for(var/mob/living/M in world)
if(!M.client) continue
if(M.client.inactivity > 10 * 60 * 10) continue
if(M.stat == 2) continue
total++
usr << "<b>Active Players: [total]</b>"
+7
View File
@@ -202,6 +202,12 @@
else
jobs += "<BR><a href='?src=\ref[src];jobban3=Syndicate;jobban4=\ref[M]'>[dd_replacetext("Syndicate", " ", "&nbsp")]</a> "
if(jobban_isbanned(M, "Emergency Response Team"))
jobs += "<BR><a href='?src=\ref[src];jobban3=Emergency Response Team;jobban4=\ref[M]'><font color=red>[dd_replacetext("Emergency Response Team", " ", "&nbsp")]</font></a> "
else
jobs += "<BR><a href='?src=\ref[src];jobban3=Emergency Response Team;jobban4=\ref[M]'>[dd_replacetext("Emergency Response Team", " ", "&nbsp")]</a> "
if(jobban_isbanned(M, "pAI"))
jobs += "<BR><a href='?src=\ref[src];jobban3=pAI;jobban4=\ref[M]'><font color=red>pAI</font></a> "
else
@@ -333,6 +339,7 @@
jobs += "<a href='?src=\ref[src];newjobban2=Scientist_RD;jobban4=\ref[M]'>Scientist+RD</a> <br>"
jobs += "<a href='?src=\ref[src];newjobban2=AI_Cyborg;jobban4=\ref[M]'>AI+Cyborg</a> <br>"
jobs += "<a href='?src=\ref[src];newjobban2=Detective_HoS;jobban4=\ref[M]'>Detective+HoS</a> <br><br>"
jobs += "<a href='?src=\ref[src];newjobban2=ERT;jobban4=\ref[M]'>Emergency Response Team</a> <br><br>"
for(var/datum/job/job in job_master.occupations)
if(job.title == "Tourist")
continue