Commit Graph

240 Commits

Author SHA1 Message Date
SkyratBot
b8d9874c27 [MIRROR] Converts all A && A.B into A?.B (#1292)
* 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>
2020-10-13 23:19:25 +02:00
SkyratBot
970a2b03d6 [MIRROR] Mobility refactor: no more update_mobility() (#1233)
* Mobility refactor: no more update_mobility()

* Update robot.dm

Fixes robots.

* megadumb

* Update robot.dm

* weh

* Update gunpoint_datum.dm

Co-authored-by: Rohesie <rohesie@gmail.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
Co-authored-by: Azarak <azarak10@gmail.com>
2020-10-10 02:31:35 +02:00
SkyratBot
1e705faa19 [MIRROR] Process procs now properly utilize deltatime when implementing rates, timers and probabilities (#709)
* Process procs now properly utilize deltatime when implementing rates, timers and probabilities (#52981)

* Process procs now properly use deltatime when implementing rates, timers and probabilities

* Review fixes

* Geiger counters cleanup

Made hardsuit geiger code more similar to geiger counter code
Geiger counters are more responsive now

* Moved SS*_DT defines to subsystems.dm

* Rebase fix

* Redefined the SS*_DT defines to use the subsystem wait vars

* Implemented suggested changes by @AnturK

* Commented /datum/proc/process about the deltatime stuff

* Send delta_time as a process parameter instead of the defines

Also DTfied acid_processing

* Dtfied new acid component

* Process procs now properly utilize deltatime when implementing rates, timers and probabilities

Co-authored-by: Donkie <daniel.cf.hultgren@gmail.com>
2020-09-09 08:19:23 +02:00
SkyratBot
cd0d700a85 [MIRROR] Mecha refactor 2020 (#579)
* Mecha refactor 2020

* Update effects.dm

Co-authored-by: TiviPlus <57223640+TiviPlus@users.noreply.github.com>
Co-authored-by: Azarak <azarak10@gmail.com>
2020-09-02 02:16:51 +02:00
SkyratBot
ec09510459 Bools and returns super-pr (#53221) (#565)
Replaces like 70-80% of 0 and such, as a side effect cleaned up a bunch of returns
Edit: Most left out ones are in mecha which should be done in mecha refactor already
Oh my look how clean it is

Co-authored-by: TiviPlus <TiviPlus>
Co-authored-by: Couls <coul422@gmail.com>

Co-authored-by: TiviPlus <57223640+TiviPlus@users.noreply.github.com>
Co-authored-by: Couls <coul422@gmail.com>
2020-08-30 05:12:59 +02:00
SkyratBot
3bd294f26f [MIRROR] Defines damage flags. (Hopefully without 50+ commits) (#491)
* Defines damage flags. (#53158)

* Defines damage flags. (Hopefully without 50+ commits)

Co-authored-by: TemporalOroboros <TemporalOroboros@gmail.com>
2020-08-24 22:52:31 +02:00
SkyratBot
72c69368b6 [MIRROR] Opacity refactor (#405)
* Opacity refactor (#52881)

    Moves all opacity var manipulation to a proc which sends a signal.
    light_blocker element for movable opaque atoms made, which tracks its movement and updates the affected turfs for proper lighting updates.
    has_opaque_atom boolean replaced by the opacity_sources lazylist to keep track of the sources, and a directional_opacity which serves a similar function but also allows for future expansion with on-border opaque objects (not yet implemented).
    Some opacity-related sight procs optimized as a result of this.
    Some variables moved to the object's definition.
    A define or two added into the mix for clarity.
    Some code cleaning, like turning booleans into their defines.
    One file renamed for clarity.

Changelog

cl
balance: Mechs no longer block sight. It's a non-trivial cost for the lighting system with little to no gain.
/cl

* Opacity refactor

Co-authored-by: Rohesie <rohesie@gmail.com>
2020-08-19 04:48:14 +02:00
SkyratBot
49f7becb88 [MIRROR] Personalized combat messages part 2 (#334)
* Personalized combat messages part 2 (#52890)

Adds more "personalized" combat messages for all participants in a fight: the attacker, the victim and the spectators

* Personalized combat messages part 2

* Update misc.dm

Co-authored-by: kingofkosmos <riki.sundberg@gmail.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2020-08-14 23:29:15 +02:00
Ryll Ryll
a97c51b30b [READY] Wounds part 2: Piercing wounds, dismemberment changes, housekeeping (#51786)
* pierce the heavens

* starts doing projs

* continue pierce

* before armor

* before sharpness redefine

* rename sharp defines, before further implementation

* finishing undoing atk_type back to sharpness

* neatens up sharpness defines, FALSE -> SHARP_NONE

* more piercing, removes brute damage bleed, bubblegum no longer wound

* starts letting embeds get in on the fun

* half with embed

* work on dismembering

* continued embed work

* more moving bandaging to limbs

* more dismemberment work

* removing embed pierce stuff

* tweaking bullets

* more docs and work on dismemberment

* spans, piercing, guns

* dismemberment and scar fixes

* bee changes

* bullets embedding

* more bullet and dismember work

* dismemberment, surgery, piercing, formaldehyde,

* pleases travis

* pierce smite

* nicer on blood

* Auto stash before rebase of "tgstation/master"

* more neatening

* wounds only consider up to 35 damage, wounds on l6 and 762

* updates hulk

* balance

* defines

* lower slug to 50 brute to accommodate wounds

* adds differentiation for having flesh/bones/both in mobs

* moves scar descs to json, renames organic_state

* excises removed healing skill

* fixes logs, inconsistencies, some balance changes

* untab

* slight compress

* a

* kills pointed global list

* dmdoc

* halfway through roh

* finishes roh review

* okay NOW i finished roh's reviews

* roh roh roh your boat

* gently down the stream

* global lists

* list ops, fix scanner for bone gel improvised fix

* travis moment

* sounds added and moved

* pellet clouds can join the fun fully, slight gun balancing for wounds

* doc moment

* unconflicts myself

* update hulk

* Update code/_onclick/item_attack.dm

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

* crying ascii face

* final rohview

* oops

* final final

Co-authored-by: Rohesie <rohesie@gmail.com>
2020-07-23 22:20:09 -04:00
anconfuzedrock
6e53a2f25c nerfs katana and suit please work (#51719) 2020-06-29 13:28:05 -04:00
ShizCalev
debba87ec2 fixes "dante torn the changeling with the sword" (#51688) 2020-06-18 15:48:12 -03:00
ShizCalev
268edde07c Fixes clothing repair not working, adds better pronoun handling (#51689)
* Fixes clothing repair not working

* Moth fixed

* message fix

* more grammar stuff

* better text handling for multiple articles
2020-06-18 15:46:53 -03:00
Ryll Ryll
e461b24ee3 Removes turf embedding (#51571)
* Auto stash before rebase of "tgstation/master"

* updates for wounds

* more cleaning up

* reexamines examines
2020-06-16 13:39:47 +02:00
ShizCalev
1ff3945b30 Fixes more belt missing texture crap (#51597)
* Fixes more belt missing texture crap

* #51010 progress

* tank fixes

* typo

* Removed dead/duplicated code

* cleanup

* don't need the - meme anymore with build_worn_icon

* icon fix

* commentary

* yelling at future coders

* more condensedd
2020-06-13 14:16:52 -04:00
nemvar
6ef421be42 Renames a few variables. Also reorders icon fallback order again. (#51060)
* Renames a few variables. Also reorders fallback order again.
Renames item_state to inhand_icon_state
Renames mob_overlay_icon to worn_icon
Renames mob_overlay_state to worn_icon_state
worn_icon_state/mob_overlay_state now never gets used for inhands.

* Fixes some comments

* Fixes map issue

* Restart lints

* Properly resolves conflicts
2020-05-25 06:47:19 +02:00
Bobbahbrown
2d03a01fe0 Ninja Suit Initialization Refactor + Cleanup (#50563)
* ninja cleanup

* documentation

* missed these
2020-04-24 00:42:02 +08:00
Cruix
e129b731ed Bug fixes (#50334)
* Fixed pointing runtime

* Fixed runtime allowing abductors to speak out loud

* Fixed being able to get two monkeys from each monkey cube

* Fixed being able to use camera consoles with the mech teleporter to teleport further than intended

* Fixed ninja suit never copying data from tech disk

* Fixed being able to tackle things not on a turf

* Rearranged ifs
2020-04-04 12:34:08 -07:00
Ryll Ryll
5c174800fb Grenades and projectiles can have shrapnel and embed, all carbons can suffer embeds, some bullets can ricochet, sizable refactor of embedding (#49634)
About The Pull Request

It annoyed me that we have a perfectly good frag grenade item, and a perfectly good shrapnel component, but no crossover episode between the two. This remedies that, and does a lot, lot more.

dreamseeker_2020-03-30_05-01-13.png

dreamseeker_2020-03-30_05-01-26.png

Big points:

    Adds new component: pellet_cloud, which can be used by ammo casings, guns, and landmines to spray shrapnel and display aggregate hit messages ("You're hit by 6 buckshot pellets!" vs "You're hit by the buckshot pellet in the X" x6). All gun ammo that shoot multiple pellets now use this component on firing.
    Adds stingbangs, premium less-lethal grenades that shoot off lots of stinger pellets, to cargo. Frag grenades are also reworked to have smaller booms, but shoot off lots of shrapnel shards. You can jump on top of these grenades to absorb a portion of the shrapnel to save those around you! There's an achievement for dying this way, called "Look Out, Sir!"
    Projectiles can now embed items/shrapnel. Adds .38 DumDum ammo to cargo that does less damage and has negative armor pen, but can embed in people. This is the only ammo that currently embeds.
    Bullets can now ricochet off walls, structures, and machinery (harder surfaces are more likely to ricochet). Only standard .38 and Match Grade .38/.357/L6 ammo can ricochet, with Match Grade being much better at ricocheting. You can buy Match Grade .38 from cargo and Match Grade L6 ammo from the nuke uplink, while Match .357 is admin only.
    Armor now protects you from harmful embeds, taking the better of the bullet/bomb armor on the affected limb. Armor penetration can modify this of course, and many blunt embeds like stingbangs and DumDum bullets are significantly worse if you have even 1 armor.

Other misc fixes/changes

    Refactored the embed element a bunch and fixed it creating new elements for every instance rather than expected bespoke behavior. There are new /obj/item helpers for modifying and adding embedding.
    Fixes #49989: Spears can no longer embed in turfs cause their sprite is annoying to me, it's generally harder for most things to embed in turfs
    Fixes #49741: New carbon helpers for removing embedded objects
    Fixes #46416: Handles embedded objects getting qdel'd or moved while embedded
    Renamed the old shrapnel component for RPG loot to MIRV to avoid confusion
    Repathed frag grenades from under minibombs to under base grenades, and added explosion vars to base grenades

Why It's Good For The Game

Fixes a bunch of janky design with embeds, adds lots of new avenues for projectile and grenade variety, ricochets and collateral damage are fun!
Changelog

🆑 Ryll/Shaps
add: Adds stingbangs to cargo (and one in the sec vendor premium), premium less-lethal grenades that shoot off a giant swarm of stingball pellets to help incapacitate swarms of people in tight quarters. You can jump on top of a live one to be a hero and absorb a bunch of shrapnel, same with frag grenades. There's even an achievement for dying to a grenade you jumped on!
add: Projectiles can now embed in people! Or at least grenade shrapnel and the new .38 DumDum ammo, now available in cargo, can. DumDum rounds excel against unarmored targets, but are pricey and do poorly against armored targets.
add: Bullets can now ricochet! Or at least, standard .38 and the new .38/L6 Match Grade ammo can. Match Grade ammo is finely tuned to ricochet easier and seek targets off bounces better, and can be purchased from cargo (for the .38) or nuke ops uplink (for the L6), but standard .38 ammo has a chance to ricochet as well.
tweak: Frag grenades now have smaller explosions but shoot off a bunch of devastating shrapnel, excellent for soft targets!
tweak: Shotguns and other multi-pellet guns now print aggregate messages, so you'll get one "You've been hit by 6 buckshot pellets!" rather than 6 "You've been hit by the buckshot pellet in the X!" messages. Bye bye lag!
balance: Armor can now protect against embedding weapons, taking the best of either the bullet or bomb armor for the limb in question away from the embed chance. Some weapons are better at piercing armor than others!
/🆑
2020-04-03 16:58:38 +13:00
kingofkosmos
79c5a80ca0 Visible_messages verb time tenses changed to present. 2020-03-16 14:55:25 +02:00
spookydonut
beca456c0f Add new lints (#49751)
Co-authored-by: Jordan Brown <Cyberboss@users.noreply.github.com>
2020-03-09 22:13:48 -07:00
spookydonut
1a9ddbee5f Merge pull request #48959 from Ryll-Ryll/embeddead
Refactors embedding, adds harmless embeds, sticky tape, admin buttons to make everything embeddable
2020-02-24 15:43:36 +08:00
nightred
2bfe630f58 Fix for space ninjas not living in space (#49460)
* spaceninja cell size reset, removed regulator, hard set temp controls

* max charge removed
2020-02-22 12:27:53 +01:00
spookydonut
fa9c266863 Merge pull request #49331 from tralezab/patch-80
fixes terrible alert by making it announce area instead of turf (and a bad span thing)
2020-02-20 19:37:28 +08:00
tralezab
09572ab93c review 2020-02-19 18:27:38 -08:00
nightred
dbc0c73081 ninja cell forgot maxsize 2020-02-18 18:10:16 -06:00
Ryll-Ryll
1fae3d4c22 new beginnings 2020-02-18 02:06:35 -05:00
nightred
6c7f97f9e7 missed the action for the suit ninja suit 2020-02-17 17:27:23 -06:00
nightred
395bebcdcc [READY] Space Suits use cells and warm the wearer (#49028)
About The Pull Request

This makes space suits use a cell and warm the wearer, This was handled by the handle_environment proc in the past with an override to make the suits work. This corrects this issue, and removes the override.

All space suits will have a cell installed at round start, this cell will last 15 min on average usage.

The cell cover can be toggled by alt+clicking (press the button), or using a crowbar (just pry it open) on the suit.
With the cover open you can remove the cell by using the suit in hand, or ctrl+clicking the suit.
As well with the cover open you can use a screwdriver to set the thermal regulator's temperature. The normal range is 20 c to 45 c, do not use an emag on the suit to increase the temperature range.

Examining the suit will report the temperature setting and the cells charge, if the cover is open you will also be able to see the type of cell that is in the suit.

Suit storage units will now charge the cells in suits, they will also require power to operate properly now.

Why It's Good For The Game

    Space suits should be managing the wearers temp in space not using some override.
    Lizards now have a portable heater in the form of any space suit.
    Now that suits need a cell it is not as easy to spend all session in a space suit.
    New interactions with hardsuits and emp's give nice combat buff to an underused item.
    Nuke ops can raid xeno for some nice yellow cells, or science for a big old bluespace cell.
2020-02-15 11:32:54 +13:00
tralezab
ca8647607e fix 2 2020-02-13 03:02:21 -08:00
tralezab
e1b5781c6f gg 2020-02-13 03:00:31 -08:00
Firecage
94c5676cca Updates energy resistance armour values on remaining armours and helmets. (#48067)
* Updates energy resistence on remaining armours.

* Changes Hardhat back to 10 energy armour value.
2019-12-07 00:08:54 +01:00
Emmett Gaines
5481515dff Removes the non bitflag slot defines (#47742)
Removes the non bitflag slot defines
2019-11-17 17:52:11 -08:00
spookydonut
2591ce17a6 Travis EOF newline detection v3 (#47539)
* scream

* aaa

* aaa

* new one
2019-11-04 19:16:50 -08:00
skoglol
938e66f62c Adds sorting to most input() lists (#47117)
* Adds sorting to most input() lists.

* Sorted some global lists, added more input sorting

* Should now use correct sort everywhere.

* compiles

* Last fixes.
2019-10-22 04:28:42 -07:00
kingofkosmos
259626a8b4 Removes excess spaces in messages. 2019-10-13 14:36:43 +03:00
kingofkosmos
280d416d4f Adds missing spans, missing periods and missing span endings. Also changes spans to suit the situation better. 2019-10-12 19:34:11 +03:00
William Wallace
70acd2bc48 remove duplicate var definition from /obj/item/energy_katana 2019-10-09 00:11:55 +01:00
oranges
ba157add71 Merge pull request #46502 from nemvar/patch-108
Fixes infinite loop
2019-09-15 20:53:37 +12:00
kingofkosmos
8358169b8e New 'hear' span class (#46369)
* Reverts italics-span back to no color.

* Cleans up many extra spaces and indents.

* Adds 'hear' span class.

* Replaces all 'italics' used in heard messages with 'hear'.
2019-09-14 23:56:34 -07:00
nemvar
2a8e76ffd5 Fixes infinite loop 2019-09-14 16:24:04 +02:00
Rob Bailey
2029163d33 playsound vary boolean define conversion (#46254)
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
2019-08-30 18:45:20 +12:00
kingofkosmos
df1fecc58c Adds notice-span to visible_messages with no spans (#46044)
About The Pull Request

Adds 'notice' span class to all visible_messages which had no span class, making all those black messages blue.
Why It's Good For The Game

This should help differentiate action-messages from talking-messages in the chat. More actions will be blue, thus black talking-messages should pop out more.
2019-08-26 20:50:00 +12:00
Rob Bailey
26b04ede42 Obliterates item_color: new washing machine functionality edition (#45961)
About The Pull Request

Completely removes item_color and the clusterfuck of bad programming it caused.

In places where item_color was used for entirely unique purposes it was split off and renamed to a new var on that typepath only, or refactored so it wasn't needed

In places where item_color was used as a dye color, it was converted to the new dye_color var

In places where item_color was used as the worn overlay it was removed and instead now icon_state is always used as the clothing overlay.

A new mob_overlay_icon var was added for manually setting where the mob overlay icon path is for specific items.

Moved some mob overlay files relating to clothing to their own directory as well for organization purposes.

Totally refactors washing machines, instead of the horrible abortion that was iterating through the typepath it now uses a registry of dye results.

Some bonus functionality to come out of this:
the washing machine now supports arbitrary dye colors.
Why It's Good For The Game

It's been 4 years since the "this should be deprecated soonish" comment was added, and this var is a shitpile of confusion if you just trace the usage of it.
Changelog

cl
add: Washing machines now support arbitrary dye color
add: Washing machines now dye nearly every item.
refactor: lots of backend changes to clothing overlays, report any issues
/cl
2019-08-26 20:38:11 +12:00
Denton
d98df6e063 Refactors plastic explosives
y
2019-08-02 22:31:05 +02:00
Akrilla
260f4c5680 Species important for life (#45179)
* important to live items

* outfit

* autodoc

* comment change

* return
2019-07-15 13:37:48 -04:00
ShizCalev
6e44bd3a93 Merge pull request #44796 from kingofkosmos/addswarningspans
Adds warning-spans
2019-07-02 00:47:43 -04:00
vuonojenmustaturska
a61b86a052 fixes2 (#44736) 2019-06-27 14:13:19 +02:00
kingofkosmos
81a0518474 * warning-spans added to cases of "You do not..." and "You don't..." 2019-06-25 22:05:55 +03:00
kingofkosmos
6bbb64e2cf * more warnings 2019-06-25 21:46:21 +03:00
vuonojenmustaturska
8ddc9677c7 examine-code refactor (#44636)
* 1/4 done? maybe?

* more

* stuff

* incremental stuff

* stuff

* stuff & things

* mostly done but not yet

* stuffing

* stuffing 2: electric boogaloo

* Git Commit and the Kingdom of the Crystal Skull

* make it actually compile

* found more stuff

* fixes

* fix AI laws appearing out of order

* fix windows

* should be the remaining stuff

* this time for real

* i guess it should compile too

* fix sechuds
2019-06-19 22:07:57 +02:00