Removed client check from mob so that if a pAI is being held by a SSD client it can still hear.
Removed 3rd deep .loc check 2 is plenty, and was making the proc rather expensive
(if you shove a pAI in a bag and toss the bag into a locker, the pAI will be deaf, you jerk).
Nano manipulators were not lowering build time at all.
Stock and Pico manipulaors were lowering build time by 6%.
This fixes that. Now: Stock = standard build time, Nano = 6% faster, Pico = 12% faster.
My VERY FIRST PR, I used it to make ghost chat be bold, instead of using viewers() to figure out
what ghosts could see the mob, I used get_mob_in_view() which sounded pretty descriptive.
Unfortunately for me it was one of the most CPU intensive ways of determining who could view the speaker for this.
So yeah, removing the second get_mobs_in_view and replacing it with viewers()
Yes this code has been in since Oct/Nov time frame :(
Before: Everytime you say something. This proc is ran. Along with it, recurses through EVERY /obj/ & /mob/ in view's contents, and EVERY /obj/ & /mob/ in that contents...and once again.
After: Fuck recursion, we're going to loop through clients and see if they are within any obj's or mobs within one iteration. MUCH cheaper, and probably less buggy.
If someone can't hear everyone and they are within an object and it's not catching? add it to the list commented for it of type checks.
- Tweaked the pressure delta check to "> 0.5", so pumps will stop transferring minor volumes of air every tick (because a delta of 3.05176e-005 is still greater than 0). This also reduces the calls to gas_mixture/merge() and gas_mixture/remove() significantly once the air in the environment has equalized.
The results after running the game for 10 minutes:
```
Proc Name Self CPU Total CPU Real Time Calls
/obj/machinery/atmospherics/unary/vent_pump/process 0.035 0.141 0.141 3808 <- before
/obj/machinery/atmospherics/unary/vent_pump/process 0.014 0.042 0.043 3808 <- after
```
Fixes#4447
- Added a parent call to each wardrobe subtypes New() proc.
Wardrobes weren't calling obj/structure/closet/New(), so weren't adding items in the same location to their contents when first created.
- Removed wardrobe/New() proc.
So all subtypes don't inherit an extra set of blue uniforms and brown shoes. Only one wardrobe on the map is of this type, and it's on the derelict, so didn't think it was worth making a map change.
Applys a client side only layer of colors over the various zones to show if they are connected or not.
Green is your current zone
Blue is adjacent zones that are connected.
yellow is zones that are connected but not adjacent to your current zone.
Red is for zones that aren't connected at all.
Before: If a canister is hooked up to a connector port it's icons were being deleted and recreated every tick.
After: We store an update_flag that is a bitfield of the current icon and overlay states, and created a proc to check if it should change. If not, we don't mess with icons. Real simple.
Before: EVERYTIME someone moved their character this proc would be called and loop through every organ looking for implanted items to see if it needs to apply damage.
After: We create a flag that is set when an item embeddes, only when that flag is set do we do that loop through organs upon movement. Also every 10 ticks while that flag
is set we will check to see if we need to unset it.
Because of the wrong direction of this sign, every single solar array was being checked for occlusion every tick.
This should fix that right up.
Trackers set to update their angle only when the sun does.
Solar panels set to calculate occlusion every minute (was every tick (though thought to be set to every 6 minutes (36 degrees)), now checks every 6 degrees of sun movement or so)
Fixes#3676
Before: Toggling would get stuck where it wouldn't toggle the camera until you reset your view.
After: Camera light toggles, you have to toggle off before turning on a new camera light though.
pAI has to be a special little snowflake and have it's own messenger proc instead of letting a AI-PDA handle it.
So, updated it with the newest tnote variable functionality so it can participate.
This is a hacky fix and is temporary until I can sit down and figure out exactly why it's not encoding that block of DNA properly.
The result of it not encoding it into the dna is that if you clone the person they have a random value there that was assigned at round start.
We discovered that most of the problems were were having was because of BYOND passing lists (e.g. SE and UI) by-ref instead of the assumed by-val.
This commit adds dna.Clone() and (UI|SE).Copy() where needed. These should be used where DNA or SE/UI lists are COPIED, otherwise changes made in the reference will affect the real strand.
This change also messes with the gene activation logic.
Conflicts:
code/game/dna/dna2_domutcheck.dm
code/game/dna/genes/powers.dm
Made after DNA2 hit /vg/'s main server after no one tested anything.
* Gene activation/deactivation made modular, refactors domutcheck.
* Standardized genetics disks and injectors a bit in response to buffer corruption issues. (Untested)
* Lots of major bug fixes.
* Skin tones fixed.
Still needs further testing. All I did was mess around with monkeys.
Conflicts:
code/game/dna/dna2.dm
code/game/dna/dna2_domutcheck.dm
code/game/dna/dna2_helpers.dm
code/game/dna/genes/disabilities.dm
code/game/dna/genes/powers.dm
code/modules/mob/living/carbon/monkey/monkey.dm