* Modifies right click logic so that it is not the same priority as modifier keys. (#59656)
Strips out the existing right click code - Due to the myriad of ways right clicking has been implemented, dedicated signals and procs for right clicking without modifiers are fundamentally incompatible with our system of primary and secondary attacks.
Adds additional signals to attacking code. These signals allow atoms to cancel the attack chain early on secondary attacks, or override the standard procs and not send signals to prevent any undesired behaviour from signal handlers.
Items that used RightClick procs have been converted to attack_hand_secondary.
The slaughter demon, having its own set of snowflake code as poor OOP principles have been applied in UnarmedAttack() procs with lacking calls to parent procs and arbitrary redefinition of behaviour, checks for a right click in its own UnarmedAttack() and performs a bodyslam off that.
Storage components now hijack the secondary attackby stage via signals to handle their opening and closing shortcuts on right click. When you right click a storage component equipped item with an object in your active hand, the object has an opportunity to perform its logic in pre secondary attack code and cancel the attack chain. If it does not cancel the attack chain in pre-attack, then the storage component takes over for attackby and, if possible, opens the relevant inventory and ends the attack chain.
The forensic scanner is a proof-of-concept of this working in action. With its scan logic moved from afterattack code to pre attack code for right clicking, right clicking with the scanner will now perform a scan where previously one was impossible. Left clicking still does what it always does - Scans at the very end of the attack chain.
The logic still isn't perfect - For example, you still can't attack containers in melee even in combat mode (you'll either open them or put your weapon into them regardless of which option you choose) - But this is a better setup overall which allows for items to at least override this behaviour in pre-attack if needed.
* Modifies right click logic so that it is not the same priority as modifier keys.
* a
Co-authored-by: Timberpoes <silent_insomnia_pp@hotmail.co.uk>
Co-authored-by: Gandalf <jzo123@hotmail.com>
* Fixes collapsed or burnt paper bins from voiding new papers added (#59732)
* Stops collapsed or burnt paper bins from voiding new paper added afterwards
* Replaces papers.Remove and paper.Add
LAZYADD and LAZYREMOVE are much more useful.
* Fixes collapsed or burnt paper bins from voiding new papers added
Co-authored-by: Ed640 <Ed.640@hotmail.com>
* Revert "Adds two clown-spection scanners that print clowncrypted reports (#59306) (#6176)"
This reverts commit 91e1aa4fe4.
* Revert "Two Person Mecha for Robotics: The Only Real Solution To An Imminent Geometer Summoning 💪 (#59249) (#6177)"
This reverts commit cf2c1ca19d.
Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com>
Alright, update the changelog and body of the PR, and comment here when that's done.
This should be ready for merge then.
Co-authored-by: interestingusernam3 <51925758+interestingusernam3@users.noreply.github.com>
* Paper bins show the paper inside them (atomised) (#57907)
Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>
* Paper bins show the paper inside them (atomised)
Co-authored-by: cacogen <25089914+cacogen@users.noreply.github.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>
* Refactors the paper bin behavior for dragging to pick up into an element (#57501)
* Drag pickup element for the paper bin behavior
* invokes async on put_in_hands to comply with the linter
* documented and like better names
* blackspace
* Refactors the paper bin behavior for dragging to pick up into an element
Co-authored-by: spessbro <51048066+spessbro@users.noreply.github.com>
* Adds a hotkey that puts you in throw mode aslong as you hold it (#57331)
Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>
* Adds a hotkey that puts you in throw mode aslong as you hold it
* a
Co-authored-by: Qustinnus <Floydje123@hotmail.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>
Co-authored-by: Gandalf2k15 <jzo123@hotmail.com>
* Clipboards: tgui and better functionality (#57289)
- Clipboards now use tgui
- View / write on paper on the chipboard using an attached pen
- Rename paper on the clipboard
- Attach a pen by clicking on a clipboard with one
- Attach paper by either clicking on a clipboard with some or:
- Rapidly attach paper by clicking on paper with the clipboard 🚀
* Clipboards: tgui and better functionality
Co-authored-by: mozi_h <die-123-321@web.de>
* Folders: tgui, refactor, qol (#57320)
Snazzy new UI is always great. Makes folders more fun to use and makes it consistent with the new clipboards
* Folders: tgui, refactor, qol
Co-authored-by: mozi_h <die-123-321@web.de>
* Refactor can_inject, and introduce try_inject (#56816)
Splits can_inject into can_inject and try_inject. The latter can perform side effects, while the former cannot. Moved the show_error bool parameter to a flag that try_inject checks.
Changes the signature to can_inject(mob/user, target_zone, injection_flags). This was previously redefined in several places, making it impossible to use named parameters. This refactor now allows named parameters to be used, and thus avoiding the ugliness of TRUE, FALSE, FALSE in parameters.
* Refactor can_inject, and introduce try_inject
Co-authored-by: Mothblocks <35135081+Jared-Fogle@users.noreply.github.com>
* renames metal sheets to iron sheets
* Merge branch 'master' into upstream-merge-56643
* yay metal
* Update DeltaStation2_skyrat.dmm
* a
* Update CentCom_skyrat_z2.dmm
* a
* a
Co-authored-by: Fikou <piotrbryla@onet.pl>
Co-authored-by: Gandalf2k15 <jzo123@hotmail.com>
* Fixing yet another item that can be remotely put in hands with TK. (#55505)
I'm adding adjacency checks to paperplane folding and unfolding so the resulting item doesn't get put in hands from afar.
* Fixing yet another item that can be remotely put in hands with TK.
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
* Fix observers not being able to read from afar (#55841)
From the examine() code it's clear that this was intended, just a check
in `ui_status` meant that the range check was being applied to them
anyway.
* Fix observers not being able to read from afar
Co-authored-by: coiax <yellowbounder@gmail.com>
* Fixes a possible oversight in photocopier code. (#55379)
I think #54336 neglected to use the icon() proc when it should have. This is a Byond proc apparently, and the rest of the code in the photocopier (and other picture related things I checked elsewhere) seems to use it when setting an image, I guess it's sort of like typecasting? So this will probably maintain consistency and prevent some weird bugs in the future
* Fixes a possible oversight in photocopier code.
Co-authored-by: uomo <51800976+uomo91@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>
* Increases large toner cartridge capacity, adds a supply pack containing them (#54556)
This PR does two things:
The capacity of large toner cartridges is increased from 15 to 25.
It adds a supply pack containing large cartridges; so far the game only has a single large cartridge available on one map.
* Increases large toner cartridge capacity, adds a supply pack containing them
Co-authored-by: 81Denton <32391752+81Denton@users.noreply.github.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>
* Increases the accuracy of the photocopier (#54336)
🆑
add: Increased photocopier accuracy
* Increases the accuracy of the photocopier
Co-authored-by: Rob Bailey <actioninja@gmail.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>
* Fully removes devil and affiliated shitcode (#53612)
Its all over the place, messy, and overall a bad enough gamemode to be removed from rotation.
A rework would have to tear out everything as is so there is no reason to allow the shitcode to live beyond tripping up everything.
* Fully removes devil and affiliated shitcode
* weh
Co-authored-by: TiviPlus <57223640+TiviPlus@users.noreply.github.com>
Co-authored-by: Azarak <azarak10@gmail.com>
* Makes Ice Box Botany Cozy as Fuck [MULTI-Z] [FUCK CABLE HUBS] (#53627)
Makes botany down a zlevel, gives them an exit so they can collect plants on the ice moon...
* Makes Ice Box Botany Cozy as Fuck [MULTI-Z] [FUCK CABLE HUBS]
Co-authored-by: tralezab <40974010+tralezab@users.noreply.github.com>