* Defines calibers (#56476)
Adds defines for all of the ammo calibers
Replaces all current magic strings with defines
Docs what guns use what calibers
Corrects the name of the incendiary .45 ammo casing to indicate that it fires incendiary rounds rather than armor piercing rounds
* Defines calibers
Co-authored-by: TemporalOroboros <TemporalOroboros@gmail.com>
* The day has come gamers, the mosin nerf/rework (#56319)
* THE NERF
* fixes a dumb mistake
* Sanity check and second thoughts
* mosin jamming
* adds the cleaning supplies, sprites, slight changes to dmg and jamming and HNNNG ONE LAST BUG
* adds maint kit to russian surplus, second try at fixing
* everything is fixed now :)
* finishing touches
* Last fix?
* fix
* fix var names
* a new sound and few more fixes
* add /brand_new variant to all ert/special spawned mosins, added a check if bolt is locked
* Bolt_locked is true when bolt is open 😂
* added a clamp just in case
Co-authored-by: Sparkezel <1haslo4@ gmail.com>
* The day has come gamers, the mosin nerf/rework
* Update to use our realism
Co-authored-by: Sparkezel <53384660+Sparkezel@users.noreply.github.com>
Co-authored-by: Sparkezel <1haslo4@ gmail.com>
Co-authored-by: Gandalf2k15 <jzo123@hotmail.com>
* Replacing magic numbers with defines in robot code (#56241)
While scouring robot code for some (hopefully upcoming) fixes, I found a bunch of gross numbers. These numbers are now letters.
* Replacing magic numbers with defines in robot code
Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com>
* [s] fixes damage multiplicative exploit with foam darts (#56250)
## About The Pull Request
fixes a pretty bad exploit with foam darts
## Why It's Good For The Game
- Modify a dart with a pen, giving it 5 damage
- Target someone's mouth (or a monkeyman)
- Fire
- Firing sequence for handle_suicide multiplies damage by 5 on the projectile instance
- Dropped projectile has 25
- Repeat 1 more time for 125 instacrit dart, or another time after that for 600 instakill dart
all discovery credits go to @ necromanceranne, this was brought to my attention
* [s] fixes damage multiplicative exploit with foam darts
Co-authored-by: silicons <2003111+silicons@users.noreply.github.com>
* Infinite Gun Culling: Gun Kit Edition (#56133)
Every prototype firearm in the game now utilizes crafting to construct it, usually sacrificing a standard version of that firearm in order to produce the new one. The guns are made using gun part kits you print from the security protolathe (or buy, in the case of hellfire lasers).
* Infinite Gun Culling: Gun Kit Edition
Co-authored-by: necromanceranne <40847847+necromanceranne@users.noreply.github.com>
* Makes the rest of large guns bulky (sans traitor objectives and a few others) (#56132)
## About The Pull Request
What it says on the tin.
Practically everything but pistols, SMGs, and traitor weapons can no longer be stashed into bags.
I had considered making some large guns that traitors can order (like the blast cannon) also bulky, but concealment is important for some of those things.
However, the bulldog shotgun and sniper rifle have been made bulky, because they're shotguns and sniper rifles!
Traitor objectives are still normal size and can fit in backpacks.
## Why It's Good For The Game
Makes previous changes to weapons and thus balance consistent across our full list of guns. Players can clearly understand what can fit in the bag based on the size of the weapon.
* Makes the rest of large guns bulky (sans traitor objectives and a few others)
* Update special.dm
Co-authored-by: Cartographer-D <63861499+Cartographer-D@users.noreply.github.com>
Co-authored-by: Azarak <azarak10@gmail.com>
* Adds Rocket Backblast (#55681)
This PR adds the backblast element, which when attached to a gun, creates giant plumes of fire when said gun is fired. The PM9 rocket launcher that nuke ops can buy kinda sucks and even a direct hit with the standard rockets loaded isn't enough to guarantee a one-hit crit on a direct hit against an armored opponent, which sucks for how much you pay for it. In that vein, I've also buffed the standard rockets a bit, they now do 50 brute up from 30 on a direct hit, and they create flames on their explosion.
Also makes a tweak to /proc/get_turf_in_angle(), since tile coordinates start at 1,1 instead of 0,0 that proc is now clamped to min 1,1 rather than 0,0
* Adds Rocket Backblast
Co-authored-by: Ryll Ryll <3589655+Ryll-Ryll@users.noreply.github.com>
* [Fuck Shotties] Makes shotguns specialist weaponry. (#55663)
Shotgun slugs can no longer be made in an autolathe.
Buckshot rounds can no longer be made in an autolathe.
Frag12 rounds deal less direct damage, since they fucking explode.
Pulse shot rounds deal less damage.
Increased the cooldown on riot shotguns.
Removed buckshot rounds from all maps.
Combat shotguns start with beanbags.
Why It's Good For The Game
Shotguns have been overpowered for too long. NT is lasers , syndicate is ballistics.
* [Fuck Shotties] Makes shotguns specialist weaponry.
Co-authored-by: EdgeLordExe <42111655+EdgeLordExe@users.noreply.github.com>
* Buffs the Blastcannon (#55573)
* Unhugboxes the blastcannon
- Flips [/obj/item/gun/blastcannon/var/hugboxed] from [TRUE] to [FALSE]
- Makes the blastcannon's maximum range scale with it's other explosive power
- Documents some class level variables for the blastcannon
* Buffs the Blastcannon
Co-authored-by: TemporalOroboros <TemporalOroboros@gmail.com>
* Refactors Beams to use signals: Revived from 2019 edition! BONUS: Medbeams are also refactored to use signals (#55193)
Huge removal of dead vars, bad timers, and other sloppy jitteriness from beams. They go from checking movement to waiting for a signal.
VARIABLE KILL LIST:
sleep_time: signals baby
finished: signals BAYBEEE
target_oldloc: not only not typecasted as a turf or named as a turf, it was unused. when are we going to use this? the beam starts from the origin!
origin_oldloc: bad name, not typecasted. renamed to originturf
static_beam: how are you an unused variable and still get replaced by signals like really
timing_id: signallllss bbbaaaabbyy
recalculating: you get the drill by now signals baby
base_icon: unused, seemingly replaced by visuals I think
* Refactors Beams to use signals: Revived from 2019 edition! BONUS: Medbeams are also refactored to use signals
Co-authored-by: tralezab <40974010+tralezab@users.noreply.github.com>
* Changes what makarovs and APS machine pistols look like suppressed (#55346)
* Changes what makarovs and APS machine pistols look like suppressed
Co-authored-by: Megarop <Largerfaker@gmail.com>
* X-Ray gun is larger not bag friendly (#55410)
The x-Ray gun was a normal sized object, made it bulky to stop printing several and putting them in bags.
Fixes#55321
* X-Ray gun is larger not bag friendly
Co-authored-by: NightRed <nightred@gmail.com>
* Replace direct poi_list manipulation with element (#55416)
Replaces GLOB.poi_list |= src and GLOB.poi_list -= src with an element that handles it directly.
More consistent code, especially when a lot of code couldn't decide how to add/remove (some |=, some -=, some .Remove, etc).
* Replace direct poi_list manipulation with element
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@users.noreply.github.com>
* pass_flags handling refactor + rewrites a part of projectiles for the n-th time (#54924)
Yeah uhh this'll probably need testmerging even after it's done because yeah it's a bit big.
If y'all want me to atomize this into two PRs (pass flags vs projectiles) tell me please. Pass flags would have to go in first though, in that case, as new projectile hit handling will rely on pass_flags_self.
Pass flags:
Pass flags handling now uses an atom variable named pass_flags_self.
If any of these match a pass_flag on a thing trying to pass through, it's allowed through by default.
This makes overriding CanAllowThrough unnecessary for the majority of things. I've however not removed overrides for very.. weird cases, like plastic flaps which uses a prob(60) for letting PASSGLASS things through for god knows why.
LETPASSTHROW is now on pass_flags_self
Projectiles:
Not finalized yet, need to do something to make the system I have in mind have less unneeded overhead + snowflake
Basically, for piercing/phasing/otherwise projectiles that go through things instead of hitting the first dense object, I have them use pass_flags flags for two new variables, projectile_phasing and projectile_piercing. Anything with pass_flags_self in the former gets phased through entirely. Anything in the latter gets hit, and the projectile then goes through. on_hit will also register a piercing hit vs a normal hit (so things like missiles can only explode on a normal hit or otherwise, instead of exploding multiple times. Not needed as missiles qdel(src) right now but it's nice to have for the future).
I still need to decide what to do for hit handling proper, as Bump() is still preferred due to it not being as high-overhead as something like scanning on Moved(). I'm thinking I'll make Moved() only scan for cases where it needs to hit a non-dense object - a prone human the user clicked on, anything special like that. Don't know the exact specifics yet, which is why this is still WIP.
Projectiles now use check_pierce() to determine if it goes through something and hits it, doesn't hit it, or doesn't go through something at all (should delete self after hitting). Will likely make an on_pierce proc to be called post-piercing something so you can have !fun! things like projectiles that go down in damage after piercing something. This will likely deprecate the process_hit proc, or at least make it less awful.
scan_for_hit() is now used to attempt to hit something and will return whether the projectile got deleted or not. It will delete the projectile if the projectile does hit something and fails to pierce through it.
scan_moved_turf() (WIP) will be used for handling moving onto a turf.
permutated has been renamed to impacted. Ricocheting projectiles get it reset, allowing projectiles to pierce and potentially hit something again if it goes back around.
A new unit test has been added checking for projectiles with movement type of PHASING. This is because PHASING completely causes projectiles to break down as projectiles mainly sense collisions through Bump. The small boost in performance from using PHASING instead of having all pass flags active/overriding check_pierce is in my opinion not worth the extra snowflake in scan_moved_turf() I'd have to do to deal with having to check for hits manually rather than Bump()ing things.
Movement types
UNSTOPPABLE renamed to PHASING to better describe what it is, going through and crossing everything but not actually bumping.
Why It's Good For The Game
Better pass flags handling allows for less proc overrides, bitflag checks are far less expensive in general.
Fixes penetrating projectiles like sniper penetrators
This system also allows for better handling of piercing projectiles (see above) without too much snowflake code, as you'd only need to modify on_pierce() if you needed to do special handling like dampening damage per target pierced, and otherwise you could just use the standardized system and just set pass flags to what's needed. If you really need a projectile that pierces almost everything, override check_pierce(), which is still going to be easier than what was done before (even with snowflake handling of UNSTOPPABLE flag process_hit() was extremely ugly, now we don't rely on movement types at all.)
* pass_flags handling refactor + rewrites a part of projectiles for the n-th time
Co-authored-by: silicons <2003111+silicons@users.noreply.github.com>
* Fixing robot upgrades sometimes not being removed from lists. (#54842)
* Fixing robot upgrades not being removed from lists all times.
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
* Changes grenade proc names to be more clear (#55181)
Grenades have, for the longest time, used the proc name preprime() to refer to arming a timed grenade so that it will boom in a few seconds, and prime() to refer to the grenade actually going boom (or releasing foam or anything else grenades do when they go off). This was very confusing, so now these two procs are called arm_grenade() and detonate().
* Changes grenade proc names to be more clear
Co-authored-by: Ryll Ryll <3589655+Ryll-Ryll@users.noreply.github.com>
* Accidental Consumption post-food refactor cleanup (#55152)
Renames a bunch of vars to be more descriptive
Removes old references to snacks
Updates some code slightly
* Accidental Consumption post-food refactor cleanup
Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
* Humans have more complicated body temperatures (#54550)
This changes how carbon/humans stabilize body temperature, and changes how damage and wounds are applied based on temperature.
Humans now have a core body temperature along with body temperature. The core temperature is used for natural stabilization and what viruses like fever and shivers target by raising or lowing the core temperature of the mob.
The standard body temperature still exists and acts exactly the same for most items at this time but is now treated as surface temperature in humans.
Damage from body temperature for humans is now based on the core temperature instead of body temperature now.
Humans will now receive burn wounds when the body (surface) temperature is to high for to long.
This causes you to see alerts for the area temperature before you take damage in most cases improving visibility of dangerous situations.
* Humans have more complicated body temperatures
Co-authored-by: NightRed <nightred@gmail.com>
* Foam darts and other unembeddable bullets will no longer leave ghost shrapnel (#54994)
Projectiles are assigned the ability to try embedding by the presence of a shrapnel_type variable being set on them, whether or not they actually have a set of embedding stats in their embedding var. By default, children of /obj/projectile/bullet have a shrapnel type set to a generic embedded bullet item, including things like foam darts and lollypop projectiles which shouldn't be able to embed (and certainly not embed as a bullet). While they had their embedding vars set to null, they still had their shrapnel_type set to the embedded bullet type, meaning shooting a person with a dart gun or whatever would leave a failed shrapnel item on the ground where they weren't supposed to.
This fixes that by requiring both a defined shrapnel_type AND a defined embedding var for the embedding stats. Any projectiles without both won't be able to try embedding. I also manually put 'shrapnel_type = null' on any bullet subtypes with embedding = null just to be safe and for consistency.
* Foam darts and other unembeddable bullets will no longer leave ghost shrapnel
Co-authored-by: Ryll Ryll <3589655+Ryll-Ryll@users.noreply.github.com>
* The clown PDA now has in-built comedy detection for when something happens to the clown and plays a fitting sound. (#54695)
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@ users.noreply.github.com>
* The clown PDA now has in-built comedy detection for when something happens to the clown and plays a fitting sound.
Co-authored-by: Qustinnus <Floydje123@hotmail.com>
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@ users.noreply.github.com>
* Speargun: Now actually a gun! Again! (#54289)
Turns the speargun from the syndikit bundle into a bolt action rifle instead of a pnuematic cannon.
The spears the rifle fires embeds using the new bullet embedding system by Ryll. The spears do a lot of fucking damage.
The new bundle includes:
The Ballistic Harpoon Gun
The weapon is a single shot rifle that can be loaded with harpoons. The rifle, being bolt action, requires pulling back the bolt, loading the new harpoon, then locking the bolt every time you wish to fire the weapon. This is more busy work than the pnuematic cannon version, but more reliable in functionality without any messy business with throwing.
The harpoons do 60 force, have a high wound chance against unarmored targets and very high embed chance, with a 100% against unarmored targets. They also have considerable armor piercing at 50, letting you nearly entirely shoot through a ballistic vest.
The weapon is essentially a powered-up single shot mosin or a significantly more powerful improvised shotgun filled with slugs.
The Quiver
Now a bag that goes on your belt. It holds up to 40 harpoons for your harpoon gun. This change was done because the harpoons cannot be retrieved, unlike the magspears, which were simply hacky ninja stars and could be pulled out with surgical tools/wirecutters. Previously you had 20 magspears, which because of their retrievable nature lasted a little longer than you would expect.
Sprites
New back sprites for the harpoon gun, ensuring nobody is missing it when you have it. Additionally, the Mosin Nagant now has it's back sprite as a suit storage sprite.
New sprite for the quiver.
* Speargun: Now actually a gun! Again!
Co-authored-by: necromanceranne <40847847+necromanceranne@users.noreply.github.com>
* Non-human mobs can now benefit from held id cards and economy. (#54647)
* Non-human mobs can now benefit from held id cards and economy.
* Moved these getters toward the upper end.
* oui?
...
dump eet.
* .tee pump
...
?iuo
* Non-human mobs can now benefit from held id cards and economy.
Co-authored-by: Rohesie <rohesie@gmail.com>
* 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>
* HoS and Captain Laserguns are now normal sized (#54281)
Co-authored-by: PolishUser <fakemail@ fake.com>
* Lasergun resizing
Co-authored-by: PolishUser <55540334+PolishUser@users.noreply.github.com>
Co-authored-by: PolishUser <fakemail@ fake.com>