Merge pull request #4785 from VOREStation/upstream-merge-5962

[MIRROR] Prevents people from joining with the same character
This commit is contained in:
Novacat
2019-03-28 21:07:32 -04:00
committed by GitHub
2 changed files with 9 additions and 2 deletions

View File

@@ -11,7 +11,7 @@ var/global/list/prevent_respawns = list()
set category = "OOC"
set desc = "Free your job slot, remove yourself from the manifest, and prevent respawning as this character for this round."
var/confirm = alert("This will free up your job slot, remove you from the manifest, and prevent you from respawning with this character for the round. You can rejoin as another \
var/confirm = alert("This will free up your job slot, remove you from the manifest, and allow you to respawn as this character. You can rejoin as another \
character if you like. Do this now?","Quit This Round","Quit Round","Cancel")
if(confirm != "Quit Round")
return
@@ -22,7 +22,7 @@ var/global/list/prevent_respawns = list()
return
//Add them to the nope list
prevent_respawns += mind.name
//prevent_respawns += mind.name //Replaced by PR 4785
//Update any existing objectives involving this mob.
for(var/datum/objective/O in all_objectives)

View File

@@ -169,6 +169,13 @@
ViewManifest()
if(href_list["SelectedJob"])
//Prevents people rejoining as same character.
for (var/mob/living/carbon/human/C in mob_list)
var/char_name = client.prefs.real_name
if(char_name == C.real_name)
usr << "<span class='notice'>There is a character that already exists with the same name - <b>[C.real_name]</b>, please join with a different one, or use Quit the Round with the previous character.</span>" //VOREStation Edit
return
if(!config.enter_allowed)
usr << "<span class='notice'>There is an administrative lock on entering the game!</span>"