Commit Graph

1669 Commits

Author SHA1 Message Date
MrMelbert
e21dc5fec7 Kicks Martial Arts out of the attack chain (yippee), makes it use signals, plus a large clean up of existing martial arts (#81097)
## About The Pull Request

- Kicks Martial Arts out of the attack chain. 
- All Martial Arts attacks are now handled via unarmed attack or grab
signals
- This means all martial arts are now technically on the living level,
allowing any mob that can unarmed attack to martial arts. Sort of. YMMV.

- All martial arts block checking is now handled by the arts themselves,
meaning you can selectively decide for a martial arts strike to not be
blocked. Maybe good for the future.

- A comprehensive cleanup of all existing martial arts. Improving var
names, code, adding some missing animation calls, etc.

Fixes #74829

## Why It's Good For The Game

Untangles the mess that is martial arts, making it a lot easier to work
with the attack chain and making it overall a ton more consistent.

## Changelog

🆑 Melbert
refactor: Big martial arts refactor, they should now overall act a ton
more consistent. Also technically any mob can do martial arts. Let me
know if something is funky.
/🆑

---------

Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
2024-02-01 14:18:46 +00:00
IndieanaJones
d4f29d182b Adds Combat Button to Living HUD (Simple + Basic Mob HUD) (#80919)
## About The Pull Request

This PR adds the combat mode toggle to the HUD of simple and basic mobs
that don't have hands (the ones with hands already had it). It looks
like this:

![image](https://github.com/tgstation/tgstation/assets/47086570/f4649693-25c6-4ebc-ad6e-bcabe9939019)

## Why It's Good For The Game

Simple and basic mobs can currently toggle combat mode by using the
keybind for it, however, they can't see whether or not they have it on
currently because the button for it is not on their HUD. Some basic
mobs, like regal rats, have different interactions when clicking on
objects depending on whether or not they have combat mode on, so this is
sort of important information to display to the player.

Which this is technically QOL, Jacquerel gave me permission to PR this
during the feature freeze.

## Changelog
🆑
qol: The combat mode toggle button is now present on the HUD for simple
and basic mobs.
/🆑
2024-01-14 02:16:16 +01:00
Chubbygummibear
7a45a518f7 Fixes Cameras views on clients 515.1615 or greater (#80818)
## About The Pull Request

Fixes https://github.com/tgstation/tgstation/issues/79954

Turns out the cause of cameras breaking was something weird with how
Byond determined the CENTER location for screen_locs on secondary popup
maps like cameras and the spyglass. This can be remedied by manually
using the LEFT,TOP position for the plane relays. However LEFT,TOP
breaks the views for clients 1614 and below so I included a jank
solution that should allow any client up to this point have the screen
displayed correctly

### 515.1609 views working

![dreamseeker_nolb8BLgRb](https://github.com/tgstation/tgstation/assets/46236974/e155c9c3-12c0-4eb5-a4a6-4e3f09dc456d)

### 515.1623 views working

![dreamseeker_I37Z4X04Hf](https://github.com/tgstation/tgstation/assets/46236974/e91b3bd8-ea05-40e7-ab20-6c48810f9879)
## Why It's Good For The Game

Cameras working passed 1614 means you can update the server. At some
point I suspect Lummox will fix the CENTER position on secondary maps
and when that happens it will likely break the current fix.


## Changelog
🆑
fix: popup screen locs will work on clients >1614. Security cameras and
Spyglass will work
/🆑

---------

Co-authored-by: SyncIt21 <110812394+SyncIt21@users.noreply.github.com>
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
2024-01-09 01:58:01 +00:00
MrMelbert
d5c547e459 Fixes COMSIG_LIVING_EARLY_UNARMED_ATTACK arguments (#80783)
## About The Pull Request

Fixes #80566 

Fixes the wrong arguments being passed to
`COMSIG_LIVING_EARLY_UNARMED_ATTACK`.
It now properly receives the proximity flag. 

Changes clicking with handcuffs to no longer always assume no proximity.

Replaces some checks for hands blocked to some checks for
`can_unarmed_attack` (which, currently, JUST checks for hands blocked,
but this is good for future reasons, just in case)

## Changelog

🆑 Melbert
fix: Strong arm implant users can shove more correctly. 
/🆑
2024-01-05 18:08:06 +00:00
Profakos
45438b4f04 Removes the attack_slime proc, and other slime refactors (#80487)
## About The Pull Request

- **Removed attack_slime**. Most of the attack_slime content has been
moved to a proc that signs up for COMSIG_LIVING_UNARMED_ATTACK. Its
ugly, but will make converting slimes to a basic mob easier. They now
use attack_animal for now, which might cause some unexpected
interactions. Hopefully when they are converted to basic mobs, these can
be cleared up properly.

- This caused some issues with cyborgs, who used to get only half damage
dealt to them. As refactoring this would have been too much of a
difficult task without much real gain, after much pondering, I have
decided that since slimes can always flash cyborgs with each of their
strikes, maybe cyborgs should only fear slimes that have electric
charges in them. In addition, slimes electric charges decrease now after
they successfully zap an cyborg, making them more consistent with the
zaps that affect carbons. AIs are still fully immune to slimes.

- The slime.dm and slime.life files were extremely bloated, and
unorganized. I have created two new files, defense.dm and ai.dm. I have
moved the various attack_by/attack_hand/etc procs to defense.dm. Ai.dm
now contains every single proc the slime's "AI" uses; this should help
getting a clearer picture of the current functionality, which should aid
with basic mob conversion and decision tree creation. The remaining
files have been slightly organized, with overrides in front, and new
procs at the back.

- Created a proc for swapping out Adult and Baby states of a slime.
Previously, attack_slime was in many cases ignoring fields like
melee_damage_lower and melee_damage_upper, replacing it with magic
numbers based on the slime's lifestate. Now these values are hard set by
these procs. This has caused slimes to be more consistent, though baby
slimes might do a bit less damage on the low end. I am tempted to turn
these in datums in the future, or as part of this PR.

- Removed baby slime's chance to accidentally attack a window/grille by
bumping into it, they had 0 object damage anyways, unlike adult slimes,
so there was no reason not to early return.

- The proc of `handle_feeding` assumed adjustBruteLoss and adjustToxLoss
return positive values when damage has been done, when in reality, it
returns the total health change along with its direction. This meant
slimes would fell off simple or basic mobs after a single bite. This has
been fixed.

- Also updated the warning before the slime type defines, as they were
out of date.

- I have removed the bespoke spacewalk override for slimes, which should
allow them to drift, should gravity go out.

- The nutrition stats are assigned only once, when the slime grows up,
instead of compared to being an adult every life tick

## Why It's Good For The Game

Less duplicated code.
This refactor should help in the basic mob conversion process.
Cyborgs have an easier time wrangling slimes, who could previously kill
them in three hits, if charged. They are mostly encased in metal, they
should feel fine when not hit with electric attacks.
Lets slimes feast on delicious corgis.
2024-01-02 18:37:20 +00:00
SyncIt21
926d000d76 Some Processing improvements (#80693)
## About The Pull Request
Got the idea from #80682. A lot of parent procs don't do anything, some
are just formatted in a bad way, and others early return and do no ops,
it's bad in general but this should give us a head start.

Some good overhead saved here
2024-01-01 20:58:34 +01:00
Rex9001
f88da4bcb9 Heretic DLC: Path of Moon (#79536)
## About The Pull Request
This pull request adds a new path.
The cross path is between ash and lock.

Credit to Fury McFlurry for the following sprites:
 ring_leader_effect

The path goes as follows:
 Moonlight Troupe
 Grasp of Lunacy
 Smile of the moon
 > Sidepaths:
    Mind Gate
    Ashen Eyes
 
 Mark of Moon
 Ritual of Knowledge
 Lunar Parade
 Moonlight Amulette
 > Sidepaths:
   Curse of Paralasys
   Unfathomable Curio
   Unsealed Arts
 
Moonlight blade
Ringleaders Rise
> Sidepaths:
   Ashen Ritual
 
 Last Act


Moonlight Troupe:
The first knowledge of path of moon, lets you make Lunar Blades with 2
iron and a knife

Grasp of Lunacy:
The grasp of this path hides your name for 15 seconds after use, but
more importantly it causes the person hit with the grasp
 to hallucinate everyone as indistinct human like figures.

Smile of the Moon:
A pointed spell that causes temporary blinding, muting, deafening and
confusing on the person its targeted at, these effects
 last longer the less sanity your victim has.

https://github.com/tgstation/tgstation/assets/120136161/db7cfaaa-8fe2-4f20-aa78-c17c17be4d63

Mindgate:
Lock-Moon. This spell causes you and your victim brain damage, the
victim also suffers a short amount of hallucinations
 and also 20 oxyloss.

https://github.com/tgstation/tgstation/assets/120136161/11d15acd-11d0-4e7d-a180-6481b18e9fd9

Mark of Moon:
When applied this paths mark pacifies the victim and they remain
pacifist until attacked or until the mark is detonated, when
 detonated the victim is left confused.

https://github.com/tgstation/tgstation/assets/120136161/41e601b5-76d4-4765-8b49-ada7de09feb7

Lunar Parade:
A spell that sends out a projectile that causes people hit by it to
follow the projectile whilst being unable to move. The
projectile also bounces around and is really useful to get people off
your back during chases.

https://github.com/tgstation/tgstation/assets/120136161/cddc8390-e8aa-4d68-b1a5-ab181e941a9b

Unfathomable Curio:
Transmute 3 rods, a brain and a belt into an Unfathomable Curio a belt
that can hold blades and items for rituals. Whilst worn
will also veil the heretic, allowing them to take 1 hit without
suffering damage, this veil will recharge quickly outside of
combat. If examined the examiner suffers brain damage and temporary
brain damage, and if a non-heretic uses it once the shield is damaged
the non-heretic user suffers massive brain damage and a permanent
uncurbable brain trauma. Lock-moon

Unsealed Arts:
Allows you to transmute a canvas and an additional item to create a
piece of art, these paintings have different effects depending on the
additional item added. Lock-moon
Possible paintings: 
    The sister and He Who Wept: 
    Additional atoms: Eyes. 
When a non-heretic looks at the painting they will begin to hallucinate
everyone as heretics.

   The First Desire: 
   Additional atoms: Any bodypart.
Increases the hunger of non-heretics, when examined drops an organ or
body part at the painting.

   Great chaparral over rolling hills: 
   Additional atoms: Any grown food. 
Spreads kudzu when placed, when examined grants a flower to the heretic.
			
   Lady out of gates: 
   Additional atoms: Gloves.
Causes non-heretics to scratch themselves until they remove their
jumpsuit, when examined removes all your mutations.
   
    Climb over the rusted mountain: 
    Additional atoms: Trash. 
Causes non-heretics to rust the floor they walk on and when examined
gives you a cool moodlet

These effects are mitigated for a few minutes when a non-heretic
suffering an effect examines the painting that caused the
effect. Except for great chapparal which spawns kudzu at their feet, and
Lady out of gates which gives them a random negative mutation.

https://github.com/tgstation/tgstation/assets/120136161/1d1bdd2f-cda5-4430-b3af-4742f98a59a8

https://github.com/tgstation/tgstation/assets/120136161/4e843ae4-9786-4e9b-8681-582713f4c789

Moonlight Amulette:
Allows the heretic to transmute 2 sheets of glass, a pair of eyes, a
brain and a tie. If the amulette is used on someone with low
sanity they go berserk attacking everyone if their sanity isnt low
enough it decreases their mood. Optionally you can add a
 poppy in the ritual to further decrease their mood on hit.

https://github.com/tgstation/tgstation/assets/120136161/ab820b3f-e7e6-407a-9a1a-93d49c0d7387

Moonlight Blade:
Causes the heretics blades to do brain and sanity damage whilst causing
hallucinations. The blades also cause giggling and
 laughter on hit. 

Ringleaders Rise:
An AoE spell that deals more brain damage the lower the sanity of the
victim, also causes hallucinations that last longer the
lower the sanity of the victim. If the victims sanity is low enoughit
causes them to go insane, the spell then halves their sanity.
This spell is on a longer cooldown and is more meant to be used as a
payoff or an instigator for a fight. The AoE area is 7 tiles

https://github.com/tgstation/tgstation/assets/120136161/4de85ba2-448a-485c-b739-77fcce86c0cb

Last Act:
The ascension lowers the cooldown of all the heretics spells by 33% and
increases the AoE range of Ringleaders Rise. The main
effect of this ascension is a passive sanity drain and hallucination
aura, if you have low sanity in the aura you will start to suffer
brain damage and if you reach the bottom you gain an aura of
hallucinations thus spreading the moon heretics influence
further. Not only that but roughly 1/5th of the crew will rise in
support of you becoming mini-heretics called acolytes that will attempt
to obey your commands!

I had videos showing off everything but they were too big for github
sadly so I will have to think of some other way to showcase all this
stuff.

This pr also adds a new optional atoms system which means that you can
have rituals that can be improved by adding additional atoms, like for
example moonlight amulette.
 
Feel free to give some suggestions for further ascension effects.
## Why It's Good For The Game

I feel like heretic is really missing a playstyle around insanity and
this slots neatly in to feel that gap. For being an eldritch antag of
horrors there is surprisingly little interaction with the sanity system
and I feel like this makes up for it, heretic is also missing some
distractions which is where the paintings can really shine and the
hallucinations which breed paranoia.

## Changelog
🆑
add: A new heretic path opens up! Gaze up at the great sky for the path
of the moon opens and the lie shall be slain in pursuit of ultimate
truth!
fix: Fixes the syndicate delusion not working
/🆑

---------

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
2024-01-01 15:03:03 +01:00
Bloop
f34174414d Cleans up some extra args in Destroy() (#80642)
## About The Pull Request

After https://github.com/tgstation/tgstation/pull/80628, these shouldn't
be needed anymore right?

## Why It's Good For The Game

Cleans up some vestigial code

## Changelog
EDIT: Not player-facing.
2023-12-30 03:54:07 +01:00
13spacemen
6c64f0d15e [NO GBP] Poll Alerts cleanup (#80572)
~Hopefully the candidates number and signed up overlay should show up
for everyone now and be more responsive~

Ghommie tackled most of it in
https://github.com/tgstation/tgstation/pull/80610

I think the candidate number overlay updating is done incorrectly in his
PR though.
Candidate number overlay should be updated for ALL candidates' poll
alert buttons, whenever ANY candidate enters/leaves the poll
2023-12-29 14:46:13 -06:00
Ghom
4b3c8f4bcb Fixing the constant poll alert runtimes, and the selector outline not being updated. (#80610) 2023-12-28 15:21:19 -08:00
13spacemen
908d6f1a2b Better Ghost Selection (#80283)
## About The Pull Request
Revived my old PR https://github.com/tgstation/tgstation/pull/68901

Replaces the annoying tgui alert popup "Do you want to be X? | Yes | No
| Never for this round" that is hard to read and steals window focus,
with a nice clean alert in the top right that counts down. If it's the
same event/mob they stack with 2x, 3x, etc. It also shows how many
candidates/ghosts are signed up.

The poll alerts have screentips too, they countdown and show if you're
signed up, how many people are signed up, if you chose "never for this
round" (which is cancelable)
## Why It's Good For The Game
![Screenshot 2023-12-13
030302](https://github.com/tgstation/tgstation/assets/46101244/04061a6b-cd9a-4546-9d71-bba6a6b70d87)

Way easier to see what role is available, you get a nice pic of the role
and get it's name in big text, you can cancel "never for this round",
and you can cancel signing up for a role before the timer is up
## Changelog
🆑
refactor: Ghost roles now offer ghosts a clickable poll button. Ghosts
can select a role, deselect it, alt-click it for "Never For This Round",
can cancel "Never", can see the countdown, and can see how many other
people are signed up for the role poll.
/🆑
2023-12-22 11:44:55 -08:00
Fikou
a3fa541e2e Bridge Assistant Station Trait (#80279)
## About The Pull Request
adds a station trait which adds a new role, the bridge assistant
he is designed to help commandeer the bridge and help out other heads
when needed. he is armed with the mini energy gun (the one heads used to
have on kilostation), a flash, a toolbelt (with an inducer), some cool
shades and a swanky scarf.
as he is a nerd he is weak and unable to twohand weapons, preventing him
from wielding the fire axe.
currently he does not have a mindshield but he cannot roll antag
he currently has access to the bridge, announcement console, eva,
teleporter, gateway, maint, and a weapon permit (somewhat (not really
other than for nerds) interestingly this is the first job that isnt
assistant that doesnt have access to any lathes, so he doesnt have orm
access unlike all the other jobs (except assistant))
the trait also makes a coffee machine spawn on the bridge
here is some useful art of your role

![image](https://github.com/tgstation/tgstation/assets/23585223/905e5527-9069-4226-b160-8dedd1ea7b74)
and ingame screenshots

![image](https://github.com/tgstation/tgstation/assets/23585223/0aa537ac-a791-4249-a702-490584919fd9)

![image](https://github.com/tgstation/tgstation/assets/23585223/eb93e2d1-0291-4ade-9208-b1c0b68648c7)

![image](https://github.com/tgstation/tgstation/assets/23585223/1d3c2f11-8ac0-4ee9-91a5-176f81a08dcb)


## Why It's Good For The Game
Adds upon the station trait job system with a straight forward role that
IS just a human (unlike the cargorilla), and is pretty basic with no
custom assets or whatever other than hud icons
Having the bridge assistant in some rounds seems like a neat way to
protect it since it gets fucked up in like half the time, while also not
having enough mechanical depth or gameplay as to warrant it as a
permanent role

## Changelog
🆑
add: Bridge Assistant job accessible from a station trait.
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
2023-12-16 20:02:45 -05:00
LemonInTheDark
d2e517103b FOV Hotfix: Actually offsets gameplane render relays (#80307)
## About The Pull Request

Whoops. We were basically skipping the master plate of our z level to
draw directly onto the one above, so anything not on the game plane (IE:
the hud) was getting totally ignored. MEMESSS

## Why It's Good For The Game

Closes #80301
2023-12-14 14:18:02 +13:00
LemonInTheDark
f03084c1ca FOV is Dead (Long Live FOV) (#80062)
## About The Pull Request

FOV as it is currently implemented is incompatible* with wallening.
I'm doin wallening, so we gotta redo things here.

The issue is the masking of mobs. Wallening relies on sidemap (layering
based off physical position), which only works on things on the same
plane (because planes are basically sheets we render down onto)
So rather then masking mobs, let's reuse the masking idea from old fov,
and use it to cut out a bit of the game render plane, and
blur/over-saturate the bit that's masked out.

My hope is this makes things visible in light, but not as much in
darkness, alongside making more vivid shit more easily seen (just like
real life)

Here's some videos, what follows after is the commits I care about
(since I had to rip a bunch of planes to nothing, so the files changed
tab might be a bit of a mess)

Oh also I had to remove the darkness pref since the darkness is doing a
lot of the heavy lifting now. I'm sorry.

Edit:
NEW FOV SPRITES! Thanks dongle your aviator glasses will guide us to a
better future.


https://github.com/tgstation/tgstation/assets/58055496/afa9eeb8-8b7b-4364-b0c0-7ac8070b5609


https://github.com/tgstation/tgstation/assets/58055496/0eff040c-8bf1-47e4-a4f3-dac56fb2ccc8

## Commits I Care About

[Implements something like fov, but without the planes as layers
hell](a604c7b1c8)

Rather then masking out mobs standing behind us, we use a combo color
matrix and blur filter to make the stuff covered by fov harder to see.

We achive this by splitting the game plane into two, masking both by fov
(one normally and one inversely), and then applying effects to one of
the two.

I want to make the fov fullscreens more gradient, but as an effect this
is a good start

[Removes WALL_PLANE_UPPER by adding a WALL_PLANE overlay to material
walls (init cost comes
here)](2548933739)

@Mothblocks see this. comment in commit explains further but uh, we need
to draw material walls to the light mask plane so things actually can be
seen on them, but we can't do that and also have them be big, so they
get an overlay. Sorry, slight init time bump, about 0.5 seconds. I can
kill it with wallening.

[Moves SEETHROUGH_PLANE above
ABOVE_GAME_PLANE](beec4c00e0)

I don't think it actually wants to draw here
@Time-Green I think this was you so pinging for opinion

[Resprites FOV masks to be clean (and more
consistent)](f02ad13696)

[f02ad13](f02ad13696)

This is 100% donglesplonge's work, he's spent a week or so going back
and forth with me sharpening these to a mirror shine, real chill

## Why It's Good For The Game

Walls are closing in

## Changelog
🆑 LemonInTheDark, Donglesplonge
image: Redoes fov "mask" sprites. They're clean, have a very pleasant
dithering effect, and look real fuckin good!
del: Changed FOV, it no longer hides mobs, instead it blurs the hidden
area, and makes it a bit darker/oversaturated
/🆑

###### * It's technically possible if we start using render targets to
create 2 sets of sources but that's insane and we aren't doing it
2023-12-13 15:52:24 +01:00
Jacquerel
90b974071d Sign up for Cargorilla from the lobby (#79776)
## About The Pull Request

If the station rolls the "Cargo Gorilla" trait, a button will now be
visible on the lobby.
Clicking on this button before the round has started will add you to a
list of participants, one of whom will be selected to become a gorilla
when the round begins.
If nobody signs up (because they're really boring I guess) the job will
instead appear on the latejoin menu.
Once someone has become the gorilla the button will disappear.


![dreamseeker_ntP3OayAuV](https://github.com/tgstation/tgstation/assets/7483112/a26087ea-1ee7-4e9f-b37c-195cb1b1744f)

While implementing this I noticed that an inverted check means we were
never populating the "GLOB.cargo_sloth" field which means the station
trait wasn't even working.

BEHIND THE SCENES
This also adds a generic "job station trait" which can be expanded in
the future.
Future developers can extend this to add other "rare jobs" with relative
ease.
By default I have made it so all subtypes of this trait are mutually
exclusive, only one can roll at a time.

This also means that I have converted "cargo gorilla" into a job, which
applies most of the code previously located in the mob's typepath or in
the station trait.
The fact that it is a job means that **admins** can enable any number of
gorillas to be present on the latejoin menu (but not the roundstart one,
as it is not possible to add Cargo Gorilla to your occupation
preferences) if they so desire.
The random beurocratic station trait, event, and traitor item (and the
job console) are not able to add gorilla slots.

Because I changed "Cargo Gorilla" to a job it now no longer exists on
the map until a player gains the role, and there wasn't a non-hacky way
to copy the name of this round's cargo sloth. Instead I just added a
small cargo gorilla name list.

## Why It's Good For The Game

Makes the presence of a fun trait more visible to players.
Means that people who aren't observing get a chance to be a monkey.
This is a framework several other people have wanted to exist for their
own features.

## Changelog

🆑 Jacquerel and Fikou
qol: If the station rolls the "Cargo Gorilla" station trait. you will be
able to sign up for the role from the game lobby.
qol: If nobody signs up to be the Cargo Gorilla then you can select it
from the Late Join menu and arrive on the arrival shuttle.
fix: The Cargo Gorilla will actually spawn.
/🆑
2023-12-12 08:48:49 -08:00
MrMelbert
787ae445d7 Fix some shenanigans involving interaction order with wound tending (#80225)
## About The Pull Request

Fixes #80223 . See issue for information about the bug.

This PR fixes it by placing wound tending before parent call but after
surgery.

It also fixes it by rewriting a little bit of medical stack item code to
only block interaction chain when actually healing someone - This is not
necessary with the above fix, but it futureproofs things.

## Changelog

🆑 Melbert
fix: When using an item on a mob, you will always attempt to fix wounds
AFTER surgery, BUT BEFORE the item's own interactions. As an example,
this means using a mesh on a mob will attempt to progress surgery first,
then attempt to fix any burn wounds, then heal burn damage.
/🆑
2023-12-10 18:17:21 -07:00
san7890
f39d539b32 Refactors Object Possession into a Component (moar modular, less /mob vars) (#80160)
## About The Pull Request

We have two verbs that allow any given mob to take control of an object
and move it ephemerally, `/proc/possess()` and `/proc/release()`. These
ones leveraged two vars present on every `/mob`: `name_archive` and
`control_object`. I don't like having vars clog up my VV and this just
injected snowflake behavior in a lot of spots - let's just make it a
component that'll clean everything else up.

This also opens up the ability to have more objects be under mob control
without giving someone verbs that spit out to the blackbox as an admin
verb + logs + message admins but that's a later thing. This just subs in
the behavior in a nice way.

Also, since it's a component, I added a small QoL that we can support
now: A screen alert that allows you to get out of the possession early
without navigating the stat panel for the specific verb. I think it's
neat. You can also trigger the aghost keybind if that's something you
want as well.

Also also, nothing actually ever cleaned up `control_object` by setting
it to null. This means that in the old framework, if a mob got qdelled
during a possession, that would have triggered a hung ref harddel. That
won't happen anymore.
## Why It's Good For The Game

Two less variables taking up crud space in the VSC debugger + view
variables panel. Better behavior injection that is far more reusable.
Component handling this behavior allows for better extensibility of this
function in the future.


![image](https://github.com/tgstation/tgstation/assets/34697715/a84238af-e014-4cff-9b4b-6cbaa36c44fd)
## Changelog
🆑
admin: Object Possession has been reworked, please report any potential
bugs.
qol: Object Possession should now throw a screen alert for you to
unpossess the object instead of you having to search the stat-panel for
the "release obj" verb. You can still use the verb but it's a lot nicer
now. Aghosting will also work now.
/🆑
2023-12-09 17:28:19 -05:00
MrMelbert
1e76fd70b4 Attack chain refactoring: Broadening tool_act into item_interact, moving some item interactions to... atom/item_interact / item/interact_with_atom (#79968)
## About The Pull Request

Implements half of this (with some minor changes): 


![image](https://github.com/tgstation/tgstation/assets/51863163/bf5cc4bb-5a1f-42e3-921d-9a57bc6096cc)

The ultimate goal of this is to split our attack chain in two: 
- One for non-combat item interactions
  - Health analyzer scanning
  - using tools on stuff
  - surgery
  - Niche other interactions
- One for combat attacking
  - Item hit thing, item deal damage. 
  - Special effects on attack would go here.  

This PR begins this by broadining tool act into item interact. 

Item interact is a catch-all proc ran at the beginning of attack chain,
before `pre_attack` and such, that handles the first part of the chain.

This allows us to easily catch item interaction and cancel the attack
part of the chain by using deliberate bitflag return values, rather than
`TRUE` / `FALSE`*.

*Because right now, `TRUE` = `cancel attack`, no matter what, which is
unclear to people.

Instead of moving as much as possible to the new proc in this PR, I
started by doing some easy, obvious things. More things can be moved in
the future, or technically they don't even need to move in a lot of
cases.

## Changelog

🆑 Melbert
refactor: Refactored some methods of items interacting with other
objects or mobs, such as surgery and health analzyers. Report if
anything seems wrong
/🆑
2023-12-08 23:50:19 -07:00
distributivgesetz
f7cb0f8018 Rename notify_ghost_cloning to notify_revival (#80096)
<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may
not be viewable. -->
<!-- You can view Contributing.MD for a detailed description of the pull
request process. -->

## About The Pull Request

Renames 
- `/mob/proc/notify_ghost_cloning` to `/mob/proc/notify_revival`
- `/mob/dead/observer/proc/notify_cloning` to
`/mob/dead/observer/proc/send_revival_notification`
- `/atom/movable/screen/alert/notify_cloning` to
`/atom/movable/screen/alert/revival`.

I could have found a way to merge both procs together but default
parameters keep me up at night.

<!-- Describe The Pull Request. Please be sure every change is
documented or this can delay review and even discourage maintainers from
merging your PR! -->

## Why It's Good For The Game

Conciseness, code that is named after a removed feature is silly.

<!-- Argue for the merits of your changes and how they benefit the game,
especially if they are controversial and/or far reaching. If you can't
actually explain WHY what you are doing will improve the game, then it
probably isn't good for the game in the first place. -->

## Changelog

<!-- If your PR modifies aspects of the game that can be concretely
observed by players or admins you should add a changelog. If your change
does NOT meet this description, remove this section. Be sure to properly
mark your PRs to prevent unnecessary GBP loss. You can read up on GBP
and it's effects on PRs in the tgstation guides for contributors. Please
note that maintainers freely reserve the right to remove and add tags
should they deem it appropriate. You can attempt to finagle the system
all you want, but it's best to shoot for clear communication right off
the bat. -->

nothing playerfacing

<!-- Both 🆑's are required for the changelog to work! You can put
your name to the right of the first 🆑 if you want to overwrite your
GitHub username as author ingame. -->
<!-- You can use multiple of the same prefix (they're only used for the
icon ingame) and delete the unneeded ones. Despite some of the tags,
changelogs should generally represent how a player might be affected by
the changes rather than a summary of the PR's contents. -->
2023-12-05 02:24:18 -05:00
Emmett Gaines
9254759323 Reorganizes the plane master subtypes according to the will of the plane master master (#79745)
Potato's the main plane master guy and I wanted to talk more about how
they should be organized. But then someone else merged the pr so now
here's the less split up version so I don't look like an ass.
2023-11-20 14:26:06 +01:00
Jeremiah
bbe440b3d6 More standardization for ghost notifications (READY) (#79596)
## About The Pull Request
I'm still not satisfied with how ghost notifications work. This gives
every notification with a source (99% of all notifications, in other
words) a link to jump/orbit. Currently, notifications with "play"
interactions would only get the interact link, so jumping to the source
was pretty annoying.

It removes posting the entire message in the alert tooltip, as some got
pretty lengthy and it didn't seem to fit. To replace this, they will
always use headers

After:


![image](https://github.com/tgstation/tgstation/assets/42397676/debfce52-3627-4a43-8663-33d61d893161)


![image](https://github.com/tgstation/tgstation/assets/42397676/01f299ae-dc6a-45f8-a97a-cb2c815088b2)


![image](https://github.com/tgstation/tgstation/assets/42397676/99567376-063e-458e-af2a-2dd4306747cc)

NOTIFY_JUMP and NOTIFY_ORBIT have been merged, since the only difference
seems to be whether it's a turf. The result shaves off some redundant
lines of code, since most-every usage of notify_ghosts uses
NOTIFY_ORBIT.
## Why It's Good For The Game
More standardization for the ghost notification system. Adds a few alert
headers that never had them. All in all, makes it easier for creators to
throw alerts at ghosts
## Changelog
🆑
qol: Nearly every ghost alert should now feature a "VIEW" button, even
those with click interaction.
del: Ghost alerts no longer show the entire message in the tooltip,
instead have been replaced with titles.
/🆑
2023-11-19 05:13:25 +01:00
MrMelbert
365e50bbce Mob attackedby / check_block refactor, plus some minor cleanup of attack_x procs (#79563)
## About The Pull Request

- Deletes `spec_attacked_by`
- Elements simple/basic mob attack threshold
- There was a skeleton mob that "mimics armor" but didn't use the actual
mimicing armor thing we have, so I changed that.
- Moves `check_shields` down to the living level, renames it to
`check_block`
 - Martial art blocking is now signalized (only CQC uses it anyways) 
- Cleaned up a bit of `attack_x` procs, but not a lot. Should have an
entire PR dedicated to this .... mess.
 - Deprecates `/obj/item/melee`

## Why It's Good For The Game

Second verse, same as the first. 

- Less bad species related procs. 
- Largely brings a lot of code in line, making combat more consistent
across types.
- Makes it a lot easier to add new code relating to blocking or taking
damage.

## Changelog

🆑 Melbert
refactor: Refactored another large chuck of attack code, primarily
involving melee item attacks and non-human mob attacks. Report if you
see anything weird
fix: Pacifists clicking on simple robots or silicons no longer causes
sparks
fix: Blocked thrown batons are now properly... blocked
/🆑
2023-11-17 19:57:51 -07:00
san7890
7f0536bb93 Makes Telekinesis + Russian Revolver Interaction more fair (#79740)
## About The Pull Request

Fixes #77238

Basically, you were able to just spam kill people with the russian
revolver if you had telekinesis, which isn't really fair. Now, after
taking a leaflet out of the the discussion in that issue report, you can
still pull off the same party trick... once...

Basically, let's just say that when you focus on firing the gun in your
mind... you're also pointing it directly at your mind (your brain (your
skull (you instantly die))). This occurs even if the projectile doesn't
actually touch you (because that would be hellish to account for) but
you're the one who's playing russian roulette man

You still get to do some collateral damage because that's still a very
funny interaction but you only get to do it once per life. I don't know
if people will be happy to revive you after you "shoot" them. Also, the
way it's coded means that you can still leave the revolver on the table
and fire it at your foot or something, or just use it normally, as a
telekinesis user. This _only_ applies to distance-based firings.
## Why It's Good For The Game

The russian revolver is specifically coded to prevent you from damaging
other people, and this was a pretty silly way to sidestep that based on
the checks. Instead, let's make it so that you can still do this
admittedly funny interaction, but with enough reason to not do it (the
reason being that you'll always get fucking blatted).
## Changelog
🆑
balance: After a string of unfortunate incidents, persons with
telekinesis have been strongly warned against playing Russian Roulette,
as they tend to hyperfixate on the gun a bit too much and end up firing
it directly at their head.
/🆑
2023-11-16 14:58:35 +01:00
MrMelbert
2562f0997a Reworks stop, drop, roll into a gradual, interruptable thing, that repeats until extinguished (#79694)
## About The Pull Request

Related: #78017 

Stop drop and roll is no longer instant -5 fire stacks -> stun -> wait. 

Now, when you stop drop and roll, every time you roll you will lose 1
firestack.

A roll is triggered every 0.8 seconds. Moving, getting up, or becoming
incapacitated / stunned will stop you from rolling.
_(This number puts it roughly equivalent to its current rate.)_

While rolling, your hands are blocked (you cannot use items, hold
things, etc.)
Additionally, you will roll until all firestacks are cleared. 

## Why It's Good For The Game

Getting stunned for 6 seconds because you decide to stop and roll is a
little silly. Reasonably you could stop rolling and get back up should
the need arise, such as "oh god there's more fire I gotta relocate".

By changing it to a gradual thing, it makes it a bit more reasonable and
fair.
- New players who immediately slam "STOP DROP ROLL" because the alert on
their screen tells them to are no longer helpless for 6 whole seconds
- People who hit the resist key, intending to interact with something
else (such as a bola) are no longer stuck rolling when they did not want
to

## Changelog

🆑 Melbert
balance: Stop, drop, and roll no longer instantly clears 5 fire stacks
off of you - Instead, it will clear 1 fire stack off of you every time
you roll, with a roll every 0.8 seconds.
balance: Stop, drop, and roll no longer stuns you for 6 seconds.
Instead, it will knock you to the floor while you are rolling. Moving
around or getting up will cancel the roll, and you cannot use items
while rolling around.
balance: Stop, drop, and roll will now repeat until the fire is put out
or you get up.
/🆑
2023-11-15 18:38:39 -07:00
LemonInTheDark
3223d2a3fb Lemon fixes ci (#79384)
## About The Pull Request

Sets up moveloops to better catch issues with duplicated loops

Letting people modify the timer var AND have it track what bucket we're
in was a bad idea.
So instead let's store the queued time separate. Also makes
allowed_to_move return true/false instead of flags

This fixed? the null loop issue locally, I honestly have no damn idea
why. I'm gonna be working on the rest of ci here, left trackers so if it
pops up between now and merge I'll know what the issue is.

---------

Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
Co-authored-by: Emmett Gaines <ninjanomnom@gmail.com>
2023-11-12 09:25:59 +00:00
Jacquerel
a1e46c5d31 Basic Guardians/Holoparasites (#79473)
## About The Pull Request

Fixes #79485
Fixes #77552

Converts Guardians (aka Holoparasites) into Basic Mobs.
Changes a bunch of their behaviours into actions or components which we
can reuse.
Replaces some verbs it would give to you and hide in the status panel
with action buttons that you may be able to find more quickly.

They _**should**_ work basically like they did before but a bit
smoother. It is not unlikely that I made some changes by accident or
just by changing framework though.

My one creative touch was adding random name suggestions.
The Wizard federation have a convention of naming their arcane spirit
guardians by combining a colour and a major arcana of the tarot. The
Syndicate of course won't truck with any of that mystical claptrap and
for their codenames use the much more sensible construction of a colour
and a gamepiece.

This lets you be randomly assigned such creative names as "Sparkling
Hermit", "Bloody Queen", "Blue World", or "Purple Diamond".
You can of course still ignore this entirely and type "The Brapmaster"
into the box if so desired.

I made _one_ other intentional change, which is to swap to Mothblocks'
nice leash component instead of instantly teleporting guardians back to
you when they are pulled out of the edge of their range. They should now
be "dragged" along behind you until they can't path, at which point they
will teleport. This should make the experience a bit less disorienting,
you have the recall button if you _want_ to instantly catch up.

This is unfortunately a bumper-sized PR because it did not seem
plausible to not do all of it at once, but I can make a project branch
for atomisation if people think this is too much of a pain in the ass to
review.

Other changes:
- Some refactoring to how the charge action works so I could
individually override "what you can hit" and "what happens when you hit"
instead of those being the same proc
- Lightning Guardian damage chain is now a component
- Explosive Guardian explosive trap is now a component
- Added even more arguments to the Healing Touch component to allow it
to heal tox/oxy damage and require a specific click modifier
- Life Link component which implements the Guardian behaviour of using
another mob as your health bar
- Moved some stuff about deciding what guardians look and are described
like into a theming datum
- Added a generic proc which can return whether your mob is meant to
apply some kind of damage multiplier to a certain damage type. It's not
perfect because I couldn't figure out how ot cram limb modifiers in
there, which is where most of it is on carbons. Oh well.
- Riders of vehicles now inherit all movement traits of those vehicles,
so riding a charging holoparasite will let you cross chasms. Also works
if you piggyback someone with wings, probably.

## Changelog

🆑
refactor: Guardians/Powerminers/Holoparasites now use the basic mob
framework. Please report any unexpected changes or behaviour.
qol: The verbs used to communicate with, recall, or banish your Guardian
are now action buttons.
balance: If (as a Guardian) your host moves slightly out of range you
will now be dragged back into range if possible, rather than being
instantly teleported to them.
balance: Protectors now have a shorter leash range rather than a longer
one, in order to more easily take advantage of their ability to drag
their charge out of danger.
balance: Ranged Guardians can now hold down the mouse button to fire
automatically.
balance: People riding vehicles or other mobs now inherit all of their
movement traits, so riding a flying mob (or vehicle, if we have any of
those) will allow you to cross chasms and lava safely.
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
2023-11-10 21:04:52 -07:00
LemonInTheDark
9696dd1a1d Targeting Datums Renamed (and global) (#79513)
## About The Pull Request

[Implements the backend required to make targeting datums
global](6901ead12e)

It's inconsistent with the rest of basic ai for these to have a high
degree of state, plus like, such a waste yaknow?

[Implements
GET_TARGETING_STRATEGY](d79c29134d)

Regexes used:
new.*(/datum/targetting_datum[^,(]*)\(*\)* -> GET_TARGETING_STRATEGY($1)

Renamed all instances of targetting to targeting (also targetting datum
-> targeting strategy)

I've used GET_TARGETING_STRATEGY at the source where the keys are
actually used, rather then in the listing. This works out just fine.

## Why It's Good For The Game

Not a misspelled name through the whole codebase, very slightly less
memory load for basically no downside (slight cpu cost maybe but not a
significant one.

---------

Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
2023-11-09 14:44:24 +00:00
Emmett Gaines
77dcdb7784 Splits up the plane masters file to be easier to browse and reference (#79370)
The title says it all, there is nothing else. Feel free to bikeshed
about code organization here.
2023-11-09 08:05:38 +00:00
lizardqueenlexi
08274f8343 Basic Constructs: Proteon (#79425)
## About The Pull Request

Last one! Makes proteons into a basic mob, and completely removes the
simple_animal construct supertype.

Proteons aren't really designed to be played by a player, instead being
a nuisance mapped into various ruins and traps. As such, they don't
really have any special abilities. Instead, the hostile variant has a
somewhat unique behavior. They'll viciously attack anyone who comes
close, but, being frail little cowards, if a proteon takes damage it
will immediately flee. After a random period between 2 and 4 seconds, it
will stop fleeing and come back for more.

In addition to this, a few other things have been done, some only
related because they're in files I touched.
- Moved proteons from the file for the Cleric's Den to their own file in
the basic constructs folder. Given that they're used in several
different ruins, they might as well not just be in the file for one.
- Simple constructs have been cut, and with them the procs for
healing/repairing on shades and cult structures, as those are no longer
needed.
- Because I was touching it anyway, I touched up the file for trap
structures. They no longer use any one-letter variable names, and time
is now universally listed in seconds rather than deciseconds in that
file.
- I removed a completely unused blackboard key from ice demons. This is
something I noticed due to a change I ended up not making while working
on proteon AI, but I figured I might as well leave it gone.
## Why It's Good For The Game

Kills the last three simple construct typepaths, bringing us to the
destined 19 removed. Huzzah!

The proteon AI routine should inject a little spice into fighting
proteons, especially for the unprepared - unlike many mobs, they won't
stand there and take it if you decide to fight back, but you can never
safely ignore them when they run away. They still aren't particularly
dangerous.
## Changelog
🆑
refactor: Proteon constructs now use the basic mob framework. The ones
encountered in ruins are a bit flightier now, and will briefly flee
combat if attacked - only so that they can return and menace you again
soon after. Please report any bugs.
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
2023-11-01 17:07:20 -06:00
Profakos
bc18450afe Converts traders to basic mobs (#79187)
## About The Pull Request

This PR converts the two trader mobs into basic mobs, these being the
basic debug trader that buys ectoplasm and sells ghost burgers, and Mr
Bones, who buys empty milk cartons and bones, and sells bone relate
paraphernalia.

Traders now use dynamic appearance generation. The old sprites still
exist as hallucinations, and as shop signs.

Trader UI is now summoned via `COMSIG_ATOM_ATTACK_HAND`, which properly
cancels the attack chain, so there is no longer need to put it on
Interact.

I kept most of the original behaviour, but moved them off into a
component. I have also cached all the images generated for the radials,
I hope I have not overengineered it. I have also created a new datum,
which stores the trader's wares, needs, and speech patterns.

Admins can put the component along with the trader data on any living
mobs with an AI controller, turning them into traders. Keep in mind that
most AI has random idle movement, meaning they have a chance to walk
off, closing your trader radial.


![image](https://github.com/tgstation/tgstation/assets/2676196/a2b216e9-f9bf-46e1-83fa-3a41c8447176)

The trader AI consists of the following, first, when a trader sees
someone, they will deploy their shop, if one does not already exists.
The shop consists of a chair, and a holographic sign. If you attack
them, they will chase you with their weapons, and then return to their
chair when victorious. If the chair is somehow destroyed, they will
create a new shop when they see a new potential customer.


![image](https://github.com/tgstation/tgstation/assets/2676196/ad5fcd5a-996c-490f-938b-6bc11c91c4ee)

Mr Bones uses a variant of the AI, where they will run at you, and
deploy their shop when they reach you. I call this the jumpscare
variant. Below you can see me getting actually jumpscared because Mr
Bones has stepped on a yelling frog when I opened the maintenance door.


![image](https://github.com/tgstation/tgstation/assets/2676196/f47a5baa-e32d-4454-97f9-d90d027003d2)

I have also made an element that toggles an ai controlled combat mode
when it gains a target, and when it loses it. I am using it to make
Traders unable to trade while they are trying to kill a robber. To aid
this, I a have made
`/datum/ai_controller/proc/sig_remove_from_blackboard` send the
`COMSIG_AI_BLACKBOARD_KEY_CLEARED` signal, in case the trader kills a
mob that deletes itself on death. This means I could remove a signup
`/datum/component/appearance_on_aggro` was doing towards Qdeleting.

Below you can see Mr Bones shooting me with candy corn.

![image](https://github.com/tgstation/tgstation/assets/2676196/489e1072-e15a-412c-a8eb-9a3f0cca7bf6)


![image](https://github.com/tgstation/tgstation/assets/2676196/8f74b50f-ea35-467c-bb07-2ef38f84c453)

Traders actually only shoot you until you are conscious, so I survived
here in crit. Most mobs don't have crit state, so they just die, so I am
sticking by this voice line.

Thank you @CoiledLamb  for help with the sale sign!

## Why It's Good For The Game

Two more mobs off the list. The AI and Componentized behaviours allows
us to set up new kind of traders.

## Changelog

🆑
refactor: Traders are basic mobs now. Please alert us of any strange
behaviours!
code: If there is only one option, radial lists will autopick it. This
behaviour can be turned off via a new argument.
/🆑
2023-10-31 01:49:56 +00:00
Jeremiah
153e06dc04 Partially reverts ghost announcements (#79221)
## About The Pull Request
#79139 turned out to be quite annoying, it wasn't taken into account
that these alerts can stack (ie: spiders).

Of course, I poked around the code and found some inconsistencies in the
process. For instance, there were usages of Topic for custom action
behavior which could've been consolidated. There were other instances
where jump (the default action) doesn't give a link at all, which I
think it should anyway, since the screen toast gives you this.

I've standardized it more, meaning you can use "NOTIFY_PLAY" without
writing a custom link and topic handler (for instance, MMIs)
## Why It's Good For The Game
Fixes #79198
Fixes #79195
## Changelog
🆑
fix: Ghost alerts have been tuned down a bit.
/🆑
2023-10-24 12:10:48 -06:00
Jeremiah
3e435cf7a9 Better looking ghost notifications (#79139)
## About The Pull Request
The alerts have been given some style

![image](https://github.com/tgstation/tgstation/assets/42397676/39812cc2-06b6-4eb3-85b9-cbc2fc625263)

Also the screen tip should be quite obvious 

![image](https://github.com/tgstation/tgstation/assets/42397676/34911b73-6707-4a69-aa52-2245b4f53848)

Cleaned up some code around the proc itself - really needed some TLC.
That, and added an arg to minor announcements to override colors.
## Why It's Good For The Game
Better styling for alerts
## Changelog
🆑
add: Just in time for Halloween- ghost notifications have been upgraded
to their own announcements. Boo!
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
2023-10-21 22:57:22 -06:00
lizardqueenlexi
1b8bcd0365 Basic drones (#79109)
## About The Pull Request

Fixes #68825
Fixes #72249
Fixes #70184

Converts maintenance drones to use the basic mob framework. As drones
don't use AI, this was mostly a perfunctory conversion, but I took the
opportunity to clean up drone code a bit and fixed a few bugs.

Noteworthy changes:
- Drones now have a `can_unhack` field. This is set to FALSE on
syndrones, because unhacking them doesn't make them stop being evil but
does cause some weirdness. Syndrones are unused right now, but you never
know.
- Drones use the Dextrous component for hand-having.
- Drones no longer have an internal ID card, instead being given
all-access with the `simple_access` component.
- Picking up drones now works the same as for other mobs, instead of
pointlessly copying the code into `attack_hand`. As a consequence, it is
now possible to punch drones if you want to for some reason.
- Drones can now reboot/cannibalize dead drones without being in combat
mode.
- Cannibalizing a drone that contains a client no longer runtimes - the
client is ghosted ahead of time.
- Drones now have TRAIT_ADVANCEDTOOLUSER, allowing them to properly
interact with machines.
- Trying to screwdriver a dead drone now gives a balloon alert about why
you can't do that.

In addition to these changes, I cleaned up the code quite a bit,
organizing things better and placing more useful comments throughout.
And removing a hell of a lot of single-letter variable names.

I will note that this PR does _not_ address #72129. The issue there is
that sprites for drones-as-hats are entirely nonexistent, and I'm not a
spriter. It shouldn't be too hard to fix if someone makes dronehat
sprites, though!

## Why It's Good For The Game
Kills 8 more simple animals.

In addition to that, drones were clearly a bit neglected, so this fixes
them up a bit and makes the code a little bit clearer. Maybe not that
much clearer, but it's something. It certainly leaves them in a better
place for further work if anyone wants to do that. Plus, a bunch of bugs
and other jankiness are fixed now, which is nice.

## Changelog
🆑
refactor: Maintenance Drones now use the basic mob framework. This
shouldn't come with any noticeable gameplay changes, but please report
any bugs.
fix: Drones can now interact normally with electrified doors.
fix: Drones' built-in tools can no longer be placed in storage objects
and/or thrown on the floor.
fix: Drones can now perform right-click interactions correctly, such as
deconstructing reinforced windows.
fix: Drones can now reboot or cannibalize other drones without being in
combat mode.
/🆑
2023-10-21 23:36:48 +00:00
LemonInTheDark
2258f12ece Tints the screen for halloween (#79062)
## About The Pull Request

Adds a color matrix to the game plate on halloween that greyscales
slightly and dims/drops dim colors for a harsher dropoff
I'm not sure the dropoff is strong enough, can't decide.

## Why It's Good For The Game


![276023326-205a3068-4f6c-4531-bc19-a3bb1f9f3a5e](https://github.com/tgstation/tgstation/assets/58055496/d6b3bd89-96a3-4da1-9d45-eac91f130c25)

## Changelog
🆑
add: Screen is now more grungy for halloween
/🆑
2023-10-19 22:54:53 +02:00
LemonInTheDark
b77fa8c2a2 Starlight Control (Aurora works now, space gas doesn't touch starlight, narsie ending effects) (#78877)
## About The Pull Request

[Implements a setter for starlight
variables](af34f06b41)

I want to start to modify starlight more, and that means I need a way to
hook into everything that uses it and update it, so we can modify it on
the fly.

This does that, alongside removing space overlays from nearspace (too
many false positives) and making the aurora modify all turfs projecting
starlight, rather then all turfs in an area.

Do still need to figure out handling for the starlight color usage in
turf underlays tho (I gave up, we just keep it static. I'll fix it
someday but the render_relay strategy just doesn't work with its masking
setup)

[Reworks how starlight overlays
work](9da4bc38e2)

Instead of setting color on the overlays directly, we instead store an
object with our current settings in every mob's screen, and
render_target it down onto our overlays.

This lets us update overlay colors VERY trivially. Just need to set
color on the overlay var. Makes modifying starlight a lot cheaper.

It doesn't work on area overlays, because suffering, and it MIGHT induce
extra cost on clients. if it does we can do something about that, we'll
play it by ear

[Removes parallax starlight
coloring.](5f701a1b13)

I'm sorta iffy on the color, the effect can be real oppressive in some
cases, and I'd like to use starlight color for more events in world, and
having it vary can make that looking nice hard.

[Adds some visual effects to narsie being
summoned](a423cfcb2b)

As the rune drawing progresses space (starlight and parallax) go from
normal to greyscale. Then, right about when narsie shows up, starlight
becomes vibrant red.

It's a nice effect. I wanna do more shit like this, I think it'll
improve vibes significantly.
## Why It's Good For The Game

Can't embed it because of github's upload limit, can show a
[link](https://cdn.discordapp.com/attachments/458452245256601615/1160821856358645860/2023-10-08_22-31-22.mp4?ex=65360e99&is=65239999&hm=680e33e4e0026b89e132afc50c04a648a24f869eb662f274a381a5de5c5a36f2&)
for the narsie stuff

Here's
[one](https://cdn.discordapp.com/attachments/326831214667235328/1160813747196141568/2023-10-08_22-34-10.mp4?ex=6536070c&is=6523920c&hm=f8d571d1013da89887f49f3fec99f632251eeeac83085aa7dde97009aee3922f&)
for the aurora too.

This gives us more pretty starlight shit, and the ABILITY to do more
pretty starlight shit. I'm pretty jazzed, and I hope people use this
proc more (keeping in mind that it's pretty hard on the lighting system,
and needs significant delay between changes)
## Changelog

🆑
add: Narsie summoning has had some effects added to space and starlight
del: Removes the link between spacegas color and starlight. It was a
slight bit too vibrant and I think impacted the vibe too wildly to be
incidental.
fix: The aurora event actually... works now. Space lights up and all
that
/🆑
2023-10-17 13:19:12 -06:00
Emmett Gaines
96d7e9c690 Invisibility refactor (#78908)
This adds a tracker for sources of invisibility and a priority system. I
needed this for another thing so I'm doing this first since it touches a
lot of code. As for the bugs fixed in the changelog, it's only what I
noticed while going through everything and there's likely a few more
things fixed with this. This should be testmerged for a while, I'll
bring this out of draft when it feels safe.

🆑
admin: Invisimin can now be used on mobs that are already invisible,
whether through temporary or permanent effects.
fix: Monkeyize/Humanize mob transformations no longer permanently reveal
invisible mobs if they had effects making them invisible otherwise.
fix: Objects with the undertile element that have been made invisible
through other means are no longer revealed by being uncovered.
/🆑
2023-10-17 13:07:31 -06:00
MrMelbert
dcedf89c70 Fixes being able to punch yourself (#79033)
## About The Pull Request

Fixes #79031 

Fixes #79042

I forgot some logic here when making the human override. 
Not the cleanest way to do it but it'll suffice. 

## Changelog

🆑 Melbert
fix: You can punch yourself again
/🆑
2023-10-17 13:02:07 -06:00
MrMelbert
9664d24c13 Refactors UnarmedAttack so we don't have like 4 Unarmed Attack signals, kills two more snowflake species procs (#78991)
## About The Pull Request

- Deletes `spec_unarmedattack`
- Deletes `spec_unarmedattacked`
- Replaces `COMSIG_HUMAN_EARLY_UNARMED_ATTACK` with
`COMSIG_LIVING_EARLY_UNARMED_ATTACK`
- Replaces uses of `COMSIG_HUMAN_MELEE_UNARMED_ATTACK` with
`COMSIG_LIVING_EARLY_UNARMED_ATTACK`
- Fixes(?)(I've never seen this work) / Elementizes Monkey ability to
bite while handcuffed
- Monkey clever `attack paw` / `attack hand` thing is now handled the
same on the human level (via `resolve_unarmed_attack`)

## Why It's Good For The Game

Atomized from swing branch. I was really annoyed with these two signals,
this kinda unifies the behavior between living and human mobs (they were
already quite similar).

One thing of note is that this will make dis-coordinated humans use
`attack_paw` rather than `attack_hand`, so they'll bite people instead
of punching them. I'm not sure if this is what we want, if we wanna
tweak that before then I can by all means.

## Changelog

🆑 Melbert
refactor: Refactored unarmed attacking mechanisms, this means
dis-coordinated humans will now bite people like monkeys (like how
coordinated monkeys punch people like humans?)
refactor: Dis-coordinated humans smashing up machines now use their
hands, rather than their paws
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
2023-10-15 22:25:19 -06:00
IndieanaJones
640980b4d3 Simplemob AttackingTarget Fix (#78966)
## About The Pull Request

Fixes #78953, plus some unreported code issues with lavaland elites,
player-controlled megafauna, and a couple other hostile simplemobs.

Basically, the sort of "attack wrapper" use of AttackingTarget seen in
some simplemobs, specifically when player-controlled, was accidentally
removed in the hands element refactor PR. This PR just re-adds that
usage for player simplemobs to preserve previous functionality for our
remaining simplemobs until their time to be refactored comes.

## Why It's Good For The Game

While we're more geared towards basic mobs and simplemob conversions
currently, we should still aim to preserve simplemob functionality until
we don't have them anymore.

## Changelog
🆑
fix: Space Dragon can break walls, eat corpses and destroy mechs more
efficiently again
fix: Player-controlled lavaland elites can once again return to their
tumor after winning their fight
/🆑
2023-10-13 16:21:59 +01:00
Jacquerel
6d59d8eb91 Hands management element (#78887)
## About The Pull Request

Places "setting up being able to use hands" into an element so it can be
easily applied to non-carbon mobs.

## Why It's Good For The Game

This is one of the last roadblocks for basic mob implementation and
people were intimidated by it but it turns out this shit is easy, 90% of
this code is already just on `living` and I put a little bit more there.
The element _really_ only handles stuff like dropping items on death,
picking things up rather than biting them, and adding examine text.

This also removes some copy/pasted code between `simple_animal` and
`carbon` and unifies some behaviours which were implemented for some
dextrous simple animals but not others.

Changes to give Ian a single hand representing his mouth will come at a
later date.

## Changelog

🆑
qol: You can now see what drones and gorillas are holding by examining
them.
admin: It's now easier to give handless mobs hands by applying the
"dextrous" element.
balance: Spiders and Bears can now climb railings (you know if... they'd
rather do that than destroy them).
/🆑
2023-10-10 15:27:12 -06:00
MrMelbert
02e87199cf Moves silicon camera (photos, not mob cameras) out of click code (#78774)
## About The Pull Request

Atomized from the swing branch. 

Moves silicon camera (taking photos, not mob camera stuff) out of their
core click code. It now uses click intercepts.

(There's an argument to be made to use signals rather than click
intercept as it's rather antiquated but w/e.)

- [x] I tested this PR 

## Why It's Good For The Game

Makes it easier to unifiy click a bit more in the future. Reduces
surface area of a feature.

## Changelog

🆑 Melbert
qol: AI, cyborg, and PAI camera (photo taking) behavior now uses balloon
alerts and has sound effects associated
refactor: Refactored AI, cyborg, and PAI camera (photo taking) code
fix: fixed being unable to print photos as a cyborg when below 50%
toner, even though photos only take 5%
/🆑
2023-10-06 12:30:39 +01:00
Bloop
68b798efa0 A thorough audit of damage procs and specifically their use in on_mob_life() (with unit tests!) (#78657) 2023-10-03 04:01:32 -04:00
Jeremiah
a3849062b8 Feature: bitrunner, a new supply role (READY) (#77259)
## About The Pull Request
[Design doc](https://hackmd.io/@shadowh4nd/r1P7atPjn) 

Adds a new supply role centered on short dungeon-esque runs with a focus
on unifying the job with the fun part. Some virtual domains are combat
related, some are silly, some focus on "objectives". Avatar health is
linked to your physical presence and retries are limited.


<details>
<summary>Photos, WIP</summary>

Net pod stasis

![netpod](https://github.com/tgstation/tgstation/assets/42397676/d99073a4-2438-4600-83c0-cafb7b3fee55)

Server loaded

![](https://cdn.discordapp.com/attachments/1131433451841662996/1135304774976278759/dreamseeker_N14j6dwLcK.gif)

Server cooldown

![](https://cdn.discordapp.com/attachments/1131433451841662996/1135304775945179217/dreamseeker_NkIwWLJZma.gif)

the quantum console UI
![Screenshot 2023-08-05
105742](https://github.com/tgstation/tgstation/assets/42397676/3a45feaf-8c80-46b2-81c9-355932d1b014)

Cyber police antag page
![Screenshot 2023-08-16
205303](https://github.com/tgstation/tgstation/assets/42397676/fc28bcdd-2a2a-487b-927c-904f224c1b89)

A safehouse

![image](https://github.com/tgstation/tgstation/assets/42397676/c22ac115-4e00-432a-aeeb-b6afdb1ef750)

Domain info page, every domain gets this (and sometimes help text)
![Screenshot 2023-08-04
141859](https://github.com/tgstation/tgstation/assets/42397676/ba9ed6d9-a318-4466-b246-d2da0fa05676)

Me getting steamrolled in one of the missions

![syndicant](https://github.com/tgstation/tgstation/assets/42397676/3eb3099a-f9b2-4431-854d-50d8cad9b7f0)

Ghost roles getting notified that server is kicking them out
![Screenshot 2023-08-04
135454](https://github.com/tgstation/tgstation/assets/42397676/edab916c-6255-4b83-b2e7-155df2f03aab)

Players enjoying the new combat missions
![Screenshot 2023-08-05
005727](https://github.com/tgstation/tgstation/assets/42397676/e302a66f-610d-4fe1-82e0-7c8aec3913ea)

Players exploring some of the virtual maps
![Screenshot 2023-08-06
220919](https://github.com/tgstation/tgstation/assets/42397676/75a92a0b-6aa1-4bac-8fd1-c9fb47c955da)

(Not part of the PR, but)
![Screenshot 2023-08-06
221527](https://github.com/tgstation/tgstation/assets/42397676/012475ec-bfa5-4fd3-9dcb-31d222bb7bef)

New bitrunner vendor

![dreamseeker_V62h2BGdEl](https://github.com/tgstation/tgstation/assets/42397676/37ca8f69-f75e-45c9-b324-e6b31696c7b7)

</details>

## Why It's Good For The Game
Content, firstly, and moreso being supply department content.

The framework that this implements is a great (preauthorized)
replacement for two systems which are collecting dust: BEPIS and the
gateway. They integrate into this system and it's a direct upgrade.

This adds a way for the players on station to generate materials (if
that remains). The nice part about it is that I can throw balance and
believability to the wind, as unlike its unrelated predecessor VR or
away missions, bitrunning entirely washes its hands of the map and mobs
each reboot.

It offers a very expandable map framework to add content and it's all
fairly well documented.

I'd like to add a feature that represents the idea that jobs don't have
to be mundane and "external" jobs can stay tied to the main gameplay
loop.

## Changelog
jlsnow301, kinneb, mmmiracles, ical92, spockye
🆑
add: Adds Bitrunning to supply department- a semi-offstation role that
rewards teamwork.
add: Adds new machines to complement the job- net pod, quantum server,
quantum consoles, and the nexacache vendor.
add: Adds several new maps which can be loaded and unloaded at will.
add: Some flair for the new bitrunning vendor.
add: Adds a new antagonist for the virtual domain only. Short lived
ghost role that fights bitrunners.
del: Removes the BEPIS machine, moves its tech into the Bitrunning
vendor.
/🆑

<!-- Both 🆑's are required for the changelog to work! You can put
your name to the right of the first 🆑 if you want to overwrite your
GitHub username as author ingame. -->
<!-- You can use multiple of the same prefix (they're only used for the
icon ingame) and delete the unneeded ones. Despite some of the tags,
changelogs should generally represent how a player might be affected by
the changes rather than a summary of the PR's contents. -->

---------

Co-authored-by: MMMiracles <lolaccount1@hotmail.com>
Co-authored-by: Ical <wolfsgamingtips@gmail.com>
Co-authored-by: spockye <79304582+spockye@users.noreply.github.com>
Co-authored-by: Watermelon914 <37270891+Watermelon914@users.noreply.github.com>
Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com>
2023-09-23 11:14:12 +02:00
Ghom
a351e4522c Culls client/mouse code only used by beam rifles in favor of signals. (#78113) 2023-09-17 01:25:51 -05:00
san7890
4b8de7b79f Refactors the notransform variable into a trait. (#78146)
## About The Pull Request

Hey there,

There were more than a few times (like in cinematic code) where we might
need to accurately know the source of what's adding this trait (or have
multiple sources for the whole 'we don't want this mob to do shit while
we transform this mob'), so in order to rectify this potential issue,
let's refactor it into a trait.

## Why It's Good For The Game

Some code already declared that there might be issues with this being a
boolean var (with no way of knowing _why_ we don't want this mob to not
transform (or not do anything idk). Let's remove those comments and any
future doubt in those instances with the trait macros. Also, stuff like
`TRAIT_IMMOBILIZED` which does a similar thing in many contexts was
already a trait that was regularly added in conjunction with flipping
the variable, so we're able to flatten all that stuff into
`add_traits()` and `remove_traits()` now. nice

I also cleaned up quite a bit of code as I saw it, let me know if it
should be split out but I guarantee that if I didn't do it- no one will
for the next two years.

## Changelog

🆑
refactor: If you transform into another mob and notice bugs with
interacting with the game world, please create a bug report as this
framework was recently refactored.
/🆑

Probably fucked up somewhere, lmk

---------

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
2023-09-07 16:45:50 +01:00
LemonInTheDark
8ada1e931c Resolves parallax harddels (#78066) 2023-09-02 22:18:26 -04:00
carlarctg
1feffb747a Adds a syndicate AI card for nuke ops (#76546)
## About The Pull Request

Adds a syndicate AI card for nuke ops. Costs 12 TC, can be refunded.
Activating it in-hand opens up a ghost poll like normal reinforcements.
## Why It's Good For The Game

> Adds a syndicate AI card for nuke ops. Costs 12 TC, can be refunded.
Activating it in-hand opens up a ghost poll.

It'll be fun to have a lil modsuit pal with you who can maybe help if
you get stunned, in critical condition, or else. With an injector module
they can even save your life, if it's loaded with medicine! Unless they
can't actually inject, but oh well, out of scope.

12 TC seems fair to me, not so expensive that nobody's going to bother
with something that's not really useful in the vast majority of
circumstances, but not so cheap that everyone will get one.

There are also doubtless a huge amount of gimmicks that savvy nukies can
get up to, having a pocket AI.

**Since this needs two players to be fully tested, I wasn't able to do
so. Please testmerge this before merging so we can confirm it works
ingame!**
## Changelog
🆑
add: Adds a syndicate AI card for nuke ops. Costs 12 TC, can be
refunded. Activating it in-hand opens up a ghost poll like normal
reinforcements. Base interaction range for syndicate AIs is one, which
means they can handle electronics only in proximity.
add: Adds a syndicate AI interaction range upgrade for nuke ops, costs 4
TC and can be applied onto a syndicate AI (inside any container) to
increase its interaction range by two per. (Three purchases are
recommended for seven tiles of range!)
/🆑
2023-08-26 16:17:21 -04:00
John Willard
ef352ca731 minor changes to living and mob vars (#77820)
## About The Pull Request

Renames m_intent to move_intent and moves it to the living level
renames tod to station_timestamp_timeofdeath
removes stun_absorption and see_override as one was unused and the other
was never actually implemented

## Why It's Good For The Game

Many vars on the mob and living level were intended to be on the living
and carbon level, but weren't for one reason or another. Generally it
was out of laziness to ensure the mobs being checked for these vars were
the intended mobs, and there's some todo comments on how they want it
changed in the future, though it never happened.
I'm hoping to get these all down in the future, I originally wanted to
move ``stat`` from mob to living but it had hundreds of errors so I
didn't want to do it all here.

## Changelog

Nothing player-facing.
2023-08-26 02:24:15 +01:00
Bloop
4c870f71ca Fixes a bunch of callbacks that were being qdeleted, and code cleanup (#77904)
## About The Pull Request


![image](https://github.com/tgstation/tgstation/assets/13398309/559eb50a-461c-4220-b628-55412baaffc3)

Continuing the work of
https://github.com/tgstation/tgstation/pull/77850.

it started with finding one that was being missed and causing a
runtime...then I noticed a whole lot more. While I was doing this I
found callbacks that weren't being nulled in `Destroy()`, so I added
that wherever I found these spots as well as some general code cleanup.

There were a lot more of these than I initially hoped to encounter so
I'm labeling it as a refactor.

## Why It's Good For The Game

Fixes lots of runtimes, improves code resiliency.

## Changelog

🆑
refactor: fixed a bunch of instances of callbacks being qdeleted and
cleaned up related code
/🆑
2023-08-25 16:03:27 -06:00
LemonInTheDark
ed0999e4ea Adds error on qdeling callback, fixes errors this causes (#77850)
## About The Pull Request

You shouldn't ever qdel a callback. If you don't want to own it free
your ref (remove it from a list/set it to null). When all refs are
cleared it'll get cleaned up by byond itself
2023-08-22 21:32:30 -05:00