diff --git a/code/__DEFINES.dm b/code/__DEFINES.dm index d0eb7cc72ab..242b17f8ef3 100644 --- a/code/__DEFINES.dm +++ b/code/__DEFINES.dm @@ -200,9 +200,6 @@ var/turf/space/Space_Tile = locate(/turf/space) // A space tile to reference whe #define SHOCKWAVE 19 // attack a nearby tile and cause a massive shockwave, knocking most people on their asses (25%) #define ELECTRICITY 20 // ability to shoot electric attacks (15%) - //2spooky -#define SKELETON 29 - //disabilities #define NEARSIGHTED 1 #define EPILEPSY 2 @@ -443,6 +440,9 @@ var/list/be_special_flags = list( #define IMPCHEM_HUD 6 // chemical implant #define IMPTRACK_HUD 7 // tracking implant +#define MANIFEST_ERROR_NAME 1 +#define MANIFEST_ERROR_COUNT 2 +#define MANIFEST_ERROR_ITEM 4 //DNA - Because fuck you and your magic numbers being all over the codebase. #define DNA_BLOCK_SIZE 3 @@ -466,4 +466,4 @@ var/list/be_special_flags = list( #define TR_KEEPIMPLANTS 16 #define TR_KEEPSE 32 // changelings shouldn't edit the DNA's SE when turning into a monkey #define TR_DEFAULTMSG 64 -#define TR_KEEPSRC 128 \ No newline at end of file +#define TR_KEEPSRC 128 diff --git a/code/__HELPERS/lists.dm b/code/__HELPERS/lists.dm index 70cf55ecbf6..a08e6827d48 100644 --- a/code/__HELPERS/lists.dm +++ b/code/__HELPERS/lists.dm @@ -134,12 +134,16 @@ proc/listclearnulls(list/list) L.Cut(picked,picked+1) //Cut is far more efficient that Remove() //Returns the top(last) element from the list and removes it from the list (typical stack function) -/proc/pop(list/listfrom) - if (listfrom.len > 0) - var/picked = listfrom[listfrom.len] - listfrom.len-- - return picked - return null +/proc/pop(list/L) + if(L.len) + . = L[L.len] + L.len-- + +/proc/sorted_insert(list/L, thing, comparator) + var/pos = L.len + while(pos > 0 && call(comparator)(thing, L[pos]) > 0) + pos-- + L.Insert(pos+1, thing) /* * Sorting diff --git a/code/__HELPERS/mobs.dm b/code/__HELPERS/mobs.dm index 0da2da6deec..fa7d1cdd380 100644 --- a/code/__HELPERS/mobs.dm +++ b/code/__HELPERS/mobs.dm @@ -39,20 +39,22 @@ proc/random_name(gender, attempts_to_find_unique_name=10) break proc/random_skin_tone() - return pick(60;"caucasian", 15;"afroamerican", 10;"african", 10;"latino", 5;"albino", 20;"oriental", 10;"mediteranian") + return pick(skin_tones) var/list/skin_tones = list( - "caucasian" = "fdc", - "afroamerican" = "963", - "african" = "630", - "latino" = "c90", - "albino" = "fff", - "oriental" = "ff6", - "mediteranian" = "cc0" + "albino", + "caucasian1", + "caucasian2", + "caucasian3", + "latino", + "mediterranean", + "asian1", + "asian2", + "arab", + "indian", + "african1", + "african2" ) -/proc/skin_tone2color(skin_tone) - . = skin_tones[skin_tone] - if(!.) . = "fdc" proc/age2agedescription(age) switch(age) diff --git a/code/__HELPERS/names.dm b/code/__HELPERS/names.dm index be838d3b607..dc8ed7bb226 100644 --- a/code/__HELPERS/names.dm +++ b/code/__HELPERS/names.dm @@ -46,14 +46,27 @@ var/religion_name = null /proc/station_name() if (station_name) return station_name + + var/short_name = pick("Station", "Fortress", "Frontier", "Suffix", "Death-trap", "Space-hulk", "Lab", "Hazard","Spess Junk", "Fishery", "No-Moon", "Tomb", "Crypt", "Hut", "Monkey", "Bomb", "Trade Post", "Fortress", "Village", "Town", "City", "Edition", "Hive", "Complex", "Base", "Facility", "Depot", "Outpost", "Installation", "Drydock", "Observatory", "Array", "Relay", "Monitor", "Platform", "Construct", "Hangar", "Prison", "Center", "Port", "Waystation", "Factory", "Waypoint", "Stopover", "Hub", "HQ", "Office", "Object", "Fortification", "Colony", "Planet-Cracker", "Roost", "Fat Camp") + station_name = new_station_name() + + if (config && config.server_name) + world.name = "[config.server_name]: [short_name]" + else + world.name = station_name + + return station_name + +/proc/new_station_name() var/random = rand(1,5) var/name = "" + var/new_station_name = "" //Rare: Pre-Prefix if (prob(10)) name = pick("Imperium", "Heretical", "Cuban", "Psychic", "Elegant", "Common", "Uncommon", "Rare", "Unique", "Houseruled", "Religious", "Atheist", "Traditional", "Houseruled", "Mad", "Super", "Ultra", "Secret", "Top Secret", "Deep", "Death", "Zybourne", "Central", "Main", "Government", "Uoi", "Fat", "Automated", "Experimental", "Augmented") - station_name = name + " " + new_station_name = name + " " // Prefix switch(events.holiday) @@ -61,45 +74,38 @@ var/religion_name = null if(null,"",0) name = pick("", "Stanford", "Dorf", "Alium", "Prefix", "Clowning", "Aegis", "Ishimura", "Scaredy", "Death-World", "Mime", "Honk", "Rogue", "MacRagge", "Ultrameens", "Safety", "Paranoia", "Explosive", "Neckbear", "Donk", "Muppet", "North", "West", "East", "South", "Slant-ways", "Widdershins", "Rimward", "Expensive", "Procreatory", "Imperial", "Unidentified", "Immoral", "Carp", "Ork", "Pete", "Control", "Nettle", "Aspie", "Class", "Crab", "Fist","Corrogated","Skeleton","Race", "Fatguy", "Gentleman", "Capitalist", "Communist", "Bear", "Beard", "Derp", "Space", "Spess", "Star", "Moon", "System", "Mining", "Neckbeard", "Research", "Supply", "Military", "Orbital", "Battle", "Science", "Asteroid", "Home", "Production", "Transport", "Delivery", "Extraplanetary", "Orbital", "Correctional", "Robot", "Hats", "Pizza") if(name) - station_name += name + " " + new_station_name += name + " " //For special days like christmas, easter, new-years etc ~Carn if("Friday the 13th") name = pick("Mike","Friday","Evil","Myers","Murder","Deathly","Stabby") - station_name += name + " " + new_station_name += name + " " random = 13 else //get the first word of the Holiday and use that var/i = findtext(events.holiday," ",1,0) name = copytext(events.holiday,1,i) - station_name += name + " " + new_station_name += name + " " // Suffix name = pick("Station", "Fortress", "Frontier", "Suffix", "Death-trap", "Space-hulk", "Lab", "Hazard","Spess Junk", "Fishery", "No-Moon", "Tomb", "Crypt", "Hut", "Monkey", "Bomb", "Trade Post", "Fortress", "Village", "Town", "City", "Edition", "Hive", "Complex", "Base", "Facility", "Depot", "Outpost", "Installation", "Drydock", "Observatory", "Array", "Relay", "Monitor", "Platform", "Construct", "Hangar", "Prison", "Center", "Port", "Waystation", "Factory", "Waypoint", "Stopover", "Hub", "HQ", "Office", "Object", "Fortification", "Colony", "Planet-Cracker", "Roost", "Fat Camp") - station_name += name + " " + new_station_name += name + " " // ID Number switch(random) if(1) - station_name += "[rand(1, 99)]" + new_station_name += "[rand(1, 99)]" if(2) - station_name += pick("Alpha", "Beta", "Gamma", "Delta", "Epsilon", "Zeta", "Eta", "Theta", "Iota", "Kappa", "Lambda", "Mu", "Nu", "Xi", "Omicron", "Pi", "Rho", "Sigma", "Tau", "Upsilon", "Phi", "Chi", "Psi", "Omega") + new_station_name += pick("Alpha", "Beta", "Gamma", "Delta", "Epsilon", "Zeta", "Eta", "Theta", "Iota", "Kappa", "Lambda", "Mu", "Nu", "Xi", "Omicron", "Pi", "Rho", "Sigma", "Tau", "Upsilon", "Phi", "Chi", "Psi", "Omega") if(3) - station_name += pick("II", "III", "IV", "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII", "XIII", "XIV", "XV", "XVI", "XVII", "XVIII", "XIX", "XX") + new_station_name += pick("II", "III", "IV", "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII", "XIII", "XIV", "XV", "XVI", "XVII", "XVIII", "XIX", "XX") if(4) - station_name += pick("Alpha", "Bravo", "Charlie", "Delta", "Echo", "Foxtrot", "Golf", "Hotel", "India", "Juliet", "Kilo", "Lima", "Mike", "November", "Oscar", "Papa", "Quebec", "Romeo", "Sierra", "Tango", "Uniform", "Victor", "Whiskey", "X-ray", "Yankee", "Zulu") + new_station_name += pick("Alpha", "Bravo", "Charlie", "Delta", "Echo", "Foxtrot", "Golf", "Hotel", "India", "Juliet", "Kilo", "Lima", "Mike", "November", "Oscar", "Papa", "Quebec", "Romeo", "Sierra", "Tango", "Uniform", "Victor", "Whiskey", "X-ray", "Yankee", "Zulu") if(5) - station_name += pick("One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight", "Nine", "Ten", "Eleven", "Twelve", "Thirteen", "Fourteen", "Fifteen", "Sixteen", "Seventeen", "Eighteen", "Nineteen") + new_station_name += pick("One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight", "Nine", "Ten", "Eleven", "Twelve", "Thirteen", "Fourteen", "Fifteen", "Sixteen", "Seventeen", "Eighteen", "Nineteen") if(13) - station_name += pick("13","XIII","Thirteen") - - - if (config && config.server_name) - world.name = "[config.server_name]: [name]" - else - world.name = station_name - - return station_name + new_station_name += pick("13","XIII","Thirteen") + return new_station_name /proc/world_name(var/name) diff --git a/code/controllers/configuration.dm b/code/controllers/configuration.dm index 37b13994707..d5e116a430d 100644 --- a/code/controllers/configuration.dm +++ b/code/controllers/configuration.dm @@ -108,6 +108,8 @@ var/silent_ai = 0 var/silent_borg = 0 + var/sandbox_autoclose = 0 // close the sandbox panel after spawning an item, potentially reducing griff + /datum/configuration/New() var/list/L = typesof(/datum/game_mode) - /datum/game_mode @@ -340,6 +342,8 @@ config.silent_ai = 1 if("silent_borg") config.silent_borg = 1 + if("sandbox_autoclose") + config.sandbox_autoclose = 1 else diary << "Unknown setting in configuration: '[name]'" diff --git a/code/controllers/lighting_controller.dm b/code/controllers/lighting_controller.dm index 503fc10c93c..3428503e2d6 100644 --- a/code/controllers/lighting_controller.dm +++ b/code/controllers/lighting_controller.dm @@ -117,7 +117,7 @@ datum/controller/lighting/proc/Recover() var/msg = "## DEBUG: [time2text(world.timeofday)] lighting_controller restarted. Reports:\n" for(var/varname in lighting_controller.vars) switch(varname) - if("tag","bestF","type","parent_type","vars") continue + if("tag","type","parent_type","vars") continue else var/varval1 = lighting_controller.vars[varname] var/varval2 = vars[varname] diff --git a/code/controllers/master_controller.dm b/code/controllers/master_controller.dm index fb369946c34..1481225d5af 100644 --- a/code/controllers/master_controller.dm +++ b/code/controllers/master_controller.dm @@ -287,7 +287,7 @@ datum/controller/game_controller/proc/Recover() //Mostly a placeholder for now. var/msg = "## DEBUG: [time2text(world.timeofday)] MC restarted. Reports:\n" for(var/varname in master_controller.vars) switch(varname) - if("tag","bestF","type","parent_type","vars") continue + if("tag","type","parent_type","vars") continue else var/varval = master_controller.vars[varname] if(istype(varval,/datum)) diff --git a/code/datums/datumvars.dm b/code/datums/datumvars.dm index 7950463b507..7613e40f383 100644 --- a/code/datums/datumvars.dm +++ b/code/datums/datumvars.dm @@ -741,7 +741,7 @@ client usr << "This can only be done to instances of type /mob/living/carbon/human" return - var/new_mutantrace = input("Please choose a new mutantrace","Mutantrace",null) as null|anything in list("NONE","golem","lizard","slime","plant","shadow", "fly") + var/new_mutantrace = input("Please choose a new mutantrace","Mutantrace",null) as null|anything in list("NONE","golem","lizard","slime","plant","shadow", "fly", "skeleton") switch(new_mutantrace) if(null) return if("NONE") new_mutantrace = "" @@ -750,7 +750,8 @@ client return if(H.dna) H.dna.mutantrace = new_mutantrace - H.update_mutantrace() + H.update_body() + H.update_hair() else if(href_list["regenerateicons"]) if(!check_rights(0)) return diff --git a/code/datums/limbs.dm b/code/datums/limbs.dm index 48681db3eb6..39b9881aceb 100644 --- a/code/datums/limbs.dm +++ b/code/datums/limbs.dm @@ -119,7 +119,7 @@ return brute_dam + burn_dam -//Updates an organ's brute/burn states for use by updateDamageIcon() +//Updates an organ's brute/burn states for use by update_damage_overlays() //Returns 1 if we need to update overlays. 0 otherwise. /datum/limb/proc/update_icon() var/tbrute = round( (brute_dam/max_damage)*3, 1 ) diff --git a/code/defines/procs/AStar.dm b/code/defines/procs/AStar.dm index 0af47ba12c6..3c97935a29d 100644 --- a/code/defines/procs/AStar.dm +++ b/code/defines/procs/AStar.dm @@ -1,185 +1,140 @@ -//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:31 +/proc/cmp_pathnodes(pathnode/A, pathnode/B) + return (A.f_score - B.f_score) -/* -A Star pathfinding algorithm -Returns a list of tiles forming a path from A to B, taking dense objects as well as walls, and the orientation of -windows along the route into account. -Use: -your_list = AStar(start location, end location, adjacent turf proc, distance proc) -For the adjacent turf proc i wrote: +pathnode + var/turf/me //turf + var/pathnode/parent //pathnode this turf was discovered from + var/f_score //total path-length of this turf + var/g_score //length of path to this turf + + New(m,p,f,g) + me = m + parent = p + f_score = f + g_score = g + +/******************** +/A* pathfinding algorithm +/This version updated May 2013 by Yvarov +/Returns a list of turfs along the discovered path, in order from start to finish. +/ +/A* is more complex than can be easily explained here, but basically +/it checks tiles, assigning a score f = g + h where +/g = distance from start & h = minimum distance to end, and repeats with +/new tiles starting with the smallest f_score. It's capable of finding +/a path (assuming one exists), without getting stuck in wrong turns or +/unnecessarily checking unpromising tiles. +/ +/The syntax for calling remains roughly the same as the version this replaces, +/minus two arguments (ones that were never given by any of +/the procs that called it anyway). + +Possible procs to use for adjacency (there may be others): /turf/proc/AdjacentTurfs -And for the distance one i wrote: -/turf/proc/Distance -So an example use might be: +/turf/proc/AdjacentTurfsSpace +/turf/proc/CardinalTurfsWithAccess (best for most occasions, four-directional) -src.path_list = AStar(src.loc, target.loc, /turf/proc/AdjacentTurfs, /turf/proc/Distance) +Possible procs to use for adjacency: +/turf/proc/Distance_cardinal (requires four-directional adjacency proc) +/turf/proc/Distance (requires eight-directional adjacency proc) -Note: The path is returned starting at the END node, so i wrote reverselist to reverse it for ease of use. +Arguments: +/turf/start_turf: The turf to start the path from. +/turf/dest_turf: The turf to finish the path on. +adjacent_proc: The proc used to find adjacent tiles. When called, id is provided as an argument. + For the best path to be found, it must only output tiles that could be reached in + one move AND aren't occupied by something else, like a wall. +distance_proc: Formula to use for calculating distance. +maxnodes: Maximum _depth_ of nodes to examine; currently used only by disease. + Not equal to the number of nodes to examine (lpct, internal) or the maximum path + length returned (max_length below). +max_length: If the path is longer, return only this many elements of it (starting from the front). + It can only be shortened after finding the whole path, so doesn't save any time, + but as different values were provided throughout the code it's kept for compatibility. +id: Supplied to the adjacency proc for doors/etc. Default is null. +/var/turf/exclude: Turfs to avoid when finding a path. Default is null. -src.path_list = reverselist(src.pathlist) +Nodes not kept at all from previous version (which were never supplied): +"Mintargetdist: Minimum distance to the target before path returns, could be used to get +near a target, but not right to it - for an AI mob with a gun, for example." +"Minnodedist: Minimum number of nodes to return in the path, could be used to give a path a minimum +length to avoid portals or something i guess?? Not that they're counted right now but w/e." +*********************/ +proc/AStar(turf/start_turf, turf/dest_turf, adjacent_proc, distance_proc, maxnodes, max_length, id=null, var/turf/exclude=null) + set background=1 //allows proc to sleep should it take more than a single frame to complete + + var/const/DEPTH_BIAS = 0.5 //preference of discovered paths. decrease with extreme caution and don't set >1! + //var/evaluations = 0 //Total number of tiles examined, including discards and duplicates. Used for debugging + var/lpct = 0 //Loop counter - turfs properly examined. Debugging and infinite loop prevention. + var/list/checked = list() //list of pathnodes already examined + var/list/priorityqueue = list() //list of pathnodes not yet examined, sorted descending by f_score + var/pathnode/current //current pathnode being examined + var/next_g //calculated g_score of a potential turf + var/next_f //calculated f_score of a potential turf + var/skip //used for internal logic branching, don't touch. + var/pathnode/temp //temporary pathnode used for comparison, don't touch. + + var/list/path = list() //return value -Then to start on the path, all you need to do it: -Step_to(src, src.path_list[1]) -src.path_list -= src.path_list[1] or equivilent to remove that node from the list. + //sanity check to avoid a huge waste of CPU time on impossible tasks + for(var/obj/O in dest_turf) + if(O.density && (!istype(O, /obj/machinery/door) || !(O.flags & ON_BORDER))) //something is blocking the destination + return path + + priorityqueue += new /pathnode(start_turf, null, call(start_turf,distance_proc)(dest_turf), 0)//add the starting turf and manhattan distance to the queue! -Optional extras to add on (in order): -MaxNodes: The maximum number of nodes the returned path can be (0 = infinite) -Maxnodedepth: The maximum number of nodes to search (default: 30, 0 = infinite) -Mintargetdist: Minimum distance to the target before path returns, could be used to get -near a target, but not right to it - for an AI mob with a gun, for example. -Minnodedist: Minimum number of nodes to return in the path, could be used to give a path a minimum -length to avoid portals or something i guess?? Not that they're counted right now but w/e. -*/ + for(lpct=0, lpct<1800, lpct++) //maximum for DEPTH_BIAS=0.5 is 958 loops to Research Division (originally 2743) + if(!priorityqueue.len) break -// Modified to provide ID argument - supplied to 'adjacent' proc, defaults to null -// Used for checking if route exists through a door which can be opened + current = pop(priorityqueue) + checked.Add(current) -// Also added 'exclude' turf to avoid travelling over; defaults to null + next_g = current.g_score + DEPTH_BIAS + //if(maxnodes && next_g > (maxnodes*DEPTH_BIAS)) continue + if(!current) //no more possibilities, or an unhandled error + //world << "Impossible path" + return path //FAILURE -PriorityQueue - var/L[] - var/cmp - New(compare) - L = new() - cmp = compare - proc - IsEmpty() - return !L.len - Enqueue(d) - var/i - var/j - L.Add(d) - i = L.len - j = i>>1 - while(i > 1 && call(cmp)(L[j],L[i]) > 0) - L.Swap(i,j) - i = j - j >>= 1 + if(current.me == dest_turf) //reached the destination + while(current) //recreate path by looping through parents + path.Insert(1, current.me) + current = current.parent + //world << "Path found! ([path.len] steps, [lpct] loops, [evaluations] evaluations)" - Dequeue() - if(!L.len) return 0 - . = L[1] - Remove(1) + path.len = min(path.len, max_length-1) + return path //SUCCESS - Remove(i) - if(i > L.len) return 0 - L.Swap(i,L.len) - L.Cut(L.len) - if(i < L.len) - _Fix(i) - _Fix(i) - var/child = i + i - var/item = L[i] - while(child <= L.len) - if(child + 1 <= L.len && call(cmp)(L[child],L[child + 1]) > 0) - child++ - if(call(cmp)(item,L[child]) > 0) - L[i] = L[child] - i = child - else - break - child = i + i - L[i] = item - List() - var/ret[] = new() - var/copy = L.Copy() - while(!IsEmpty()) - ret.Add(Dequeue()) - L = copy - return ret - RemoveItem(i) - var/ind = L.Find(i) - if(ind) - Remove(ind) -PathNode - var/datum/source - var/PathNode/prevNode - var/f - var/g - var/h - var/nt // Nodes traversed - New(s,p,pg,ph,pnt) - source = s - prevNode = p - g = pg - h = ph - f = g + h - source.bestF = f - nt = pnt + var/adjacent = call(current.me,adjacent_proc)(id) + for(var/next_turf in adjacent) + //evaluations++ + if(next_turf == exclude) + continue + skip = 0 + next_f = next_g + call(next_turf,distance_proc)(dest_turf) + var/i = 0 + while(i < checked.len && !skip) + i++ + temp = checked[i] + if(temp.me == next_turf) //if this turf has already been checked + skip = 1 + if(temp.f_score > next_f) //BUT the current path to it is better + checked[i] = new /pathnode(next_turf, current, next_f, next_g) + //then update it + if(!skip) //if it hasn't been checked + i = 0 + while(i < priorityqueue.len && !skip) + i++ + temp = priorityqueue[i] + if(temp.me == next_turf) //if this turf was already on the openlist + if(temp.f_score > next_f) //BUT the current path to it is better + priorityqueue.Cut(i,i+1) //then remove it + skip = 2 + else + skip = 1 //otherwise leave it and don't add this version + if(!(skip % 2)) + sorted_insert(priorityqueue, new /pathnode(next_turf, current, next_f, next_g), /proc/cmp_pathnodes) -datum - var/bestF -proc - PathWeightCompare(PathNode/a, PathNode/b) - return a.f - b.f - - AStar(start,end,adjacent,dist,maxnodes,maxnodedepth = 30,mintargetdist,minnodedist,id=null, var/turf/exclude=null) - -// world << "A*: [start] [end] [adjacent] [dist] [maxnodes] [maxnodedepth] [mintargetdist], [minnodedist] [id]" - var/PriorityQueue/open = new /PriorityQueue(/proc/PathWeightCompare) - var/closed[] = new() - var/path[] - start = get_turf(start) - if(!start) return 0 - - open.Enqueue(new /PathNode(start,null,0,call(start,dist)(end))) - - while(!open.IsEmpty() && !path) - { - var/PathNode/cur = open.Dequeue() - closed.Add(cur.source) - - var/closeenough - if(mintargetdist) - closeenough = call(cur.source,dist)(end) <= mintargetdist - - if(cur.source == end || closeenough) - path = new() - path.Add(cur.source) - while(cur.prevNode) - cur = cur.prevNode - path.Add(cur.source) - break - - var/L[] = call(cur.source,adjacent)(id) - if(minnodedist && maxnodedepth) - if(call(cur.source,minnodedist)(end) + cur.nt >= maxnodedepth) - continue - else if(maxnodedepth) - if(cur.nt >= maxnodedepth) - continue - - for(var/datum/d in L) - if(d == exclude) - continue - var/ng = cur.g + call(cur.source,dist)(d) - if(d.bestF) - if(ng + call(d,dist)(end) < d.bestF) - for(var/i = 1; i <= open.L.len; i++) - var/PathNode/n = open.L[i] - if(n.source == d) - open.Remove(i) - break - else - continue - - open.Enqueue(new /PathNode(d,cur,ng,call(d,dist)(end),cur.nt+1)) - if(maxnodes && open.L.len > maxnodes) - open.L.Cut(open.L.len) - } - - var/PathNode/temp - while(!open.IsEmpty()) - temp = open.Dequeue() - temp.source.bestF = 0 - while(closed.len) - temp = closed[closed.len] - temp.bestF = 0 - closed.Cut(closed.len) - - if(path) - for(var/i = 1; i <= path.len/2; i++) - path.Swap(i,path.len-i+1) - - return path + //world << "Didn't find a path within [evaluations] evaluations and [lpct] loops." + return path //FAILURE + //This return should only be reached if the path is too long, and the while loop gives up. diff --git a/code/game/area/Space Station 13 areas.dm b/code/game/area/Space Station 13 areas.dm index 7ef90d907d3..9b7693d9f19 100644 --- a/code/game/area/Space Station 13 areas.dm +++ b/code/game/area/Space Station 13 areas.dm @@ -275,7 +275,7 @@ proc/process_ghost_teleport_locs() requires_power = 0 /area/centcom/control - name = "\improper Centcom Control" + name = "\improper Centcom Docks" /area/centcom/evac name = "\improper Centcom Emergency Shuttle" @@ -286,6 +286,9 @@ proc/process_ghost_teleport_locs() /area/centcom/ferry name = "\improper Centcom Transport Shuttle" +/area/centcom/prison + name = "\improper Admin Prison" + /area/centcom/holding name = "\improper Holding Facility" diff --git a/code/game/area/areas.dm b/code/game/area/areas.dm index 9c7a2b7cb7b..13293f514dc 100644 --- a/code/game/area/areas.dm +++ b/code/game/area/areas.dm @@ -1,5 +1,16 @@ // Areas.dm +// Added to fix mech fabs 05/2013 ~Sayu +// This is necessary due to lighting subareas. If you were to go in assuming that things in +// the same logical /area have the parent /area object... well, you would be mistaken. If you +// want to find machines, mobs, etc, in the same logical area, you will need to check all the +// related areas. This returns a master contents list to assist in that. +/proc/area_contents(var/area/A) + if(!istype(A)) return null + var/list/contents = list() + for(var/area/LSA in A.related) + contents += LSA.contents + return contents // === diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 98777f7e0ac..235ac44654b 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -304,69 +304,57 @@ its easier to just keep the beam vertical. if(!istype(W, /obj/item/weapon/grab) && !istype(W, /obj/item/weapon/plastique) && !istype(W, /obj/item/weapon/reagent_containers/spray) && !istype(W, /obj/item/weapon/packageWrap) && !istype(W, /obj/item/device/detective_scanner)) visible_message("[src] has been hit by [user] with [W].") +var/list/blood_splatter_icons = list() +/atom/proc/blood_splatter_index() + return "\ref[initial(icon)]-[initial(icon_state)]" //returns 1 if made bloody, returns 0 otherwise -/atom/proc/add_blood(mob/living/carbon/human/M as mob) - if (!( istype(M, /mob/living/carbon/human) )) +/atom/proc/add_blood(mob/living/carbon/M) + if(!initial(icon) || !initial(icon_state)) return 0 - check_dna_integrity(M) //check dna is valid and create/setup if necessary - if (!( src.flags ) & FPRINT) + if(!istype(M)) return 0 - if(!blood_DNA || !istype(blood_DNA, /list)) //if our list of DNA doesn't exist yet (or isn't a list) initialise it. + if(!check_dna_integrity(M)) //check dna is valid and create/setup if necessary + return 0 //no dna! + if(!(flags & FPRINT)) + return 0 + if(!istype(blood_DNA, /list)) //if our list of DNA doesn't exist yet (or isn't a list) initialise it. blood_DNA = list() //adding blood to items - if (istype(src, /obj/item)&&!istype(src, /obj/item/weapon/melee/energy))//Only regular items. Energy melee weapon are not affected. - var/obj/item/O = src - - //if we haven't made our blood_overlay already - if( !O.blood_overlay ) - var/icon/I = new /icon(O.icon, O.icon_state) - I.Blend(new /icon('icons/effects/blood.dmi', rgb(255,255,255)),ICON_ADD) //fills the icon_state with white (except where it's transparent) - I.Blend(new /icon('icons/effects/blood.dmi', "itemblood"),ICON_MULTIPLY) //adds blood and the remaining white areas become transparant - - //not sure if this is worth it. It attaches the blood_overlay to every item of the same type if they don't have one already made. - for(var/obj/item/A in world) - if(A.type == O.type && !A.blood_overlay) - A.blood_overlay = I - + if(istype(src, /obj/item)) //apply the blood-splatter overlay if it isn't already in there if(!blood_DNA.len) - O.overlays += O.blood_overlay - + //try to find a pre-processed blood-splatter. otherwise, make a new one + var/index = blood_splatter_index() + var/icon/blood_splatter_icon = blood_splatter_icons[index] + if(!blood_splatter_icon ) + blood_splatter_icon = icon(initial(icon), initial(icon_state), , 1) //we only want to apply blood-splatters to the initial icon_state for each object + blood_splatter_icon.Blend("#fff", ICON_ADD) //fills the icon_state with white (except where it's transparent) + blood_splatter_icon.Blend(icon('icons/effects/blood.dmi', "itemblood"), ICON_MULTIPLY) //adds blood and the remaining white areas become transparant + blood_splatter_icon = fcopy_rsc(blood_splatter_icon) + blood_splatter_icons[index] = blood_splatter_icon + overlays += blood_splatter_icon + //if this blood isn't already in the list, add it - if(blood_DNA[M.dna.unique_enzymes]) return 0 //already bloodied with this blood. Cannot add more. blood_DNA[M.dna.unique_enzymes] = M.dna.b_type return 1 //we applied blood to the item //adding blood to turfs - else if (istype(src, /turf/simulated)) + else if(istype(src, /turf/simulated)) var/turf/simulated/T = src //get one blood decal and infect it with virus from M.viruses - for(var/obj/effect/decal/cleanable/blood/B in T.contents) - if(!B.blood_DNA[M.dna.unique_enzymes]) - B.blood_DNA[M.dna.unique_enzymes] = M.dna.b_type - /*for(var/datum/disease/D in M.viruses) - var/datum/disease/newDisease = D.Copy(1) - B.viruses += newDisease - newDisease.holder = B*/ - return 1 //we bloodied the floor - - //if there isn't a blood decal already, make one. - var/obj/effect/decal/cleanable/blood/newblood = new /obj/effect/decal/cleanable/blood(T) - newblood.blood_DNA[M.dna.unique_enzymes] = M.dna.b_type - /*for(var/datum/disease/D in M.viruses) - var/datum/disease/newDisease = D.Copy(1) - newblood.viruses += newDisease - newDisease.holder = newblood*/ + var/obj/effect/decal/cleanable/blood/B = locate() in T.contents + if(!B) B = new /obj/effect/decal/cleanable/blood(T) + B.blood_DNA[M.dna.unique_enzymes] = M.dna.b_type return 1 //we bloodied the floor //adding blood to humans - else if (istype(src, /mob/living/carbon/human)) + else if(istype(src, /mob/living/carbon/human)) var/mob/living/carbon/human/H = src //if this blood isn't already in the list, add it if(blood_DNA[H.dna.unique_enzymes]) @@ -391,34 +379,22 @@ its easier to just keep the beam vertical. // Only adds blood on the floor -- Skie /atom/proc/add_blood_floor(mob/living/carbon/M as mob) - if( istype(M, /mob/living/carbon/monkey) || istype(M, /mob/living/carbon/human)) - if( istype(src, /turf/simulated) ) - var/turf/simulated/source1 = src - var/obj/effect/decal/cleanable/blood/this = new /obj/effect/decal/cleanable/blood(source1) - this.blood_DNA[M.dna.unique_enzymes] = M.dna.b_type - /*for(var/datum/disease/D in M.viruses) - var/datum/disease/newDisease = D.Copy(1) - this.viruses += newDisease - newDisease.holder = this*/ - - else if( istype(M, /mob/living/carbon/alien )) - if( istype(src, /turf/simulated) ) - var/turf/simulated/source2 = src - var/obj/effect/decal/cleanable/xenoblood/this = new /obj/effect/decal/cleanable/xenoblood(source2) - this.blood_DNA["UNKNOWN BLOOD"] = "X*" - /*for(var/datum/disease/D in M.viruses) - var/datum/disease/newDisease = D.Copy(1) - this.viruses += newDisease - newDisease.holder = this*/ - - else if( istype(M, /mob/living/silicon/robot )) - if( istype(src, /turf/simulated) ) - var/turf/simulated/source2 = src - new /obj/effect/decal/cleanable/oil(source2) + if(istype(src, /turf/simulated)) + if(check_dna_integrity(M)) //mobs with dna = (monkeys + humans at time of writing) + var/obj/effect/decal/cleanable/blood/B = locate() in contents + if(!B) B = new(src) + B.blood_DNA[M.dna.unique_enzymes] = M.dna.b_type + else if(istype(M, /mob/living/carbon/alien)) + var/obj/effect/decal/cleanable/xenoblood/B = locate() in contents + if(!B) B = new(src) + B.blood_DNA["UNKNOWN BLOOD"] = "X*" + else if(istype(M, /mob/living/silicon/robot)) + var/obj/effect/decal/cleanable/oil/B = locate() in contents + if(!B) B = new(src) /atom/proc/clean_blood() if(istype(blood_DNA, /list)) - del(blood_DNA) + blood_DNA = null return 1 diff --git a/code/game/communications.dm b/code/game/communications.dm index 5220d157e75..c5fc236456c 100644 --- a/code/game/communications.dm +++ b/code/game/communications.dm @@ -107,9 +107,10 @@ var/list/radiochannels = list( "Deathsquad" = 1441, "Syndicate" = 1213, "Supply" = 1347, + "Service" = 1349, ) //depenging helpers -var/list/DEPT_FREQS = list(1351,1355,1357,1213,1441,1347) +var/list/DEPT_FREQS = list(1351,1355,1357,1213,1441,1347,1349) var/const/SEC_FREQ = 1359 //security, colored cyan in chat window var/const/COMM_FREQ = 1353 //command, colored gold in chat window var/const/SYND_FREQ = 1213 diff --git a/code/game/dna.dm b/code/game/dna.dm index 663f3f6add9..7136e7375ed 100644 --- a/code/game/dna.dm +++ b/code/game/dna.dm @@ -39,9 +39,9 @@ L[DNA_HAIR_COLOR_BLOCK] = sanitize_hexcolor(H.h_color) L[DNA_FACIAL_HAIR_STYLE_BLOCK] = construct_block(hair_styles_list.Find(H.f_style), facial_hair_styles_list.len) L[DNA_FACIAL_HAIR_COLOR_BLOCK] = sanitize_hexcolor(H.f_color) - L[DNA_SKIN_TONE_BLOCK] = construct_block(skin_tones.Find(H.s_tone), skin_tones.len) + L[DNA_SKIN_TONE_BLOCK] = construct_block(skin_tones.Find(H.skin_tone), skin_tones.len) L[DNA_EYE_COLOR_BLOCK] = sanitize_hexcolor(H.eye_color) - + for(var/i=1, i<=DNA_UNI_IDENTITY_BLOCKS, i++) if(L[i]) . += L[i] else . += random_string(DNA_BLOCK_SIZE,hex_characters) @@ -68,53 +68,55 @@ return . /proc/hardset_dna(mob/living/carbon/owner, ui, se, real_name, mutantrace, blood_type) - if(!istype(owner)) + if(!istype(owner, /mob/living/carbon/monkey) && !istype(owner, /mob/living/carbon/human)) return if(!owner.dna) owner.dna = new /datum/dna() - + if(real_name) owner.real_name = real_name owner.dna.generate_unique_enzymes(owner) - + if(blood_type) owner.dna.b_type = blood_type - + if(ui) owner.dna.uni_identity = ui updateappearance(owner) - + var/update_mutantrace = (mutantrace != owner.dna.mutantrace) owner.dna.mutantrace = mutantrace if(update_mutantrace && istype(owner, /mob/living/carbon/human)) var/mob/living/carbon/human/H = owner - H.update_mutantrace() - + H.update_body() + H.update_hair() + if(se) owner.dna.struc_enzymes = se domutcheck(owner) - + check_dna_integrity(owner) - + return owner.dna + /proc/check_dna_integrity(mob/living/carbon/character) if(!istype(character)) - return 0 + return if(!character.dna) if(ready_dna(character)) - return 1 - return 0 - + return character.dna + return + if(length(character.dna.uni_identity) != DNA_UNI_IDENTITY_BLOCKS*DNA_BLOCK_SIZE) - character.dna.uni_identity = character.dna.generate_uni_identity(character) + character.dna.uni_identity = character.dna.generate_uni_identity(character) if(length(character.dna.struc_enzymes)!= DNA_STRUC_ENZYMES_BLOCKS*DNA_BLOCK_SIZE) character.dna.struc_enzymes = character.dna.generate_struc_enzymes() if(!character.dna.real_name || length(character.dna.unique_enzymes) != DNA_UNIQUE_ENZYMES_LEN) character.dna.unique_enzymes = character.dna.generate_unique_enzymes(character) - return 1 + return character.dna /proc/ready_dna(mob/living/carbon/character, blood_type) if(!istype(character, /mob/living/carbon/monkey) && !istype(character, /mob/living/carbon/human)) - return 0 + return if(!character.dna) character.dna = new /datum/dna() if(blood_type) @@ -123,7 +125,7 @@ character.dna.uni_identity = character.dna.generate_uni_identity(character) character.dna.struc_enzymes = character.dna.generate_struc_enzymes(character) character.dna.unique_enzymes = character.dna.generate_unique_enzymes(character) - return 1 + return character.dna /////////////////////////// DNA DATUM @@ -204,21 +206,23 @@ /////////////////////////// DNA HELPER-PROCS /////////////////////////// DNA MISC-PROCS -/proc/updateappearance(mob/living/carbon/human/H) - if(!istype(H) || !istype(H.dna)) +/proc/updateappearance(mob/living/carbon/C) + if(!check_dna_integrity(C)) return 0 - check_dna_integrity() - var/structure = H.dna.uni_identity - H.h_color = sanitize_hexcolor(getblock(structure, DNA_HAIR_COLOR_BLOCK)) - H.f_color = sanitize_hexcolor(getblock(structure, DNA_FACIAL_HAIR_COLOR_BLOCK)) - H.s_tone = skin_tones[deconstruct_block(getblock(structure, DNA_SKIN_TONE_BLOCK), skin_tones.len)] - H.eye_color = sanitize_hexcolor(getblock(structure, DNA_EYE_COLOR_BLOCK)) - H.gender = (deconstruct_block(getblock(structure, DNA_GENDER_BLOCK), 2)-1) ? MALE : FEMALE - H.f_style = facial_hair_styles_list[deconstruct_block(getblock(structure, DNA_FACIAL_HAIR_STYLE_BLOCK), facial_hair_styles_list.len)] - H.h_style = hair_styles_list[deconstruct_block(getblock(structure, DNA_HAIR_STYLE_BLOCK), hair_styles_list.len)] + + var/structure = C.dna.uni_identity + C.gender = (deconstruct_block(getblock(structure, DNA_GENDER_BLOCK), 2)-1) ? FEMALE : MALE + if(istype(C, /mob/living/carbon/human)) + var/mob/living/carbon/human/H = C + H.h_color = sanitize_hexcolor(getblock(structure, DNA_HAIR_COLOR_BLOCK)) + H.f_color = sanitize_hexcolor(getblock(structure, DNA_FACIAL_HAIR_COLOR_BLOCK)) + H.skin_tone = skin_tones[deconstruct_block(getblock(structure, DNA_SKIN_TONE_BLOCK), skin_tones.len)] + H.eye_color = sanitize_hexcolor(getblock(structure, DNA_EYE_COLOR_BLOCK)) + H.f_style = facial_hair_styles_list[deconstruct_block(getblock(structure, DNA_FACIAL_HAIR_STYLE_BLOCK), facial_hair_styles_list.len)] + H.h_style = hair_styles_list[deconstruct_block(getblock(structure, DNA_HAIR_STYLE_BLOCK), hair_styles_list.len)] - H.update_body(0) - H.update_hair() + H.update_body() + H.update_hair() return 1 /proc/domutcheck(mob/living/carbon/M, connected, inj) @@ -239,7 +243,7 @@ blocks[i] = (deconstruct_block(getblock(M.dna.struc_enzymes, i), GOOD_MUTATION_DIFFICULTY) == GOOD_MUTATION_DIFFICULTY) for(var/i in op_se_blocks) //Overpowered mutations...extra difficult to obtain blocks[i] = (deconstruct_block(getblock(M.dna.struc_enzymes, i), OP_MUTATION_DIFFICULTY) == OP_MUTATION_DIFFICULTY) - + if(blocks[NEARSIGHTEDBLOCK]) M.disabilities |= NEARSIGHTED M << "\red Your eyes feel strange." @@ -499,7 +503,7 @@ density = 1 var/radduration = 2 var/radstrength = 1 - + var/list/buffer[NUMBER_OF_BUFFERS] var/injectorready = 0 //Quick fix for issue 286 (screwdriver the screen twice to restore injector) -Pete @@ -640,7 +644,7 @@ occupant_status = "Invalid DNA structure" else occupant_status = "No subject detected" - + if(connected.locked) scanner_status = "Locked" else @@ -649,7 +653,7 @@ occupant_status = "Error: Undefined" scanner_status = "Error: No scanner detected" var/status = "
| " + if(i<=leftcolumn.len) + dat += leftcolumn[i] + dat += " | " + if(i<=rightcolumn.len) + dat += rightcolumn[i] + dat += " |
| "
dat += "Blood Type: [b_type] " - dat += "Skin Tone: [s_tone] " + dat += "Skin Tone: [skin_tone] " dat += "Underwear: [underwear] " dat += "Backpack: [backbaglist[backbag]] " @@ -493,7 +493,7 @@ datum/preferences if("eyes") eye_color = random_eye_color() if("s_tone") - s_tone = random_skin_tone() + skin_tone = random_skin_tone() if("bag") backbag = rand(1,3) if("all") @@ -564,7 +564,7 @@ datum/preferences if("s_tone") var/new_s_tone = input(user, "Choose your character's skin-tone:", "Character Preference") as null|anything in skin_tones if(new_s_tone) - s_tone = new_s_tone + skin_tone = new_s_tone if("ooccolor") var/new_ooccolor = input(user, "Choose your OOC colour:", "Game Preference") as color|null @@ -667,7 +667,7 @@ datum/preferences character.h_color = h_color character.f_color = f_color - character.s_tone = s_tone + character.skin_tone = skin_tone character.h_style = h_style character.f_style = f_style character.underwear = underwear diff --git a/code/modules/client/preferences_savefile.dm b/code/modules/client/preferences_savefile.dm index b079a33ece1..e81362ca614 100644 --- a/code/modules/client/preferences_savefile.dm +++ b/code/modules/client/preferences_savefile.dm @@ -163,7 +163,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car S["hair_color"] >> h_color S["facial_hair_color"] >> f_color S["eye_color"] >> eye_color - S["skin_tone"] >> s_tone + S["skin_tone"] >> skin_tone S["hair_style_name"] >> h_style S["facial_style_name"] >> f_style S["underwear"] >> underwear @@ -203,7 +203,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car h_color = sanitize_hexcolor(h_color, 3, 0) f_color = sanitize_hexcolor(f_color, 3, 0) eye_color = sanitize_hexcolor(eye_color, 3, 0) - s_tone = sanitize_inlist(s_tone, skin_tones) + skin_tone = sanitize_inlist(skin_tone, skin_tones) backbag = sanitize_integer(backbag, 1, backbaglist.len, initial(backbag)) userandomjob = sanitize_integer(userandomjob, 0, 1, initial(userandomjob)) @@ -236,7 +236,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car S["hair_color"] << h_color S["facial_hair_color"] << f_color S["eye_color"] << eye_color - S["skin_tone"] << s_tone + S["skin_tone"] << skin_tone S["hair_style_name"] << h_style S["facial_style_name"] << f_style S["underwear"] << underwear diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm index afe08dbad1f..477f50888ae 100644 --- a/code/modules/clothing/clothing.dm +++ b/code/modules/clothing/clothing.dm @@ -25,6 +25,7 @@ var/vision_flags = 0 var/darkness_view = 0//Base human is 2 var/invisa_view = 0 + var/emagged = 0 /* SEE_SELF // can see self, no matter what diff --git a/code/modules/clothing/glasses/glasses.dm b/code/modules/clothing/glasses/glasses.dm index a9fab6bf5d5..d86d473de24 100644 --- a/code/modules/clothing/glasses/glasses.dm +++ b/code/modules/clothing/glasses/glasses.dm @@ -122,6 +122,22 @@ src.hud = new/obj/item/clothing/glasses/hud/security(src) return +/* /obj/item/clothing/glasses/sunglasses/sechud/attackby(obj/item/weapon/W as obj, mob/user as mob) + ..() + if(istype(W, /obj/item/weapon/card/emag)) + if(emagged == 0) + emagged = 1 + user << "PZZTTPFFFT" + desc = desc + " The display flickers slightly." + else + user << "It is already emagged!" */ //Fuck emags + +/obj/item/clothing/glasses/sunglasses/sechud/emp_act(severity) + if(emagged == 0) + emagged = 1 + desc = desc + " The display flickers slightly." + + /obj/item/clothing/glasses/thermal name = "Optical Thermal Scanner" desc = "Thermals in the shape of glasses." diff --git a/code/modules/clothing/glasses/hud.dm b/code/modules/clothing/glasses/hud.dm index c0a545fa96d..e9776ab7155 100644 --- a/code/modules/clothing/glasses/hud.dm +++ b/code/modules/clothing/glasses/hud.dm @@ -8,6 +8,20 @@ proc process_hud(var/mob/M) return +/* /obj/item/clothing/glasses/hud/attackby(obj/item/weapon/W as obj, mob/user as mob) + ..() + if(istype(W, /obj/item/weapon/card/emag)) + if(emagged == 0) + emagged = 1 + user << "PZZTTPFFFT" + desc = desc+ " The display flickers slightly." + else + user << "It is already emagged!" */ //No emags allowed + +/obj/item/clothing/glasses/hud/emp_act(severity) + if(emagged == 0) + emagged = 1 + desc = desc + " The display flickers slightly." /obj/item/clothing/glasses/hud/health @@ -118,7 +132,7 @@ C.images += holder break else if((R.fields["id"] == E.fields["id"]) && (R.fields["criminal"] == "Incarcerated")) - holder.icon_state = "hudprisoner" + holder.icon_state = "hudincarcerated" C.images += holder break else if((R.fields["id"] == E.fields["id"]) && (R.fields["criminal"] == "Parolled")) diff --git a/code/modules/flufftext/Hallucination.dm b/code/modules/flufftext/Hallucination.dm index 9264c0e28dd..5a3205749e1 100644 --- a/code/modules/flufftext/Hallucination.dm +++ b/code/modules/flufftext/Hallucination.dm @@ -229,7 +229,7 @@ proc/check_panel(mob/M) var/image/stand_icon = null var/image/currentimage = null var/icon/base = null - var/s_tone + var/skin_tone var/mob/living/clone = null var/image/left var/image/right diff --git a/code/modules/hydroponics/biogenerator.dm b/code/modules/hydroponics/biogenerator.dm index c75cda5dba5..b8ddadf09e4 100644 --- a/code/modules/hydroponics/biogenerator.dm +++ b/code/modules/hydroponics/biogenerator.dm @@ -14,9 +14,7 @@ New() ..() - var/datum/reagents/R = new/datum/reagents(1000) - reagents = R - R.my_atom = src + create_reagents(1000) beaker = new /obj/item/weapon/reagent_containers/glass/beaker/large(src) on_reagent_change() //When the reagents change, change the icon as well. diff --git a/code/modules/hydroponics/growninedible.dm b/code/modules/hydroponics/growninedible.dm index 6a0b5e6a520..c24e02fef31 100644 --- a/code/modules/hydroponics/growninedible.dm +++ b/code/modules/hydroponics/growninedible.dm @@ -17,9 +17,7 @@ var/potency = 1 var/plant_type = 0 New() - var/datum/reagents/R = new/datum/reagents(50) - reagents = R - R.my_atom = src + create_reagents(50) /obj/item/weapon/grown/proc/changePotency(newValue) //-QualityVan potency = newValue diff --git a/code/modules/hydroponics/hydroitemcode.dm b/code/modules/hydroponics/hydroitemcode.dm index 521e2f0390c..1d66bb3acb9 100644 --- a/code/modules/hydroponics/hydroitemcode.dm +++ b/code/modules/hydroponics/hydroitemcode.dm @@ -34,7 +34,7 @@ var/organ = ((user.hand ? "l_":"r_") + "arm") var/datum/limb/affecting = user.get_organ(organ) if(affecting.take_damage(0,force)) - user.UpdateDamageIcon(0) + user.update_damage_overlays(0) else user.take_organ_damage(0,force) @@ -57,7 +57,7 @@ var/organ = ((user.hand ? "l_":"r_") + "arm") var/datum/limb/affecting = user.get_organ(organ) if(affecting.take_damage(0,force)) - user.UpdateDamageIcon(0) + user.update_damage_overlays(0) else user.take_organ_damage(0,force) if(prob(50)) diff --git a/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm b/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm index e8cf1555e27..db7e7f2900b 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm @@ -7,9 +7,7 @@ plasma_rate = 15 /mob/living/carbon/alien/humanoid/drone/New() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) if(src.name == "alien drone") src.name = text("alien drone ([rand(1, 1000)])") src.real_name = src.name diff --git a/code/modules/mob/living/carbon/alien/humanoid/caste/hunter.dm b/code/modules/mob/living/carbon/alien/humanoid/caste/hunter.dm index 3a15f620b20..428dc0d0b0b 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/caste/hunter.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/caste/hunter.dm @@ -9,9 +9,7 @@ plasma_rate = 5 /mob/living/carbon/alien/humanoid/hunter/New() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) if(name == "alien hunter") name = text("alien hunter ([rand(1, 1000)])") real_name = name diff --git a/code/modules/mob/living/carbon/alien/humanoid/caste/sentinel.dm b/code/modules/mob/living/carbon/alien/humanoid/caste/sentinel.dm index 226824c6ab4..d40108475c3 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/caste/sentinel.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/caste/sentinel.dm @@ -9,9 +9,7 @@ plasma_rate = 10 /mob/living/carbon/alien/humanoid/sentinel/New() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) if(name == "alien sentinel") name = text("alien sentinel ([rand(1, 1000)])") real_name = name diff --git a/code/modules/mob/living/carbon/alien/humanoid/humanoid.dm b/code/modules/mob/living/carbon/alien/humanoid/humanoid.dm index a700cd7be65..700beb09773 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/humanoid.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/humanoid.dm @@ -8,9 +8,7 @@ //This is fine right now, if we're adding organ specific damage this needs to be updated /mob/living/carbon/alien/humanoid/New() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(1000) if(name == "alien") name = text("alien ([rand(1, 1000)])") real_name = name diff --git a/code/modules/mob/living/carbon/alien/humanoid/queen.dm b/code/modules/mob/living/carbon/alien/humanoid/queen.dm index 35a6538d558..30d8dc8b89f 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/queen.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/queen.dm @@ -10,9 +10,7 @@ /mob/living/carbon/alien/humanoid/queen/New() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) //there should only be one queen for(var/mob/living/carbon/alien/humanoid/queen/Q in living_mob_list) diff --git a/code/modules/mob/living/carbon/alien/larva/larva.dm b/code/modules/mob/living/carbon/alien/larva/larva.dm index c6e137289fa..3ad9fe8b9c1 100644 --- a/code/modules/mob/living/carbon/alien/larva/larva.dm +++ b/code/modules/mob/living/carbon/alien/larva/larva.dm @@ -15,9 +15,7 @@ //This is fine right now, if we're adding organ specific damage this needs to be updated /mob/living/carbon/alien/larva/New() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) if(name == "alien larva") name = "alien larva ([rand(1, 1000)])" real_name = name @@ -33,14 +31,6 @@ now_pushing = 1 if(ismob(AM)) var/mob/tmob = AM - if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations)) - if(prob(70)) - src << "\red You fail to push [tmob]'s fat ass out of the way." - now_pushing = 0 - return - if(!(tmob.status_flags & CANPUSH)) - now_pushing = 0 - return tmob.LAssailant = src now_pushing = 0 diff --git a/code/modules/mob/living/carbon/brain/brain.dm b/code/modules/mob/living/carbon/brain/brain.dm index 0de81585a37..d837c80ebb1 100644 --- a/code/modules/mob/living/carbon/brain/brain.dm +++ b/code/modules/mob/living/carbon/brain/brain.dm @@ -7,9 +7,7 @@ var/alert = null New() - var/datum/reagents/R = new/datum/reagents(1000) - reagents = R - R.my_atom = src + create_reagents(1000) ..() Del() diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index 84abccad38d..2f657dea928 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -23,7 +23,7 @@ if (istype(organ, /datum/limb)) var/datum/limb/temp = organ if(temp.take_damage(d, 0)) - H.UpdateDamageIcon(0) + H.update_damage_overlays(0) H.updatehealth() else src.take_organ_damage(d) @@ -174,7 +174,7 @@ if(status == "") status = "OK" src << "\t [status == "OK" ? "\blue" : "\red"] My [org.getDisplayName()] is [status]." - if(SKELETON in H.mutations && !H.w_uniform && !H.wear_suit) + if(dna && (dna.mutantrace == "skeleton") && !H.w_uniform && !H.wear_suit) H.play_xylophone() else if(ishuman(src)) diff --git a/code/modules/mob/living/carbon/human/death.dm b/code/modules/mob/living/carbon/human/death.dm index 024d9255509..8988ef4e4fc 100644 --- a/code/modules/mob/living/carbon/human/death.dm +++ b/code/modules/mob/living/carbon/human/death.dm @@ -70,36 +70,26 @@ return ..(gibbed) /mob/living/carbon/human/proc/makeSkeleton() - if(SKELETON in src.mutations) return - - if(f_style) - f_style = "Shaved" - if(h_style) - h_style = "Bald" - update_hair(0) - - mutations.Add(SKELETON) + if(!check_dna_integrity(src) || (dna.mutantrace == "skeleton")) return + dna.mutantrace = "skeleton" status_flags |= DISFIGURED - update_body(0) - update_mutantrace() - return + update_hair() + update_body() + return 1 -/mob/living/carbon/human/proc/ChangeToHusk() +/mob/living/carbon/proc/ChangeToHusk() if(HUSK in mutations) return - - if(f_style) - f_style = "Shaved" //we only change the icon_state of the hair datum, so it doesn't mess up their UI/UE - if(h_style) - h_style = "Bald" - update_hair(0) - mutations.Add(HUSK) status_flags |= DISFIGURED //makes them unknown without fucking up other stuff like admintools - update_body(0) - update_mutantrace() - return + return 1 -/mob/living/carbon/human/proc/Drain() +/mob/living/carbon/human/ChangeToHusk() + . = ..() + if(.) + update_hair() + update_body() + +/mob/living/carbon/proc/Drain() ChangeToHusk() mutations |= NOCLONE - return \ No newline at end of file + return 1 \ No newline at end of file diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm index 2eb34249e7a..6f3c1ec9432 100644 --- a/code/modules/mob/living/carbon/human/examine.dm +++ b/code/modules/mob/living/carbon/human/examine.dm @@ -48,7 +48,7 @@ t_is = "are" else if(icon) - msg += "\icon[icon] " //fucking BYOND: this should stop dreamseeker crashing if we -somehow- examine somebody before their icon is generated + msg += "\icon[src] " //note, should we ever go back to runtime-generated icons (please don't), you will need to change this to \icon[icon] to prevent crashes. switch(gender) if(MALE) t_He = "He" diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 6c35fe3bfee..b7f48e81bfa 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -3,7 +3,7 @@ real_name = "unknown" voice_name = "unknown" icon = 'icons/mob/human.dmi' - icon_state = "body_m_s" + icon_state = "caucasian1_m_s" var/list/hud_list = list() @@ -14,9 +14,7 @@ /mob/living/carbon/human/New() - var/datum/reagents/R = new/datum/reagents(1000) - reagents = R - R.my_atom = src + create_reagents(1000) //initialise organs organs = newlist(/datum/limb/chest, /datum/limb/head, /datum/limb/l_arm, @@ -66,11 +64,6 @@ slime.UpdateFeed() return - if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations)) - if(prob(40) && !(FAT in src.mutations)) - src << "\red You fail to push [tmob]'s fat ass out of the way." - now_pushing = 0 - return if(tmob.r_hand && istype(tmob.r_hand, /obj/item/weapon/shield/riot)) if(prob(99)) now_pushing = 0 @@ -209,7 +202,7 @@ update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05) if("r_leg") update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05) - if(update) UpdateDamageIcon(0) + if(update) update_damage_overlays(0) /mob/living/carbon/human/blob_act() @@ -229,10 +222,10 @@ if(!affecting) return if (istype(O, /obj/effect/immovablerod)) if(affecting.take_damage(101, 0)) - UpdateDamageIcon(0) + update_damage_overlays(0) else if(affecting.take_damage((istype(O, /obj/effect/meteor/small) ? 10 : 25), 30)) - UpdateDamageIcon(0) + update_damage_overlays(0) updatehealth() return @@ -499,18 +492,22 @@ var/mob/living/carbon/human/H = usr if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud)) - /* // Uncomment if you want sechuds to need security access + // Checks the user has security clearence before allowing them to change arrest status via hud, comment out to enable all access var/allowed_access = 0 - if(H.wear_id) - var/list/access = H.wear_id.GetAccess() - if(access_security in access) - allowed_access = 1 - return + var/obj/item/clothing/glasses/G = H.glasses + if (!G.emagged) + if(H.wear_id) + var/list/access = H.wear_id.GetAccess() + if(access_sec_doors in access) + allowed_access = 1 + else + allowed_access = 1 + if(!allowed_access) H << "ERROR: Invalid Access" return - */ + var/modified = 0 var/perpname = "wot" diff --git a/code/modules/mob/living/carbon/human/human_damage.dm b/code/modules/mob/living/carbon/human/human_damage.dm index d50fc786a20..86ad74c85e2 100644 --- a/code/modules/mob/living/carbon/human/human_damage.dm +++ b/code/modules/mob/living/carbon/human/human_damage.dm @@ -80,7 +80,7 @@ if(!parts.len) return var/datum/limb/picked = pick(parts) if(picked.heal_damage(brute,burn)) - UpdateDamageIcon(0) + update_damage_overlays(0) updatehealth() //Damages ONE external organ, organ gets randomly selected from damagable ones. @@ -91,7 +91,7 @@ if(!parts.len) return var/datum/limb/picked = pick(parts) if(picked.take_damage(brute,burn)) - UpdateDamageIcon(0) + update_damage_overlays(0) updatehealth() @@ -113,7 +113,7 @@ parts -= picked updatehealth() - if(update) UpdateDamageIcon(0) + if(update) update_damage_overlays(0) // damage MANY external organs, in random order /mob/living/carbon/human/take_overall_damage(var/brute, var/burn) @@ -134,7 +134,7 @@ parts -= picked updatehealth() - if(update) UpdateDamageIcon(0) + if(update) update_damage_overlays(0) //////////////////////////////////////////// @@ -143,7 +143,7 @@ var/datum/limb/E = get_organ(zone) if(istype(E, /datum/limb)) if (E.heal_damage(brute, burn)) - UpdateDamageIcon(0) + update_damage_overlays(0) else return 0 return @@ -179,11 +179,11 @@ if(BRUTE) damageoverlaytemp = 20 if(organ.take_damage(damage, 0)) - UpdateDamageIcon(0) + update_damage_overlays(0) if(BURN) damageoverlaytemp = 20 if(organ.take_damage(0, damage)) - UpdateDamageIcon(0) + update_damage_overlays(0) // Will set our damageoverlay icon to the next level, which will then be set back to the normal level the next mob.Life(). diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm index f8cb5acb450..f53b78f5224 100644 --- a/code/modules/mob/living/carbon/human/human_defense.dm +++ b/code/modules/mob/living/carbon/human/human_defense.dm @@ -145,7 +145,7 @@ emp_act location.add_blood(src) if(ishuman(user)) var/mob/living/carbon/human/H = user - if(get_dist(H, src) > 1) //people with TK won't get smeared with blood + if(get_dist(H, src) <= 1) //people with TK won't get smeared with blood if(H.wear_suit) H.wear_suit.add_blood(src) H.update_inv_wear_suit(0) //updates mob overlays to show the new blood (no refresh) diff --git a/code/modules/mob/living/carbon/human/human_defines.dm b/code/modules/mob/living/carbon/human/human_defines.dm index 3cb7acc54ac..a773b91d671 100644 --- a/code/modules/mob/living/carbon/human/human_defines.dm +++ b/code/modules/mob/living/carbon/human/human_defines.dm @@ -10,7 +10,7 @@ //Eye colour var/eye_color = "000" - var/s_tone = "caucasian" //Skin tone + var/skin_tone = "caucasian1" //Skin tone var/lip_style = null //no lipstick by default- arguably misleading, as it could be used for general makeup @@ -34,9 +34,7 @@ var/obj/item/l_store = null var/obj/item/s_store = null - - var/icon/stand_icon = null - var/icon/lying_icon = null + var/base_icon_state = "caucasian1_m" var/list/organs = list() //Gets filled up in the constructor (human.dm, New() proc, line 24. I'm sick and tired of missing comments. -Agouri diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index 967256a9cff..27ebba1e5fc 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -755,17 +755,13 @@ if(FAT in mutations) if(overeatduration < 100) src << "\blue You feel fit again!" - mutations.Remove(FAT) - update_mutantrace(0) - update_mutations(0) + mutations -= FAT update_inv_w_uniform(0) update_inv_wear_suit() else if(overeatduration > 500) src << "\red You suddenly feel blubbery!" - mutations.Add(FAT) - update_mutantrace(0) - update_mutations(0) + mutations |= FAT update_inv_w_uniform(0) update_inv_wear_suit() diff --git a/code/modules/mob/living/carbon/human/update_icons.dm b/code/modules/mob/living/carbon/human/update_icons.dm index e001ab7eeeb..70f989d9727 100644 --- a/code/modules/mob/living/carbon/human/update_icons.dm +++ b/code/modules/mob/living/carbon/human/update_icons.dm @@ -1,56 +1,38 @@ /////////////////////// //UPDATE_ICONS SYSTEM// /////////////////////// -/* -Calling this a system is perhaps a bit trumped up. It is essentially update_clothing dismantled into its -core parts. The key difference is that when we generate overlays we do not generate either lying or standing -versions. Instead, we generate both and store them in two fixed-length lists, both using the same list-index -(The indexes are in update_icons.dm): Each list for humans is (at the time of writing) of length 19. -This will hopefully be reduced as the system is refined. +/* Keep these comments up-to-date if you -insist- on hurting my code-baby ;_; +This system allows you to update individual mob-overlays, without regenerating them all each time. +When we generate overlays we do not generate either lying or standing, as used to happen. +Instead, we generate both standing and lying stances and store them in two fixed-length lists, +both using the same list-index. (The index values are defines within this file. - var/overlays_lying[19] //For the lying down stance - var/overlays_standing[19] //For the standing stance +As of the time of writing there are 20 layers within this list. Please try to keep this from increasing. + var/overlays_lying[20] //For the lying down stance + var/overlays_standing[20] //For the standing stance -When we call update_icons, the 'lying' variable is checked and then the appropriate list is assigned to our overlays! -That in itself uses a tiny bit more memory (no more than all the ridiculous lists the game has already mind you). +Most of the time we only wish to update one overlay: + e.g. - we dropped the fireaxe out of our left hand and need to remove its icon from our mob + e.g.2 - our hair colour has changed, so we need to update our hair icons on our mob +In these cases, instead of updating every overlay using the old behaviour (regenerate_icons), we instead call +the appropriate update_X proc. + e.g. - update_l_hand() + e.g.2 - update_hair() -On the other-hand, it should be very CPU cheap in comparison to the old system. -In the old system, we updated all our overlays every life() call, even if we were standing still inside a crate! -or dead!. 25ish overlays, all generated from scratch every second for every xeno/human/monkey and then applied. -More often than not update_clothing was being called a few times in addition to that! CPU was not the only issue, -all those icons had to be sent to every client. So really the cost was extremely cumulative. To the point where -update_clothing would frequently appear in the top 10 most CPU intensive procs during profiling. - -Another feature of this new system is that our lists are indexed. This means we can update specific overlays! -So we only regenerate icons when we need them to be updated! This is the main saving for this system. - -In practice this means that: - everytime you fall over, we just switch between precompiled lists. Which is fast and cheap. - Everytime you do something minor like take a pen out of your pocket, we only update the in-hand overlay - etc... +Note: Recent changes by aranclanos+carn: + update_icons() no longer needs to be called. + This unfortunately means that cloaking is not working properly at time of writing, + however the system is easier to use. update_icons() should not be called unless you absolutely -know- you need it. + One such example would be when var/lying changes state (because every overlay needs to be updated, but not regenerated). In these + very specific cases, update_icons() will be faster than calling each update_X proc individually. + IN ALL OTHER CASES it's better to just call the specific update_X procs. +All of this means that this code is more maintainable, faster and still fairly easy to use. There are several things that need to be remembered: - > Whenever we do something that should cause an overlay to update (which doesn't use standard procs - ( i.e. you do something like l_hand = /obj/item/something new(src) ) - You will need to call the relevant update_inv_* proc: - update_inv_head() - update_inv_wear_suit() - update_inv_gloves() - update_inv_shoes() - update_inv_w_uniform() - update_inv_glasses() - update_inv_l_hand() - update_inv_r_hand() - update_inv_belt() - update_inv_wear_id() - update_inv_ears() - update_inv_s_store() - update_inv_pockets() - update_inv_back() - update_inv_handcuffed() - update_inv_wear_mask() + ( i.e. you do something like l_hand = /obj/item/something new(src), rather than using the helper procs) + You will need to call the relevant update_inv_* proc All of these are named after the variable they update from. They are defined at the mob/ level like update_clothing was, so you won't cause undefined proc runtimes with usr.update_inv_wear_id() if the usr is a @@ -58,47 +40,30 @@ There are several things that need to be remembered: > There are also these special cases: - update_mutations() //handles updating your appearance for certain mutations. e.g TK head-glows - update_mutantrace() //handles updating your appearance after setting the mutantrace var - UpdateDamageIcon() //handles damage overlays for brute/burn damage //(will rename this when I geta round to it) - update_body() //Handles updating your mob's icon to reflect their gender/race/complexion etc - update_hair() //Handles updating your hair overlay (used to be update_face, but mouth and - ...eyes were merged into update_body) + update_mutations() //handles updating your appearance for certain mutations. e.g TK head-glows + update_damage_overlays() //handles damage overlays for brute/burn damage + update_base_icon_state() //Handles updating var/base_icon_state (WIP) This is used to update the + mob's icon_state easily e.g. "[base_icon_state]_s" is the standing icon_state + update_body() //Handles updating your mob's icon_state (using update_base_icon_state()) + as well as sprite-accessories that didn't really fit elsewhere (underwear, lips, eyes) + //NOTE: update_mutantrace() is now merged into this! + update_hair() //Handles updating your hair overlay (used to be update_face, but mouth and + eyes were merged into update_body()) -> All of these procs update our overlays_lying and overlays_standing, and then call update_icons() by default. - If you wish to update several overlays at once, you can set the argument to 0 to disable the update and call - it manually: - e.g. - update_inv_head(0) - update_inv_l_hand(0) - update_inv_r_hand() //<---calls update_icons() - - or equivillantly: - update_inv_head(0) - update_inv_l_hand(0) - update_inv_r_hand(0) - update_icons() - -> If you need to update all overlays you can use regenerate_icons(). it works exactly like update_clothing used to. - -> I reimplimented an old unused variable which was in the code called (coincidentally) var/update_icon +> I repurposed an old unused variable which was in the code called (coincidentally) var/update_icon It can be used as another method of triggering regenerate_icons(). It's basically a flag that when set to non-zero will call regenerate_icons() at the next life() call and then reset itself to 0. The idea behind it is icons are regenerated only once, even if multiple events requested it. + //NOTE: fairly unused, maybe this could be removed? -This system is confusing and is still a WIP. It's primary goal is speeding up the controls of the game whilst -reducing processing costs. So please bear with me while I iron out the kinks. It will be worth it, I promise. -If I can eventually free var/lying stuff from the life() process altogether, stuns/death/status stuff -will become less affected by lag-spikes and will be instantaneous! :3 - -If you have any questions/constructive-comments/bugs-to-report/or have a massivly devestated butt... -Please contact me on #coderbus IRC. ~Carn x +If you have any questions/constructive-comments/bugs-to-report +Please contact me on #coderbus IRC. ~Carnie x */ //Human Overlays Indexes///////// -#define MUTANTRACE_LAYER 20 //TODO: make part of body? -#define MUTATIONS_LAYER 19 -#define DAMAGE_LAYER 18 +#define BODY_LAYER 20 //underwear, eyes, lips(makeup) +#define MUTATIONS_LAYER 19 //Tk headglows etc. +#define DAMAGE_LAYER 18 //damage indicators (cuts and burns) #define UNIFORM_LAYER 17 #define ID_LAYER 16 #define SHOES_LAYER 15 @@ -115,14 +80,40 @@ Please contact me on #coderbus IRC. ~Carn x #define HANDCUFF_LAYER 4 #define LEGCUFF_LAYER 3 #define L_HAND_LAYER 2 -#define R_HAND_LAYER 1 -#define TOTAL_LAYERS 20 +#define R_HAND_LAYER 1 //Having the two hands seperate seems rather silly, merge them together? It'll allow for code to be reused on mobs with arbitarily many hands +#define TOTAL_LAYERS 20 //KEEP THIS UP-TO-DATE OR SHIT WILL BREAK ;_; ////////////////////////////////// /mob/living/carbon/human var/list/overlays_lying[TOTAL_LAYERS] var/list/overlays_standing[TOTAL_LAYERS] +/mob/living/carbon/human/proc/update_base_icon_state() + var/race = dna ? dna.mutantrace : null + switch(race) + if("lizard","golem","slime","shadow","adamantine","fly","plant") + base_icon_state = "[dna.mutantrace]_[(gender == FEMALE) ? "f" : "m"]" + if("skeleton") + base_icon_state = "skeleton" + else + if(HUSK in mutations) + base_icon_state = "husk" + else + base_icon_state = "[skin_tone]_[(gender == FEMALE) ? "f" : "m"]" + + +/mob/living/carbon/human/proc/apply_overlay(cache_index) + var/image/I = lying ? overlays_lying[cache_index] : overlays_standing[cache_index] + if(I) + overlays += I + +/mob/living/carbon/human/proc/remove_overlay(cache_index) + if(overlays_lying[cache_index]) + overlays -= overlays_lying[cache_index] + overlays_lying[cache_index] = null + if(overlays_standing[cache_index]) + overlays -= overlays_standing[cache_index] + overlays_standing[cache_index] = null //UPDATES OVERLAYS FROM OVERLAYS_LYING/OVERLAYS_STANDING //this proc is messy as I was forced to include some old laggy cloaking code to it so that I don't break cloakers @@ -131,11 +122,11 @@ Please contact me on #coderbus IRC. ~Carn x lying_prev = lying //so we don't update overlays for lying/standing unless our stance changes again update_hud() //TODO: remove the need for this overlays.Cut() - - if(lying) //can't be cloaked when lying. (for now) - icon = lying_icon - for(var/image/I in overlays_lying) - overlays += I + + if(lying) //can't be cloaked whilst lying down + icon_state = "[base_icon_state]_l" + for(var/thing in overlays_lying) + if(thing) overlays += thing else var/stealth = 0 if(istype(wear_suit, /obj/item/clothing/suit/space/space_ninja) && wear_suit:s_active) @@ -147,26 +138,28 @@ Please contact me on #coderbus IRC. ~Carn x stealth = 1 break if(stealth) - icon = 'icons/mob/human.dmi' icon_state = "body_cloaked" - var/image/I = overlays_standing[L_HAND_LAYER] - if(istype(I)) overlays += I - I = overlays_standing[R_HAND_LAYER] - if(istype(I)) overlays += I + if(overlays_standing[L_HAND_LAYER]) + overlays += overlays_standing[L_HAND_LAYER] + if(overlays_standing[R_HAND_LAYER]) + overlays += overlays_standing[R_HAND_LAYER] else - icon = stand_icon - for(var/image/I in overlays_standing) - overlays += I + icon_state = "[base_icon_state]_s" + for(var/thing in overlays_standing) + if(thing) overlays += thing //DAMAGE OVERLAYS //constructs damage icon for each organ from mask * damage field and saves it in our overlays_ lists -/mob/living/carbon/human/UpdateDamageIcon(var/update_icons=1) - overlays -= overlays_lying[DAMAGE_LAYER] - overlays -= overlays_standing[DAMAGE_LAYER] - var/image/standing = image("icon" = 'icons/mob/dam_human.dmi', "icon_state" = "blank", "layer" = -DAMAGE_LAYER) - var/image/lying = image("icon" = 'icons/mob/dam_human.dmi', "icon_state" = "blank2", "layer" = -DAMAGE_LAYER) +/mob/living/carbon/human/update_damage_overlays() + remove_overlay(DAMAGE_LAYER) + + var/image/standing = image("icon"='icons/mob/dam_human.dmi', "icon_state"="blank", "layer"=-DAMAGE_LAYER) + var/image/lying = image("icon"='icons/mob/dam_human.dmi', "icon_state"="blank2", "layer"=-DAMAGE_LAYER) + overlays_standing[DAMAGE_LAYER] = standing + overlays_lying[DAMAGE_LAYER] = lying + for(var/datum/limb/O in organs) if(O.brutestate) standing.overlays += "[O.icon_name]_[O.brutestate]0" //we're adding icon_states of the base image as overlays @@ -174,533 +167,360 @@ Please contact me on #coderbus IRC. ~Carn x if(O.burnstate) standing.overlays += "[O.icon_name]_0[O.burnstate]" lying.overlays += "[O.icon_name]2_0[O.burnstate]" - - overlays_standing[DAMAGE_LAYER] = standing - overlays_lying[DAMAGE_LAYER] = lying - if (src.lying) - overlays += overlays_lying[DAMAGE_LAYER] - else - overlays += overlays_standing[DAMAGE_LAYER] - if(update_icons) update_icons() - -//BASE MOB SPRITE -/mob/living/carbon/human/proc/update_body(var/update_icons=1) - if(stand_icon) del(stand_icon) - if(lying_icon) del(lying_icon) - if(dna && dna.mutantrace) return - - var/husk = (HUSK in src.mutations) //100% unnecessary -Agouri //nope, do you really want to iterate through src.mutations repeatedly? -Pete - var/fat = (FAT in src.mutations) - var/skeleton = (SKELETON in src.mutations) - var/g = "m" - - if(gender == FEMALE) g = "f" - //Base mob icon - if(husk) - stand_icon = new /icon('icons/mob/human.dmi', "husk_s") - lying_icon = new /icon('icons/mob/human.dmi', "husk_l") - else if(fat) - stand_icon = new /icon('icons/mob/human.dmi', "fatbody_s") - lying_icon = new /icon('icons/mob/human.dmi', "fatbody_l") - else if(skeleton) - stand_icon = new /icon('icons/mob/human.dmi', "skeleton_s") - lying_icon = new /icon('icons/mob/human.dmi', "skeleton_l") - else - stand_icon = new /icon('icons/mob/human.dmi', "body_[g]_s") - lying_icon = new /icon('icons/mob/human.dmi', "body_[g]_l") - - //Skin tone - if(!skeleton) - var/color = skin_tones[s_tone] - if(color) - color = "#" + color - stand_icon.Blend(color, ICON_MULTIPLY) - lying_icon.Blend(color, ICON_MULTIPLY) - - //Eyes - var/icon/eyes_s = new/icon('icons/mob/human_face.dmi', "eyes_s") - var/icon/eyes_l = new/icon('icons/mob/human_face.dmi', "eyes_l") - eyes_s.Blend("#[eye_color]", ICON_ADD) - eyes_l.Blend("#[eye_color]", ICON_ADD) - stand_icon.Blend(eyes_s, ICON_OVERLAY) - lying_icon.Blend(eyes_l, ICON_OVERLAY) - - //Mouth (lipstick!) - if(lip_style) //skeletons are allowed to wear lipstick no matter what you think, agouri. - stand_icon.Blend(new/icon('icons/mob/human_face.dmi', "lips_[lip_style]_s"), ICON_OVERLAY) - lying_icon.Blend(new/icon('icons/mob/human_face.dmi', "lips_[lip_style]_l"), ICON_OVERLAY) - - //Underwear - if(underwear && !fat && !skeleton) - var/datum/sprite_accessory/underwear/U = underwear_all[underwear] - if(U) - stand_icon.Blend(new /icon(U.icon, "[U.icon_state]_s"), ICON_OVERLAY) - lying_icon.Blend(new /icon(U.icon, "[U.icon_state]_l"), ICON_OVERLAY) - - if(update_icons) update_icons() + + apply_overlay(DAMAGE_LAYER) //HAIR OVERLAY -/mob/living/carbon/human/proc/update_hair(var/update_icons=1) +/mob/living/carbon/human/proc/update_hair() //Reset our hair - overlays -= overlays_lying[HAIR_LAYER] - overlays -= overlays_standing[HAIR_LAYER] - overlays_standing[HAIR_LAYER] = null - overlays_lying[HAIR_LAYER] = null + remove_overlay(HAIR_LAYER) //mutants don't have hair. masks and helmets can obscure our hair too. - if( (dna && dna.mutantrace) || (head && (head.flags & BLOCKHAIR)) || (wear_mask && (wear_mask.flags & BLOCKHAIR)) ) - if(update_icons) update_icons() + if( (HUSK in mutations) || (dna && dna.mutantrace) || (head && (head.flags & BLOCKHAIR)) || (wear_mask && (wear_mask.flags & BLOCKHAIR)) ) return //base icons - var/icon/face_standing = new /icon('icons/mob/human_face.dmi',"bald_s") - var/icon/face_lying = new /icon('icons/mob/human_face.dmi',"bald_l") - + var/list/standing = list() + var/list/lying = list() + if(f_style) var/datum/sprite_accessory/facial_hair_style = facial_hair_styles_list[f_style] if(facial_hair_style) - var/icon/facial_s = new/icon("icon" = facial_hair_style.icon, "icon_state" = "[facial_hair_style.icon_state]_s") - var/icon/facial_l = new/icon("icon" = facial_hair_style.icon, "icon_state" = "[facial_hair_style.icon_state]_l") + var/icon/facial_s = icon("icon"=facial_hair_style.icon, "icon_state"="[facial_hair_style.icon_state]_s") + var/icon/facial_l = icon("icon"=facial_hair_style.icon, "icon_state"="[facial_hair_style.icon_state]_l") facial_s.Blend("#[f_color]", ICON_ADD) facial_l.Blend("#[f_color]", ICON_ADD) - face_standing.Blend(facial_s, ICON_OVERLAY) - face_lying.Blend(facial_l, ICON_OVERLAY) + standing += image("icon"=facial_s, "layer"=-HAIR_LAYER) + lying += image("icon"=facial_l, "layer"=-HAIR_LAYER) //Applies the debrained overlay if there is no brain if(!getbrain(src)) - face_standing.Blend(new /icon('icons/mob/human_face.dmi', "debrained_s"), ICON_OVERLAY) - face_lying.Blend(new /icon('icons/mob/human_face.dmi', "debrained_l"), ICON_OVERLAY) - h_style = "Bald" - + standing += image("icon"='icons/mob/human_face.dmi', "icon_state"="debrained_s", "layer"=-HAIR_LAYER) + lying += image("icon"='icons/mob/human_face.dmi', "icon_state"="debrained_l", "layer"=-HAIR_LAYER) else if(h_style) var/datum/sprite_accessory/hair_style = hair_styles_list[h_style] if(hair_style) - var/icon/hair_s = new/icon("icon" = hair_style.icon, "icon_state" = "[hair_style.icon_state]_s") - var/icon/hair_l = new/icon("icon" = hair_style.icon, "icon_state" = "[hair_style.icon_state]_l") + var/icon/hair_s = icon("icon"=hair_style.icon, "icon_state"="[hair_style.icon_state]_s") + var/icon/hair_l = icon("icon"=hair_style.icon, "icon_state"="[hair_style.icon_state]_l") hair_s.Blend("#[h_color]", ICON_ADD) hair_l.Blend("#[h_color]", ICON_ADD) - face_standing.Blend(hair_s, ICON_OVERLAY) - face_lying.Blend(hair_l, ICON_OVERLAY) + standing += image("icon"=hair_s, "layer"=-HAIR_LAYER) + lying += image("icon"=hair_l, "layer"=-HAIR_LAYER) - overlays_lying[HAIR_LAYER] = image(face_lying, "layer" = -HAIR_LAYER) - overlays_standing[HAIR_LAYER] = image(face_standing, "layer" = -HAIR_LAYER) + if(lying.len) + overlays_lying[HAIR_LAYER] = lying + if(standing.len) + overlays_standing[HAIR_LAYER] = standing + + apply_overlay(HAIR_LAYER) - if (src.lying) - overlays += overlays_lying[HAIR_LAYER] - else - overlays += overlays_standing[HAIR_LAYER] - if(update_icons) update_icons() +/mob/living/carbon/human/update_mutations() + remove_overlay(MUTATIONS_LAYER) -/mob/living/carbon/human/update_mutations(var/update_icons=1) - overlays -= overlays_lying[MUTATIONS_LAYER] - overlays -= overlays_standing[MUTATIONS_LAYER] - - var/fat - if(FAT in mutations) - fat = "fat" - - var/image/lying = image("icon" = 'icons/effects/genetics.dmi', "layer" = -MUTATIONS_LAYER) - var/image/standing = image("icon" = 'icons/effects/genetics.dmi', "layer" = -MUTATIONS_LAYER) - var/add_image = 0 - var/g = "m" - if(gender == FEMALE) g = "f" + var/list/standing = list() + var/list/lying = list() + + var/g = (gender == FEMALE) ? "f" : "m" for(var/mut in mutations) switch(mut) if(HULK) - if(fat) - lying.underlays += "hulk_[fat]_l" - standing.underlays += "hulk_[fat]_s" - else - lying.underlays += "hulk_[g]_l" - standing.underlays += "hulk_[g]_s" - add_image = 1 + lying += image("icon"='icons/effects/genetics.dmi', "icon_state"="hulk_[g]_l", "layer"=-MUTATIONS_LAYER) + standing += image("icon"='icons/effects/genetics.dmi', "icon_state"="hulk_[g]_s", "layer"=-MUTATIONS_LAYER) if(COLD_RESISTANCE) - lying.underlays += "fire[fat]_l" - standing.underlays += "fire[fat]_s" - add_image = 1 + lying += image("icon"='icons/effects/genetics.dmi', "icon_state"="fire_l", "layer"=-MUTATIONS_LAYER) + standing += image("icon"='icons/effects/genetics.dmi', "icon_state"="fire_s", "layer"=-MUTATIONS_LAYER) if(TK) - lying.underlays += "telekinesishead[fat]_l" - standing.underlays += "telekinesishead[fat]_s" - add_image = 1 + lying += image("icon"='icons/effects/genetics.dmi', "icon_state"="telekinesishead_l", "layer"=-MUTATIONS_LAYER) + standing += image("icon"='icons/effects/genetics.dmi', "icon_state"="telekinesishead_s", "layer"=-MUTATIONS_LAYER) if(LASER) - lying.overlays += "lasereyes_l" - standing.overlays += "lasereyes_s" - add_image = 1 - if(add_image) + lying += image("icon"='icons/effects/genetics.dmi', "icon_state"="lasereyes_l", "layer"=-MUTATIONS_LAYER) + standing += image("icon"='icons/effects/genetics.dmi', "icon_state"="lasereyes_s", "layer"=-MUTATIONS_LAYER) + if(lying.len) overlays_lying[MUTATIONS_LAYER] = lying + if(standing.len) overlays_standing[MUTATIONS_LAYER] = standing - if (src.lying) - overlays += overlays_lying[MUTATIONS_LAYER] - else - overlays += overlays_standing[MUTATIONS_LAYER] - else - overlays -= overlays_lying[MUTATIONS_LAYER] - overlays -= overlays_standing[MUTATIONS_LAYER] - overlays_lying[MUTATIONS_LAYER] = null - overlays_standing[MUTATIONS_LAYER] = null - if(update_icons) update_icons() + + apply_overlay(MUTATIONS_LAYER) -/mob/living/carbon/human/proc/update_mutantrace(var/update_icons=1) - overlays -= overlays_lying[MUTANTRACE_LAYER] - overlays -= overlays_standing[MUTANTRACE_LAYER] - var/fat - if( FAT in mutations ) - fat = "fat" +/mob/living/carbon/human/proc/update_body() + remove_overlay(BODY_LAYER) + + update_base_icon_state() + icon_state = "[base_icon_state]_[src.lying ? "l" : "s"]" + + var/list/lying = list() + var/list/standing = list() + + //Mouth (lipstick!) + if(lip_style) + standing += image("icon"='icons/mob/human_face.dmi', "icon_state"="lips_[lip_style]_s", "layer"=-BODY_LAYER) + lying += image("icon"='icons/mob/human_face.dmi', "icon_state"="lips_[lip_style]_l", "layer"=-BODY_LAYER) - if(dna) - switch(dna.mutantrace) - if("lizard","golem","slime","shadow","adamantine", "fly") - overlays_lying[MUTANTRACE_LAYER] = image("icon" = 'icons/effects/genetics.dmi', "icon_state" = "[dna.mutantrace][fat]_[gender]_l", "layer" = -MUTANTRACE_LAYER) - overlays_standing[MUTANTRACE_LAYER] = image("icon" = 'icons/effects/genetics.dmi', "icon_state" = "[dna.mutantrace][fat]_[gender]_s", "layer" = -MUTANTRACE_LAYER) - if("plant") - if(stat == DEAD) //TODO - overlays_lying[MUTANTRACE_LAYER] = image("icon" = 'icons/effects/genetics.dmi', "icon_state" = "[dna.mutantrace]_d", "layer" = -MUTANTRACE_LAYER) - else - overlays_lying[MUTANTRACE_LAYER] = image("icon" = 'icons/effects/genetics.dmi', "icon_state" = "[dna.mutantrace][fat]_[gender]_l", "layer" = -MUTANTRACE_LAYER) - overlays_standing[MUTANTRACE_LAYER] = image("icon" = 'icons/effects/genetics.dmi', "icon_state" = "[dna.mutantrace][fat]_[gender]_s", "layer" = -MUTANTRACE_LAYER) - else - overlays -= overlays_lying[MUTANTRACE_LAYER] - overlays -= overlays_standing[MUTANTRACE_LAYER] - overlays_lying[MUTANTRACE_LAYER] = null - overlays_standing[MUTANTRACE_LAYER] = null - update_body(0) - update_hair(0) - if(update_icons) update_icons() + //Eyes + if(!dna || dna.mutantrace != "skeleton") + var/icon/eyes_s = icon('icons/mob/human_face.dmi', "eyes_s") + var/icon/eyes_l = icon('icons/mob/human_face.dmi', "eyes_l") + eyes_s.Blend("#[eye_color]", ICON_ADD) + eyes_l.Blend("#[eye_color]", ICON_ADD) + standing += image("icon"=eyes_s, "layer"=-BODY_LAYER) + lying += image("icon"=eyes_l, "layer"=-BODY_LAYER) + + //Underwear + if(underwear) + var/datum/sprite_accessory/underwear/U = underwear_all[underwear] + if(U) + standing += image("icon"=U.icon, "icon_state"="[U.icon_state]_s", "layer"=-BODY_LAYER) + lying += image("icon"=U.icon, "icon_state"="[U.icon_state]_l", "layer"=-BODY_LAYER) + + if(lying.len) + overlays_lying[BODY_LAYER] = lying + if(standing.len) + overlays_standing[BODY_LAYER] = standing + + apply_overlay(BODY_LAYER) /* --------------------------------------- */ //For legacy support. /mob/living/carbon/human/regenerate_icons() ..() if(monkeyizing) return - update_mutations(0) - update_mutantrace(0) - update_inv_w_uniform(0) - update_inv_wear_id(0) - update_inv_gloves(0) - update_inv_glasses(0) - update_inv_ears(0) - update_inv_shoes(0) - update_inv_s_store(0) - update_inv_wear_mask(0) - update_inv_head(0) - update_inv_belt(0) - update_inv_back(0) - update_inv_wear_suit(0) - update_inv_r_hand(0) - update_inv_l_hand(0) - update_inv_handcuffed(0) - update_inv_legcuffed(0) - update_inv_pockets(0) - update_icons() + update_body() + update_hair() + update_mutations() + update_inv_w_uniform() + update_inv_wear_id() + update_inv_gloves() + update_inv_glasses() + update_inv_ears() + update_inv_shoes() + update_inv_s_store() + update_inv_wear_mask() + update_inv_head() + update_inv_belt() + update_inv_back() + update_inv_wear_suit() + update_inv_r_hand() + update_inv_l_hand() + update_inv_handcuffed() + update_inv_legcuffed() + update_inv_pockets() //Hud Stuff update_hud() /* --------------------------------------- */ //vvvvvv UPDATE_INV PROCS vvvvvv -/mob/living/carbon/human/update_inv_w_uniform(var/update_icons=1) - if(w_uniform && istype(w_uniform, /obj/item/clothing/under) ) +/mob/living/carbon/human/update_inv_w_uniform() + remove_overlay(UNIFORM_LAYER) + + if(istype(w_uniform, /obj/item/clothing/under)) + var/obj/item/clothing/under/U = w_uniform if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) w_uniform.screen_loc = ui_iclothing client.screen += w_uniform - overlays -= overlays_lying[UNIFORM_LAYER] - overlays -= overlays_standing[UNIFORM_LAYER] + var/t_color = w_uniform.color if(!t_color) t_color = icon_state - var/image/lying = image("icon_state" = "[t_color]_l", "layer" = -UNIFORM_LAYER) - var/image/standing = image("icon_state" = "[t_color]_s", "layer" = -UNIFORM_LAYER) - - if(FAT in mutations) - if(w_uniform.flags&ONESIZEFITSALL) - lying.icon = 'icons/mob/uniform_fat.dmi' - standing.icon = 'icons/mob/uniform_fat.dmi' - else - src << "\red You burst out of \the [w_uniform]!" - drop_from_inventory(w_uniform) - return - else - lying.icon = 'icons/mob/uniform.dmi' - standing.icon = 'icons/mob/uniform.dmi' - - if(w_uniform.blood_DNA) - lying.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "uniformblood2") - standing.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "uniformblood") - - if(w_uniform:hastie) //WE CHECKED THE TYPE ABOVE. THIS REALLY SHOULD BE FINE. - var/tie_color = w_uniform:hastie.color - if(!tie_color) tie_color = w_uniform:hastie.icon_state - lying.overlays += image("icon" = 'icons/mob/ties.dmi', "icon_state" = "[tie_color]2") - standing.overlays += image("icon" = 'icons/mob/ties.dmi', "icon_state" = "[tie_color]") - + var/image/lying = image("icon"='icons/mob/uniform.dmi', "icon_state"="[t_color]_l", "layer"=-UNIFORM_LAYER) + var/image/standing = image("icon"='icons/mob/uniform.dmi', "icon_state"="[t_color]_s", "layer"=-UNIFORM_LAYER) overlays_lying[UNIFORM_LAYER] = lying overlays_standing[UNIFORM_LAYER] = standing - if (src.lying) - overlays += overlays_lying[UNIFORM_LAYER] - else - overlays += overlays_standing[UNIFORM_LAYER] + + if(w_uniform.blood_DNA) + lying.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="uniformblood2") + standing.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="uniformblood") + + if(U.hastie) + var/tie_color = U.hastie.color + if(!tie_color) tie_color = U.hastie.icon_state + lying.overlays += image("icon"='icons/mob/ties.dmi', "icon_state"="[tie_color]2") + standing.overlays += image("icon"='icons/mob/ties.dmi', "icon_state"="[tie_color]") else - overlays -= overlays_lying[UNIFORM_LAYER] - overlays -= overlays_standing[UNIFORM_LAYER] - overlays_lying[UNIFORM_LAYER] = null - overlays_standing[UNIFORM_LAYER] = null // Automatically drop anything in store / id / belt if you're not wearing a uniform. //CHECK IF NECESARRY - for( var/obj/item/thing in list(r_store, l_store, wear_id, belt) ) // - if(thing) // - u_equip(thing) // - if (client) // - client.screen -= thing // - // - if (thing) // - thing.loc = loc // - thing.dropped(src) // - thing.layer = initial(thing.layer) - if(update_icons) update_icons() + for(var/obj/item/thing in list(r_store, l_store, wear_id, belt)) // + drop_from_inventory(thing) + + apply_overlay(UNIFORM_LAYER) -/mob/living/carbon/human/update_inv_wear_id(var/update_icons=1) + +/mob/living/carbon/human/update_inv_wear_id() + remove_overlay(ID_LAYER) if(wear_id) if(client && hud_used && hud_used.hud_shown) wear_id.screen_loc = ui_id //TODO client.screen += wear_id - overlays -= overlays_lying[ID_LAYER] - overlays -= overlays_standing[ID_LAYER] - overlays_lying[ID_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "id2", "layer" = -ID_LAYER) - overlays_standing[ID_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "id", "layer" = -ID_LAYER) - if (src.lying) - overlays += overlays_lying[ID_LAYER] - else - overlays += overlays_standing[ID_LAYER] - else - overlays -= overlays_lying[ID_LAYER] - overlays -= overlays_standing[ID_LAYER] - overlays_lying[ID_LAYER] = null - overlays_standing[ID_LAYER] = null - if(update_icons) update_icons() + + overlays_lying[ID_LAYER] = image("icon"='icons/mob/mob.dmi', "icon_state"="id2", "layer"=-ID_LAYER) + overlays_standing[ID_LAYER] = image("icon"='icons/mob/mob.dmi', "icon_state"="id", "layer"=-ID_LAYER) + + apply_overlay(ID_LAYER) -/mob/living/carbon/human/update_inv_gloves(var/update_icons=1) + +/mob/living/carbon/human/update_inv_gloves() + remove_overlay(GLOVES_LAYER) if(gloves) if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) gloves.screen_loc = ui_gloves client.screen += gloves - overlays -= overlays_lying[GLOVES_LAYER] - overlays -= overlays_standing[GLOVES_LAYER] + var/t_state = gloves.item_state if(!t_state) t_state = gloves.icon_state - var/image/lying = image("icon" = 'icons/mob/hands.dmi', "icon_state" = "[t_state]2", "layer" = -GLOVES_LAYER) - var/image/standing = image("icon" = 'icons/mob/hands.dmi', "icon_state" = "[t_state]", "layer" = -GLOVES_LAYER) - if(gloves.blood_DNA) - lying.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "bloodyhands2") - standing.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "bloodyhands") + var/image/lying = image("icon"='icons/mob/hands.dmi', "icon_state"="[t_state]2", "layer"=-GLOVES_LAYER) + var/image/standing = image("icon"='icons/mob/hands.dmi', "icon_state"="[t_state]", "layer"=-GLOVES_LAYER) overlays_lying[GLOVES_LAYER] = lying overlays_standing[GLOVES_LAYER] = standing - if (src.lying) - overlays += overlays_lying[GLOVES_LAYER] - else - overlays += overlays_standing[GLOVES_LAYER] + + if(gloves.blood_DNA) + lying.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="bloodyhands2") + standing.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="bloodyhands") else if(blood_DNA) - overlays_lying[GLOVES_LAYER] = image("icon" = 'icons/effects/blood.dmi', "icon_state" = "bloodyhands2") - overlays_standing[GLOVES_LAYER] = image("icon" = 'icons/effects/blood.dmi', "icon_state" = "bloodyhands") - else - overlays -= overlays_lying[GLOVES_LAYER] - overlays -= overlays_standing[GLOVES_LAYER] - overlays_lying[GLOVES_LAYER] = null - overlays_standing[GLOVES_LAYER] = null - if(update_icons) update_icons() + overlays_lying[GLOVES_LAYER] = image("icon"='icons/effects/blood.dmi', "icon_state"="bloodyhands2") + overlays_standing[GLOVES_LAYER] = image("icon"='icons/effects/blood.dmi', "icon_state"="bloodyhands") + + apply_overlay(GLOVES_LAYER) -/mob/living/carbon/human/update_inv_glasses(var/update_icons=1) + +/mob/living/carbon/human/update_inv_glasses() + remove_overlay(GLASSES_LAYER) + if(glasses) if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) glasses.screen_loc = ui_glasses client.screen += glasses - overlays -= overlays_lying[GLASSES_LAYER] - overlays -= overlays_standing[GLASSES_LAYER] - overlays_lying[GLASSES_LAYER] = image("icon" = 'icons/mob/eyes.dmi', "icon_state" = "[glasses.icon_state]2", "layer" = -GLASSES_LAYER) - overlays_standing[GLASSES_LAYER] = image("icon" = 'icons/mob/eyes.dmi', "icon_state" = "[glasses.icon_state]", "layer" = -GLASSES_LAYER) - if (src.lying) - overlays += overlays_lying[GLASSES_LAYER] - else - overlays += overlays_standing[GLASSES_LAYER] - else - overlays -= overlays_lying[GLASSES_LAYER] - overlays -= overlays_standing[GLASSES_LAYER] - overlays_lying[GLASSES_LAYER] = null - overlays_standing[GLASSES_LAYER] = null - if(update_icons) update_icons() + + overlays_lying[GLASSES_LAYER] = image("icon"='icons/mob/eyes.dmi', "icon_state"="[glasses.icon_state]2", "layer"=-GLASSES_LAYER) + overlays_standing[GLASSES_LAYER] = image("icon"='icons/mob/eyes.dmi', "icon_state"="[glasses.icon_state]", "layer"=-GLASSES_LAYER) -/mob/living/carbon/human/update_inv_ears(var/update_icons=1) + apply_overlay(GLASSES_LAYER) + + +/mob/living/carbon/human/update_inv_ears() + remove_overlay(EARS_LAYER) + if(ears) if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) ears.screen_loc = ui_ears client.screen += ears - overlays -= overlays_lying[EARS_LAYER] - overlays -= overlays_standing[EARS_LAYER] - overlays_lying[EARS_LAYER] = image("icon" = 'icons/mob/ears.dmi', "icon_state" = "[ears.icon_state]2", "layer" = -EARS_LAYER) - overlays_standing[EARS_LAYER] = image("icon" = 'icons/mob/ears.dmi', "icon_state" = "[ears.icon_state]", "layer" = -EARS_LAYER) - if (src.lying) - overlays += overlays_lying[EARS_LAYER] - else - overlays += overlays_standing[EARS_LAYER] - else - overlays -= overlays_lying[EARS_LAYER] - overlays -= overlays_standing[EARS_LAYER] - overlays_lying[EARS_LAYER] = null - overlays_standing[EARS_LAYER] = null - if(update_icons) update_icons() + + overlays_lying[EARS_LAYER] = image("icon"='icons/mob/ears.dmi', "icon_state"="[ears.icon_state]2", "layer"=-EARS_LAYER) + overlays_standing[EARS_LAYER] = image("icon"='icons/mob/ears.dmi', "icon_state"="[ears.icon_state]", "layer"=-EARS_LAYER) + + apply_overlay(EARS_LAYER) -/mob/living/carbon/human/update_inv_shoes(var/update_icons=1) + +/mob/living/carbon/human/update_inv_shoes() + remove_overlay(SHOES_LAYER) + if(shoes) if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) shoes.screen_loc = ui_shoes client.screen += shoes - var/image/lying = image("icon" = 'icons/mob/feet.dmi', "icon_state" = "[shoes.icon_state]2", "layer" = -SHOES_LAYER) - var/image/standing = image("icon" = 'icons/mob/feet.dmi', "icon_state" = "[shoes.icon_state]", "layer" = -SHOES_LAYER) - if(shoes.blood_DNA) - lying.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "shoeblood2") - standing.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "shoeblood") - overlays -= overlays_lying[SHOES_LAYER] - overlays -= overlays_standing[SHOES_LAYER] + + var/image/lying = image("icon"='icons/mob/feet.dmi', "icon_state"="[shoes.icon_state]2", "layer"=-SHOES_LAYER) + var/image/standing = image("icon"='icons/mob/feet.dmi', "icon_state"="[shoes.icon_state]", "layer"=-SHOES_LAYER) overlays_lying[SHOES_LAYER] = lying overlays_standing[SHOES_LAYER] = standing - if (src.lying) - overlays += overlays_lying[SHOES_LAYER] - else - overlays += overlays_standing[SHOES_LAYER] - else - overlays -= overlays_lying[SHOES_LAYER] - overlays -= overlays_standing[SHOES_LAYER] - overlays_lying[SHOES_LAYER] = null - overlays_standing[SHOES_LAYER] = null - if(update_icons) update_icons() + + if(shoes.blood_DNA) + lying.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="shoeblood2") + standing.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="shoeblood") + + apply_overlay(SHOES_LAYER) -/mob/living/carbon/human/update_inv_s_store(var/update_icons=1) + +/mob/living/carbon/human/update_inv_s_store() + remove_overlay(SUIT_STORE_LAYER) + if(s_store) if(client && hud_used && hud_used.hud_shown) s_store.screen_loc = ui_sstore1 //TODO client.screen += s_store - overlays -= overlays_lying[SUIT_STORE_LAYER] - overlays -= overlays_standing[SUIT_STORE_LAYER] + var/t_state = s_store.item_state if(!t_state) t_state = s_store.icon_state - overlays_lying[SUIT_STORE_LAYER] = image("icon" = 'icons/mob/belt_mirror.dmi', "icon_state" = "[t_state]2", "layer" = -SUIT_STORE_LAYER) - overlays_standing[SUIT_STORE_LAYER] = image("icon" = 'icons/mob/belt_mirror.dmi', "icon_state" = "[t_state]", "layer" = -SUIT_STORE_LAYER) - if (src.lying) - overlays += overlays_lying[SUIT_STORE_LAYER] - else - overlays += overlays_standing[SUIT_STORE_LAYER] - else - overlays -= overlays_lying[SUIT_STORE_LAYER] - overlays -= overlays_standing[SUIT_STORE_LAYER] - overlays_lying[SUIT_STORE_LAYER] = null - overlays_standing[SUIT_STORE_LAYER] = null - if(update_icons) update_icons() + overlays_lying[SUIT_STORE_LAYER] = image("icon"='icons/mob/belt_mirror.dmi', "icon_state"="[t_state]2", "layer"=-SUIT_STORE_LAYER) + overlays_standing[SUIT_STORE_LAYER] = image("icon"='icons/mob/belt_mirror.dmi', "icon_state"="[t_state]", "layer"=-SUIT_STORE_LAYER) + + apply_overlay(SUIT_STORE_LAYER) -/mob/living/carbon/human/update_inv_head(var/update_icons=1) + +/mob/living/carbon/human/update_inv_head() + remove_overlay(HEAD_LAYER) + if(head) if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) head.screen_loc = ui_head //TODO client.screen += head - overlays -= overlays_lying[HEAD_LAYER] - overlays -= overlays_standing[HEAD_LAYER] + var/image/lying var/image/standing if(istype(head,/obj/item/clothing/head/kitty)) - lying = image("icon" = head:mob2, "layer" = -HEAD_LAYER) - standing = image("icon" = head:mob, "layer" = -HEAD_LAYER) + var/obj/item/clothing/head/kitty/K = head + lying = image("icon"=K.mob2, "layer"=-HEAD_LAYER) + standing = image("icon"=K.mob, "layer"=-HEAD_LAYER) else - lying = image("icon" = 'icons/mob/head.dmi', "icon_state" = "[head.icon_state]2", "layer" = -HEAD_LAYER) - standing = image("icon" = 'icons/mob/head.dmi', "icon_state" = "[head.icon_state]", "layer" = -HEAD_LAYER) - if(head.blood_DNA) - lying.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "helmetblood2") - standing.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "helmetblood") + lying = image("icon"='icons/mob/head.dmi', "icon_state"="[head.icon_state]2", "layer"=-HEAD_LAYER) + standing = image("icon"='icons/mob/head.dmi', "icon_state"="[head.icon_state]", "layer"=-HEAD_LAYER) overlays_lying[HEAD_LAYER] = lying overlays_standing[HEAD_LAYER] = standing - if (src.lying) - overlays += overlays_lying[HEAD_LAYER] - else - overlays += overlays_standing[HEAD_LAYER] - else - overlays -= overlays_lying[HEAD_LAYER] - overlays -= overlays_standing[HEAD_LAYER] - overlays_lying[HEAD_LAYER] = null - overlays_standing[HEAD_LAYER] = null - if(update_icons) update_icons() + + if(head.blood_DNA) + lying.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="helmetblood2") + standing.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="helmetblood") + + apply_overlay(HEAD_LAYER) -/mob/living/carbon/human/update_inv_belt(var/update_icons=1) + +/mob/living/carbon/human/update_inv_belt() + remove_overlay(BELT_LAYER) + if(belt) if(client && hud_used && hud_used.hud_shown) - belt.screen_loc = ui_belt //TODO + belt.screen_loc = ui_belt client.screen += belt - overlays -= overlays_lying[BELT_LAYER] - overlays -= overlays_standing[BELT_LAYER] + var/t_state = belt.item_state if(!t_state) t_state = belt.icon_state - overlays_lying[BELT_LAYER] = image("icon" = 'icons/mob/belt.dmi', "icon_state" = "[t_state]2", "layer" = -BELT_LAYER) - overlays_standing[BELT_LAYER] = image("icon" = 'icons/mob/belt.dmi', "icon_state" = "[t_state]", "layer" = -BELT_LAYER) - if (src.lying) - overlays += overlays_lying[BELT_LAYER] - else - overlays += overlays_standing[BELT_LAYER] - else - overlays -= overlays_lying[BELT_LAYER] - overlays -= overlays_standing[BELT_LAYER] - overlays_lying[BELT_LAYER] = null - overlays_standing[BELT_LAYER] = null - if(update_icons) update_icons() + overlays_lying[BELT_LAYER] = image("icon"='icons/mob/belt.dmi', "icon_state"="[t_state]2", "layer"=-BELT_LAYER) + overlays_standing[BELT_LAYER] = image("icon"='icons/mob/belt.dmi', "icon_state"="[t_state]", "layer"=-BELT_LAYER) + + apply_overlay(BELT_LAYER) -/mob/living/carbon/human/update_inv_wear_suit(var/update_icons=1) - if( wear_suit && istype(wear_suit, /obj/item/clothing/suit) ) //TODO check this + +/mob/living/carbon/human/update_inv_wear_suit() + remove_overlay(SUIT_LAYER) + + if(istype(wear_suit, /obj/item/clothing/suit)) if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) wear_suit.screen_loc = ui_oclothing //TODO client.screen += wear_suit - overlays -= overlays_lying[SUIT_LAYER] - overlays -= overlays_standing[SUIT_LAYER] - var/image/lying = image("icon" = 'icons/mob/suit.dmi', "icon_state" = "[wear_suit.icon_state]2", "layer" = -SUIT_LAYER) - var/image/standing = image("icon" = 'icons/mob/suit.dmi', "icon_state" = "[wear_suit.icon_state]", "layer" = -SUIT_LAYER) - - if(FAT in mutations) - if(!wear_suit.flags&ONESIZEFITSALL) - src << "\red You burst out of \the [wear_suit]!" - var/obj/item/clothing/c = wear_suit - wear_suit = null - if(client) - client.screen -= c - c.loc = loc - c.dropped(src) - c.layer = initial(c.layer) - lying = null - standing = null - - else - if( istype(wear_suit, /obj/item/clothing/suit/straight_jacket) ) - drop_from_inventory(handcuffed) - drop_l_hand() - drop_r_hand() - - if(wear_suit.blood_DNA) - var/obj/item/clothing/suit/S = wear_suit - lying.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "[S.blood_overlay_type]blood2") - standing.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "[S.blood_overlay_type]blood") - + + var/image/lying = image("icon"='icons/mob/suit.dmi', "icon_state"="[wear_suit.icon_state]2", "layer"=-SUIT_LAYER) + var/image/standing = image("icon"='icons/mob/suit.dmi', "icon_state"="[wear_suit.icon_state]", "layer"=-SUIT_LAYER) overlays_lying[SUIT_LAYER] = lying overlays_standing[SUIT_LAYER] = standing - if (src.lying) - overlays += overlays_lying[SUIT_LAYER] - else - overlays += overlays_standing[SUIT_LAYER] - else - overlays -= overlays_lying[SUIT_LAYER] - overlays -= overlays_standing[SUIT_LAYER] - overlays_lying[SUIT_LAYER] = null - overlays_standing[SUIT_LAYER] = null - if(update_icons) update_icons() -/mob/living/carbon/human/update_inv_pockets(var/update_icons=1) + if(istype(wear_suit, /obj/item/clothing/suit/straight_jacket)) + drop_from_inventory(handcuffed) + drop_l_hand() + drop_r_hand() + + if(wear_suit.blood_DNA) + var/obj/item/clothing/suit/S = wear_suit + lying.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="[S.blood_overlay_type]blood2") + standing.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="[S.blood_overlay_type]blood") + + apply_overlay(SUIT_LAYER) + + +/mob/living/carbon/human/update_inv_pockets() if(l_store) if(client && hud_used && hud_used.hud_shown) l_store.screen_loc = ui_storage1 //TODO @@ -709,54 +529,42 @@ Please contact me on #coderbus IRC. ~Carn x if(client && hud_used && hud_used.hud_shown) r_store.screen_loc = ui_storage2 //TODO client.screen += r_store - if(update_icons) update_icons() -/mob/living/carbon/human/update_inv_wear_mask(var/update_icons=1) - if( wear_mask && istype(wear_mask, /obj/item/clothing/mask) ) +/mob/living/carbon/human/update_inv_wear_mask() + remove_overlay(FACEMASK_LAYER) + + if(istype(wear_mask, /obj/item/clothing/mask)) if(client && hud_used && hud_used.hud_shown && hud_used.inventory_shown) wear_mask.screen_loc = ui_mask //TODO client.screen += wear_mask - overlays -= overlays_lying[FACEMASK_LAYER] - overlays -= overlays_standing[FACEMASK_LAYER] - var/image/lying = image("icon" = 'icons/mob/mask.dmi', "icon_state" = "[wear_mask.icon_state]2", "layer" = -FACEMASK_LAYER) - var/image/standing = image("icon" = 'icons/mob/mask.dmi', "icon_state" = "[wear_mask.icon_state]", "layer" = -FACEMASK_LAYER) - if( !istype(wear_mask, /obj/item/clothing/mask/cigarette) && wear_mask.blood_DNA ) - lying.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "maskblood2") - standing.overlays += image("icon" = 'icons/effects/blood.dmi', "icon_state" = "maskblood") + + var/image/lying = image("icon"='icons/mob/mask.dmi', "icon_state"="[wear_mask.icon_state]2", "layer"=-FACEMASK_LAYER) + var/image/standing = image("icon"='icons/mob/mask.dmi', "icon_state"="[wear_mask.icon_state]", "layer"=-FACEMASK_LAYER) overlays_lying[FACEMASK_LAYER] = lying overlays_standing[FACEMASK_LAYER] = standing - if (src.lying) - overlays += overlays_lying[FACEMASK_LAYER] - else - overlays += overlays_standing[FACEMASK_LAYER] - else - overlays -= overlays_lying[FACEMASK_LAYER] - overlays -= overlays_standing[FACEMASK_LAYER] - overlays_lying[FACEMASK_LAYER] = null - overlays_standing[FACEMASK_LAYER] = null - if(update_icons) update_icons() + + if(wear_mask.blood_DNA && !istype(wear_mask, /obj/item/clothing/mask/cigarette)) + lying.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="maskblood2") + standing.overlays += image("icon"='icons/effects/blood.dmi', "icon_state"="maskblood") + + apply_overlay(FACEMASK_LAYER) -/mob/living/carbon/human/update_inv_back(var/update_icons=1) + +/mob/living/carbon/human/update_inv_back() + remove_overlay(BACK_LAYER) + if(back) if(client && hud_used && hud_used.hud_shown) back.screen_loc = ui_back //TODO client.screen += back - overlays -= overlays_lying[BACK_LAYER] - overlays -= overlays_standing[BACK_LAYER] - overlays_lying[BACK_LAYER] = image("icon" = 'icons/mob/back.dmi', "icon_state" = "[back.icon_state]2", "layer" = -BACK_LAYER) - overlays_standing[BACK_LAYER] = image("icon" = 'icons/mob/back.dmi', "icon_state" = "[back.icon_state]", "layer" = -BACK_LAYER) - if (src.lying) - overlays += overlays_lying[BACK_LAYER] - else - overlays += overlays_standing[BACK_LAYER] - else - overlays -= overlays_lying[BACK_LAYER] - overlays -= overlays_standing[BACK_LAYER] - overlays_lying[BACK_LAYER] = null - overlays_standing[BACK_LAYER] = null - if(update_icons) update_icons() + + overlays_lying[BACK_LAYER] = image("icon"='icons/mob/back.dmi', "icon_state"="[back.icon_state]2", "layer"=-BACK_LAYER) + overlays_standing[BACK_LAYER] = image("icon"='icons/mob/back.dmi', "icon_state"="[back.icon_state]", "layer"=-BACK_LAYER) + + apply_overlay(BACK_LAYER) + /mob/living/carbon/human/update_hud() //TODO: do away with this if possible @@ -766,7 +574,9 @@ Please contact me on #coderbus IRC. ~Carn x hud_used.hidden_inventory_update() //Updates the screenloc of the items on the 'other' inventory bar -/mob/living/carbon/human/update_inv_handcuffed(var/update_icons=1) +/mob/living/carbon/human/update_inv_handcuffed() + remove_overlay(HANDCUFF_LAYER) + if(handcuffed) drop_r_hand() drop_l_hand() @@ -774,84 +584,72 @@ Please contact me on #coderbus IRC. ~Carn x if(hud_used) //hud handcuff icons var/obj/screen/inventory/R = hud_used.adding[3] var/obj/screen/inventory/L = hud_used.adding[4] - R.overlays += image("icon" = 'icons/mob/screen_gen.dmi', "icon_state" = "markus") - L.overlays += image("icon" = 'icons/mob/screen_gen.dmi', "icon_state" = "gabrielle") - overlays -= overlays_lying[HANDCUFF_LAYER] - overlays -= overlays_standing[HANDCUFF_LAYER] - overlays_lying[HANDCUFF_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "handcuff2", "layer" = -HANDCUFF_LAYER) - overlays_standing[HANDCUFF_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "handcuff1", "layer" = -HANDCUFF_LAYER) - if(src.lying) - overlays += overlays_lying[HANDCUFF_LAYER] - else - overlays += overlays_standing[HANDCUFF_LAYER] + R.overlays += image("icon"='icons/mob/screen_gen.dmi', "icon_state"="markus") + L.overlays += image("icon"='icons/mob/screen_gen.dmi', "icon_state"="gabrielle") + + overlays_lying[HANDCUFF_LAYER] = image("icon"='icons/mob/mob.dmi', "icon_state"="handcuff2", "layer"=-HANDCUFF_LAYER) + overlays_standing[HANDCUFF_LAYER] = image("icon"='icons/mob/mob.dmi', "icon_state"="handcuff1", "layer"=-HANDCUFF_LAYER) else if(hud_used) var/obj/screen/inventory/R = hud_used.adding[3] var/obj/screen/inventory/L = hud_used.adding[4] R.overlays = null L.overlays = null - overlays -= overlays_lying[HANDCUFF_LAYER] - overlays -= overlays_standing[HANDCUFF_LAYER] - overlays_lying[HANDCUFF_LAYER] = null - overlays_standing[HANDCUFF_LAYER] = null - if(update_icons) update_icons() + + apply_overlay(HANDCUFF_LAYER) -/mob/living/carbon/human/update_inv_legcuffed(var/update_icons=1) + +/mob/living/carbon/human/update_inv_legcuffed() + remove_overlay(LEGCUFF_LAYER) + if(legcuffed) - overlays -= overlays_lying[LEGCUFF_LAYER] - overlays -= overlays_standing[LEGCUFF_LAYER] - overlays_lying[LEGCUFF_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "legcuff2", "layer" = -LEGCUFF_LAYER) - overlays_standing[LEGCUFF_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "legcuff1", "layer" = -LEGCUFF_LAYER) - if(src.lying) - overlays += overlays_lying[LEGCUFF_LAYER] - else - overlays += overlays_standing[LEGCUFF_LAYER] if(src.m_intent != "walk") src.m_intent = "walk" if(src.hud_used && src.hud_used.move_intent) src.hud_used.move_intent.icon_state = "walking" + + overlays_lying[LEGCUFF_LAYER] = image("icon"='icons/mob/mob.dmi', "icon_state"="legcuff2", "layer"=-LEGCUFF_LAYER) + overlays_standing[LEGCUFF_LAYER] = image("icon"='icons/mob/mob.dmi', "icon_state"="legcuff1", "layer"=-LEGCUFF_LAYER) - else - overlays -= overlays_lying[LEGCUFF_LAYER] - overlays -= overlays_standing[LEGCUFF_LAYER] - overlays_lying[LEGCUFF_LAYER] = null - overlays_standing[LEGCUFF_LAYER] = null - if(update_icons) update_icons() + apply_overlay(LEGCUFF_LAYER) -/mob/living/carbon/human/update_inv_r_hand(var/update_icons=1) + +/mob/living/carbon/human/update_inv_r_hand() + remove_overlay(R_HAND_LAYER) + if(r_hand) if(client) r_hand.screen_loc = ui_rhand //TODO client.screen += r_hand + var/t_state = r_hand.item_state if(!t_state) t_state = r_hand.icon_state - overlays -= overlays_standing[R_HAND_LAYER] - overlays_standing[R_HAND_LAYER] = image("icon" = 'icons/mob/items_righthand.dmi', "icon_state" = "[t_state]", "layer" = -R_HAND_LAYER) - overlays += overlays_standing[R_HAND_LAYER] - else - overlays -= overlays_standing[R_HAND_LAYER] - overlays_standing[R_HAND_LAYER] = null - if(update_icons) update_icons() + + overlays_standing[R_HAND_LAYER] = image("icon"='icons/mob/items_righthand.dmi', "icon_state"="[t_state]", "layer"=-R_HAND_LAYER) + + apply_overlay(R_HAND_LAYER) -/mob/living/carbon/human/update_inv_l_hand(var/update_icons=1) + +/mob/living/carbon/human/update_inv_l_hand() + remove_overlay(L_HAND_LAYER) + if(l_hand) if(client) l_hand.screen_loc = ui_lhand //TODO client.screen += l_hand + var/t_state = l_hand.item_state if(!t_state) t_state = l_hand.icon_state - overlays -= overlays_standing[L_HAND_LAYER] - overlays_standing[L_HAND_LAYER] = image("icon" = 'icons/mob/items_lefthand.dmi', "icon_state" = "[t_state]", "layer" = -L_HAND_LAYER) - overlays += overlays_standing[L_HAND_LAYER] - else - overlays -= overlays_standing[L_HAND_LAYER] - overlays_standing[L_HAND_LAYER] = null - if(update_icons) update_icons() + + overlays_standing[L_HAND_LAYER] = image("icon"='icons/mob/items_lefthand.dmi', "icon_state"="[t_state]", "layer"=-L_HAND_LAYER) + + apply_overlay(L_HAND_LAYER) + //Human Overlays Indexes///////// -#undef MUTANTRACE_LAYER +#undef BODY_LAYER #undef MUTATIONS_LAYER #undef DAMAGE_LAYER #undef UNIFORM_LAYER diff --git a/code/modules/mob/living/carbon/metroid/metroid.dm b/code/modules/mob/living/carbon/metroid/metroid.dm index d565fd874ce..62485667501 100644 --- a/code/modules/mob/living/carbon/metroid/metroid.dm +++ b/code/modules/mob/living/carbon/metroid/metroid.dm @@ -62,9 +62,7 @@ /mob/living/carbon/slime/New() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) name = text("[colour] baby slime ([rand(1, 1000)])") real_name = name spawn (1) @@ -722,9 +720,7 @@ mob/living/carbon/slime/var/temperature_resistance = T0C+75 /obj/item/slime_extract/New() ..() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) /obj/item/slime_extract/grey name = "grey slime extract" @@ -1082,9 +1078,7 @@ mob/living/carbon/slime/var/temperature_resistance = T0C+75 /obj/item/slime_core/New() ..() - var/datum/reagents/R = new/datum/reagents(100) - reagents = R - R.my_atom = src + create_reagents(100) POWERFLAG = rand(1,10) Uses = rand(7, 25) //flags |= NOREACT diff --git a/code/modules/mob/living/carbon/monkey/monkey.dm b/code/modules/mob/living/carbon/monkey/monkey.dm index 1beac95ed93..6f381e56834 100644 --- a/code/modules/mob/living/carbon/monkey/monkey.dm +++ b/code/modules/mob/living/carbon/monkey/monkey.dm @@ -10,9 +10,7 @@ update_icon = 0 ///no need to call regenerate_icon /mob/living/carbon/monkey/New() - var/datum/reagents/R = new/datum/reagents(1000) - reagents = R - R.my_atom = src + create_reagents(1000) internal_organs += new /obj/item/organ/appendix internal_organs += new /obj/item/organ/heart @@ -47,11 +45,6 @@ now_pushing = 1 if(ismob(AM)) var/mob/tmob = AM - if(istype(tmob, /mob/living/carbon/human) && (HULK in tmob.mutations)) - if(prob(70)) - usr << "\red You fail to push [tmob]'s fat ass out of the way." - now_pushing = 0 - return if(!(tmob.status_flags & CANPUSH)) now_pushing = 0 return diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 46a7d09e551..7812fd2bc13 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -41,7 +41,7 @@ for(var/datum/limb/affecting in H.organs) if(!affecting) continue if(affecting.take_damage(0, divided_damage+extradam)) //TODO: fix the extradam stuff. Or, ebtter yet...rewrite this entire proc ~Carn - H.UpdateDamageIcon(0) + H.update_damage_overlays(0) H.updatehealth() return 1 else if(istype(src, /mob/living/carbon/monkey)) @@ -260,7 +260,7 @@ ..() return -/mob/living/proc/UpdateDamageIcon() +/mob/living/proc/update_damage_overlays() return diff --git a/code/modules/mob/living/say.dm b/code/modules/mob/living/say.dm index 4f12b17ef9d..2eda94c37f1 100644 --- a/code/modules/mob/living/say.dm +++ b/code/modules/mob/living/say.dm @@ -14,6 +14,7 @@ var/list/department_radio_keys = list( ":a" = "alientalk", "#a" = "alientalk", ".a" = "alientalk", ":t" = "Syndicate", "#t" = "Syndicate", ".t" = "Syndicate", ":u" = "Supply", "#u" = "Supply", ".u" = "Supply", + ":v" = "Service", "#v" = "Service", ".v" = "Service", ":g" = "changeling", "#g" = "changeling", ".g" = "changeling", ":R" = "right hand", "#R" = "right hand", ".R" = "right hand", @@ -30,6 +31,7 @@ var/list/department_radio_keys = list( ":A" = "alientalk", "#A" = "alientalk", ".A" = "alientalk", ":T" = "Syndicate", "#T" = "Syndicate", ".T" = "Syndicate", ":U" = "Supply", "#U" = "Supply", ".U" = "Supply", + ":V" = "Service", "#V" = "Service", ".V" = "Service", ":G" = "changeling", "#G" = "changeling", ".G" = "changeling", //kinda localization -- rastaf0 diff --git a/code/modules/mob/living/silicon/pai/hud.dm b/code/modules/mob/living/silicon/pai/hud.dm index 78cd8a00b99..c1f1a4b3eda 100644 --- a/code/modules/mob/living/silicon/pai/hud.dm +++ b/code/modules/mob/living/silicon/pai/hud.dm @@ -34,7 +34,7 @@ client.images += holder break else if((R.fields["id"] == E.fields["id"]) && (R.fields["criminal"] == "Incarcerated")) - holder.icon_state = "hudprisoner" + holder.icon_state = "hudincarcerated" client.images += holder break else if((R.fields["id"] == E.fields["id"]) && (R.fields["criminal"] == "Parolled")) diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm index 78a2070aedc..2f513e5c0a4 100644 --- a/code/modules/mob/living/silicon/robot/robot.dm +++ b/code/modules/mob/living/silicon/robot/robot.dm @@ -327,11 +327,6 @@ now_pushing = 1 if(ismob(AM)) var/mob/tmob = AM - if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations)) - if(prob(20)) - usr << "\red You fail to push [tmob]'s fat ass out of the way." - now_pushing = 0 - return if(!(tmob.status_flags & CANPUSH)) now_pushing = 0 return diff --git a/code/modules/mob/living/simple_animal/constructs.dm b/code/modules/mob/living/simple_animal/constructs.dm index e2ed726be3a..6e597ffbe1d 100644 --- a/code/modules/mob/living/simple_animal/constructs.dm +++ b/code/modules/mob/living/simple_animal/constructs.dm @@ -60,11 +60,6 @@ now_pushing = 1 if(ismob(AM)) var/mob/tmob = AM - if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations)) - if(prob(5)) - src << "\red You fail to push [tmob]'s fat ass out of the way." - now_pushing = 0 - return if(!(tmob.status_flags & CANPUSH)) now_pushing = 0 return diff --git a/code/modules/mob/living/simple_animal/friendly/corgi.dm b/code/modules/mob/living/simple_animal/friendly/corgi.dm index 5fb5eca6582..7475984be61 100644 --- a/code/modules/mob/living/simple_animal/friendly/corgi.dm +++ b/code/modules/mob/living/simple_animal/friendly/corgi.dm @@ -40,7 +40,7 @@ else dat += " Back: Nothing" - user << browse(dat, text("window=mob[];size=325x500", name)) + user << browse(dat, text("window=mob[];size=325x500", real_name)) onclose(user, "mob[real_name]") return @@ -82,6 +82,7 @@ SetLuminosity(0) inventory_head.loc = src.loc inventory_head = null + regenerate_icons() else usr << "\red There is nothing to remove from its [remove_from]." return @@ -89,76 +90,23 @@ if(inventory_back) inventory_back.loc = src.loc inventory_back = null + regenerate_icons() else usr << "\red There is nothing to remove from its [remove_from]." return - //show_inv(usr) //Commented out because changing Ian's name and then calling up his inventory opens a new inventory...which is annoying. + show_inv(usr) //Adding things to inventory else if(href_list["add_inv"]) if(get_dist(src,usr) > 1 || !(ishuman(usr) || ismonkey(usr) || isrobot(usr) || isalienadult(usr))) return + var/add_to = href_list["add_inv"] - if(!usr.get_active_hand()) - usr << "\red You have nothing in your hand to put on its [add_to]." - return + switch(add_to) if("head") - if(inventory_head) - usr << "\red It's is already wearing something." - return - else - place_on_head(usr.get_active_hand()) - - var/obj/item/item_to_add = usr.get_active_hand() - if(!item_to_add) - return - - //Corgis are supposed to be simpler, so only a select few objects can actually be put - //to be compatible with them. The objects are below. - //Many hats added, Some will probably be removed, just want to see which ones are popular. - - var/list/allowed_types = list( - /obj/item/clothing/head/helmet, - /obj/item/clothing/glasses/sunglasses, - /obj/item/clothing/head/caphat, - /obj/item/clothing/head/collectable/captain, - /obj/item/clothing/head/that, - /obj/item/clothing/head/that, - /obj/item/clothing/head/kitty, - /obj/item/clothing/head/collectable/kitty, - /obj/item/clothing/head/rabbitears, - /obj/item/clothing/head/collectable/rabbitears, - /obj/item/clothing/head/beret, - /obj/item/clothing/head/collectable/beret, - /obj/item/clothing/head/det_hat, - /obj/item/clothing/head/nursehat, - /obj/item/clothing/head/pirate, - /obj/item/clothing/head/collectable/pirate, - /obj/item/clothing/head/ushanka, - /obj/item/clothing/head/chefhat, - /obj/item/clothing/head/collectable/chef, - /obj/item/clothing/head/collectable/police, - /obj/item/clothing/head/wizard/fake, - /obj/item/clothing/head/wizard, - /obj/item/clothing/head/collectable/wizard, - /obj/item/clothing/head/hardhat, - /obj/item/clothing/head/collectable/hardhat, - /obj/item/clothing/head/hardhat/white, - /obj/item/weapon/bedsheet, - /obj/item/clothing/head/helmet/space/santahat, - /obj/item/clothing/head/collectable/paper, - /obj/item/clothing/head/soft - ) - - if( ! ( item_to_add.type in allowed_types ) ) - usr << "\red It doesn't seem too keen on wearing that item." - return - - usr.drop_item() - - place_on_head(item_to_add) + place_on_head(usr.get_active_hand()) if("back") if(inventory_back) @@ -166,7 +114,12 @@ return else var/obj/item/item_to_add = usr.get_active_hand() + if(!item_to_add) + usr.visible_message("\blue [usr] pets [src]","\blue You rest your hand on [src]'s back for a moment.") + return + if(istype(item_to_add,/obj/item/weapon/plastique)) // last thing he ever wears, I guess + item_to_add.afterattack(src,usr,1) return //Corgis are supposed to be simpler, so only a select few objects can actually be put @@ -178,7 +131,14 @@ ) if( ! ( item_to_add.type in allowed_types ) ) - usr << "\red This object won't fit." + usr << "You set [item_to_add] on [src]'s back, but \he shakes it off!" + usr.drop_item() + item_to_add.loc = loc + if(prob(25)) + step_rand(item_to_add) + for(var/i in list(1,2,4,8,4,8,4,dir)) + dir = i + sleep(1) return usr.drop_item() @@ -186,73 +146,147 @@ src.inventory_back = item_to_add regenerate_icons() - //show_inv(usr) //Commented out because changing Ian's name and then calling up his inventory opens a new inventory...which is annoying. + show_inv(usr) else ..() +//Corgis are supposed to be simpler, so only a select few objects can actually be put +//to be compatible with them. The objects are below. +//Many hats added, Some will probably be removed, just want to see which ones are popular. /mob/living/simple_animal/corgi/proc/place_on_head(obj/item/item_to_add) - item_to_add.loc = src - src.inventory_head = item_to_add - regenerate_icons() - //Various hats and items (worn on his head) change Ian's behaviour. His attributes are reset when a HAT is removed. - switch(inventory_head && inventory_head.type) + if(istype(item_to_add,/obj/item/weapon/plastique)) // last thing he ever wears, I guess + item_to_add.afterattack(src,usr,1) + return + + if(inventory_head) + usr << "\red You can't put more than one hat on [src]!" + return + if(!item_to_add) + usr.visible_message("\blue [usr] pets [src]","\blue You rest your hand on [src]'s head for a moment.") + return + + + var/valid = 0 + + //Various hats and items (worn on his head) change Ian's behaviour. His attributes are reset when a hat is removed. + switch(item_to_add.type) + if( /obj/item/clothing/glasses/sunglasses, /obj/item/clothing/head/that, /obj/item/clothing/head/collectable/paper, + /obj/item/clothing/head/hardhat, /obj/item/clothing/head/collectable/hardhat,/obj/item/clothing/head/hardhat/white, /obj/item/weapon/paper ) + valid = 1 + + if(/obj/item/clothing/head/helmet) + name = "Sergeant [real_name]" + desc = "The ever-loyal, the ever-vigilant." + valid = 1 + + if(/obj/item/clothing/head/chefhat, /obj/item/clothing/head/collectable/chef) + name = "Sous chef [real_name]" + desc = "Your food will be taste-tested. All of it." + valid = 1 + if(/obj/item/clothing/head/caphat, /obj/item/clothing/head/collectable/captain) name = "Captain [real_name]" desc = "Probably better than the last captain." + valid = 1 + if(/obj/item/clothing/head/kitty, /obj/item/clothing/head/collectable/kitty) name = "Runtime" emote_see = list("coughs up a furball", "stretches") emote_hear = list("purrs") speak = list("Purrr", "Meow!", "MAOOOOOW!", "HISSSSS", "MEEEEEEW") desc = "It's a cute little kitty-cat! ... wait ... what the hell?" + valid = 1 + if(/obj/item/clothing/head/rabbitears, /obj/item/clothing/head/collectable/rabbitears) name = "Hoppy" emote_see = list("twitches its nose", "hops around a bit") desc = "This is hoppy. It's a corgi-...urmm... bunny rabbit" + valid = 1 + if(/obj/item/clothing/head/beret, /obj/item/clothing/head/collectable/beret) name = "Yann" desc = "Mon dieu! C'est un chien!" speak = list("le woof!", "le bark!", "JAPPE!!") emote_see = list("cowers in fear", "surrenders", "plays dead","looks as though there is a wall in front of him") + valid = 1 + if(/obj/item/clothing/head/det_hat) name = "Detective [real_name]" desc = "[name] sees through your lies..." emote_see = list("investigates the area","sniffs around for clues","searches for scooby snacks") + valid = 1 + if(/obj/item/clothing/head/nursehat) name = "Nurse [real_name]" desc = "[name] needs 100cc of beef jerky...STAT!" + valid = 1 + if(/obj/item/clothing/head/pirate, /obj/item/clothing/head/collectable/pirate) name = "[pick("Ol'","Scurvy","Black","Rum","Gammy","Bloody","Gangrene","Death","Long-John")] [pick("kibble","leg","beard","tooth","poop-deck","Threepwood","Le Chuck","corsair","Silver","Crusoe")]" desc = "Yaarghh!! Thar' be a scurvy dog!" emote_see = list("hunts for treasure","stares coldly...","gnashes his tiny corgi teeth") emote_hear = list("growls ferociously", "snarls") speak = list("Arrrrgh!!","Grrrrrr!") + valid = 1 + if(/obj/item/clothing/head/ushanka) name = "[pick("Comrade","Commissar","Glorious Leader")] [real_name]" desc = "A follower of Karl Barx." emote_see = list("contemplates the failings of the capitalist economic model", "ponders the pros and cons of vangaurdism") + valid = 1 + if(/obj/item/clothing/head/collectable/police) name = "Officer [real_name]" emote_see = list("drools","looks for donuts") desc = "Stop right there criminal scum!" + valid = 1 + if(/obj/item/clothing/head/wizard/fake, /obj/item/clothing/head/wizard, /obj/item/clothing/head/collectable/wizard) name = "Grandwizard [real_name]" speak = list("YAP", "Woof!", "Bark!", "AUUUUUU", "EI NATH!") + valid = 1 + if(/obj/item/weapon/bedsheet) name = "\improper Ghost" speak = list("WoooOOOooo~","AUUUUUUUUUUUUUUUUUU") emote_see = list("stumbles around", "shivers") emote_hear = list("howls","groans") desc = "Spooky!" + valid = 1 + if(/obj/item/clothing/head/helmet/space/santahat) name = "Rudolph the Red-Nosed Corgi" emote_hear = list("barks christmas songs", "yaps") desc = "He has a very shiny nose." SetLuminosity(4) + valid = 1 + if(/obj/item/clothing/head/soft) name = "Corgi Tech [real_name]" desc = "The reason your yellow gloves have chew-marks." + valid = 1 + + if(valid) + usr.visible_message("[usr] puts [item_to_add] on [real_name]'s head. [src] looks at [usr] and barks once.", + "You put [item_to_add] on [real_name]'s head. [src] gives you a peculiar look, then wags \his tail once and barks.", + "You hear a friendly-sounding bark.") + usr.drop_item() + item_to_add.loc = src + src.inventory_head = item_to_add + regenerate_icons() + + else + usr << "You set [item_to_add] on [src]'s head, but \he shakes it off!" + usr.drop_item() + item_to_add.loc = loc + if(prob(25)) + step_rand(item_to_add) + for(var/i in list(1,2,4,8,4,8,4,dir)) + dir = i + sleep(1) + + return valid //IAN! SQUEEEEEEEEE~ @@ -309,7 +343,7 @@ movement_target.attack_animal(src) else if(ishuman(movement_target.loc) ) if(prob(20)) - emote("stares at the [movement_target] that [movement_target.loc] has with a sad puppy-face") + emote("stares at [movement_target.loc]'s [movement_target] with a sad puppy-face") if(prob(1)) emote(pick("dances around","chases its tail")) @@ -326,11 +360,6 @@ now_pushing = 1 if(ismob(AM)) var/mob/tmob = AM - if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations)) - if(prob(70)) - src << "\red You fail to push [tmob]'s fat ass out of the way." - now_pushing = 0 - return if(!(tmob.status_flags & CANPUSH)) now_pushing = 0 return @@ -358,9 +387,7 @@ /mob/living/simple_animal/corgi/attackby(var/obj/item/O as obj, var/mob/user as mob) //Marker -Agouri if(istype(O, /obj/item/weapon/newspaper)) if(!stat) - for(var/mob/M in viewers(user, null)) - if ((M.client && !( M.blinded ))) - M.show_message("\blue [user] baps [name] on the nose with the rolled up [O]") + user.visible_message("\blue [user] baps [name] on the nose with the rolled up [O]") spawn(0) for(var/i in list(1,2,4,8,4,2,1,2)) dir = i diff --git a/code/modules/mob/living/simple_animal/friendly/farm_animals.dm b/code/modules/mob/living/simple_animal/friendly/farm_animals.dm index 5d79c98fb6b..84d52743fac 100644 --- a/code/modules/mob/living/simple_animal/friendly/farm_animals.dm +++ b/code/modules/mob/living/simple_animal/friendly/farm_animals.dm @@ -140,7 +140,7 @@ var/list/responses = list( "[src] looks at you imploringly.", "[src] looks at you pleadingly", "[src] looks at you with a resigned expression.", - "[src] seems resigned to it's fate.") + "[src] seems resigned to its fate.") M << pick(responses) else ..() diff --git a/code/modules/mob/living/simple_animal/friendly/slime.dm b/code/modules/mob/living/simple_animal/friendly/slime.dm index adb494adec8..0b6c2d00cfe 100644 --- a/code/modules/mob/living/simple_animal/friendly/slime.dm +++ b/code/modules/mob/living/simple_animal/friendly/slime.dm @@ -22,11 +22,6 @@ now_pushing = 1 if(ismob(AM)) var/mob/tmob = AM - if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations)) - if(prob(70)) - src << "\red You fail to push [tmob]'s fat ass out of the way." - now_pushing = 0 - return if(!(tmob.status_flags & CANPUSH)) now_pushing = 0 return diff --git a/code/modules/mob/mob_grab.dm b/code/modules/mob/mob_grab.dm index 7e0cb82f2e6..14ec3a49e10 100644 --- a/code/modules/mob/mob_grab.dm +++ b/code/modules/mob/mob_grab.dm @@ -122,12 +122,6 @@ icon_state = "grabbed1" else if(state < GRAB_NECK) - if(istype(affecting, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = affecting - if(FAT in H.mutations) - assailant << "You can't strangle [affecting] through all that fat!" - return - if(isslime(affecting)) assailant << "You squeeze [affecting], but nothing interesting happens." return diff --git a/code/modules/mob/new_player/preferences_setup.dm b/code/modules/mob/new_player/preferences_setup.dm index d4447280d2a..7cfb72db6c3 100644 --- a/code/modules/mob/new_player/preferences_setup.dm +++ b/code/modules/mob/new_player/preferences_setup.dm @@ -6,7 +6,7 @@ datum/preferences else gender = pick(MALE,FEMALE) underwear = random_underwear(gender) - s_tone = random_skin_tone() + skin_tone = random_skin_tone() h_style = random_hair_style(gender) f_style = random_facial_hair_style(gender) h_color = random_short_color() @@ -23,10 +23,7 @@ datum/preferences var/g = "m" if(gender == FEMALE) g = "f" - preview_icon = new /icon('icons/mob/human.dmi', "body_[g]_s") - - // Skin tone - preview_icon.Blend("#[skin_tones[s_tone]]", ICON_MULTIPLY) + preview_icon = new /icon('icons/mob/human.dmi', "[skin_tone]_[g]_s") if(underwear) var/datum/sprite_accessory/underwear/U = underwear_all[underwear] diff --git a/code/modules/paperwork/paper.dm b/code/modules/paperwork/paper.dm index b2495c0f730..c97fa96e0fe 100644 --- a/code/modules/paperwork/paper.dm +++ b/code/modules/paperwork/paper.dm @@ -323,7 +323,7 @@ /obj/item/weapon/paper/djstation name = "paper - 'DJ Listening Outpost'" - info = "Welcome new owner! You have purchased the latest in listening equipment. The telecommunication setup we created is the best in listening to common and private radio fequencies. Here is a step by step guide to start listening in on those saucy radio channels:
You have purchased the latest in listening equipment. The telecommunication setup we created is the best in listening to common and private radio fequencies. Here is a step by step guide to start listening in on those saucy radio channels:
+
+
+11 May 2013+Malkevin updated:+
+
+
+7 May 2013+Ikarrus updated:+
+
5 May 2013+Rolan7 updated:+
2 May 2013@@ -60,9 +83,14 @@ should be listed in the changelog upon commit tho. Thanks. -->
+
30 April 2013+Ikarrus updated:+
24 April 2013@@ -116,7 +144,7 @@ should be listed in the changelog upon commit tho. Thanks. -->17 April 2013@@ -125,7 +153,7 @@ should be listed in the changelog upon commit tho. Thanks. -->10 April 2013@@ -138,7 +166,7 @@ should be listed in the changelog upon commit tho. Thanks. -->9 April 2013@@ -2708,4 +2736,4 @@ should be listed in the changelog upon commit tho. Thanks. -->Some icons by Yusuke Kamiyamane. All rights reserved. Licensed under a Creative Commons Attribution 3.0 License. |