mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-24 05:30:05 +01:00
Fixed the lazy "fix" which caused mobs that Login or Logout to lose their hotkey mode; even when they transfer to another mob.
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
|
||||
|
||||
/mob/living/silicon/robot/Login()
|
||||
..()
|
||||
regenerate_icons()
|
||||
show_laws(0)
|
||||
if(mind) ticker.mode.remove_revolutionary(mind)
|
||||
|
||||
winset(src, null, "mainwindow.macro=borgmacro hotkey_toggle.is-checked=false input.focus=true input.background-color=#D3B5B5")
|
||||
/mob/living/silicon/robot/update_hotkey_mode()
|
||||
winset(src, null, "mainwindow.macro=borghotkeymode hotkey_toggle.is-checked=true mapwindow.map.focus=true input.background-color=#F0F0F0")
|
||||
|
||||
return
|
||||
/mob/living/silicon/robot/update_normal_mode()
|
||||
winset(src, null, "mainwindow.macro=borgmacro hotkey_toggle.is-checked=false input.focus=true input.background-color=#D3B5B5")
|
||||
|
||||
@@ -47,6 +47,20 @@
|
||||
if(isobj(loc))
|
||||
var/obj/Loc=loc
|
||||
Loc.on_log()
|
||||
//set macro to normal incase it was overriden (like cyborg currently does)
|
||||
|
||||
update_interface()
|
||||
|
||||
/mob/proc/update_interface()
|
||||
if(client)
|
||||
if(winget(src, "hotkey_toggle", "is-checked"))
|
||||
update_hotkey_mode()
|
||||
else
|
||||
update_normal_mode()
|
||||
|
||||
/mob/proc/update_hotkey_mode()
|
||||
winset(src, null, "mainwindow.macro=hotkeymode hotkey_toggle.is-checked=true mapwindow.map.focus=true input.background-color=#F0F0F0")
|
||||
|
||||
/mob/proc/update_normal_mode()
|
||||
winset(src, null, "mainwindow.macro=macro hotkey_toggle.is-checked=false input.focus=true input.background-color=#D3B5B5")
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user