mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Merge pull request #4785 from VOREStation/upstream-merge-5962
[MIRROR] Prevents people from joining with the same character
This commit is contained in:
@@ -11,7 +11,7 @@ var/global/list/prevent_respawns = list()
|
|||||||
set category = "OOC"
|
set category = "OOC"
|
||||||
set desc = "Free your job slot, remove yourself from the manifest, and prevent respawning as this character for this round."
|
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")
|
character if you like. Do this now?","Quit This Round","Quit Round","Cancel")
|
||||||
if(confirm != "Quit Round")
|
if(confirm != "Quit Round")
|
||||||
return
|
return
|
||||||
@@ -22,7 +22,7 @@ var/global/list/prevent_respawns = list()
|
|||||||
return
|
return
|
||||||
|
|
||||||
//Add them to the nope list
|
//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.
|
//Update any existing objectives involving this mob.
|
||||||
for(var/datum/objective/O in all_objectives)
|
for(var/datum/objective/O in all_objectives)
|
||||||
|
|||||||
@@ -170,6 +170,13 @@
|
|||||||
|
|
||||||
if(href_list["SelectedJob"])
|
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)
|
if(!config.enter_allowed)
|
||||||
usr << "<span class='notice'>There is an administrative lock on entering the game!</span>"
|
usr << "<span class='notice'>There is an administrative lock on entering the game!</span>"
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user