* Converts some unique and typelists into stringlists (#54237)
* Converts some unique and typelists into stringlists
Co-authored-by: Rohesie <rohesie@gmail.com>
* Fix some potential sleeps as detected by SpacemanDMM improvements (#54230)
overrides weren't detected by should not sleep, i think i've mostly
fixed that with SpaceManiac/SpacemanDMM#214
Some of these are wacky but overall this pr is harmless
signals shouldnt sleep even in weird 1 in a million situations or due
to other people adding bad code
overrides of changeling can_sting() use alert() and input() and that's
just too fucked for me to fix in this pr
* Fixes some potential sleeps as detected by SpacemanDMM improvements
Co-authored-by: spookydonut <github@spooksoftware.com>
* Moves over cakes to newfood and transfers reagents when crafting (#53316)
* Moves over cakes to newfood and transfers reagents when crafting
Co-authored-by: Qustinnus <Floydje123@hotmail.com>
* Adds TCG Decks in order to play with them like a TCG. (#53200)
* Card Decks n shuffling.
* the "crackling with sexual energy" update
}
Kept you waiting, hunh?
This adds a new multi-faceted object to the game, the TCG Card Pile. Using any 2 cards together on each other will create a pile, and the first card in the pile will determine if the card pile is face-up, or face-down. Depending on the orientation of the card pile, you'll draw cards out of it in the orientation. So, a "deck" card pile would be flipped face down, and would allow you to draw cards out of it also face down, and vis versa.
Decks can be renamed with a pen, and use a radial menu in order to enable quick action on the Trading Card game battlefield.
image
Draw allows you to draw a single card from the deck, again based on the orientation of the cards used to build the deck.
Shuffle calls the shuffle() proc on the deck, and (should) randomize the order of the cards in the deck for use.
Pick up puts the deck into your hands instead of the nonsense dragging required with regular playing cards.
Flip flips the orientation of the cards in the deck, turning a face up pile into a facedown pile, and a facedown, faceup. Also, calls reverseRange() on the contents of the deck, which should put the bottom of the deck on top, and vis verse, ALSO enabling you to put cards on the bottom or the top of your deck easily.
Card piles also operate with a custom storage component, so you can search for cards in your deck if need be, but also handle edge cases like when you only have 1 card in a pile left, or when you dump out a deck of cards like you would a bag.
This basically adds in more sane hands, more sane decks and discard piles, and a massive QOL update to the trading card game to make it actually playable (once potato actually puts the card stats and effects on the cards themselves.)
* Adds TCG Decks in order to play with them like a TCG.
Co-authored-by: ArcaneMusic <41715314+ArcaneMusic@users.noreply.github.com>
* Componentizes Food Storage (#53116)
Moves the food storage behavior on (formerly) bread, cheese wheels, and cakes from /food/snacks/store/ to a component.
This lets just about any food/edible thing be used for storing fun things like glass shards, which is pretty neat. Also helps work towards the food refactor.
* Componentizes Food Storage
Co-authored-by: MrMelbert <51863163+MrMelbert@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>
* you can no longer stuff a bajillion live mice into your chef's hat (#52640)
* fuck
* Update code/datums/components/storage/concrete/pockets.dm
Co-authored-by: Rohesie <rohesie@gmail.com>
Co-authored-by: Rohesie <rohesie@gmail.com>
* you can no longer stuff a bajillion live mice into your chef's hat
Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>
Co-authored-by: Rohesie <rohesie@gmail.com>
* Nanotrasen fires the Wave Motion Gun at the Clock Cult
* Fixes a random changelog appearing from the reebe void.
* Fixes a wrong type reference regarding the bronze sheets in the Lavaland Ruin for it.
* Fixes redundant cells after CC removal in ruin by populating them with varied ore chunks, or destruction clutter.
* why is it /obj/item/stack/sheet/metal but not /obj/item/stack/sheet/iron
* Fixes the lavaland ratvar ruin to have fluff variant structures of deleted shit it referenced instead what I thought was reasonable.
* Doubtful improvement
* Switches out all the magic numbers with defines
* Thanks travis for finally finding a real error
* properly resolves some left over conflict
About The Pull Request
Converts every single usage of playsound's vary parameter to use the boolean define instead of 1 or 0. I'm tired of people copypasting the incorrect usage.
Also changes a couple of places where a list was picked from instead of using get_sfx internal calls
This was done via regex:
(playsound\(.+,.+,.+, ?)1( ?\)| ?,.+\)) to match 1
(playsound\(.+,.+,.+, ?)0( ?\)| ?,.+\)) to match 0
full sed commands:
/(playsound\(.+,.+,.+, ?)1( ?\)| ?,.+\))/\1TRUE\2/ 1 to TRUE
/(playsound\(.+,.+,.+, ?)0( ?\)| ?,.+\))/\1FALSE\2/ 0 to FALSE
I'm not very good with regex and these could probably be optimized, but they worked.
Why It's Good For The Game
Code usability
Ever since the big BoH nerf, BoH bombing is kind of a joke. The damage it does is not really huge, and it's lame for traitors - it lacks emotion and their target may not even die, as they can use the ladders to get away.
So, what this does is add back some soul into BoH bombing, while not making it too round-ending and adding some degree of damage control for admins in case of griefing.
When BoH bombing, a stationary singulo with custom sprite will spawn. Its gravitational pull is REALLY strong, so people near it are probably going to get eaten, and there will be some real damage to the hull. The singulo will cease existing after 5 seconds.
For antags, I think this becomes much more interesting than the current BoH bombing. In the case of griefers, the damage to the station isn't too big because the singulo is stationary and fades away after some seconds. And then, admins can click a button in their chat to bring back everything the singulo ate into the game (the button expires in 10 minutes, however, but this can be changed if you think it is needed).
Settings like gravitational pull can be tweaked if yall find it to be too strong or something.
Changelog
cl
tweak: BoH bombing changed again. Now it's more violent.
/cl
* Removes repeated line
* Description change for clothing items that can only store specific items
* Get all children of can_hold listed items.
* can_hold only needs the top most item, child items are dealt automatically
* cant_hold related change
* Text change
* Moves the item check to the line above, and removes the current.
* Same changes, but to belt/wallet code.
* Change to using signals instead
* Generic signal on datum/topic
* Cache typecache, and small signal change
* Small argument tweaks and remove unneeded lists
* Change to proc
* Change call can_holds/cant_holds to use new proc
* initial, and cleaned up display code
* Null check
* 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
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)