* Makes blast doors/shutters and blast door controllers buildable and deconstructible (#56486)
* Makes blast doors/shutters and blast door controllers buildable and deconstructible
Co-authored-by: HugoOdaX <42174630+HugoOdaX@users.noreply.github.com>
* Fix elevators (#56117)
Currently elevators are broken since they try to use the z level of the assembly inside the button to determine how to move
The assemblies z level is however always 0 and instead the z level of the button containing the assembly must be used
This fixes this
* Fix elevators movement when called via button
Co-authored-by: Gamer025 <33846895+Gamer025@users.noreply.github.com>
* Mechanical Curtains (#55751)
good for better mapping, I have seen some mappers wish to utilize fancy curtains on their rooms windows (for example, a psychologist office) but wanted to be able to have privacy when with a patient, which curtains can be opened from either side of the window, and shutters just dont fit the theme, this way mappers can add in curtains which are button operated and cant be opened manually, basically, it functions like a shutter, only it looks and acts like curtains (can be destroyed like one, etc... it is literally a curtain subtype)
* Mechanical Curtains
Co-authored-by: 小月猫 <alina.r.starkova@gmail.com>
* fixes high confusion levels blocking rev conversions and removes help intent disabling the usage of tacticool flashing (#55750)
* fixes high confusion levels blocking rev conversions and removes help intent disabling the usage of tacticool flashing 2
Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>
* pass_flags handling refactor + rewrites a part of projectiles for the n-th time (#54924)
Yeah uhh this'll probably need testmerging even after it's done because yeah it's a bit big.
If y'all want me to atomize this into two PRs (pass flags vs projectiles) tell me please. Pass flags would have to go in first though, in that case, as new projectile hit handling will rely on pass_flags_self.
Pass flags:
Pass flags handling now uses an atom variable named pass_flags_self.
If any of these match a pass_flag on a thing trying to pass through, it's allowed through by default.
This makes overriding CanAllowThrough unnecessary for the majority of things. I've however not removed overrides for very.. weird cases, like plastic flaps which uses a prob(60) for letting PASSGLASS things through for god knows why.
LETPASSTHROW is now on pass_flags_self
Projectiles:
Not finalized yet, need to do something to make the system I have in mind have less unneeded overhead + snowflake
Basically, for piercing/phasing/otherwise projectiles that go through things instead of hitting the first dense object, I have them use pass_flags flags for two new variables, projectile_phasing and projectile_piercing. Anything with pass_flags_self in the former gets phased through entirely. Anything in the latter gets hit, and the projectile then goes through. on_hit will also register a piercing hit vs a normal hit (so things like missiles can only explode on a normal hit or otherwise, instead of exploding multiple times. Not needed as missiles qdel(src) right now but it's nice to have for the future).
I still need to decide what to do for hit handling proper, as Bump() is still preferred due to it not being as high-overhead as something like scanning on Moved(). I'm thinking I'll make Moved() only scan for cases where it needs to hit a non-dense object - a prone human the user clicked on, anything special like that. Don't know the exact specifics yet, which is why this is still WIP.
Projectiles now use check_pierce() to determine if it goes through something and hits it, doesn't hit it, or doesn't go through something at all (should delete self after hitting). Will likely make an on_pierce proc to be called post-piercing something so you can have !fun! things like projectiles that go down in damage after piercing something. This will likely deprecate the process_hit proc, or at least make it less awful.
scan_for_hit() is now used to attempt to hit something and will return whether the projectile got deleted or not. It will delete the projectile if the projectile does hit something and fails to pierce through it.
scan_moved_turf() (WIP) will be used for handling moving onto a turf.
permutated has been renamed to impacted. Ricocheting projectiles get it reset, allowing projectiles to pierce and potentially hit something again if it goes back around.
A new unit test has been added checking for projectiles with movement type of PHASING. This is because PHASING completely causes projectiles to break down as projectiles mainly sense collisions through Bump. The small boost in performance from using PHASING instead of having all pass flags active/overriding check_pierce is in my opinion not worth the extra snowflake in scan_moved_turf() I'd have to do to deal with having to check for hits manually rather than Bump()ing things.
Movement types
UNSTOPPABLE renamed to PHASING to better describe what it is, going through and crossing everything but not actually bumping.
Why It's Good For The Game
Better pass flags handling allows for less proc overrides, bitflag checks are far less expensive in general.
Fixes penetrating projectiles like sniper penetrators
This system also allows for better handling of piercing projectiles (see above) without too much snowflake code, as you'd only need to modify on_pierce() if you needed to do special handling like dampening damage per target pierced, and otherwise you could just use the standardized system and just set pass flags to what's needed. If you really need a projectile that pierces almost everything, override check_pierce(), which is still going to be easier than what was done before (even with snowflake handling of UNSTOPPABLE flag process_hit() was extremely ugly, now we don't rely on movement types at all.)
* pass_flags handling refactor + rewrites a part of projectiles for the n-th time
Co-authored-by: silicons <2003111+silicons@users.noreply.github.com>
* Minor refactor to signal handlers to remove potential sleeps (#54649)
About The Pull Request
These are legacy sleepers, the remaining 12 are non-trivial to fix.
* Minor refactor to signal handlers to remove potential sleeps
Co-authored-by: spookydonut <github@spooksoftware.com>
* Mousetrap the movie (#54965)
I forgot to check more than ismouse() on the mousetrap side, because I am blind.
This adds the extra checks for israt() and isregalrat() to the trap triggering.
* Mice, Rats, and Regal Rats all trigger mousetrap effects properly.
Co-authored-by: ArcaneMusic <41715314+ArcaneMusic@users.noreply.github.com>
* Improves admin logging for when TTV valves get opened. (#54776)
Basically just reformats the logging code for TTVs when valves get opened. It's a bit more verbose, giving a bit more detail in general. It also has line breaks, because it makes things easier to read.
I've also added the ability for signals to hold a logging string. In this case, a signaller creates a signal and attaches a logging string. If the signal is received by any signallers attached to a TTV, it stores the last logging string associated with that signal. Functionally, this means that TTVs can now ask their attached signaller for the logging string of the last signal it received and display it as part of the logging string.
* Improves admin logging for when TTV valves get opened.
Co-authored-by: Timberpoes <silent_insomnia_pp@hotmail.co.uk>
* 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.
* Converts all A && A.B into A?.B
Co-authored-by: ZeWaka <zewakagamer@gmail.com>
* Cleans up rat related features and makes Regal Ratking a rare spawn from mouse migration event. (#54191)
* Cleans up rat related features and makes Regal Ratking a rare spawn from mouse migration event.
Co-authored-by: ArcaneMusic <41715314+ArcaneMusic@users.noreply.github.com>
* Enforce preserving parent proc return values across ui_act call stacks (#53964)
All ui_act procs should call parent by default. All procs should preserve the value of the parent proc when it's TRUTHY and pass it down the call stack. No UI should be interactible when its flags or state indicate it should not be, except when explicity overriden by child procs intentionally disregarding parent return values to achieve a specific goal.
* Enforce preserving parent proc return values across ui_act call stacks
Co-authored-by: Timberpoes <silent_insomnia_pp@hotmail.co.uk>
* Gives Public Mining on Icebox an Elevator, and just a TON of lift fixes so they're viable to map with. [MULTI-BEE] [:pslime: in the chat] (#53728)
add: Icebox now has an elevator! I just took the trousers of every shaft miner to batter town, word.
* Gives Public Mining on Icebox an Elevator, and just a TON of lift fixes so they're viable to map with. [MULTI-BEE] [:pslime: in the chat]
Co-authored-by: tralezab <40974010+tralezab@users.noreply.github.com>
* Fixes oversight with "tactical combat spinning" and flashes (#53823)
Using the spin emote can no longer let you RNG your way out of new flash mechanics.
Mobs have a new flag that is set to when they start spinning and unset when they stop.
Flashes now use this new flag when calcing deviation.
Tactical combat spinning using the spin emote now results in a full deviation flash when it may previously have resulted in a failure or half-deviation flash.
Emotes should either not influence combat at all (spin on floor when both players share the same loc, this was already handled by same-loc code), or negatively influence combat for the emote user (spin in all other circumtances, which is what this PR addresses).
* Fixes oversight with "tactical combat spinning" and flashes
Co-authored-by: Timberpoes <silent_insomnia_pp@hotmail.co.uk>
* Fix flash runtime, improve flash logic (#53784)
image
Flash + Emp = Flash with no user = Runtime.
Additional logic has been put in place to handle this.
I've also robustified the calculate_deviation proc to have explicit returns in every code path and simplified it to only care about the direction the victim is facing compared to the attacker's position.
* Magic numbers are bad because wizards are bad
* Rohesie feex
* Fix flash runtime, improve flash logic
Co-authored-by: Timberpoes <silent_insomnia_pp@hotmail.co.uk>
* Nerfs Flashes [Edge Awards 2020] (#53604)
Flashes now deal stamina damage and micro-stun, they deal higher damage than batons BUT they have a severe disadavntage in form of directionality. Stamina damage and the duration of the micro stun is determined by direction your enemy is facing.
* Nerfs Flashes [Edge Awards 2020]
Co-authored-by: EdgeLordExe <42111655+EdgeLordExe@users.noreply.github.com>
* 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
* Process procs now properly utilize deltatime when implementing rates, timers and probabilities
Co-authored-by: Donkie <daniel.cf.hultgren@gmail.com>
* Overlay lighting component (#52413)
Sparks no longer lag, projectile beams move super smoothly, same with mobs and whatnot. This also allows for easy expansion into directional lights, field-of-view, wee-woo rotating lights or whatever.
It does have a downside: things right-clicked or checked through the alt+click tab will show the light overlay:
This is a BYOND limitation, very well worth it IMO.
🆑
add: Smooth movable lighting system implemented. Projectiles, sparks, thrown flashlights or moving mobs with lights should be much smoother and less laggy.
balance: Light sources no longer stack in range, though they still do in intensity.
/🆑
* Overlay lighting component
Co-authored-by: Rohesie <rohesie@gmail.com>
* Voice analyzers will no longer accept any message when not recorded (#53033)
* Voice analyzers will no longer accept any message when nothing is recorded
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@users.noreply.github.com>
* Adds SIGNAL_HANDLER and SIGNAL_HANDLER_DOES_SLEEP to prevent signal callbacks from blocking (#52761)
Adds SIGNAL_HANDLER, a macro that sets SHOULD_NOT_SLEEP(TRUE). This should ideally be required on all new signal callbacks.
Adds BLOCKING_SIGNAL_HANDLER, a macro that does nothing except symbolize "this is an older signal that didn't necessitate a code rewrite". It should not be allowed for new work.
This comes from discussion around #52735, which yields by calling input, and (though it sets the return type beforehand) will not properly return the flag to prevent attack from slapping.
To fix 60% of the yielding cases, WrapAdminProcCall no longer waits for another admin's proc call to finish. I'm not an admin, so I don't know how many behinds this has saved, but if this is problematic for admins I can just make it so that it lets you do it anyway. I'm not sure what the point of this babysitting was anyway.
Requested by @optimumtact.
Changelog
cl
admin: Calling a proc while another admin is calling one will no longer wait for the first to finish. You will simply just have to call it again.
/cl
* Adds SIGNAL_HANDLER and SIGNAL_HANDLER_DOES_SLEEP to prevent signal callbacks from blocking
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@users.noreply.github.com>
* Tweaks voice analyzers, pulsing a grenade's bomb wire now uses the grenade's timer delay. (#52710)
Makes suicide bombing with voice analyzers harder, while keeping the more fun behavior by adding some tells and delays.
Things attached to a grenade's pulse wire use the grenades timer, rather then just insta booming.
* Tweaks voice analyzers, pulsing a grenade's bomb wire now uses the grenade's timer delay.
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
* Confusion will no longer continue to confuse after being cured (#52286)
* Confusion will no longer continue to confuse after being cured
* Grammar comment fix
* Move to status effect
* Remove test per request
* Make confusion a status effect, confusion curing now completely neuters the confusion
* set_confusion changes, get_confusion
* Fix confusion going down twice per tick
* Change strength = to proc
* Move procs to status_procs
* Confusion will no longer continue to confuse after being cured
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@users.noreply.github.com>
* 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.
* Color standardization, vars moved, and signals
Co-authored-by: Rohesie <rohesie@gmail.com>
* Fixed#51574 - Added htmlrendertext and implemented it for the voice analyzer
* Made a htmlrendertext regex static
Co-authored-by: Bobbahbrown <bobbahbrown@gmail.com>
* Made a htmlrendertext regex static again
Co-authored-by: Bobbahbrown <bobbahbrown@gmail.com>
Remake of #50528
About The Pull Request
https://hackmd.io/@tgstation/r1tzxpwPL
Basically that.
Raw anomaly cores
Cargo crates for them (currently 5k credits each, please tell me if this is good I balanced it relative to other crates I have no clue what the current cargo "meta"/power levels are)
Finish the explosive/implosion compressor attackby and implosion procs
Map in the implosion compressor
Map in the roundstart 2 cores each type for science
Current values are set to maxcap at the 8th core, and 4 light radius (1/2/4 explosion required) at the first core. I think this is a bit low but I'm just going off the document.
The implosion compressor consumes the TTV + tanks on an attempted detonation, regardless of success. However, the "bare minimum" of checks are included (it won't let you insert incomplete TTVs. It will however, let you insert TTVs that have no explosive potential (test your bombs like you test your code ;) ), and will not waste the raw core if you fail to make a high enough radius.
Props to @ArcaneMusic for the machine sprite!
Why It's Good For The Game
image
Start of the anomaly core system I guess, gives toxins a use other than doing the quirky 50k maxcap tritium speedrun rush (or was that removed already?).
Yadda yadda allows locking items behind it and another method of getting these other than supermatter overloads (I don't know if that is already gone either by the by).
Changelog
🆑
add: An explosion compressor has been added to science. It makes raw anomaly cores into proper anomaly cores using prepared TTVs of a specific required blast radius.
/🆑
* Renames a few variables. Also reorders fallback order again.
Renames item_state to inhand_icon_state
Renames mob_overlay_icon to worn_icon
Renames mob_overlay_state to worn_icon_state
worn_icon_state/mob_overlay_state now never gets used for inhands.
* Fixes some comments
* Fixes map issue
* Restart lints
* Properly resolves conflicts
* Adds a freezy igniter
* adds to component vendor.
* don't nightcode.
* Back to condenser names.
* Adds to autolathe as well.
* Applies heat to flamethrower_process.
* Refresh
* Review changes
* Undefines properly I think.
About The Pull Request
Extools maptick stuff is in the game. Stolen from BeeStation/BeeStation-Hornet#1119, improves performance. Requires ex-tools on the server, though.
Explosions have been refactored to do the actual exploding in a subsystem.
Credit to goon.
Here's some videos!
Why It's Good For The Game
Basically instant max-caps now.
We can now give more of a tick over to the sending of map updates
Changelog
cl Goonstation Coders, Beestation, Extools devs
refactor: Explosions have been heavily optimized.
/cl
* Splits anomaly cores into separate versions
* Converts the wormhole projector to require a bluespace core.
* Cleaned up a few lines
* Fixed small bug issues
* The gravity gun now requires a grav core. Increased weight of some anomalies.
* Enables high-intensity grav anomaly
* Fixing minor issues
Adds a hypnotic flashbang, disguised as a regular flashbang, to the traitor/nuke op uplink. Pretty much an AoE one-use hypnotic flash, but it doesn't require weakening the targets as long as they can be affected by the sound of the grenade, since it causes minor hallucinations.
Why It's Good For The Game
Effectively this is a non-lethal, non-destructive chaos-making tool. Even without the hypnosis it's a better flashbang; if everything goes right you've got a roomful of followers obeying your orders, but on the other hand something might go wrong, and then Poly is the one with the roomful of followers.
Changelog
🆑
add: Added a hypnotic flashbang to the uplink for 12 TC. It can hypnotize people much like a hypnoflash, and the sound will automatically make victims vulnerable to the trance.
/🆑