Attack logging, better intent switcher HUD, alien species fixes, misc admin commands, moderator commands.

This commit is contained in:
Erthilo
2012-09-24 17:56:49 +01:00
parent 1ed6478d65
commit a88c318051
27 changed files with 1176 additions and 226 deletions
+2 -2
View File
@@ -217,7 +217,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
A.loc = T
else
A << "This mob is not located in the game world."
/*
/mob/dead/observer/verb/boo()
set category = "Ghost"
set name = "Boo!"
@@ -231,7 +231,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
return
//Maybe in the future we can add more <i>spooky</i> code here!
return
*/
/mob/dead/observer/verb/toggle_alien_candidate()
set name = "Toggle Be Alien Candidate"
set category = "Ghost"
@@ -46,6 +46,45 @@
src.adding += using
action_intent = using
//intent small hud objects
using = new src.h_type( src )
using.name = "help"
using.icon = 'screen1_alien.dmi'
using.icon_state = (mymob.a_intent == "help" ? "help_small_active" : "help_small")
using.screen_loc = ui_help_small
using.layer = 21
src.adding += using
help_intent = using
using = new src.h_type( src )
using.name = "disarm"
using.icon = 'screen1_alien.dmi'
using.icon_state = (mymob.a_intent == "disarm" ? "disarm_small_active" : "disarm_small")
using.screen_loc = ui_disarm_small
using.layer = 21
src.adding += using
disarm_intent = using
using = new src.h_type( src )
using.name = "grab"
using.icon = 'screen1_alien.dmi'
using.icon_state = (mymob.a_intent == "grab" ? "grab_small_active" : "grab_small")
using.screen_loc = ui_grab_small
using.layer = 21
src.adding += using
grab_intent = using
using = new src.h_type( src )
using.name = "harm"
using.icon = 'screen1_alien.dmi'
using.icon_state = (mymob.a_intent == "hurt" ? "harm_small_active" : "harm_small")
using.screen_loc = ui_harm_small
using.layer = 21
src.adding += using
hurt_intent = using
//end intent small hud objects
using = new src.h_type( src )
using.name = "mov_intent"
using.dir = SOUTHWEST
+4
View File
@@ -393,6 +393,10 @@
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been thrown by [usr.name] ([usr.ckey]) from [start_T_descriptor] with the target [end_T_descriptor]</font>")
usr.attack_log += text("\[[time_stamp()]\] <font color='red'>Has thrown [M.name] ([M.ckey]) from [start_T_descriptor] with the target [end_T_descriptor]</font>")
log_attack("<font color='red'>[usr.name] ([usr.ckey]) Has thrown [M.name] ([M.ckey]) from [start_T_descriptor] with the target [end_T_descriptor]</font>")
log_admin("ATTACK: [usr.name] ([usr.ckey]) Has thrown [M.name] ([M.ckey]) from [start_T_descriptor] with the target [end_T_descriptor]")
msg_admin_attack("ATTACK: [usr.name] ([usr.ckey]) Has thrown [M.name] ([M.ckey]) from [start_T_descriptor] with the target [end_T_descriptor]")
if(!item) return //Grab processing has a chance of returning null
u_equip(item)
@@ -51,6 +51,45 @@
src.adding += using
action_intent = using
//intent small hud objects
using = new src.h_type( src )
using.name = "help"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "help" ? "help_small_active" : "help_small")
using.screen_loc = ui_help_small
using.layer = 21
src.adding += using
help_intent = using
using = new src.h_type( src )
using.name = "disarm"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "disarm" ? "disarm_small_active" : "disarm_small")
using.screen_loc = ui_disarm_small
using.layer = 21
src.adding += using
disarm_intent = using
using = new src.h_type( src )
using.name = "grab"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "grab" ? "grab_small_active" : "grab_small")
using.screen_loc = ui_grab_small
using.layer = 21
src.adding += using
grab_intent = using
using = new src.h_type( src )
using.name = "harm"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "hurt" ? "harm_small_active" : "harm_small")
using.screen_loc = ui_harm_small
using.layer = 21
src.adding += using
hurt_intent = using
//end intent small hud objects
using = new src.h_type( src )
using.name = "mov_intent"
using.dir = SOUTHWEST
@@ -54,6 +54,45 @@
src.adding += using
action_intent = using
//intent small hud objects
using = new src.h_type( src )
using.name = "help"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "help" ? "help_small_active" : "help_small")
using.screen_loc = ui_help_small
using.layer = 21
src.adding += using
help_intent = using
using = new src.h_type( src )
using.name = "disarm"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "disarm" ? "disarm_small_active" : "disarm_small")
using.screen_loc = ui_disarm_small
using.layer = 21
src.adding += using
disarm_intent = using
using = new src.h_type( src )
using.name = "grab"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "grab" ? "grab_small_active" : "grab_small")
using.screen_loc = ui_grab_small
using.layer = 21
src.adding += using
grab_intent = using
using = new src.h_type( src )
using.name = "harm"
using.icon = ui_style
using.icon_state = (mymob.a_intent == "hurt" ? "harm_small_active" : "harm_small")
using.screen_loc = ui_harm_small
using.layer = 21
src.adding += using
hurt_intent = using
//end intent small hud objects
using = new src.h_type( src )
using.name = "mov_intent"
using.dir = SOUTHWEST
+16
View File
@@ -69,15 +69,31 @@
if("help")
usr.a_intent = "disarm"
usr.hud_used.action_intent.icon_state = "disarm"
usr.hud_used.hurt_intent.icon_state = "harm_small"
usr.hud_used.help_intent.icon_state = "help_small"
usr.hud_used.grab_intent.icon_state = "grab_small"
usr.hud_used.disarm_intent.icon_state = "disarm_small_active"
if("disarm")
usr.a_intent = "grab"
usr.hud_used.action_intent.icon_state = "grab"
usr.hud_used.hurt_intent.icon_state = "harm_small"
usr.hud_used.help_intent.icon_state = "help_small"
usr.hud_used.grab_intent.icon_state = "grab_small_active"
usr.hud_used.disarm_intent.icon_state = "disarm_small"
if("grab")
usr.a_intent = "hurt"
usr.hud_used.action_intent.icon_state = "harm"
usr.hud_used.hurt_intent.icon_state = "harm_small_active"
usr.hud_used.help_intent.icon_state = "help_small"
usr.hud_used.grab_intent.icon_state = "grab_small"
usr.hud_used.disarm_intent.icon_state = "disarm_small"
if("hurt")
usr.a_intent = "help"
usr.hud_used.action_intent.icon_state = "help"
usr.hud_used.hurt_intent.icon_state = "harm_small"
usr.hud_used.help_intent.icon_state = "help_small_active"
usr.hud_used.grab_intent.icon_state = "grab_small"
usr.hud_used.disarm_intent.icon_state = "disarm_small"
else if(isrobot(usr))
if(usr.a_intent == "help")
usr.a_intent = "hurt"
+43 -10
View File
@@ -241,13 +241,26 @@
return
switch(name)
if("act_intent")
if(ishuman(usr) || istype(usr,/mob/living/carbon/alien/humanoid) || islarva(usr))
var/intent = usr.a_intent
if(intent == "hurt")
intent = "harm" //hurt and harm have different sprite names for some reason.
usr.hud_used.action_intent.icon_state = "[intent]"
if (usr.hud_used.show_intent_icons)
usr.hud_used.show_intent_icons = 0
usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("harm")
if (usr.hud_used.show_intent_icons)
usr.hud_used.show_intent_icons = 0
usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("help")
if (usr.hud_used.show_intent_icons)
usr.hud_used.show_intent_icons = 0
usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("disarm")
if (usr.hud_used.show_intent_icons)
usr.hud_used.show_intent_icons = 0
usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("grab")
if (usr.hud_used.show_intent_icons)
usr.hud_used.show_intent_icons = 0
usr.client.screen -= usr.hud_used.intent_small_hud_objects
*/
/obj/screen/Click(location, control, params)
switch(name)
if("map")
@@ -381,19 +394,39 @@
if("help")
usr.a_intent = "help"
usr.hud_used.action_intent.icon_state = "help"
usr.hud_used.show_intent_icons = 0
usr.hud_used.hurt_intent.icon_state = "harm_small"
usr.hud_used.help_intent.icon_state = "help_small_active"
usr.hud_used.grab_intent.icon_state = "grab_small"
usr.hud_used.disarm_intent.icon_state = "disarm_small"
// usr.hud_used.show_intent_icons = 0
// usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("harm")
usr.a_intent = "hurt"
usr.hud_used.action_intent.icon_state = "harm"
usr.hud_used.show_intent_icons = 0
usr.hud_used.hurt_intent.icon_state = "harm_small_active"
usr.hud_used.help_intent.icon_state = "help_small"
usr.hud_used.grab_intent.icon_state = "grab_small"
usr.hud_used.disarm_intent.icon_state = "disarm_small"
// usr.hud_used.show_intent_icons = 0
// usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("grab")
usr.a_intent = "grab"
usr.hud_used.action_intent.icon_state = "grab"
usr.hud_used.show_intent_icons = 0
usr.hud_used.hurt_intent.icon_state = "harm_small"
usr.hud_used.help_intent.icon_state = "help_small"
usr.hud_used.grab_intent.icon_state = "grab_small_active"
usr.hud_used.disarm_intent.icon_state = "disarm_small"
// usr.hud_used.show_intent_icons = 0
// usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("disarm")
usr.a_intent = "disarm"
usr.hud_used.action_intent.icon_state = "disarm"
usr.hud_used.show_intent_icons = 0
usr.hud_used.hurt_intent.icon_state = "harm_small"
usr.hud_used.help_intent.icon_state = "help_small"
usr.hud_used.grab_intent.icon_state = "grab_small"
usr.hud_used.disarm_intent.icon_state = "disarm_small_active"
// usr.hud_used.show_intent_icons = 0
// usr.client.screen -= usr.hud_used.intent_small_hud_objects
if("pull")
usr.stop_pulling()
if("throw")