Commit Graph

57 Commits

Author SHA1 Message Date
Akrilla
55ed0ebf35 Fedoras hold small and gimmick items (#44139)
* This was probably originally intended...

* Fedoras hold small items, and exceptions for gimmicks

* Only create cache once

* Cache exception_hold, and adds other katana type
2019-05-28 09:57:59 -04:00
vuonojenmustaturska
fb45b7a017 Turns trait accessors into defines, fixes some bugs (#43820)
It's free performance.
2019-05-06 19:44:05 -04:00
Tlaltecuhtli
ec1ad61558 new cargo crates & tweaks (#43454)
* 1

* 2

* finall pre pr

* oof

* oof

* testing merge conflict fix

* test mk2

* test mk3

* plant & chem

* bvcgr

* fixed stuff

* grammar stuff

* fixes clothing + cobby bribe

* new sprites by wjohn

* Update code/modules/clothing/suits/armor.dm

Co-Authored-By: Tlaltecuhtli <33834933+Tlaltecuhtli@users.noreply.github.com>

* tweaks .38 stuff

* Update code/modules/cargo/packs.dm

Co-Authored-By: Tlaltecuhtli <33834933+Tlaltecuhtli@users.noreply.github.com>

* nuclear option
2019-04-03 14:23:38 -04:00
oranges
0267bce949 Turns out a bunch of components do not properly transfer because of (#42691)
one of three things.

    1. They don't use RegisterWithParent or UnregisterFromParent to unregister
       and register signals

    2. They use callbacks which refer to a source object, which is usually deleted
       on transfer, or lost in some manner, or simply makes no sense at all to be
       transferred

    3. the component was never designed to be transferred at all

TransferComponents gave no shits about any of this and just blindly transferred
all components, if they were actually capable of it or not.

I only noticed this because it was causing chairs to break as they would not register signals
and verbs correctly for rotation after being picked up and then placed down, and a player
reported that issue via ahelp.

Luckily we caught it before the rot got anywhere, only chairs and the shuttle subystem
tend to use this proc (Shuttle uses it on turfs), can you imagine if everything was using
this LMAO

Which is good because it's more dangerous than a loaded gun

I have added a can_transfer var, that is true when a component is valid to
actually transfer, which means the dev has actually thought about what happens when
you take the parent object away and swap it for another and all the crazy that is entailed
by this

I have done my best to audit what components are actually
transferable, but things are basically a hot mess (Thanks @Cyberboss )

The following components required edits:
Forensics:
did not register/deregister the clean_act signal properly, did not checkblood on new parent

Rotation:
did not use RegisterWithParent or UnregisterFromParent, turned out
to not be transferable anyway due to having callbacks that can be
passed in to the parent with unknown sources that we can't feasibly
reuse (i.e if you're transferred from a chair to a bed, your old rotation
call backs are no longer valid). Turns out the use case it was for (just chairs)
didn't need it anyway, so I just made it non valid for transfer.

Wet Floor:
Honestly this one is just a hot mess, it should be a subtype of the slippery
component with the extra wet turf handling.

As it is it basically manages a slippery component on top of it's own extra
functionality, so that's a major code smell.

I added registration/unregistration of the signals, and made it's pretransfer
remove the slippery component and the posttransfer add it back (via update_flags)

Components that seem transferable without issues
mirage_border
orbiter
decal
spill
storage (I hope to earth)
2019-03-05 20:27:29 +01:00
Trilbyspaceclone
555f0bda23 Fixes power tool drill fitting in boots/wallet (#42476)
* Update wallets.dm

* Update pockets.dm

* Apply suggestions from code review

For when people forget how sister code works

Co-Authored-By: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com>
2019-01-23 14:32:04 -05:00
coiax
881e8c1ab9 Refactors NODROP flag into TRAIT_NODROP (#42109)
* Refactors NODROP flag into TRAIT_NODROP

🆑 coiax
fix: Anti-drop implants can no longer be used to drop objects that they
were not responsible for sticking to a person's hand.
fix: Backfiring with a Barnyard spellbook will now play a spooky horse sound.
refactor: Refactors the way that "NODROP" items work to a new system,
there should be no change in functionality.
/🆑

Various items in the codebase were doing weird hoop jumps in order to
preserve the nodrop flag's state when it also wanted to change it, so I
moved it to a trait system.

I may have gone overboard with the type of unique trait sources, but
those can be changed later. My long term plan is make a general "CURSED"
nodrop origin, which means you can unlock cursed items by being hit with
a bolt of door opening or something. But that's for another PR, this has
no functionality changes, apart from some slightly modified descriptions
on cursed masks.

- Removed a bunch of redundant voice changing code for all the voice
changing animal masks, used two new clothing flags for this purpose.
- Also refactored a bit the animal masks, making new cursed subtypes that play
the sound when created.

* Drop location
2019-01-17 15:24:30 -05:00
subject217
5a52f8a7bf Removes smugglers satchels (#42166)
* Removes smugglers satchels

I love the cutie reading this

* remove smuggler's satchel from code

* removes all smugglers' satchel persistence code

* removes remaining things

storage component for smugglers, the miracle ruin (uses smugglers), the dme
2019-01-02 15:28:26 -05:00
skoglol
4a5fc9e14e Makes satchels stack by name instead of type (#41827)
* Makes satchels stack by name

* Type and name and hopefully fixed branch?
2018-12-23 16:30:34 +11:00
Francesco
0e8eb3acfc Nuclear bombs in rifts spawn a singulo on the station and count as a syndie victory (#42011)
* A nuclear bomb in a rift in spacetime will now count as a syndie major victory, and spawn a singulo back at the station

* Removes config debug stuff
2018-12-23 16:09:25 +11:00
coiax
00cd022dd5 BoH bombing logs now include ckey in admin logs/messages (#42030)
🆑 coiax
fix: A player who bag of holding bombs now correctly has their
ckey entered in the admin log, and admin messages.
/🆑

The mob was gibbed (and thus destroyed) before the message
was being sent.
2018-12-22 12:47:16 -08:00
oranges
0e982cad32 Merge pull request #41921 from kevinz000/patch-584
Fixes some instances of storage not closing when it should (on move)
2018-12-16 13:02:44 +13:00
coiax
d27c64c3a8 Christmas code changes (#41763)
* Christmas code changes

🆑 coiax
add: Santa can now examine presents to see what's inside.
del: Santa no longer has a mass summon presents spell, because of his
new regenerating bag!
add: Santa's bag regenerates presents as long as Santa is holding it.
balance: You can only find one gift under a christmas tree per round, no
matter how many trees you search.
balance: Santa's teleport does not announce where he's going.
fix: Fixed Santa not having a full head and beard of white hair.
fix: Fixed Santa not being genetically white-haired.
fix: Fixed Concentrated Barber's Aid not growing extreme amounts of
hair.
/🆑

The `box` var has been moved down from `/datum/outfit/job` to
`/datum/outfit`.

Added unlimited christmas tree with presents, for testing.

Santa's restriction against opening presents is now done by
TRAIT_CANNOT_OPEN_PRESENTS. Santa's ability to see inside presents is
done by the TRAIT_PRESENT_VISION, which also determines if Santa's Bag
will regenerate presents every 30 to 60 seconds.

Santa no longer starts with a breath mask and O2 tank, but instead has
an internals box. Santa no longer has a no-access gold ID, he can
teleport from room to room!

Gifts determine what type is inside them on initialization, rather than
when unwrapped.

- Reasoning -

Unlike last year, there are various possible methods of accessing
christmas trees spawners, allowing for an unlimited number of anything
presents. Cutting down the presents to one per round regardless of tree
count will avoid this.

Santa should be able to see what he's giving, because then he can reward
the naughty and nice children with different gifts.

* Missed a merge

* Adds present investigate logs, and visible messages

* Use the body+mind checking of mob.has_trait

* Less globals, more static vars on types; also event renaming
2018-12-16 12:44:53 +13:00
kevinz000
18860d2346 Update storage.dm 2018-12-12 04:45:38 -08:00
skoglol
6aac8b26bc Open storage by alt clicking (#41712)
Provides an alternative to click-dragging.

The on_alt_click() proc wasn't ever used, but seemed to be ready for replacing
the AltClick() overload from sabre sheath. I kept that part and added
fingerprints to it as well, and it is still good to go (if it really was)
whenever someone bothers.
2018-11-29 21:40:32 -08:00
MrDoomBringer
3d24bc0f08 Prevents blob overminds, sentient diseases, etc. from dumping out boxes (#40823)
* nerf boxes

* uuh i think i see what you mean. hows this

* shuffles it over to mob.dm

* asdf

* hows this

* ooga

* i should probably rebase

* t

* cheaper and stronger unlike me

* aaaaa

* does the thing with the words
2018-10-26 22:03:09 +02:00
kevinz000
3e7184c975 Combat/Stun (slip) overhaul staging, mobility flags, adds crawling (#39967)
Aiming to implement the framework oranges has detailed in https://tgstation13.org/phpBB/viewtopic.php?f=10&t=19102
Moves canmove to a bitflag in a new variable called mobility_flags, that will allow finer grain control of what someone can do codewise, for example, letting them move but not stand up, or stand up but not move.

Adds Immobilize()d status effect that freezes movement but does not prevent anything else.
Adds Paralyze()d which is oldstun "You can't do anything at all and knock down).
Stun() will now prevent any item/UI usage and movement (which is similar to before).
Knockdown() will now only knockdown without preventing item usage/movement.
People knocked down will be able to crawl at softcrit-speeds
Refactors some /mob variables and procs to /mob/living.
update_canmove() refactored to update_mobility() and will handle mobility_flags instead of the removed canmove

cl
rscadd: Crawling is now possible if you are down but not stunned. Obviously, you will be slower.
/cl
Refactors are done. I'd rather get this merged faster than try to fine tune stuff like slips. The most obvious gameplay effect this pr has will be crawling, and I believe I made tiny tweaks but I can't find it Anything I missed or weird behavior should be reported.
2018-10-11 11:22:21 +13:00
Emmett Gaines
0943e56e08 Adds the signal origin as the first arg to all signals (#39861)
* Adds the signal origin as the first arg to all signals

* Fixes some storage and nanite procs
2018-08-28 18:28:29 +03:00
kevinz000
0038c9cafd exploitfix (#39842) 2018-08-24 12:40:11 +03:00
kevinz000
1bfa10d012 Fix bio bags not working for reproductive extracts (#39753)
> Take 1
> Length of cubes is above 1
> Cut(1)
> Wait that just cut the entire list to nothing

Now the signal should work properly instead of not working whenever there's
more of a thing than the requested amount.
2018-08-23 19:32:01 -07:00
Jared-Fogle
0308655a68 Hovering over storage slots with an item in your hand will show you if you can put the item in (#39661)
Quality of life. Sometimes I forget whether or not I can put an item in my suit storage/pockets. Note this doesn't trigger for hands.
2018-08-17 16:24:56 -07:00
Patrick Chieppe
2c8248575a Logging system refactor and improvement (#39521)
* Refactor several log lines to use datum_info_line and atom_loc_line

* Add default return strings from datum_info_line and atom_loc_line

* Add parentheses around atom_loc_line data

* Change more logs to use atom_loc_line

* Add check in atom_loc_line for turfs to avoid calling get_turf on them

* Re-add removed 'at'

* Replace datum_info_line with key_name and atom_loc_line with loc_name

* Refactor logging functions

* Avoid double-logging self-interactions

* Fallback to simple stringification if all else fails in key_name()

* Rewrite muscle spasm logging to use log_message

* Standardize logging of martial arts

* Tweak individual logging panel look

* Fix individual logging panel source

* When I typed || I really meant &&

* Fix Telecomms logging always showing client logs in the panel

* Reverts addition of buggy ownership log to panel

* Remove colon

* Fix missing log_directed_talk tag

* Add warning for missing type in log_direted_talk

* Change warnings to stack_traces

* Add square brackets around fallthrough key_name() case to help parsing

* Allow atom arguments/src in log_*() functions

* Change log_combat call with null argument to log_message

* Change mecha types' log_message() arguments to match atom and mob version

* Add key_name() case for atoms

* Fix resist_grab() unsetting pulledby before log_combat gets a chance to use it

* Fix log_globally logic

* Add logging for hitting objects with items

* Move log_combat() to atoms.dm

* Use utility functions for object stringification in log_combat()

* Use utility functions for object stringification in log_combat()

* Add missing logs for interacting with display cases

* Rewrite log_combat() comment

* Add missing space in log_combat()

* Add logging for hitting grilles barehanded

* Add missing ..()
2018-08-12 21:41:09 +02:00
ninjanomnom
befaa09c88 Removes a couple storage GetComponent calls 2018-08-02 00:52:12 -04:00
Emmett Gaines
44da4cb683 Makes magnetic catch cleaner in game (#38956)
Utilizes the new signal refactor to cancel throws before they happen. This prevents the silly spin even though the throw was stopped.
2018-07-13 10:31:30 +02:00
Emmett Gaines
34a3d2da4d Refactors component signals registration (#38798)
Datums know what signals are being listened for and components can now be registered to listen for signals on more than one object.
2018-07-05 00:56:39 +03:00
vuonojenmustaturska
34c70340f9 Makes tear in the fabric of reality inaccessible until a boh bomb is detonated (#38852)
* a commit message

* reviews addressed?
2018-07-03 18:02:16 -04:00
Dax Dupont
d577ab0372 Makes bags of holding gib the user on boh detonation (#38737)
It doesn't seem right the user of a boh explosion gets off scott free especially when they just climb the ladder and use a hand tele, mine a little or whatever.

At least with autocloners there needs to be a autocloner and some more effort than printing two bags.
2018-07-03 12:57:48 +12:00
Jordan Brown
26b6fab1fe Merge branch 'pr-38604'
Signed-off-by: Jordan Brown <Cyberboss@users.noreply.github.com>
2018-06-28 14:22:03 -04:00
Tad Hardesty
de205b5517 Fix pocket protectors (#38665) 2018-06-26 16:44:52 -04:00
ShizCalev
89752866aa Merge branch 'master' into spellcheck 2018-06-26 16:43:41 -04:00
ShizCalev
ff532a4ca4 Spellchecks TGStation 2018-06-19 18:57:44 -04:00
Tad Hardesty
870ac15480 Improve how vending machine restocking works 2018-06-16 23:02:41 -07:00
Tad Hardesty
2f8f166d88 Merge pull request #38287 from ninjanomnom/signal-define
Use a define to speed up sending signals to datums with no signals
2018-06-14 22:17:01 -07:00
ninjanomnom
d483ff3ef0 Regexes
`([^_\.])SendSignal\((.+?)\)` -> `\1SEND_SIGNAL(src, \2)`
`([\.\w]+?)\.SendSignal\((.+?)\)` -> `SEND_SIGNAL(\1, \2)`
2018-06-13 19:19:23 -04:00
Jordan Brown
7b06cbb63a [s] Fixes BoH loc being determined before warning prompt (#38459)
* This is clearly @kevinz000' fault

* Not even null checking properly, smh

* Speling

* Fax
2018-06-14 01:37:44 +03:00
kevinz000
a3d1581083 BoH bombs now forcefully stun anyone flying when they go off (#38397)
* Update bag_of_holding.dm

* Incorrect type.
2018-06-13 05:32:48 -04:00
Tad Hardesty
106f5af48b Fix lockboxes not actually being locked 2018-06-08 23:22:12 -07:00
Tad Hardesty
1ed3b1b589 Fix paradox bags (#38212)
* Fix linked storages not initializing correctly

* Rewrite CanReach to handle multiparent storages

* Fix being able to click anything
2018-06-08 13:47:30 +02:00
vuonojenmustaturska
c65a99f130 Move NODROP_1, DROPDEL_1, ABSTRACT_1 and NOBLUDGEON_1 to item_flags where they belong (#38171)
* (mostly) nodrop

* (mostly) dropdel

* (mostly) abstract

* nobludgeon

* things i missed

* forgot one

* unintended changes

* energy handcuffs
2018-06-01 11:36:31 +02:00
ShizCalev
c41d6ac965 Standardizes and cleans up some admin messages & logging (#38128)
* Improved logging

* Fixes & emitter logging

* ded
2018-05-30 21:57:06 -07:00
Dax Dupont
4efb660d8c Adds better admin messaging to boh and fixes summons happening in the wrong places (#38096)
* Adds better admin messaging to boh

* Same for the logs

* chumbis

* I'm a chumbis
2018-05-27 14:02:55 -07:00
KorPhaeron
f5e063414a Bag of Holding Rework (#38010)
* Bag of Holding Rework

* RCDs work on chasms

* No transit space nonsense

* Fixes runtimes

* No infinite chasm
2018-05-26 00:27:32 -04:00
Tad Hardesty
f53caac04a Refresh mob views when atoms enter/exit storage (#37954) 2018-05-21 12:45:52 +03:00
Dax Dupont
b10b31a53d The great bag of holding n e r f 2018-05-19 19:52:21 +02:00
kevinz000
85aef5755a Fixes EMPs (#37656) 2018-05-10 08:32:40 +02:00
kevinz000
2d91fdbd93 Fixes mousetraps not going off from being dumped out (#37447)
* mousetrap fix

* fix mousetraps

* Update storage.dm

* Combine checks
2018-05-04 11:42:55 +02:00
Tad Hardesty
e268d6fe52 Fix placing boxes in storage implants (#37579) 2018-05-01 08:29:41 -04:00
Jordan Brown
8ce7d19c9c Merge pull request #37565 from ninjanomnom/component-limbo
Modifies component transfer to make ChangeTurf able to transfer components
2018-04-30 22:16:47 -04:00
ninjanomnom
ff856e4bf5 Proper method fixes 2018-04-30 15:54:59 -04:00
ninjanomnom
c1e5150681 Purge references in /storage/concrete Destroy 2018-04-29 19:13:18 -04:00
ninjanomnom
5028239b35 Modifies the component transfer to make ChangeTurf work 2018-04-29 18:11:02 -04:00