Commit Graph

714 Commits

Author SHA1 Message Date
Mothblocks
bcaaa65e6a 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.
2021-05-14 20:12:46 -07:00
Kylerace
08df8798ce (code bounty) refactors all uses of Crossed() and Uncrossed() into signals sent to loc, tracked by connect_loc (#58340)
Co-authored-by: Jared-Fogle <35135081+Mothblocks@users.noreply.github.com>
Co-authored-by: Emmett Gaines <ninjanomnom@gmail.com>
2021-05-07 03:54:03 -07:00
LemonInTheDark
a924226b50 React optimization + event based processing for tanks, canisters and pipelines (#58418)
* Makes tanks only process when needed, rather then doing it constantly

* Makes portable atmos machines only process when needed, makes adding and removing atmos machinery cheaper, makes the tank processing logic actually work properly

* Makes pipelines only react() when their mix changes, fixes a ton of misuses of update_parents that were causing about 10ms of load for atmos just from reconcile_air()

* Adds in a new reaction framework alongside the old one for profiling related reasons

* whoops

* Cleanup, removes the react profiling code, I've chosen a direction to go here

* Cleans up some code, adds comments describing how to interact with portable atmos machines/tanks and their
mixes, adds a blurb to Atmospherics.md about the topic as a whole, leaves a line of bread for someone to follow
if I get hit by a bus in 2 days (Knock on wood)

* Removes priority from reactions, moves priority groups to the defines file

* whoops

* Converts air_contents to _air_contents, replaces all the out of file things that used it with return_air()

* Replaces the canister air contents uses, converts it back to air_contents, I decided I didn't like the _

* Fixes
2021-04-30 12:29:29 +02:00
TemporalOroboros
9f598a9662 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.
2021-04-26 17:31:25 -07:00
Mothblocks
7e4de07506 Remove all gamemodes except Dynamic (#58470)
Removes all /datum/game_mode except dynamic. Eventually, all of mode and game_mode will be removed, and Dynamic will become an ingrained system. Every single other gamemode was unmaintained at best and poisoned other code at worst. Currently all tg servers run 24/7 Dynamic, so the time to act is now.

* Remove gamemode references from age checks

* Monkey

* Remove heretics

* Remove BBs

* Refactor uplinks and remove clown ops

* Remove nuke ops

* Removes and refactors cult

* Remove extended

* Remove and move out meteors

* Removes wizard

* Remove sandbox

* Remove changelings

* Remove traitors

* Remove revs

* Remove gangs

* Remove changing mode and voting for new gamemodes

* get_candidates signature fix

* Summon ERT and NERD in their own panel

* Remove some old unneeded age_check stuff

* Fix old signatures of get_uplink_items

* Use Extended like config for dynamic.json

* Fix discounted gear
2021-04-25 01:55:10 -07:00
Seth Scherer
0dcc5410b4 weldies (#58560) 2021-04-21 20:33:46 +02:00
Ghilker
e582414f44 emitters and collectors code improvements (#58454)
Refactor of collector and emitters to current standards
2021-04-18 01:11:17 -07:00
Rob Bailey
292b217911 Layer overhaul (#57915)
## About The Pull Request
Changes up some layer and plane defines for no particular reason lol

## Why It's Good For The Game
Planes actually override layers, and layers control ordering within planes. A lot of the usage of plane and layer was wholly unnecessary. This refactor helps future maintainability while also being needed staging for _future features._
2021-03-29 09:51:44 -04:00
TemporalOroboros
fb488fdfff Some explosions code cleanup (#57493)
Clears out two deprecated explosions systems (explosion ids and explosion levels)
Refactors a bunch of contents_explosions procs to be maybe slightly faster.
Cleans up a bunch of ex_act code.
Slightly cleaner code
A few less unused vars on /atom and /turf
2021-03-20 16:03:59 -07:00
LemonInTheDark
9ac761b299 Draws the singularity and other large objects that create their own light or break/effect turfs above the lighting plane, to prevent shitty appearences when the lighting subsystem lags behind (#57512) 2021-03-08 23:51:33 -08:00
TiviPlus
fbf80847dc Remove narnar sleeps (#57353) 2021-03-03 16:20:46 -08:00
Sparkezel
bd711855cc Replaces old array sprites (#57252)
Co-authored-by: Stanisław <1haslo4@gmail.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2021-03-01 00:26:24 -08:00
TemporalOroboros
e4079c87b8 update_appearance (#55468)
Creates update_name and update_desc
Creates the wrapper proc update_appearance to batch update_name, update_desc, and update_icon together
Less non-icon handling code in update_icon and friends
Signal hooks for things that want to change names and descriptions
99%+ of the changes in this are just from switching everything over to update_appearance from update_icon
2021-02-19 12:06:18 -03:00
LemonInTheDark
5c22a0cfc1 Converts many proc overrides to properly use list/modifiers, lots of other smaller things (#56847)
Converts many proc overrides to properly use list/modifiers, fixes some spots where modifiers should have been passed, calls modifiers what it is, a lazy list, and cleans up some improper arg names like L, M, C, and N. Oh and I think there was a spot where someone was trying to pass M.name in as a string, but forgot to wrap it in []. I fixed that too.
2021-02-16 09:18:46 -05:00
Mothblocks
0f435d5dff Remove hideous inline tab indentation, and bans it in contributing guidelines (#56912)
Done using this command sed -Ei 's/(\s*\S+)\s*\t+/\1 /g' code/**/*.dm

We have countless examples in the codebase with this style gone wrong, and defines and such being on hideously different levels of indentation. Fixing this to keep the alignment involves tainting the blames of code your PR doesn't need to be touching at all. And ultimately, it's hideous.

There are some files that this sed makes uglier. I can fix these when they are pointed out, but I believe this is ultimately for the greater good of readability. I'm more concerned with if any strings relied on this.

Hi codeowners!

Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@users.noreply.github.com>
2021-02-14 16:53:29 -08:00
NotRanged
ec83d8a2ec Makes emitters hitscan (#56579) 2021-02-03 13:33:57 -08:00
LemonInTheDark
6d1cb94ffb LINDA Reforged (#55604)
Speeds up gas movement significantly
Documents the intent and finer details of the atmos system (Thanks dunc)
Fixes excited groups constantly rebuilding, this broke 4 years ago
Fixes superconductors just straight up not working
Allows turfs to sleep while inside an excited group
Adds a new subprocess to SSAir to support rebuilding in this state
Most heat based behavior no longer relies on being inside a fire
Adds a new element to support doing this cleanly
Adds a new subprocess to SSAir to support doing this while a turf is asleep
Refactors air_update_turf to allow for finer control
Makes apcs take damage in heat to prevent infinite plasma fire diffs
Cleans up immutable gas mixtures to make them work properly when the mix has gas in it
Planetary turfs no longer create a new copy of themselves each time they process. We instead use a global
immutable mix
Cleans up a typed for loop in reactions
Canisters will take damage from outside heat now
Speeds up excited group dismantle
Increases the superconductor threshold by 200k
Cleans up some roundstart ATs on some ruins
Uses /turf/open/var/excited to track if a turf is actively processing, preventing a |=
Prevents openspace from trying to melt
Tweaks a canister examine line
Makes planetary turfs reset to base when broken down as part of an excited group
Makes it impossible for planetary turfs to rebuild, just like space tiles
Fixes closed turfs not activating their replacement when destroyed by moving closed -> open turf activation to
the adjacent air subsystem. They were activating and then going back to sleep before adjacent air got a chance
to tick.
Fire alarms will trigger when the area gets too cold for humans
2021-01-08 08:14:08 +01:00
Ryll Ryll
91a8cf6cf7 You can now mount things from the side (#55741) 2021-01-01 12:29:57 -08:00
Timberpoes
b5332ee4db Deadchat plays everything - A simple way for admins to let deadchat control things. (#55314)
* Deadchat plays things

* Pocket lint

* View those variables

* Arr var

* Arrr save changes and don't code while drunk

* Loog dot exe

* Big ol' changes
2020-12-26 21:03:47 +01:00
Jared-Fogle
38fb0ad6fe Make singularity dissipation use delta time (#55612)
About The Pull Request

Converts singularity's dissipation code to use delta time instead of assuming it'll always be the same.

Numbers were based on the previous code given a delta_time of 2.
2020-12-21 10:28:52 +13:00
Jared-Fogle
40a44b63ab Nar'Sie is now a point of interest (#55540)
Fixes a regression from the singularity rewrite that made Nar'Sie its own object.
2020-12-17 01:45:48 -08:00
Jared-Fogle
0a77d27a1b Replace direct poi_list manipulation with element (#55416)
Replaces GLOB.poi_list |= src and GLOB.poi_list -= src with an element that handles it directly.

More consistent code, especially when a lot of code couldn't decide how to add/remove (some |=, some -=, some .Remove, etc).
2020-12-10 23:30:25 +00:00
Jared-Fogle
f00e379939 Singularity component (#55096)
Adds singularity component
2020-12-08 10:58:03 +01:00
TiviPlus
0eaab0bc54 Grep for space indentation (#54850)
#54604 atomizing
Since a lot of the space indents are in lists ill atomize those later
2020-11-30 12:48:40 -05:00
Coffee
053de0e224 Adds N2 Canisters to the Delta Supermatter (#55205)
* Does the Thing

* Removes delta rad collector subtype

Co-authored-by: Coffee <crashkray@gmail.coom>
2020-11-28 21:16:14 +01:00
Rohesie
c55bb1b6c8 Basepixels (#54652) 2020-10-28 20:31:13 -07:00
Ghom
247488d2fe Converting the EMP protection component into an element. (#54617) 2020-10-27 21:48:22 +08:00
Rohesie
c07df08690 Standardizes attack chain signal returns and fixes a tk bug (#54475)
The attack chain is a bit of a mess, and the introduction of signals hasn't helped in simplifying it.

In order to take a step into untangling this, I re-ordered the attack signals to no longer be by source type and instead to be grouped more modularly, as they are all members of the attack chain and function similarly. They all share the trait of potentially ending the attack chain via a return, but had several different names for it. I joined it into one.

Additionally, fixed a tk bug reported by @Timberpoes by adding a signal return check at the base of /mob/proc/RangedAttack

Lastly, removed the async call of /datum/mutation/human/telekinesis/proc/on_ranged_attack, which was added as a lazy patch to appease the linter complaining about a sleep on a signal handler (namely in /obj/singularity/attack_tk). Fixed the problem using timers.

Also cleaned some code here and there.
2020-10-21 05:42:38 +01:00
ZeWaka
9629feed35 Converts A && A.B into A?.B (#54342)
Implements the ?. operator, replacing code like A && A.B with A?.B

BYOND Ref:
When reading A?.B, it's equivalent to A && A.B except that A is only evaluated once, even if it's a complex expression like a proc call.
2020-10-13 16:43:53 -03:00
Rohesie
db54913fe6 Mobility refactor: UI, pull and lying down edition (#54078) 2020-10-03 17:23:21 -07:00
Rohesie
3cc7733f34 Moblity refactor: hands blocked and restrained edition. (#53981)
Splits the restrained() proc into component traits: TRAIT_HANDS_BLOCKED for the general inability to use hands and TRAIT_RESTRAINED for the more specific condition that permits arrests.
    Code moved away from the update_mobility() proc so it doesn't have to wait for an update, instead changing based on events. The idea is to eventually kill that proc.
    Wrapper proc added for setting the handcuffed value so we can react to the event of it changing.
    Kills the RestrainedClickOn() proc. That is now just an UnarmedAttack(), in where the ability to use hands can be checked. Monkeys keep their bite attack and humans their self-examine.
2020-09-29 11:23:43 +01:00
msgerbs
f91dd961aa Adds NO_ALERT flag to areas, refactors area alerts slightly (#53487)
Adds a NO_ALERTS flag for areas and adds it to most off-station area types. Up until now, whether or not an area should trigger alerts has been a snowflakey mix of ALWAYS_UNPOWERED and outdoors, with some smattering of other conditions thrown in. This unifies it all behind a single bitflag so it's easy to make sure an area does not send alerts to the station consoles. I also refactored alerts slightly so they make sense (state = 1 means not alerting? Seriously??), removed an unnecessary override of poweralm from some lavaland areas which probably doesn't do what somebody thought it does, and removes an old snowflaky override of power alarms in engineering which is a leftover from the singulo days. As an additional side effect, off-station fire alarms can now properly work locally (previously, the entire fire alarm did not work if it wasn't on the station. Now they work but just won't send alarms)
2020-09-11 04:31:42 +01:00
Jared-Fogle
0c8bf36548 Remove references to old singularity machines (#53509)
Removes the singularity generator and the particle accelerator. The former had no sprite, and the latter only existed because of a leftover type path. This does not affect gameplay at all.

Removes the "Start Singularity" verb that was only intended for debug use.

Fixes #53508.
2020-09-11 01:08:43 +01:00
LemonInTheDark
2c20897f00 Readds the tesla, reworks it a bit (#53072)
* Makes tesla movement nicer, fixes some atmos concerns, changes how energy is handled, and readds the tesla

* readds delam and desc

* I fucked it

* flags

* holy fuck

* Constricts the zaps that can generate power from a tesla coil

* *kick?
2020-09-08 20:16:42 -07:00
Donkie
53b212ddf2 Process procs now properly utilize deltatime when implementing rates, timers and probabilities (#52981)
* Process procs now properly use deltatime when implementing rates, timers and probabilities

* Review fixes

* Geiger counters cleanup

Made hardsuit geiger code more similar to geiger counter code
Geiger counters are more responsive now

* Moved SS*_DT defines to subsystems.dm

* Rebase fix

* Redefined the SS*_DT defines to use the subsystem wait vars

* Implemented suggested changes by @AnturK

* Commented /datum/proc/process about the deltatime stuff

* Send delta_time as a process parameter instead of the defines

Also DTfied acid_processing

* Dtfied new acid component
2020-09-08 10:24:05 +02:00
TiviPlus
ca366c3ea1 Bools and returns super-pr (#53221)
Replaces like 70-80% of 0 and such, as a side effect cleaned up a bunch of returns
Edit: Most left out ones are in mecha which should be done in mecha refactor already
Oh my look how clean it is

Co-authored-by: TiviPlus <TiviPlus>
Co-authored-by: Couls <coul422@gmail.com>
2020-08-28 14:26:37 -07:00
Rob Bailey
533201a9f1 Smooth Movement: Resurrection: Resurgence: Revengeance 4: The Return of Smooth Movement: Smooth Edition Director's Cut (#52515)
Automatic glide size adjustment based on move delay.
Essentially a port of https://github.com/yogstation13/Yogstation/pull/8132 but that was mostly my code with some fixes.

Why again? well it turns out the recent byond fixes to glide size actually worked and solved the issues that were unsolvable.
https://file.house/0B3u.mp4
Glide size no longer incorrectly scales at fps, so it works as intended at any framerate with the only stuttering being normal byond suck stuttering.
2020-08-27 18:34:11 -07:00
TemporalOroboros
6e950daccc Defines damage flags. (#53158) 2020-08-24 08:20:33 -03:00
CRITAWAKETS
da354ba4e2 Removes singularity, tesla, TEG and Mrs. Pacman. Changes supermatter overcharge delam. (#52873)
About The Pull Request

This PR removes the tesla and Mrs. Pacman from the game. The title is actually misleading, the TEG and singularity are still in the game but inaccessible and the singularity no longer has its generator.

Field generators and tesla coils have been kept because shocking your fellow man is the greatest sensation of power in the world.

The overcharging delamination for the supermatter has been replaced by the release of 2500 mols of tritium at 500,000 kelvin. An engineer who's really hateful of the station can use this for fusion, if they desire. Otherwise, its a tritium fire in engineering alongside the explosion. This will probably be changed in the future to be more potent since the explosion will pretty much just space all the tritium away.

Singularities no longer produce radiation. Now, keeping one is less about making power and more about making a statement, especially since you need to delaminate an SM shard for it.
Why It's Good For The Game

Having power optimized for one generator (SM+Turbine) will allow balancing to be feasible, also oranges wanted this. The other generators may later return but with tweaked values and different roles.
Changelog

🆑
del: Nanotrasen has removed their outdated teslas, singularities, TEGs and Mrs. Pacman generators from their servers and warehouse.
/🆑
2020-08-15 10:42:08 +12:00
Timberpoes
19c3bbde31 Cleanup up all instances of using var/ definitions in proc parameters. (#52728)
* var/list cleanup

* The rest of the owl

* plushvar bad

* Can't follow my own advice.
2020-08-07 12:23:42 -03:00
Rohesie
6ff08e1c69 Color standardization, vars moved, and signals (#52574)
Defined all the existing light_color values.
    Moved their definitions to colors.dm
    Made white the default color. It was so already, but that was very obscured.
    Moved the atom light-related variables to the atom definition.
    Wrapped changes to variables such as light_color into procs that report the event through signals.
    Moved the light_on variable to the atom level, also adding a signal for its changing, to represent toggling lights.
    Cleaned up a little bit of code in where new variables were defined before redefinitions.

This is all atomization to reduce changes in #52413
None of this affect gameplay at all, it's all code cleaning and refactoring.

There's more colors to standardize, a search for color = will find lots of targets, and I see little need to have both the LIGHT_COLOR and COLOR patterns, but I don't want to make this PR bigger than it already is.
2020-08-04 13:59:48 +12:00
ShizCalev
4b6500fb67 Makes all anchored changes use setAnchored(), COMSIG_MOVABLE_SETANCHORED now only sent if an AM's anchored var has changed for more reliable usage. (#52254)
* Converts everything to use setAnchored() + other fixes

* Fixed singulo debug

* singulo again

* forgot to move the vv_edit proc

* caught that this time :)

* changes

* Update code/game/atoms_movable.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

Co-authored-by: Rohesie <rohesie@gmail.com>
2020-07-21 02:20:26 -03:00
Aleksej Komarov
0cf00a2645 tgui 4.0 (#52085)
* tgui 4.0 hyper squash

* Upgrade dependencies
2020-07-16 20:13:04 +02:00
jdawg1290
62676e72a8 Force LF line endings with gitattributes and convert repo (#52266)
Co-authored-by: Aleksej Komarov <stylemistake@gmail.com>
2020-07-16 03:02:40 +03:00
ShizCalev
90fef217c7 Fixes anchored state mismatch for field generators on delta (#52056) 2020-07-10 20:21:12 +02:00
LemonInTheDark
92209dd23a Sweeps up some rarely used and unbalanced sources of research points (#52012)
About The Pull Request

Removes the research point gen modes from tesla coils and rad collectors.
Someone is gonna take some flak for removing these at some point, may as well be me.
Why It's Good For The Game

THE DESIGN DOC DICTACT-

Nah powergen should be valid on it's own, it shouldn't need to rely on other econs to make it worth the work. We can try that later, but not now.
Changelog

cl
del: Removed the research modes from tesla coils and radiation collectors.
/cl
2020-07-07 11:02:33 +12:00
spookydonut
88d1d36aef Removes some var/const that should be defines (#51461)
* Removes some var/const that should be defines

* change requests

* change requests
2020-06-25 03:00:09 -04:00
LemonInTheDark
1614501d23 Datum view and some other things (#51208)
* Datumizes all uses of change_view

* Cleanup and helper procs

* tweaks values to match the format, hint hint, (value - 0.5) works just fine

* And there's the rest

* woop, braindamage

* and one more

* fuck you menu file

* woops

* we should apply that

* fixes tooltip drift, thank you goon coders

* you can shake but you can't zoom
2020-05-25 01:53:51 +08:00
spessman-007
5ae305ec9f Resolve issues with incorrect usage of a/an (#51095)
Co-authored-by: NewSta <spessman-007@users.noreply.github.com>
2020-05-25 01:34:34 +08:00
Fikou
564620c14d changes cult sprites + radials (#50620)
* makes cult sexy

* turns cult sprites into sex

* gurgr

* hola

* final commit maybe

* FUCK

* shit

* a

* walla walla bing bong

* man fuck

* i didnt even know you could do this wtf

* new sounds from actioninja

* ahoy spongebob

* yeah

* bazinga

* should be finished

* oops
2020-04-22 11:57:00 -03:00