mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 10:21:11 +00:00
Ok, part 1 of this huge mind datum fix. I need to run over the next part again because I've made a lot inconsistencies in it. This is sort of all the misc stuff that got tidied up whilst I was trying to get my head around how everything related to eachother.
This part focuses on: -structuring the way silicon mobs initialise upon login (there was some hideous copypasta in Login() and New() which used spawn() to change the order of the calls so it was all jumbled up. I think I've got it sorted now. -Borgs var/real_name was not initialising as "Cyborg". Meaning the name checks were kind of borked. -Ghosts are now deleted at logout if they no longer have a key. This will stop unneeded ghosts being left lying around. It will not delete ghosts with keys assigned (so people can't respawn or anything). Removed all the del(ghost_ref) stuff I could find. Generally movign the key from a ghost should be the last thing you do as the ghost will be deleted by Logout. However I've put it in a spawn() to hopefully avoid coders accisentally using it in a way which causes runtimes. -Fixed clone-plants spawning dud potato-people left, right and centre. They'll now dump seeds if it fails for whatever reason. -Cultist and Rev status are removed at mob/living/silicon/Login() rather than having to be called on a special-case basis everywhere. This may not be necessary when this stuff is finished. -Removed a bunch of : -Commented mob/living/Login() with the rest of the antag-indicator code from cloning.dm and hydroponics.dm for any coders whom feel brave/suicidal to fix the related issues Next on the agenda, replacing mob/var/original_name with datum/mind/var/name to fix the ticker runtimes Then, fixing mind/proc/transfer_to(mob) once and for all. (There are issues with duplicate minds, role updates, inconsistent initialisation etc etc *yawn* There's probably a few obscure bugs in there somewhere. Might want to hold off on the updates for a bit. Coderbus will likely spot them all by the end of the week. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4322 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -7,7 +7,7 @@ world/IsBanned(key,address,computer_id)
|
||||
if( !guests_allowed && IsGuestKey(key) )
|
||||
log_access("Failed Login: [key] - Guests not allowed")
|
||||
message_admins("\blue Failed Login: [key] - Guests not allowed")
|
||||
return list("reason"="guest", "desc"="\nReason: Guests not allowed.brb")
|
||||
return list("reason"="guest", "desc"="\nReason: Guests not allowed. Please sign in with a byond account.")
|
||||
|
||||
//check if the IP address is a known TOR node
|
||||
if( config && config.ToRban && ToRban_isbanned(address) )
|
||||
|
||||
@@ -396,10 +396,10 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
if(alert("This mob is being controlled by [M.ckey]. Are you sure you wish to assume control of it? [M.ckey] will be made a ghost.",,"Yes","No") != "Yes")
|
||||
return
|
||||
else
|
||||
var/mob/dead/observer/ghost = new/mob/dead/observer()
|
||||
ghost.ckey = M.ckey;
|
||||
var/mob/dead/observer/ghost = new/mob/dead/observer(M,1)
|
||||
ghost.ckey = M.ckey
|
||||
var/mob/adminmob = src.mob
|
||||
M.ckey = src.ckey;
|
||||
M.ckey = src.ckey
|
||||
if( isobserver(adminmob) )
|
||||
del(adminmob)
|
||||
feedback_add_details("admin_verb","ADC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -238,11 +238,11 @@ proc/cmd_admin_mute(mob/M as mob, mute_type, automute = 0)
|
||||
var/mob/living/carbon/alien/humanoid/new_xeno
|
||||
switch(alien_caste)
|
||||
if("Hunter")
|
||||
new_xeno = new /mob/living/carbon/alien/humanoid/hunter (spawn_here)
|
||||
new_xeno = new /mob/living/carbon/alien/humanoid/hunter(spawn_here)
|
||||
if("Sentinel")
|
||||
new_xeno = new /mob/living/carbon/alien/humanoid/sentinel (spawn_here)
|
||||
new_xeno = new /mob/living/carbon/alien/humanoid/sentinel(spawn_here)
|
||||
if("Drone")
|
||||
new_xeno = new /mob/living/carbon/alien/humanoid/drone (spawn_here)
|
||||
new_xeno = new /mob/living/carbon/alien/humanoid/drone(spawn_here)
|
||||
else
|
||||
return 0
|
||||
|
||||
@@ -269,7 +269,6 @@ proc/cmd_admin_mute(mob/M as mob, mute_type, automute = 0)
|
||||
else//We won't be reporting duds.
|
||||
del(new_xeno)
|
||||
|
||||
del(G)
|
||||
return 1
|
||||
|
||||
alert("There are no available ghosts to throw into the xeno. Aborting command.")
|
||||
@@ -294,7 +293,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
|
||||
var/mob/dead/observer/G_found
|
||||
for(var/mob/dead/observer/G in player_list)
|
||||
if(G.client&&ckey(G.key)==ckey(input))
|
||||
if(G.client&&G.ckey==ckey(input))
|
||||
G_found = G
|
||||
break
|
||||
|
||||
|
||||
@@ -74,12 +74,11 @@ var/global/sent_strike_team = 0
|
||||
|
||||
if(commandos_list.len)
|
||||
G = pick(commandos_list)
|
||||
commandos_list -= G
|
||||
new_commando.mind.key = G.key//For mind stuff.
|
||||
new_commando.key = G.key
|
||||
new_commando.internal = new_commando.s_store
|
||||
new_commando.internals.icon_state = "internal1"
|
||||
commandos_list -= G
|
||||
del(G)
|
||||
|
||||
//So they don't forget their code or mission.
|
||||
if(nuke_code)
|
||||
|
||||
Reference in New Issue
Block a user