mirror of
https://github.com/KabKebab/GS13.git
synced 2026-07-11 07:59:08 +01:00
@@ -12,48 +12,6 @@
|
||||
|
||||
var/rotation_flags = NONE
|
||||
var/default_rotation_direction = ROTATION_CLOCKWISE
|
||||
/*
|
||||
/proc/add_verb(client/target, verb_or_list_to_add)
|
||||
if(!target)
|
||||
CRASH("add_verb called without a target")
|
||||
if(IsAdminAdvancedProcCall())
|
||||
return
|
||||
var/mob/mob_target = null
|
||||
|
||||
if(ismob(target))
|
||||
mob_target = target
|
||||
target = mob_target.client
|
||||
else if(!istype(target, /client))
|
||||
CRASH("add_verb called on a non-mob and non-client")
|
||||
var/list/verbs_list = list()
|
||||
if(!islist(verb_or_list_to_add))
|
||||
verbs_list += verb_or_list_to_add
|
||||
else
|
||||
var/list/verb_listref = verb_or_list_to_add
|
||||
var/list/elements_to_process = verb_listref.Copy()
|
||||
while(length(elements_to_process))
|
||||
var/element_or_list = elements_to_process[length(elements_to_process)] //Last element
|
||||
elements_to_process.len--
|
||||
if(islist(element_or_list))
|
||||
elements_to_process += element_or_list //list/a += list/b adds the contents of b into a, not the reference to the list itself
|
||||
else
|
||||
verbs_list += element_or_list
|
||||
|
||||
if(mob_target)
|
||||
mob_target.verbs += verbs_list
|
||||
if(!target)
|
||||
return //Our work is done.
|
||||
else
|
||||
target.verbs += verbs_list
|
||||
|
||||
var/list/output_list = list()
|
||||
for(var/thing in verbs_list)
|
||||
var/procpath/verb_to_add = thing
|
||||
//output_list[++output_list.len] = list(verb_to_add.category, verb_to_add.name)
|
||||
output_list = url_encode(json_encode(output_list))
|
||||
|
||||
target << output("[output_list];", "statbrowser:add_verb_list")
|
||||
*/
|
||||
|
||||
/datum/component/simple_rotation/Initialize(rotation_flags = NONE ,can_user_rotate,can_be_rotated,after_rotation)
|
||||
if(!ismovableatom(parent))
|
||||
|
||||
Reference in New Issue
Block a user