* Add locking into portals with right click on hand tele, refactor hand tele code, add pre_attack_secondary (#56700)
Refactors hand tele code with better variable names, splitting procs, fixing C&P code, etc.
Adds pre_attack_secondary, the right click version of pre_attack.
Adds a new alternate function to hand teles, which will reopen the last location you opened. Works based off locations, not turfs. For example, right clicking after locking in "None (Dangerous)" will not teleport you to the same place.
* Add locking into portals with right click on hand tele, refactor hand tele code, add pre_attack_secondary
Co-authored-by: Mothblocks <35135081+Jared-Fogle@users.noreply.github.com>
* M90 changes (#56667)
The m90 is now 14tc instead of 18. Its grenades can be bought from the uplink in boxes for 6tc, instead of individual grenades for 2tc each. You can also fire the m90's grenade launcher with right click.
* M90 changes
Co-authored-by: TJatPBnJ <69724863+TJatPBnJ@users.noreply.github.com>
Co-authored-by: Gandalf2k15 <jzo123@hotmail.com>
* Refactors plane masters a bit and introduces plane master controllers (#56717)
* plane master controllers
* small adjustments
* bro its a comment CHILL OUT
* powerful
* Refactors plane masters a bit and introduces plane master controllers
Co-authored-by: Qustinnus <Floydje123@hotmail.com>
* Renames the _alt attacks to _secondary for clarity (#56752)
* Renames the _alt attacks to _secondary for clarity
Co-authored-by: Rohesie <rohesie@gmail.com>
* Add pAI internal GPS to possible software (#56404)
pAIs are now a useful space travelling companion, they can help you
navigate if lost (although only the pAI has the GPS view, so they'll
need to communicate the information). If you're holding a GPS, then the
pAI can find you even if you get separated.
* Add pAI internal GPS to possible software
Co-authored-by: coiax <yellowbounder@gmail.com>
* Add alternate attack procs (#56663)
Adds alternate attack procs for right-clicking. Updates the gunpoint code to use this new proc as an example (though I suspect this is being changed soon, so oops).
This makes it easier to add new behavior to right click, which we should be doing.
* Add alternate attack procs
Co-authored-by: Mothblocks <35135081+Jared-Fogle@users.noreply.github.com>
* Cleans up blob code, removes a lot of hardcoded stuff, many new defines (#56306)
Cleaned up, commented on, and (hopefully) improves a lot of blob code.
Put pretty much everything balance-related (except for the strains themselves) into a define file, for easier viewing, changing, and balancing.
Added a bunch of new functionality that new strains (some of which I plan to add in the future) could use: from increased expansion range to more spores per factory.
* Cleans up blob code, removes a lot of hardcoded stuff, many new defines
Co-authored-by: NotRanged <rangedvdk@gmail.com>
* reverts Adds Neon Carpet (#55782), it appears to have been causing massive amounts of maptick (#56496)
It appears to have been causing massive amounts of maptick, this'll need a testmerge so we can test my hypothesis
* Reverts Adds Neon Carpet (#55782)
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
* Replacing magic numbers with defines in robot code (#56241)
While scouring robot code for some (hopefully upcoming) fixes, I found a bunch of gross numbers. These numbers are now letters.
* Replacing magic numbers with defines in robot code
Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com>
* Fixes parallax runtime when observing someone without client (#56092)
When observing someone without client (because they for example disconnected) a runtime happened:
This was because update_parallax didn't take a mob as parameter but instead always updated the parallax of the mob to which the HUD datum belonged (which was the HUD of the person who you tried to observe)
If that mob had no client this caused a runtime.
If you observe someone now the game updates parallax for your client and not the client of the person you tried to observe.
* Fixes parallax runtime when observing someone without client
Co-authored-by: Gamer025 <33846895+Gamer025@users.noreply.github.com>
* Telekinesis can throw non items (vending machines, lockers) only 1 tile far (#56063)
Telekinesis users can now only throw items 10 tiles, everything else can only be thrown 1 tile
* Telekinesis can throw non items (vending machines, lockers) only 1 tile far
Co-authored-by: Gamer025 <33846895+Gamer025@users.noreply.github.com>
* Merge pull request #55869 from LemonInTheDark/fixes-plasma-alerts
Fixes plasma alerts not showing up
* Fixes plasma alerts not showing up
Co-authored-by: 81Denton <32391752+81Denton@users.noreply.github.com>
* Fixes two bugs with Blob strain rerolling (#55833)
* tested locally and it works
* As suggested
Co-authored-by: Ranged <nickvanderkroon@ gmail.com>
* Fixes two bugs with Blob strain rerolling
Co-authored-by: NotRanged <rangedvdk@gmail.com>
Co-authored-by: Ranged <nickvanderkroon@ gmail.com>
* Fix zero damage items not showing explicitly set attack verbs in chat (#55509)
Borked exactly five months ago by #52890.
This will close#55219.
* Fixing zero damage items with set attack verbs not showing chat messages anyway.
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
* Fixes mech equipment being unusable for AIs (#55248)
Adds a signal listener on mechs that listens for middle clicks, and calls a proc that will, in turn, call the normal click proc if the user is an AI.
Middle clicks now pass through params just like left clicks.
* Fixes mech equipment being unusable for AIs
* Add CI-conform #2347 to this.
Co-authored-by: zxaber <37497534+zxaber@users.noreply.github.com>
Co-authored-by: Alex 'Avunia' Takiya <git@takiya.cloud>
* Generalizes hands blocked as unarmed attack block (#55579)
I suppose for bots there's a certain level of abstraction involved, but it makes sense within the context.
There's a pretty bad bug associated with shades here that this fixes.
* Generalizes the hands-blocked trait as UnarmedAttack block
Co-authored-by: Rohesie <rohesie@gmail.com>
* Rerolling blob strains now uses a radial menu, and lets you see what the strain does before picking it (#55559)
Also provides a generic, forward proof way to provide information to radial menu choices.
Why It's Good For The Game
input is old and crummy.
Blob is a very wiki reliant mechanic. This moves a bit of it into the game itself to fix that.
Provides a real cancel option, whereas the old one had none. This is not a balance change, but a QoL one--everyone just moved the input window off to the side.
* Rerolling blob strains now uses a radial menu, and lets you see what the strain does before picking it
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@users.noreply.github.com>
* [READY] Kitchen Rework part 1: I just want to griddle! (#55319)
This PR essentialy moves away from the extremely microwave dependent cooking we have for meat right now, and making it a bit more sensical by making you use a grill to grill meat. The grill takes a different time (with variation) for different grilled things. Once finished it will turn that food into something else.
Yes, this does mean creating burgers takes longer, but in return you can make more patties at once, and you are not required to stay at the grill while its going. This lets you cook as much as you want at once, just make sure your meat doesn't burn!
In the future, I hope to move more things like this to machines similar to this (Pasta boiling, putting eggs on the griddle, soup making, etcetera) to create for a more interesting cooking experience.
* [READY] Kitchen Rework part 1: I just want to griddle!
Co-authored-by: Qustinnus <Floydje123@hotmail.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>
* unfucks hitting simplemobs with melee attacks (sorry!) (#55269)
Adds a single "!" to the code I added (in #55023) to make it not make most simplemobs immune to being hit with most melee weapons.
* unfucks hitting simplemobs with melee attacks (sorry!)
Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>
* Makes the usage of force_threshold in the attackby() proc for simplemobs consistent with the way it's used everywhere else (#55023)
## About The Pull Request
Namely, this means that a simplemob's immunity to melee attacks of force X or lower now accounts for that simplemobs damage multipliers to various damage types. It also means that simplemobs with a force_threshold of X are now immune to melee attacks of force X or lower, not melee attacks with a force less than X (<= vs. <).
## Why It's Good For The Game
**tldr;
This make the code for simplemob "your stick must be this strong to deal damage" thresholds more consistent.**
Xenomorphs, xenomorph larvae, barehanded monkeys, slimes, and simplemobs in general all multiply the damage of their attacks by the relevant damage resistance multiplier BEFORE checking it against the force_threshold of the simplemob they're attacking, and also check to see if their damage is <= the force_threshold of the simplemob they're attacking (instead of requiring it to be strictly < the force_threshold of the simplemob they're attacking).
As for balance concerns, while this will affect juggernauts *slightly* (as they'll now be immune to force <= 10 melee weapons instead of just force < 10 melee weapons), I'm not too worried about that. What I _am_ worried about is blobbernauts, who, after this change, will be immune to brute melee weapons of force 20 or lower (due to their 0.5 brute damage multiplier). You will, of course, still be able to welder them just as effectively as you could before, but I'm worried that this could make blob-aligned blobbernauts even stronger than they already are.
* Makes the usage of force_threshold in the attackby() proc for simplemobs consistent with the way it's used everywhere else
Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>
* Fix 'your mind won't reach that far' message when clicking moodlet with TK (#55070)
The mood /atom/movable/screen, instead of having a Click() override, instead has its COMSIG_ATOM_CLICK registered in the mood component. This has the side effect of normal attack chain protocol being ran on it, meaning that if you click it with TK you will get a message saying "Your mind won't reach that far". This fixes that by overriding attack_tk into a noop.
* Fix 'your mind won't reach that far' message when clicking moodlet with TK
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@users.noreply.github.com>
* Refactored 'IsAdvancedToolUser' into a macro plus relative trait. Tweaked 'can_hold_items'. (#54665)
The PR aims to allow advanced tool users to be defined by traits rather than a hardcoded proc.
Also necessary for the CanUseTopic refactor I'm working on, which will be PRed separately for atomization purposes.
This PR also fixes an inconsistency with can_hold_items (since monkeys can actually hold items).
* Refactored 'IsAdvancedToolUser' into a macro plus relative trait. Tweaked 'can_hold_items'.
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
* radial menus ignore the anchor's alpha, color and transform now. (#54870)
* radial menus ignore the anchor's alpha, color and transform now.
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
* Adds layer switching with mouse wheel to the RPD. (#54458)
Adds a signal that gets sent to items in currently active hand on mouse scroll
and makes RPD listen to this and change the piping layer accordingly.
* Adds layer switching with mouse wheel to the RPD.
Co-authored-by: TheChosenEvilOne <34602646+TheChosenEvilOne@users.noreply.github.com>
* Adds 👏 High 👏 Fives 👏 (#54516)
This PR lets you post up for high-fives with your buds so you can slap some skin and show off how well you vibe together. To initiate a high-five, simply stand next to another person with a slapper (the *slap emote one) in hand, and hit the offer item button (default G) to let the people adjacent to you know you're available. They'll get an alert that you're offering a high-five, and clicking it will follow through and award you both a small positive moodlet, or they can just walk away and leave you hanging, earning you a negative moodlet.
Is a high-five not enough to show the world how tight your crew is? Double the fun! If whoever initiates the high-five has a slapper in both hands, and the taker has two hands free, you'll go for the mythical high-ten for a louder slap and extra emphasis! Woo!
* Adds 👏 High 👏 Fives 👏
Co-authored-by: Ryll Ryll <3589655+Ryll-Ryll@users.noreply.github.com>
* Adds a runechat plane to fix the issues related to the chat messages (#54522)
Previously your chat messages would be obstructed by the blackness of blocked turfs, aswell as dark lighting and some other effects. This fixes that
It still has backdrop ambient occlusion like it used to.
* Adds a runechat plane to fix the issues related to the chat messages
Co-authored-by: Azarak <azarak10@gmail.com>
* 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.
* Standardizes attack chain signal returns and fixes a tk bug
Co-authored-by: Rohesie <rohesie@gmail.com>
* Moves screen objects from mob to hud (#54400)
This moves screen images from icons/mob to icons/hud
Makes more sense and it is easier to find
* Moves screen objects from mob to hud
* Update radial.dm
Co-authored-by: nicbn <nicolas.nattis@gmail.com>
Co-authored-by: Azarak <azarak10@gmail.com>
* 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>
* Merge pull request #53702 from zxaber/kiltborg
[READY] Highlander mode now includes silicons
* [READY] Highlander mode now includes silicons
Co-authored-by: nemvar <47324920+nemvar@users.noreply.github.com>