Commit Graph

12250 Commits

Author SHA1 Message Date
kingofkosmos
3263decaad Personalized combat messages part 2 (#52890)
Adds more "personalized" combat messages for all participants in a fight: the attacker, the victim and the spectators
2020-08-13 11:34:57 -03:00
LemonInTheDark
f66dc66ae5 Fixes tesla coil hell contraptions (#52889)
Removes the ability for tesla coils to generate power with more then 85% efficiency.
Cleans up the remainder of my zap_act refactor, making the proc better fit its usecase and removing some unneeded code.
Adds a check in the tesla coil zap() proc that makes sure we're not trying to use power that's not there.
Removes some seemingly complex math from said proc, replaces it with a static 20% draw * the efficiency.
2020-08-13 11:32:27 -03:00
Rohesie
7586d20c23 Fixes staminacrit not paralyzing (#52906)
Additionally removes the now-superfluous stam_paralyzed variable. We can already track this with the incapacitated effect from the stamina source.
2020-08-13 14:51:56 +12:00
Rohesie
c5feef02df Fixes a slime emote runtime (#52896)
It wasn't checking the parent call return value.
This is the runtime:
2020-08-13 14:05:13 +12:00
Rohesie
14f5c6f918 Floored trait (#52884)
Refactors mobility, so we respond to more things as events.
One has_legs and has_arms are turned into events we'll be close to be able to eschew update_mobility()
2020-08-13 14:04:33 +12:00
Rohesie
b0726e032b Icon smooth refactor (#52864)
bitflag list construct added: an associative list of bitflags for cheap and quick element comparison between two lists using the same system.

    canSmoothWith list turned into a bitflag list.

    smoothing_groups list added to substitute the type path list.

    smoothing procs turned into atom procs, refactored and optimized a bit.

    smooth directions redefined in order to fit in 8 bits for a future smoothing system

    some variable names changed, foreseeing a second smoothing system

    SMOOTH_OBJ flag added, for things that need to scan turfs for smoothing. The old locate() optimization has the risk of returning false negatives by finding a child and returning null while there might be one of the wanted type as well, as it doesn't match the type exactly.

    SMOOTH_TRUE and SMOOTH_MORE condensed into SMOOTH_CORNERS. The old behavior can be replicated using smoothing groups without loss.

    Does very minor code cleanup.

    Processing-wise didn't find a noticeable difference. The system loses on init a bit by setting the bitflag_lists, and by scanning whole turf contents for object smoothing (increasing accuracy), and gains by making less checks per target to smooth, through the same bitflag_lists.

    Memory-wise there should be a small improvement, given that on the old system we had 63512 canSmoothWith lists (a few typelists, most unique), and on this new system canSmoothWith + smoothing_groups are both bitflag_lists from the same pool, totaling 46 in number.

Could be tested a bit to see if I missed any icons not properly smoothing.
2020-08-13 14:03:49 +12:00
Kyle Spier-Swenson
8df93ba39e [Ready] CDN browser assets! (#52681)
Rewrites the asset_cache system to handle sending assets to a CDN via a webroot.

see https://github.com/MrStonedOne/tgstation/blob/asset-cdn/code/modules/asset_cache/readme.md

Fixed a lot of bugs with assets, removed some dead code.

Changes:
    Moved asset cache code to transport datums, the currently loaded one is located at SSassets.transport, asset cache calls made before the config is loaded use the simple browse_rsc transport.
    Added subsystem call for when the config loads or reloads.
    Added a webroot CDN asset transport. assets are saved to a file in a format based on the file's hash (currently md5).
    Assets that don't use get_asset_url or get_url_mappings (such as browser assets referred to by static html files like changelog.html or static css files) can be saved to browse_rsc even when in cdn asset mode by setting legacy to TRUE on the datum returned by register_assets
    Added a system for saving assets on a cdn in a hash based namespace (folder), assets within the same namespace will always be able to refer to each other by relative names. (used to allow cdn'ing font awesome without having to make something that regenerates it's css files.).
    The simple/namespaced asset cache datum helper will handle generating a namespace composed of the combined md5 of everything in the same datum, as well as registering them properly.
    Moved external resource from a snowflake loaded file to a config entry, added it to resources.txt
    To ensure the system breaks in local testing in any situation that wouldn't work in cdn mode, the simple transport will mutate the filenames of non-legacy and non-namespaced assets and return this with get_asset_url.
    Simple transport's passive send of all roundstart assets to all clients is now a config that defaults to off. this is to break race conditions during local testings from devs accidentally relying on this instead of using send() properly.

cl
refactor: Interface assets (js/css/images) can now be managed using an external webserver instead of byond's one at a time file transfer queue.
admin: Adds admin verb toggle-cdn that allows admins to disable the external webserver asset transport and revert to the old system. Useful if the webserver backing this goes down (thanks cloudflare).
config: New config file, resources.txt, (must be loaded by an $include statement from the main config)
server: The external_rsc_urls.txt config has been moved to the main config system.
/cl
Porting notes:

Interface webpages must refer to their assets (css/js/image/etc) by a generated url, or the asset must register itself as a legacy asset. The system is designed to break in localtest (on simple/legacy mode) in most situations that would break in cdn mode.

Requires latest tgui.

The webserver must set the proper CORS headers for font files or font awesome (and other fonts) won't load.

/tg/'s webserver config: https://gist.github.com/MrStonedOne/523388b2f161af832292d98a8aad0eae
2020-08-12 13:51:43 +12:00
Timberpoes
d2fa99ff76 Telekinesis works on interacting with items. (#52834)
Rolls TK checks into baseline mob can_interact_with code.

TK check code unashamedly stolen from /mob/living/carbon/human/shared_living_ui_distance

This change touches every single can_interact interaction involving a mob and an atom, except /obj/machine which overrides can_interact without calling the parent and thus is unaffected by this change.

It enables any functionality that would require a can_interact() check to return TRUE. It effectively works alongside the adjacency check and comes into play if the adjacency check would fail.
2020-08-11 15:51:33 -03:00
Jared-Fogle
3cf450d564 Give mood buff for defibbing someone (#52798) 2020-08-11 11:55:46 -03:00
Timberpoes
215f036bb9 TRAIT_NODEATH blocks succumbing (#52836) 2020-08-11 11:13:17 -03:00
zxaber
94c4367ede Support for expansion-class modPC hardware (#52644)
* Support for expansion-class modPC hardware

* end of the line

* As requested

Did anyone know that the tablet vendor was attaching the wrong ModPC printer? I bet no one knew that.

* update
2020-08-11 13:40:05 +03:00
Rohesie
8f917ff1d9 immobilized (#52578)
Adds an immobilized trait.
    Adds procs for several variable changes so we can respond to their events.
    Adds some signals for said variables changing.

Need to turn the variation in number of usable legs and arms (get_num_legs() and get_num_arms()) into events we can respond to, but they are pretty annoying to do so. Probably for a different PR.
2020-08-11 14:44:01 +12:00
uomo
c3bae86da9 Fixing icon state. (#52829) 2020-08-10 21:32:03 -03:00
uomo
52a090af65 Consistency for station pets. (#52717)
* Station pets!

* Makes Lia and Sgt Araneus actual subtypes.

* Fixes some vars.

* Turns on AI for Cayenne and Lia, makes Lia neutral faction.

* Gives Lamarr a description.

* Pettable status and emotes for HoS and syndicate pet..

* Tom the mouse consistency.

* Comment correction.
2020-08-10 17:46:03 -03:00
Timberpoes
26afd77419 Species code can go fellate itself (#52774)
Fixes #51787
Fixes #44981

Species code is the fucking worst.

Lizard tails and spikes are broken outside of admin intervention and neither work nor apply when spawning into the game from the main menu.

Functionality was broken in #49062
Functionality was further broken in #49771

This code makes my soul hurt. I don't have the time or patience to refactor it. This should work around all the functionality broken in the above two PRs until such a time as someone fixes this mess.

If anyone does that, may God have mercy on their soul, for this code has none.
2020-08-10 17:09:11 -03:00
ShizCalev
a611971abe Fixes floorbots potentially ending up with negative tiles in their inventory. (#52772) 2020-08-10 17:03:43 -03:00
Jared-Fogle
82125e06eb CPR will now automatically repeat, but you can no longer do it multiple times at once (#52521)
* CPR will now automatically repeat

* Fix being able to do multiple CPRs at once, styling

* Make changes as per review

* Refactor into loop

* Change while TRUE to do while

* Change conditional

* Explicitly set 3 SECONDS
2020-08-10 16:34:01 -03:00
TiviPlus
b4fe4f717b Refactors area stuff (#52751)
-bitfielded a bunch of bools on /area, I left some untouched cus they get called a lot
-Unused vars
-Fixed a var pretending to be a fake bool
-Probably more
2020-08-10 16:31:59 -03:00
Ryll Ryll
b7ae6fc64d Refactors Temporal Scarring, changes how it works, removes longtimer quirk (#52688)
* changes temporal scarring

* hhh why is there no ckey

* note

* oops

* fixed
2020-08-10 16:29:27 -03:00
tralezab
63382211d8 Mafia Lobby Reworks, Panel Redesign, Abstaining, and More
Co-authored-by: Aleksej Komarov <stylemistake@gmail.com>
2020-08-08 23:36:37 +03:00
Timberpoes
c3f23edfc0 Re-enables cyborg cameras through camera consoles and AI eye vision. (#52767)
* Better camera logic

* AI eye cameras can see through borgo cams

* Switch that to being able to see through any silicon's camera

* Switch that to being able to see through any silicon's camera

* Disable borgo camera at high damage

* Rohesie-proof some code
2020-08-08 16:52:00 +02:00
uomo
358e549229 Petting more animals now causes floating hearts and a moodlet, borgs can now pet animals. (#52594)
* Petting.

* Oops.

* Update code/modules/mob/living/simple_animal/friendly/penguin.dm

Co-authored-by: Fikou <piotrbryla@onet.pl>

* Working on underlying redo.

* More.

* Fixing to work with new emote system.

* Move proc and defines to living instead of mob.

* ...Moves it to simple_animal instead.

* Revert cat crate fix (other PR handling), fixes emote thing.

* Appveyor did not care for that.

* Comment typo.

* Very descriptive var name.

* Borgs can now commit pet.

* sweeps up missing manual_emotes, adds a hop to link for ghosts, and moves the name preface to ghost only

* More descriptive vars and proc name.

* Better descriptive vars.

* Making the borg code slightly nicer.

Co-authored-by: Fikou <piotrbryla@onet.pl>
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
2020-08-07 20:46:49 -04:00
Timberpoes
19c3bbde31 Cleanup up all instances of using var/ definitions in proc parameters. (#52728)
* var/list cleanup

* The rest of the owl

* plushvar bad

* Can't follow my own advice.
2020-08-07 12:23:42 -03:00
TiviPlus
8d72c64910 Lazylists some /mob and /living stuff (#52750)
* lazy

* Apply suggestions from code review

Co-authored-by: Rohesie <rohesie@gmail.com>

Co-authored-by: TiviPlus <TiviPlus>
Co-authored-by: Rohesie <rohesie@gmail.com>
2020-08-07 12:09:16 -03:00
skoglol
4b7eeef8e3 Merge pull request #52725 from ShizCalev/pai-fixes
Pai cable fix, adds icon for when new personalities show up
2020-08-07 08:39:10 +02:00
skoglol
9ce3040f81 Merge pull request #52727 from MrMelbert/touchyfeely
Allows blind people to touch things to examine them
2020-08-07 08:35:23 +02:00
tralezab
c26a134945 Ghost Pool Protection Admin Button (#52683)
* Ghost Pool Protection

* okay

* Update tgui.bundle.js

* just a bit of feedback

* temporarily

Co-authored-by: Emmanuel S. <emmanuelssr@gmail.com>

* Update GhostPoolProtection.js

* Update tgui.bundle.js

* my devserver broke

* okay done for real

* conflict resolution bundle

* Rohesies dope review

Co-authored-by: Rohesie <rohesie@gmail.com>

Co-authored-by: Emmanuel S. <emmanuelssr@gmail.com>
Co-authored-by: Rohesie <rohesie@gmail.com>
2020-08-06 18:00:55 -03:00
ShizCalev
b4121e4746 Sharpness fixes (#52720)
* Sharpness fixes

* fix
2020-08-06 15:05:27 -03:00
Fikou
310024066d repaths the demons (#52716)
* repaths the demons

* tweaks

* sprite tweak to imp

* adresses review

* Update code/modules/antagonists/slaughter/slaughter.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update _maps/RandomZLevels/Academy.dmm

Co-authored-by: Rohesie <rohesie@gmail.com>

Co-authored-by: Rohesie <rohesie@gmail.com>
2020-08-06 12:49:25 -03:00
MrMelbert
f14abf747b no more help 2020-08-05 21:06:12 -05:00
Jared-Fogle
7df16c595e 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
2020-08-05 16:36:00 -03:00
Timberpoes
8fc671f942 Implements job skillchip framework as per hackmd.io design document (#52630)
* Shift wire revealing logic to dedicated proc

* Bit of code modification. Framework for roundstart job skillchips.

* Implement roboticist skillchip trait functionality.

* Feex moth feet messup

* Add skill chips to robodrobe inventory

* Code refactor. Add missing skill_stations to Pubby and Delta.

* Implement special flags, changelings inherit skillchip skills

* Additional code refactor. Traitor chameleon skillchip framework.

* Implement traitor skillchip, fix up more code, move job chips to outfit datums

* Modify autosurgeon, create skillchip variant, add to uplink

* Implement chip cooldowns. Add new skillchip for station engineers. Cleanup some code. Add job chips to lockers.

* Feex

* Feex

* Code review implementation

* More feexes, improved chameleon chip code and more.

* Code review and minor refactor

* Additional review fixes, rebuild tgui

* Minor logic fixes

* Final Rohesie review

* Robust code changes, improved slot/complexity system.

* Rebuild tgui

* Code review

* Brain regeneration failsafe

* Lazylist cut fix
2020-08-05 21:21:29 +02:00
Timberpoes
50f738ab2c Add a space to stop my eternal triggering (#52697) 2020-08-04 23:50:54 -04:00
MrMelbert
3f6e6ef5b4 Braille 2020-08-04 15:01:09 -05:00
ShizCalev
9972cc5533 Fixes doorjack cable 2020-08-04 15:42:55 -04:00
Rohesie
32ae206794 Fixes seeing audible emotes on runechat while deaf (#52584)
* deaf folk

* no blind
2020-08-04 10:11:10 +02:00
Rohesie
6ff08e1c69 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.
2020-08-04 13:59:48 +12:00
ShizCalev
cb694e8095 Fixes carbon wash runtime (#52643)
* Fixes carbon wash runtime

* Update code/modules/mob/living/carbon/carbon.dm

Co-authored-by: spookydonut <github@spooksoftware.com>

Co-authored-by: spookydonut <github@spooksoftware.com>
2020-08-04 01:32:00 +08:00
LemonInTheDark
3558dc1f1b Adds a coder override emote so manual custom emotes work properly (#52602)
* Adds a coder override emote to skip dumb shit with me

* I know this sucks, I can't comprehend how to do this cleanly without a full rewrite

* cleaner now
2020-08-03 05:05:07 -03:00
ShizCalev
2eb12fd169 Fixes pets breeding with their own children. (#52669)
* Fixes pets breeding with their own children.

* cached var
2020-08-03 03:46:17 -03:00
Arkatos1
a673bf8fbe Drone radial menus (#52618) 2020-08-02 23:36:11 +08:00
ShizCalev
47e93df584 Cleans up paicard and aicard code (#52575)
* Cleans up paicard and aicard code

* fix

* more fixes
2020-08-01 06:44:21 -03:00
Jared-Fogle
f23dcd2067 Fix pulsing the power wire shocking you repeatedly unless you close tgui (#52541)
* Fixes #52538

* Allow those with insulated gloves to mess with airlocks still

* Fix not being able to interact with insulos

* Fix style qualms

* Add shock immune to should_electrocute
2020-07-30 23:15:12 -03:00
EdgeLordExe
ed5745ae44 [READY] HERETICS balancing: makes raw prophets more useful (#52028)
* e

* makes raw prophets more useful

* e

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>

* Update code/modules/antagonists/eldritch_cult/eldritch_magic.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/antagonists/eldritch_cult/eldritch_magic.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/antagonists/eldritch_cult/eldritch_magic.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/antagonists/eldritch_cult/eldritch_magic.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* E

* Update code/modules/antagonists/eldritch_cult/eldritch_magic.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* E

* Update code/modules/antagonists/eldritch_cult/eldritch_magic.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* E

* Update code/modules/antagonists/eldritch_cult/eldritch_magic.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Update code/modules/mob/living/simple_animal/eldritch_demons.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

* Apply suggestions from code review

Co-authored-by: Rohesie <rohesie@gmail.com>

* E

Co-authored-by: ATH1909 <42606352+ATH1909@users.noreply.github.com>
Co-authored-by: Rohesie <rohesie@gmail.com>
2020-07-30 14:52:00 -03:00
Rohesie
ac64362c11 Admins can respawn (#52567)
* respawn

* changes

* spawn

* R_ADMIN
2020-07-30 02:25:02 -04:00
ShizCalev
3eeef6c272 Cleans up some unused procs and makes is_blocked_turf a turf proc. (#52482)
* Cleans up some unused procs and makes is_blocked_turf a turf proc.

* Update code/game/turfs/turf.dm

Co-authored-by: Rohesie <rohesie@gmail.com>

Co-authored-by: Rohesie <rohesie@gmail.com>
2020-07-30 02:20:35 -03:00
Fikou
14725daf58 repaths neurotoxin + embedding changes in bullets + adds effects when you shoot energy weapons (#52543)
* how

* Update alien_powers.dm

* adds impact effects, makes thinks that shouldnt embed not embed

* rogue pixel moment
2020-07-30 01:33:51 -03:00
Ryll Ryll
dfcd304dcc Dismemberment wound tweaks, zombies are easy to wound/dismember, tweaks to head vulnerability (#52534)
* adds wound armor to helmets + such, nerfs standard head resist

* dismember + wound species balance, retitle traits
2020-07-30 01:18:57 -03:00
Daniel Hultgren
0741b1977f Cleanable cleanup (#52477)
* Don't initialize the atom_colours list on atoms until it's actually needed

* Moved bloody_hands var to mob/living/carbon/human instead

* Added COMSIG_COMPONENT_CLEAN_RADIATION signal to reduce moms spaghetti

The shower and suit storage unit now calls this signal instead of either doing it manually or doing it via the washed proc

* Cleaned up carbon washing, renamed washed to wash

* The wash proc now doesn't take the washer as first arg because that wasn't used anywhere
* The wash strength is no longer optional
* Carbons now overrides the wash proc instead of using the signal
* Properly check for obscuredness before washing any equipped items
* Properly wash all items and bloody hands etc
* Added clean_lips proc for humans for cleaning any lipstick

* Cleaned up washing. Washy stuff now calls wash instead of calling the clean signal directly

* Renamed is_cleanable to ismopable, gives this category a more fitting purpose. Many things beyond floor decals are cleanable. It is now also determined using the atom layer instead to make it more generic.
* Properly utilize the is_cleanable define
* Added wash override for turfs where they also wash any mopables on the same tile
* Space cleaner and cleaning element etc now simply washes the mob instead of doing its own manual cleaning on ~some~ equipped items

* Non-component washables now simply override wash instead of registering for the clean signal

* Fixed some left over clean signal registers not returning true

* Added clean_strength var to space cleaner

* Moved human wash proc next to the other washing procs

* Also wash glasses and mask if not obscured when washing face

* Fixed attempting to "scoop up" cleanable decals using a rag

* Fixed plasmaman spacehelm icon not updating when washed

Also removed a duplicated worn_overlays proc

* Fixed head icon not updating when washing lipstick

* Moved radioactive clean signal register to where it should be

* Added atom radiate VV verb for debugging

* Redesigned the CLEAN constants into a more sensible flags setup

This makes it more dynamic, cleaning apparatuses can clean more specific than just a cleaning strength.

* CLEAN_TYPE_* flags indicate a specific cleanable, such as blood, fingerprints or disease
* CLEAN_* consts consist of a combination of cleaning types to make cleaning apparatuses have a consistent behaviour on what they clean

* Fixed broken rad removal logic in showers

* Apply suggestions from code review

Co-authored-by: Rohesie <rohesie@gmail.com>

* Removed unneccesary bool from sink code

* Fixed wrongly named variable in turf wash

* Renamed bloody_hands to blood_in_hands

Co-authored-by: Rohesie <rohesie@gmail.com>
2020-07-29 09:31:38 -03:00
Rohesie
cb9f81e43c Renames smooth var to smoothing_flags (#52427)
* smooth_flags

* SMOOTH_FALSE

* smooth_flags
2020-07-29 10:19:23 +02:00