Merge pull request #6481 from Atermonera/maint_drone_spawn

Reduces maintenance drone spawn time to 5 minutes
This commit is contained in:
Anewbe
2019-11-24 17:28:52 -05:00
committed by GitHub
2 changed files with 43 additions and 7 deletions

View File

@@ -65,7 +65,7 @@
/obj/machinery/drone_fabricator/examine(mob/user)
..(user)
if(produce_drones && drone_progress >= 100 && istype(user,/mob/observer/dead) && config.allow_drone_spawn && count_drones() < config.max_maint_drones)
user << "<BR><B>A drone is prepared. Select 'Join As Drone' from the Ghost tab to spawn as a maintenance drone.</B>"
to_chat(user, "<BR><B>A drone is prepared. Select 'Join As Drone' from the Ghost tab to spawn as a maintenance drone.</B>")
/obj/machinery/drone_fabricator/proc/create_drone(var/client/player)
@@ -113,14 +113,14 @@
return 0 //something is terribly wrong
if(jobban_isbanned(src,"Cyborg"))
usr << "<span class='danger'>You are banned from playing synthetics and cannot spawn as a drone.</span>"
to_chat(usr, "<span class='danger'>You are banned from playing synthetics and cannot spawn as a drone.</span>")
return
if(!MayRespawn(1))
return
var/deathtime = world.time - src.timeofdeath
var/deathtimeminutes = round(deathtime / 600)
var/deathtimeminutes = round(deathtime / (1 MINUTE))
var/pluralcheck = "minute"
if(deathtimeminutes == 0)
pluralcheck = ""
@@ -128,11 +128,11 @@
pluralcheck = " [deathtimeminutes] minute and"
else if(deathtimeminutes > 1)
pluralcheck = " [deathtimeminutes] minutes and"
var/deathtimeseconds = round((deathtime - deathtimeminutes * 600) / 10,1)
var/deathtimeseconds = round((deathtime - deathtimeminutes * 1 MINUTE) / 10,1)
if (deathtime < 6000)
usr << "You have been dead for[pluralcheck] [deathtimeseconds] seconds."
usr << "You must wait 10 minutes to respawn as a drone!"
if (deathtime < 5 MINUTES)
to_chat(usr, "You have been dead for[pluralcheck] [deathtimeseconds] seconds.")
to_chat(usr, "You must wait 5 minutes to respawn as a drone!")
return
var/list/all_fabricators = list()