Commit Graph

2306 Commits

Author SHA1 Message Date
SkyratBot
71067d86c9 [MIRROR] Fixes rad collectors ignoring access requirements for locking. (#7353)
* Fixes rad collector ignoring access requirements for locking. (#60656)

* Fixes rad collectors ignoring access requirements for locking.

Co-authored-by: TemporalOroboros <TemporalOroboros@gmail.com>
2021-08-03 20:06:45 +01:00
Pinta
76f5fd2e1b [NONMODUAR] Fixes mediguns fitting inside turrets and emitters (#7244)
* Guns no longer fit inside of Turrets

* Guns no longer fit inside of Emitters

* linters
2021-08-01 14:20:50 +01:00
SkyratBot
0e021eceea [MIRROR] Fix APC power usage (#7161)
* Fix APC power usage

* Update apc.dm

Co-authored-by: Jordan Brown <Cyberboss@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-07-28 22:04:32 +01:00
SkyratBot
f8f51cbd86 [MIRROR] Kills _globalvars/misc.dm (#7152)
* Kills _globalvars/misc.dm

* aaa

Co-authored-by: tralezab <40974010+tralezab@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-07-28 22:03:21 +01:00
SkyratBot
e341153ed0 [MIRROR] Hulks and larvas will now dust when punching the supermatter (#7036)
* Hulks and larvas will now dust when punching the supermatter (#60307)

* Hulks and larvas will now dust when punching the supermatter

Co-authored-by: TheSmallBlue <ilanmori@hotmail.com>
2021-07-20 14:47:03 +02:00
Gandalf
5e337e0798 AA 2021-07-12 23:09:30 +01:00
SkyratBot
0842c757f9 [MIRROR] makes a bunch of lists that use typecacheof() static. doesnt find out why its overtiming at all but what the hell it helps (#6885)
* makes a bunch of lists that use typecacheof() static. doesnt find out why its overtiming at all but what the hell it helps (#60147)

Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>

* makes a bunch of lists that use typecacheof() static. doesnt find out why its overtiming at all but what the hell it helps

Co-authored-by: Kylerace <kylerlumpkin1@gmail.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>
2021-07-12 22:50:42 +01:00
SkyratBot
1d04e79f6a [MIRROR] Makes Emitter locks silicon compatible (#6812)
* Makes Emitter locks silicon compatible (#60070)

* Makes Emitter locks silicon compatible

Co-authored-by: Wayland-Smithy <64715958+Wayland-Smithy@users.noreply.github.com>
2021-07-10 14:08:28 +01:00
SkyratBot
2a42a55760 [MIRROR] makes some instances of x^y into x**y because thats what exponents are in dm (#6790)
* makes some instances of x^y into x**y because thats what exponents are in dm (#60050)

caught by monster at yogstation13/Yogstation#11703
probably not intended, 2^15 = 13 in dm so dont call this proc more than 13 times sequentially i guess

I have a suspicion that it doesn't matter assuming it gets caught by tick_usage being different but just in case

also fixes two other instances in code shown to me by mso

* makes some instances of x^y into x**y because thats what exponents are in dm

* Update lighting.dm

Co-authored-by: Kylerace <kylerlumpkin1@gmail.com>
Co-authored-by: Useroth <37159550+Useroth@users.noreply.github.com>
2021-07-08 03:41:11 +02:00
jjpark-kb
70926c87ba light replacer fix (#6695) 2021-07-03 22:33:59 +01:00
SkyratBot
de2b2ebbbc [MIRROR] Fix turbine free power exploit (#6689)
* Fix turbine exploit (#59934)

* Fix turbine free power exploit

Co-authored-by: Urumasi <Urumasi@email.cz>
2021-07-03 22:25:35 +01:00
SkyratBot
ad835a6c72 [MIRROR] Fix incorporeal movers procing containment field effects (#6683)
* Fix incorporeal movers procing containment field effects (#59919)

* Fix incorporeal movers procing containment field effects

Co-authored-by: Wayland-Smithy <64715958+Wayland-Smithy@users.noreply.github.com>
2021-07-03 22:24:43 +01:00
Gandalf
dd82e31878 Firelocks are now sentient + better firealarms (#6595)
* yes

* Update firedoor.dm

* manual triggering/garbage cleanup to prevent hardels.

* few fixes, more logic, autoalarms.

* more fixes

* a

* Update firealarm.dm

* Update firealarm.dm

* eee

* a

* a

* Update firedoor.dm

* 0

* signal

* Update firealarm.dm
2021-07-01 23:38:09 +01:00
SkyratBot
cab78dcf78 [MIRROR] Changes how weather sends sound to players, reduces sound loop overtime (#6627)
* Changes how weather sends sound to players, reduces sound loop overtime (#59284)

* Converts looping sounds from a list of play locations to just the one

* Updates all uses of looping sounds to match the new arg

* Adds an area based sound manager that hooks into looping sounds to drive the actual audio. I'll be using this to redo how weather effects handle sound

* Some structrual stuff to make everything else smoother
Timers now properly return the time left for client based timers
Weather sends global signals when it starts/stops
Looping sounds now use their timerid var for all their sound related timers, not just the main loop

* This is the painful part
Adds an area sound manager component, it handles the logic of moving into new areas potentially creating new
sound loops. We do some extra work to prevent stacking sound loops.
Adds an ash storm listener element that adds a tailored area sound manager to clients on the lavaland z level.
It's removed on logout.
Adds the ash_storm_sounds assoc list, a reference to this is passed into area sound managers, and it's modified
in a manner that doesn't break the reference in ash_storm (This is what I hate)

* Hooks ash storm listener into cliented mobs and possessed objects

* Documents the odd ref stuff, adds an ignore start var to looping sounds, fixes some errors and lint issues

* Applies kyler's review

banging

Co-authored-by: Kylerace <kylerlumpkin1@ gmail.com>

* Cleans up some var names, reduces the amount of looping we do in some areas

* Makes the code compile, redoes the movement listener to be more general

* fuck

* We don't need to detach on del if we're just removing signals on detach

* Should? work

* if(direct) memes

Co-authored-by: Kylerace <kylerlumpkin1@ gmail.com>

* Changes how weather sends sound to players, reduces sound loop overtime

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
Co-authored-by: Kylerace <kylerlumpkin1@ gmail.com>
2021-07-01 02:18:04 +01:00
Gandalf
778a589555 Removes a lot of redundant non-modular changes and maybe fixes cleanbots (#6615)
* oof

* Update _ai_controller.dm

* no need for this anymore
2021-06-30 21:50:50 +02:00
SkyratBot
d1b0927117 [MIRROR] fixes singularity beacon (#6592)
* Fix singularity beacon (#59868)

Stops singularity objects from being added to the global singularity list,
this list is only for singularity components.

This fixes singularity beacons breaking because they expect that only
singularity components are in the global singularity list.

* fixes singularity beacon

Co-authored-by: Fikou <piotrbryla@onet.pl>
2021-06-29 21:04:44 +01:00
Gandalf
98e46a709c SSdecay - Making the station dirty(and creepy) (#6480)
* SSDECAY

* Update decaySS.dm

* Update decaySS.dm

* Update decaySS.dm

* Update lighting.dm

* Update decaySS.dm

* Update decaySS.dm

* a

* a

* Update decaySS.dm

* Update decaySS.dm

* Update lighting.dm

* Update decaySS.dm

* Update decaySS.dm

* oof

* Update decaySS.dm

* Update decaySS.dm

* OOPS

* Update nests.dm

* Update nests.dm

* Update nests.dm

* a

* Update nests.dm

* dry blood

* no more light noise

* Update nests.dm

* Update nests.dm

* a

* Update vatbeast.dm

* Update decaySS.dm

* Update nests.dm

* Update decaySS.dm

* Update nests.dm

* bad

* Update nests.dm

* a

* Update nests.dm
2021-06-28 15:41:32 +02:00
SkyratBot
5b2582de27 [MIRROR] Refactors species stomach code, makes ethereal charge inherent to their stomach (#6554)
* Refactors species stomach code, makes ethereal charge inherent to their stomach (#59801)

A stomach would literally just ask the species datum how to be hungry and made a bunch of exceptions for ethereals. I mostly just moved code around so that hunger is handled by a persons stomach, thus shrinking the species.dm bloat.

This also makes it so ethereal's charge mechanic is unique to their stomache, instead of this really weird inbetween where just nothing happens and you kinda starve to death. You can stick an ethereal stomach in a human and this will replace their hunger mechanic with the charge mechanic and lets them absorb power from APCs and everything. You can also give ethereals a normal stomach and they'll use the normal hunger mechanics

* Refactors species stomach code, makes ethereal charge inherent to their stomach

Co-authored-by: Time-Green <timkoster1@hotmail.com>
2021-06-27 16:44:17 +01:00
SkyratBot
79c3c379b9 [MIRROR] Fix missing SIGNAL_HANDLER (#6552)
* Fix missing SIGNAL_HANDLER (#59826)

Adds SIGNAL_HANDLER to everywhere that didn't have it that was picked up by dm-lua, which is now ready enough to catch these.

* Fix missing SIGNAL_HANDLER

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2021-06-27 16:16:04 +01:00
SkyratBot
a14b1dadb5 [MIRROR] CanPass refactor (#6527)
* CanPass refactor (#59804)

* CanPass refactor

Co-authored-by: Rohesie <rohesie@gmail.com>
2021-06-25 22:33:51 +01:00
SkyratBot
5326760cb3 [MIRROR] Makes turfs persist their signals, uses this to optimize connect_loc (#6465)
* Makes turfs persist their signals, uses this to optimize connect_loc  (#59608)

* Makes turfs persist signals

* Splits connect_loc up into two elements, one for stuff that wishes to connect on behalf of something, and one for stuff that just wants to connect normally. Connecting on behalf of someone has a significant amount of overhead, so let's do this to keep things clear

* Converts all uses of connect_loc over to the new patterns

* Adds some comments, actually makes turfs persist signals

* There's no need to detach connect loc anymore, since all it does is unregister signals. Unregisters a signal from formorly decal'd turfs, and makes the changeturf signal persistance stuff actually work

* bro fuck documentation

* Changes from a var to a proc, prevents admemems and idiots

* Extra detail on why we do the copy post qdel

* Makes turfs persist their signals, uses this to optimize connect_loc

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
2021-06-23 04:23:48 +01:00
Useroth
873144d8ef Adds a setter for density (#59529) (#6437)
Adds set_density()
Fixes one instance of a duplicate density assignment on an object.
Comments two hacky usages of density which will have to forgo using the setter for now.

Lets us append code to the event of density changing.
Pretty sure this is leading up to some multitile object thing -Lemon

Co-authored-by: Rohesie <rohesie@gmail.com>
2021-06-22 01:24:59 +01:00
SkyratBot
7d1d0e1fad [MIRROR] Refactors most spans into span procs (#6315)
* Refactors most spans into span procs

* AA

* a

* AAAAAAAAAAAAAAAAAAAAAA

* Update species.dm

Co-authored-by: Watermelon914 <37270891+Watermelon914@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-06-16 00:24:49 +01:00
SkyratBot
f6c9fd9599 [MIRROR] Fixes defibrillator paddles and wall mounts not detecting charge changes. (#6227)
* - fixed various charge-related bugs of defib and defib wall mounts (#59366)

Co-authored-by: norill <4>

* Fixes defibrillator paddles and wall mounts not detecting charge changes.

Co-authored-by: norill <norill@wp.pl>
2021-06-10 23:50:32 +01:00
SkyratBot
69bae037dc [MIRROR] Fixes documentation for /obj/item/stock_parts/cell. (#6164)
* Fixes comments for /obj/item/stock_parts/cell. (#59510)

* Fixes documentation for /obj/item/stock_parts/cell.

Co-authored-by: interestingusernam3 <51925758+interestingusernam3@users.noreply.github.com>
2021-06-07 10:50:59 +12:00
SkyratBot
8438e129c0 [MIRROR] Ghosts can open the NT CIMS TGUI by clicking the SM Crystal. (#6140)
* Ghosts can open the NT CIMS TGUI by clicking the SM Crystal. (#59475)

* Ghosts can open the NT CIMS TGUI by clicking the SM Crystal.

Co-authored-by: vincentiusvin <54709710+vincentiusvin@users.noreply.github.com>
2021-06-05 16:56:15 +12:00
SkyratBot
0827abbacb [MIRROR] Allows ghosts to see the status of the power network by examining cables. (#6128)
* Allows ghosts to see the status of the power network by examining cables. (#59469)

Ghosts can now inspect cables to get the same readout that the multitool gives when you use it on a cable.

* Allows ghosts to see the status of the power network by examining cables.

Co-authored-by: peptron1 <57651027+peptron1@users.noreply.github.com>
2021-06-05 16:39:25 +12:00
SkyratBot
fbb78302cf [MIRROR] Makes obj_integrity private and only updated through procs (#6125)
* Makes obj_integrity only updated through procs (#59474)

Having things updating integrity directly is just going to cause more problems down the line as more elements and components depend on being notified of integrity changes. It's an easy mistake to make so making it private should deal with the problem.

get_integrity() might be useful in the future but is mainly a side effect of making obj_integrity private as that also disallows reads.

* Makes obj_integrity private and only updated through procs

* Mirror!

Co-authored-by: Emmett Gaines <ninjanomnom@gmail.com>
Co-authored-by: Funce <funce.973@gmail.com>
2021-06-05 16:35:09 +12:00
Matthew J
aac40d2ed3 [TM-ONLY][DNM] Attempts to remove all instances where a list is accessed with a '?' (#5932)
* I hate TGUI even if its better than what we had before

* this is why linters exist

* you need to be a Head or the Warden to get items

* does this please you linter?

* foundation

* basic interactions

* yea I can spell okay?

* linters please leave me alone

* begone debug code

* if you are dead, no interacting

* linters leave me alone

* linters are stealing my soul

* forgot to do this

* sound framework, probably wont work though

* max length, and interaction cooldowns

* message can now be a list and minor code improve

* I am a slave and linters are my master

* fix improper static reference

* add json loading/saving functionality

* default for message is now a list

* jsonize def interactions; implement requirements

* bad

* bug fix; CtrlShiftClick to interact

* minor qol fix

* fix CtrlShiftClick and remove debug code

* haha docker has security measures

* this was painful

* why are you in this branch

* begone

* bruh

* begone

Co-authored-by: Matthew <matthew@tfaluc.com>
Co-authored-by: Matthew J <GoldenKeyboard@users.noreply.github.com>
2021-05-25 16:26:39 +01:00
FlamingLily
e0459ee20b [NONMODULAR] Ports Arcing APCs from paradise. (#5767)
* bzap

* defines

* 4got my comments

* Update apc.dm

* bzap
2021-05-22 03:45:54 +01:00
SkyratBot
ea9aed5554 [MIRROR] Replace alert usage with tgui_alert (#5815)
* Replace alert usage with tgui_alert

* a

* Update observer.dm

Co-authored-by: Celotajs <81999976+celotajstg@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-05-21 00:06:09 +01:00
SkyratBot
11e1e4dadc [MIRROR] Stop singularities from consuming themselves (#5709)
* Stop singularities from consuming themselves (#58987)

This bug was fixed by one of the connect_loc PRs, but this is still useful as it contains a CRASH for when it happens if this bug comes back again.

* Stop singularities from consuming themselves

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2021-05-15 04:54:21 +01:00
SkyratBot
945bff2c10 [MIRROR] The Wallening Approacheth: Adds directional variants to most wall mounts (#5551)
* The Wallening Approacheth: Adds directional variants to most wall mounts

* Update reagent_dispenser.dm

* Update CentCom_skyrat.dmm

Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com>
Co-authored-by: KathrinBailey <53862927+KathrinBailey@users.noreply.github.com>
Co-authored-by: KathrinBailey <evesovereign@hotmail.co.uk>
2021-05-08 14:46:01 +01:00
SkyratBot
5880be0168 [MIRROR] (code bounty) refactors all uses of Crossed() and Uncrossed() into signals sent to loc, tracked by connect_loc (#5524)
* (code bounty) refactors all uses of Crossed() and Uncrossed() into signals sent to loc, tracked by connect_loc

* WHEW THAT WAS EASY

* Update ammo.dm

Co-authored-by: Kylerace <kylerlumpkin1@gmail.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-05-07 22:39:27 +01:00
SkyratBot
42bd885efd [MIRROR] Fixes a fuck ton more harddels (#5476)
* Fixes a fuck ton more harddels (#58779)

Redoes how geese handle eating shit, it was fucking stupid and caused harddels, and while this method is technically slower in the best case, it's a fucking goose
Fixes action related harddels, I hate how they work but at least this way they won't hold refs.
Fixes the hierophont causing its beacon to harddel
Removes the M variable from megafauna actions, it was used like a typed owner and caused harddels, so I burned it
Fixes target and targets_from harddels, replaces all setters of target with LoseTarget and GiveTarget, which should help maintain behavior. I'm not sure if this breaks anything, but if it does we should fix the assumptions that code makes instead of reverting this change
Fixes more area_senstive_contents related harddels, we need to allow the mob to move before clearing out its list.
Fixes marked object harddels (I'm coming for you admin team)
Fixes a language based human harddel
Fixes managed overlay related harddels (This was just emissive blockers, but I think this is a good safety net to have. If we clear the overlay list we should clear this one as well)
Fixes bot core harddels, I hate the fact that this exists but it has no reason to know who its owner is
Adds a walk(src, 0) to simple_animal destroy, it's the best bang for the buck in terms of stopping spurious harddels. Walk related harddels aren't that expensive in the first place, since byond does the same thing I'm doing here, but this makes finding mob harddels easier, so let's go with it
I fixed another source of part harddels, I hate fullupgrade so much
Fixes all the sound loop harddels

* Fixes a fuck ton more harddels

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
2021-05-05 17:46:22 +01:00
SkyratBot
d8ee087d8d React optimization + event based processing for tanks, canisters and pipelines (#5352)
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-05-01 14:08:53 +01:00
SkyratBot
7f083e7cb6 [MIRROR] Converts the atmos senstive component over to connect_loc (#5376)
* Converts the atmos senstive component over to connect_loc (#58266)

* Makes all uses of atmos_senstive pass in mapload as context

* Converts atmos senstive to connect_loc, does some general cleanup to the element, and makes it check the state of the tile the thing is on assuming creation didn't happen as a part of map loading

* Updates connect loc to match the new arg list

* Converts the atmos senstive component over to connect_loc

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
2021-05-01 09:44:09 +01:00
SkyratBot
64684fba8e [MIRROR] SM code improvements (#5303)
* SM code improvements

* mister pointy.... hehe...

Co-authored-by: Ghilker <42839747+Ghilker@users.noreply.github.com>
Co-authored-by: Funce <funce.973@gmail.com>
2021-04-29 15:35:21 +01:00
SkyratBot
d7c91d7c94 Removes Crystal Invasion (#5276)
Co-authored-by: tralezab <40974010+tralezab@users.noreply.github.com>
2021-04-28 21:41:37 +01:00
SkyratBot
438e8e1b71 [MIRROR] Blind people no longer get hallucinations from supermatter crystals (#5268)
* Blind people no longer get hallucinations from supermatter crystals (#58718)

The Supermatter Crystal no longer causes blind people to get hallucinations. The SM causes hallucinations based on eyesight, which is why eye protection (meson glasses) can protect you from it. It makes sense that those who can't see don't get affected by the hallucinations.

It makes the mechanics more consistent. It also adds interesting situations, like if you can't find meson goggles, a blindfold will do in a pinch.

* Blind people no longer get hallucinations from supermatter crystals

Co-authored-by: MrZoraman <MrZoraman@Gmail.com>
2021-04-28 02:17:39 +01:00
SkyratBot
295e3d7c26 [MIRROR] More HFR interactions, better damage control, better Meltdown (#5260)
* More HFR interactions, better damage control, better Meltdown (#58506)

Some more gas interactions with the HFR
-O2 will help remove iron content
-Antinoblium accumulation or damage over 60% will now start zaps similar to those of the SM (useful to produce power too)
-Bz will make more particles shoot out
-Meltdown now spew the hot fusion gases around the machine too (20% of the total gases are randomly placed around the machine in 10 open turfs each containing only 10% of that 20%)
-damage system now uses cooling temperature instead of the internal fusion temperature

* More HFR interactions, better damage control, better Meltdown

Co-authored-by: Ghilker <42839747+Ghilker@users.noreply.github.com>
2021-04-27 23:33:32 +01:00
SkyratBot
5b8a38af3a [MIRROR] Makes the explosive compressor and blastcannon actually use the TTVs they're given + the explosion changes to support that. (#5244)
* Makes the explosive compressor and blastcannon actually use the TTVs they're given + the explosion changes to support that. (#58015)

* Adds explosion SFX to the blastcannon and explosive compressor

- Extracts the explosion SFX and screenshake proc from the SSexplosions explosion handling proc and lets the explosive compressor and blastcannon use it.

* Miscellaneous changes

- Adds defines for the internal explosion arglist keys
- Reverses the values of the explosion severity defines
- Changes almost everything that uses `/proc/explosion` to use named arguments

- Removes a whole bunch of argname = 0 in explosion calls.

* Removes named callback arguments.

* Changes the explosion signals to just use the arguments list

Adds a simple framework to let objects respond to explosions occurring inside of them.

Changes a whole bunch of explosions to use the object being exploded as the origin of the explosion rather than the turf the object is on.

Makes the explosive compressor and blastcannon actually use the TTVs they are given.

Adds support for things responding to internal explosions.
Less snowflake code for the explosive compressor and blastcannon calculating bomb range.*
Less confusing explosion severity defines.
Less opaque explosion arguments

*does not guarantee that the solution to letting them actually use the TTV is any less snowflake.

* Makes the explosive compressor and blastcannon actually use the TTVs they're given + the explosion changes to support that.

Co-authored-by: TemporalOroboros <TemporalOroboros@gmail.com>
2021-04-27 01:53:17 +01:00
SkyratBot
01af3694ce [MIRROR] Emissive system refactor (#5234)
* Emissive system refactor (#58130)

The emissives system is the system that both lets computer screens and vendors glow in the dark and lets mobs and items block those glows. The current implementation relies on using filters to let mobs and items mask out the glow in the dark overlays on some structures. This is difficult to extend properly without massively increasing maptick. This PR changes the emissives system to use BYONDs native image layering to mask emissive overlays. This should prove to be a more extensible option.

tldr; There exists a system that lets computer screens glow on the dark and lets mobs and items block the glow. It isn't very extensible and this PR attempts to make it more extensible.

How emissive overlays used to work

Currently emissive overlays and the emissive blockers that mask those overlays are handled using a system of inter-masking planes. The emissive overlays and the emissive blockers are placed on separate, hidden plane masters. These are essentially rendering layers and groups. The emissive blocker plane is then used to mask the emissive overlay plane which effectively allows the emissive blockers to block the emissive overlays from being seen. After is has been masked the emissive overlay plane is used to mask the lighting plane, essentially creating holes in the shadows wherever an unblocked glowing thing exists.

Why this is a potential problem

This system works fine. In fact it works great! The computer screens glow, any person or item that winds up on a computer blocks the glow, and everything just works. However, this system runs into some issues when you try to extend it to work on things other than structures. Namely, the current system only supports emissive overlays on structures and emissive overlays that are completely unblockable by any means. As a result, several interesting uses to the system require extending the system.

As a result, if you want to apply emissive overlays to items (which exist between structures and mobs) or emissive overlays to turfs (which exist below structures) you must extend the emissives system to get the emissive overlays and emissive blockers to properly function. Doing this naively, by adding extra emissive overlay and emissive blocker planes and applying all of the relevant masking filters, is not exactly performant.

Maptick is a major contributor to lag and the higher the maptick the more free lag you, the player, get delivered fresh to your client. Trying the naive method resulted in #55782 (1f1b58bb26), an attempt to add glowing carpet to the game. Since the PR revolved around adding glowing carpet it had to extend the emissives system to allow for emissive turfs and emissive blocking structures. Extending the system was done naively as described above and you can see the results. 1.5 times the maptick across the board. Ouch.

So, we know that extending the system in it's current form is impractical. At least if done naively. Thus we are stuck.

tldr; The emissive system currently uses inter-plane masking to allow for emissive blockers to function. This is difficult to reasonably extend without murdering maptick. See #56496 (1f1b58bb26) for the results of naively extending this system.

How emissive overlays are going to work

Alright, so we know that the current system of using planes to let the emissive blockers mask the emissive overlays is difficult to extend in it's current form. The solution is to change how the system works so that it can be extended in a more efficient manner. What we want is a system that allows one set of images to be out masked by another set of images and for the first set of images to be capable of masking the light plane. Preferably, we would also like the ability to interleave the masking effect between emissives and emissive blockers with almost arbitrary layering.

Conveniently, this layering and masking is something BYOND already does to normal items and objects. If we put the emissive overlays and the emissive blockers on the same plane we can use their layers to interleave them almost arbitrarily like any normal structures and items! All we need is a way to mask away the emissive blockers from the resulting rendered plane and we can mask the lighting plane with the remaining emissive overlays.

Luckily, BYOND has provided a single filter that is capable of this task. The color matrix filter. This filter can be used to apply a color matrix to an image! Provided that the emissive overlays and the emissive blockers are different colors we can use a color matrix filter to effectively mask out the emissive blockers from the plane! The resulting emissive plane can be applied as an alpha mask to the lighting plane as it used to, to the same effect. The best part is, we get layering practically for free!

This is exactly what this PR does. It converts the emissives system from the old plane and masking based blocking to a new layer-based system which uses BYONDs native layer handling to mask the emissive overlays.

* Emissive system refactor

Co-authored-by: TemporalOroboros <TemporalOroboros@gmail.com>
2021-04-27 00:03:46 +01:00
SkyratBot
2ab15aecb5 [MIRROR] Remove all gamemodes except Dynamic (#5173)
* Remove all gamemodes except Dynamic

* qaaaaaaaa

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-04-25 21:20:30 +01:00
SkyratBot
7de0aaf82d [MIRROR] Fixes emitter welding issue (#5076)
* weldies (#58560)

* Fixes emitter welding issue

Co-authored-by: Seth Scherer <supernovaa41@protonmail.com>
2021-04-22 00:40:16 +01:00
SkyratBot
0fca6c7035 [MIRROR] emitters and collectors code improvements (#5002)
* emitters and collectors code improvements (#58454)

Refactor of collector and emitters to current standards

* emitters and collectors code improvements

Co-authored-by: Ghilker <42839747+Ghilker@users.noreply.github.com>
2021-04-18 14:26:32 +01:00
SkyratBot
a52b9f6bbf [MIRROR] Makes radiation related pluouxium only generate in cold conditions (#4837)
* Pluoxium can currently be created in mico amounts on a lot of tiles, which creates a lot of unneeded active (#58306)

turfs, and wastes processing time.
Let's only make pluox in cold mixes then, and since it's not gonna mitigate high power runaways quite as hard
now, let's make it a net negative on waste gas output for the sm.

* Makes radiation related pluouxium only generate in cold conditions

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
2021-04-12 04:43:31 +01:00
Gandalf
f2a60da60c AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA (#4826) 2021-04-11 19:58:19 +01:00
Gandalf
2bb0f8d775 aaa (#4812) 2021-04-11 00:22:07 +01:00
Yawet330
c49c546bde [NONMODULAR]Shocks & Zaps, Episode 2 (#4684)
* OH NO

* Update powernet.dm

* ae

* alexia please play despacito

* Update powernet.dm

* Merge branch 'master' into pr/4684

Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-04-10 18:31:05 +01:00