Commit Graph

424 Commits

Author SHA1 Message Date
AnturK
57df597138 Fixes runtime on initalizing science programs (#78842)
Datums don't have location, so there's no z level to search here.
2023-10-08 23:01:55 -06:00
John Willard
36a41f584d Camera consoles no longer constantly check camera list (#78822)
## About The Pull Request

I would like camera sorting to be handled without having to constantly
get the entire list of cameras and sorting itself, but this occasion it
isn't even necessary, and was only added because I wanted to keep it
consistent with old behavior. This wasn't the best idea, and this is
trying to make amends with that.

Instead of getting the entire list of cameras when swapping cameras, it
instead gets that specific camera from the list and sets your active
camera to that. To do so, camera consoles now have a ref to the camera,
rather than going by name alone.

## Why It's Good For The Game

Explained in the about section mostly, we're no longer checking through
and sorting the entire list of cameras every single time you swap from
one camera to another.

## Changelog

Nothing player-facing.
2023-10-07 16:59:26 -07:00
GPeckman
f5188c9c4d Security Officers can now Download the Plexagon Crew Manifest PDA App (#78678)
## About The Pull Request

Despite starting with the Plexagon app, security officers did not have
sufficient access to actually download the app onto new machines. Now
they do.
## Why It's Good For The Game

Its weird and unintuitive to start with an app but not be able to
download it if you have to get a new PDA.
## Changelog
🆑
fix: Security officers can now download the crew manifest PDA app that
they start with.
/🆑
2023-09-30 20:12:26 -04:00
John Willard
aaff861c90 pdas now use their cells more (#78580)
## About The Pull Request

So one aspect of PDAs that I quite liked previously was managing and
upgrading your power.
This was lost when all cell parts got removed, mostly, and now I'd like
to re-add it.
PDAs and Tablets now use more power each second it's on
Programs being active/idle now take charge too.
And all this now takes ``seconds_per_tick`` into account.

Screenshots of APC use before and after having 6 programs open at once

![image](https://github.com/tgstation/tgstation/assets/53777086/14699ae7-19a7-4eb6-a211-5944cc1867d0)

![image](https://github.com/tgstation/tgstation/assets/53777086/804fedde-0d5a-43a9-9e61-34139257a16f)

PDA default power cells have a max charge of 1000, each cell use is
around ``1.00970340315`` power, which is ``1.01013789399`` w/ 2 programs
in idle and 1 active program (which is what PDAs are capable of). This
means it takes about 990 ticks to fully drain your power, or about 50
minutes, at max use.

This is completely blasted away the moment you put anything beyond a t1
cell inside of it, which is unfortunate but what can you do about tiered
parts being so poor.

The problem of no public PDA chargers are alleviated by
https://github.com/tgstation/tgstation/pull/78600

### Update

The PDA flashlight being on now also drains the battery 25% times
faster. PDA running out of charge now also turns the flashlight off.

## Why It's Good For The Game

You may or may not have to actually charge your PDA once in a round now,
maybe. I liked this part of tablets and would like to see it brought
back, managing your power to use your apps is important to ensure you're
not just using all apps 24/7

Because this also adds the functionality to add/remove power cells
again, it opens up to some minor little pranks/messing with people that
isn't completely destroying their tools, as well as some minor
upgradeability.

## Changelog

🆑
balance: You can now remove and replace power cells from PDAs (with
screwdriver).
balance: PDAs now drain their power cells harder, and also take into
account active programs & their flashlight being on.
balance: PDAs running out of charge now turn their flashlights off.
/🆑
2023-09-27 21:15:19 -04:00
Iamgoofball
dd87788877 TTS: Gas Mask muffling, Hailer Mask voice effects, support for more filters that use samplerate, voice effects for lizards, ethereals, and xenomorphs. (#78567)
## About The Pull Request


https://github.com/tgstation/tgstation/assets/4081722/7c8df2e2-8795-4048-b11e-e831f749a097


https://github.com/tgstation/tgstation/assets/4081722/d0bec7fd-25b1-4bdd-98a6-0ebfea749551


https://github.com/tgstation/tgstation/assets/4081722/31c0259a-2bd4-4575-a758-a2044ccf17b0


## Why It's Good For The Game

Improves TTS audio immersion.

## Changelog
🆑
qol: Gas masks now muffle your voice with TTS.
qol: Security Hailer masks now disguise your voice to protect your right
to brutalize greytiders.
qol: Lizards, Ethereals, and Xenomorphs now have a vocal effect.
qol: Security Records now show someone's voice name.
/🆑
2023-09-27 01:01:47 +00:00
Ghom
b23b1dd310 The notepad app now includes basic nautical directions in its default message. (#78241)
## About The Pull Request
Based on an old PR from citadel:
Citadel-Station-13/Citadel-Station-13/pull/7690

It also comes with a tip.

Screenshot of what it looks like more or less (a smidge outdated):

![immagine](https://github.com/tgstation/tgstation/assets/42542238/8f9338c3-2794-485f-ab25-b36fcc33143f)


## Why It's Good For The Game
This should help new players and not learn and memorize these five
simple terms often used in station area names.

## Changelog

🆑 Ghommie (Based on an old PR by Trilbyspaceclone from Citadel)
qol: The notepad app now includes basic nautical directions in its
default message.
qol: A tip about nautical directions, too.
/🆑
2023-09-12 19:05:32 +00:00
Waterpig
9fc5a95503 You can now send PDA messages when resting (#78154)
## About The Pull Request

No longer must you stand up when sending messages over the PDA! Do it
all comfortably, laying down in your bed!

Computers are automatically inaccessible when resting, so this only
affects PDA's, TABLETS, and LAPTOPS

## Why It's Good For The Game

Why wouldn't I be able to use a PDA laying down, heck everyone uses
their phone laying on their back, using your PDA like that only makes
sense

## Changelog
🆑
fix: The messenger app can now be used when laying down.
/🆑

Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
2023-09-09 00:51:39 +01:00
John Willard
aa820c08fe Oldstation now has their own RND (#78132)
## About The Pull Request

This PR does many things and I expect to be asked to atomize some stuff.

### Oldstation Additions

Oldstation now has their own research server, generating their own
points. To help alleviate major concerns, they have a few stuff to help
with this:
- They now have a pre-built operating computer
- They now have an Autopsy scanner
- They now have access to Experimental Dissection

Experimental Dissection is the old dissection, giving research points in
the form of paper notes on completion. They must be turned in to the RND
server (only works on the Oldstation one, so you can't abuse this) for
points. This was an idea I've had for some time, as Oldstation is used
somewhat as a representation of how ss13 used to be (through its use of
directional windows (before they got removed, but I'd like to bring them
back), old IDs, RTGs, and old engines before they got removed from the
game fully)

Considering there are 11 alien mobs in Oldstation, there is 27.5k
research points to get from alien corpses, enough to bring them up to
speed with whatever they wish to do. This is their 'alternative' for
experiments (which they can still do if they want, but it is very hard
to do, outside of dissection which is needed for the node).

This surgery isn't repeatable, isn't upgradable, and isn't removed by
being healed. It is not mutually exclusive with autopsy (so you can't
ruin yourself doing the wrong surgery).

### Other stuff

- Ninjas now drain RND points from the server they drain from, rather
than always hitting science
- Syncing machines to research roundstart is now a macro, and now
immediately syncs to a server on your Z-level. Machines will
automatically connect to the Science servers if none else are available.

### non-player facing

- Science, Admin, and Oldstation techwebs are now no longer vars on
research, but stored in research's list of techwebs.
- ``get_available_servers`` and ``find_valid_servers`` are now procs on
the research subsystem, rather than the experisci component.
- Oldstation code has been split into separate files.

## Why It's Good For The Game

Oldstation is one of my favorite ruins, but it is also one of the
largest complaints for RND (along with Golems) because they use the
station's Science nodes & points (I recently tried de-hardcoding Science
stuff to help prepare for this, but I didn't get everything in advance).

The complaint stems from these ghost roles, who are meant to be a fun
activity to do while waiting for the next round, using the station's
research points for their own stuff, completely untrackable unless
someone goes out of their way to grief a ghost spawn just for using
points to get things they need. These roles make their own servers to
drain the station, and I find that unfun and quite boring for everyone-
it's also not very flavorful, why would Charliestation know of the
station's RND to take advantage of it?

This hopes to fix those issues, make Charliestation more worthwhile, and
more flavorful.

## Changelog

🆑
fix: Getting a node researched now properly makes it no longer hidden.
fix: Ninjas draining RD servers now drains it from the connected
techweb, rather than sniping Science.
balance: Machines will first try to connect to a techweb with servers on
their z-level, with the Science techweb remaining as fallback.
add: Oldstation RND, comes with their own Techweb and special surgery to
gain research points through dissecting Xenomorphs.
/🆑
2023-09-07 17:59:17 +01:00
John Willard
fe104cf8da pAIs control a PDA they're inserted into (#78103)
## About The Pull Request

This PR lets pAIs inserted into a PDA to control the PDA of their owner.
They can see their own pAI configurations but cannot edit any of it.
They also can't eject themselves from it.
This means they can receive and send PDA messages as their owner, acting
like a personal secretary

This also adds support for multiple people using a PDA and its UI
updating for all of them and PDA messages being received and responded
to from multiple people under the same PDA
It also removes pAI camera in favor of using siliconcamera, which is the
same thing; this just cuts down on some copy paste.

I also reverted PDA's ringer being off preventing messages from being
sent to your chat, silent mode was meant to prevent only the ringing
sound.

## Why It's Good For The Game

pAIs can now do a little bit more to help their owners on a personal
level, and adds support for more stuff like this in the future (an idea
I had was being able to hack into PDAs in the same way the CE can hack
into APCs remotely)

This is a re-PR of https://github.com/tgstation/tgstation/pull/76445 but
it's a little better this time and does not remove the PDA Messenger app
from pAIs.

## Changelog

🆑
fix: PDAs being on silent no longer prevents PDAs from being sent to
your chat, again.
add: pAIs inserted into a PDA can now control the PDA, and will receive
PDA messages sent to it (and can respond under the PDA's name).
/🆑
2023-09-04 17:32:52 +01:00
DrTuxedo
a49b804ab3 Better alert/announcment sounds and Status displays (#78047)
## About The Pull Request
**Simplified version of #72179**

### SOUNDS

Changes next sound files:
- airraid.ogg
- bloblarm.ogg
- alert.ogg

Adds next sound files:
- notice3.ogg
- announce_syndi.ogg

Now `announce.ogg` plays when a Captain joins round, and
`announce_dig.ogg` for Requests Console announcements.
The `announce_syndi.ogg` plays when an announcement is made through an
emagged communications console. It also plays when the evacuation
shuttle is fully hijacked or Cultists fully corrupt the evacuation
shuttle.
You can listen to them all here:


https://github.com/tgstation/tgstation/assets/42353186/10c5e597-6db7-464a-b693-f5a2672dc3d0

_All of the sound files are either made by me from existing sounds in
the game or taken from freesound.org and properly credited._

### STATUS DISPLAYS
Status displays are fully replaced with the addition of a few new ones.
<details>
<summary>Status display monitor</summary>


![monitor](https://github.com/tgstation/tgstation/assets/42353186/3ad61a98-d4c7-47da-9107-b39a2fcedace)

![logo](https://github.com/tgstation/tgstation/assets/42353186/38f48aa9-1451-46c0-bccb-7f61d8aa6731)

</details>
<details>
<summary>Misc displays</summary>


![biohazard_big](https://github.com/tgstation/tgstation/assets/42353186/54204671-308b-4a0d-b6a1-a91ad6014eec)

![lockdown_big](https://github.com/tgstation/tgstation/assets/42353186/5d603daa-75b3-4390-a5df-2f6546d66bbf)

![radiation_big](https://github.com/tgstation/tgstation/assets/42353186/d77c5ff6-4a3b-46de-91ad-b3da7326f8b2)

</details>
<details>
<summary>Alert displays</summary>


![greenalert_big](https://github.com/tgstation/tgstation/assets/42353186/adc96267-c722-46e5-8e55-1998860e1c30)

![bluealert_big](https://github.com/tgstation/tgstation/assets/42353186/9a4d2da7-c29a-4987-8333-b2041b0ccb42)

![redalert_big](https://github.com/tgstation/tgstation/assets/42353186/427d4fed-19a2-49c1-86fe-d04c25f0417d)

![deltaalert_big](https://github.com/tgstation/tgstation/assets/42353186/72717e79-bb04-4961-ab06-baf714924139)

</details>

Now the communications console Status Display menu replaced the "Red
Alert" display option with the "Current Alert" which showcases the
current alert display.
Also, the Status Display menu has an additional "Radiation" display
option.
## Why It's Good For The Game

I believe this Pull Request is a good game for a couple of reasons:

1. It better conveys the gravity of emergency situations, such as Code
Red, by utilizing a more intimidating and recognizable sound. This gives
more weight to these situations, making them feel more urgent and
important in the game. Players always tend to not notice that it's in
action.
2. The replacement of the old and outdated Status Display sprites with
newer, more eye-catching ones is a great improvement. This helps to
emphasize the importance of emergency situations even further by making
them more noticeable. Status Displays was one of the last wall-mounts
using ancient sprites.
3. The Captain's arrival using another sound effect from other
announcements gives more status to the Captain as the ultimate head of
the station.
4. Heads announcement using `announce_dig.ogg` makes the sound itself
more used outside of SM cascade, and also makes Head announcements more
noticeable.
5. Emagged console using `announce_syndi.ogg` making Traitor
announcements more noticeable. Also, it is played after evac shuttle is
fully hijacked or corrupted by Cultists giving a more ominous effect
## Changelog
🆑
sound: Adds/modifies next sound files: airraid.ogg, bloblarm.ogg,
alert.ogg, notice3.ogg, announce_syndi.ogg
sound: Code Red, Delta, and other extreme emergencies now possess more
unique alarm sound effect
sound: Captain's arrival now is announced by Captain's announcement
sound, but not for Acting Captain's
sound: Making Captain announcement through emagged console; hijacking or
fully corrupting evacuation shuttle now plays more ominous sound
sound: Making announcements through Requests Console now plays a more
noticeable sound
image: Status Displays sprites have been fully changed. Now they include
displays for every Security Level
qol: The "Red Alert" button in the Communications console status display
menu has been replaced with a "Current Alert" button showing the current
station Security Level display on Status Displays
qol: Communications console status display menu got a new "Radiation"
button which shows radiation symbol on Status Displays
/🆑
2023-09-03 06:10:41 +02:00
distributivgesetz
1837a5f393 [NO GBP] Add some istype guards to the PDA messenger's get_messengers proc (#78070)
## About The Pull Request

Read title, not having these checks can knock out the messenger for
everyone for the entire round
## Why It's Good For The Game

I didn't think about hard deletes in my original NT Messenger PR, and as
far as I know this hasn't happened on this codebase yet.
However this PR doesn't only help downstreams that struggle with hard
deletes, it also implements some pretty critical guards as not having a
messenger for an entire round is pretty bad and sometimes hard deletes
are very hard to track and fix, so it could potentially break the
messenger for a lot of rounds.
2023-09-02 18:25:10 +01:00
John Willard
17e16ad0c2 Replaces Camera bug with Camera tablet app (#77713)
## About The Pull Request

Replaces the Traitor's Camera Bug item with an application that allows
you to view camera apps.
The difference between this app and the Security one is that it does not
have an access requirement, does not make noise (it didn't previously
due to a bug, fixed in this PR), and can be installed on PDAs.
This can also be installed from syndienet, which means nukies now have a
way to see the station cameras while off the ship.

Adds Syndicate app disks, which are made of Gold. This is only used by
the Camera app as of right now.

I also fixed some issues along the way;
- Camera tablet app now properly shows cameras
- It now properly makes the noises it is supposed to
- It clears the viewers properly on the ui being closed or the app being
exited.

Syndicate app disks ddelete their apps upon being transferred over (like
maintenance disks), trying to remain consistent with previous behavior.

I also made this for a [personal project I am currently working
on](https://hackmd.io/XLt5MoRvRxuhFbwtk4VAUA). I could just make this UI
be TGUI, but I thought it could be worth trying to turn it into a better
item first.

Tracking people is much simpler now- You choose anyone from a list of
people found on cameras, and it will try to find a camera that sees
them. It follows them until you close the app or switch camera.

https://github.com/tgstation/tgstation/assets/53777086/1536ebb9-0c4f-45bb-b593-f98791ea6d23

## Why It's Good For The Game

The Camera Bug is one of the worst traitor items as of current. You can
remotely shut off a single camera, something that can be done with basic
tools you are likely carrying around anyways, and uses an HTML clunky UI
to flip through cameras.
This new Traitor item makes it much easier to use, since the camera
consoles are something you are likely already used to.
It also means emagging a tablet is slightly more useful, and golden data
disks are pretty cool.

Unfortunately this means that they no longer grant illegal tech, because
otherwise you can simply clone the app infinitely for personal use, and
deconstruct the disk itself for tech. This can be grinded into gold, but
I think if we want an illegal tech item, it'll have to find a new host.

Closes https://github.com/tgstation/tgstation/issues/74839
Closes https://github.com/tgstation/tgstation/issues/39975
Closes https://github.com/tgstation/tgstation/issues/53820

## Changelog

🆑
balance: The Traitor's Camera bug is now a tablet app that works like a
silent camera console with an extra ability to track people through
their nearby cameras.
/🆑
2023-08-23 21:09:28 +12:00
Zephyr
3923814194 PDA Messages are once again shown to non-observing dead mobs (#77750)
Current implementation uses isobserver for checking if we should send to
the player but dead players (who are still in their body) are not
observers and will fail that check.
2023-08-22 01:17:43 +00:00
John Willard
78e96f2f12 Reworks how AI tracking is handled & reorganizes it (#77776)
## About The Pull Request

Completely reworks how AI tracking is handled, this has no in-game
effects.
This moves nearly all AI tracking handling onto ``/datum/tracking``,
which previously was pretty bad. I tried documenting as much as I can,
making comments actually useful and give accurate information.

Turns ``get_camera_list`` into a global proc, which we now use for
camera consoles (including the app), cutting down on copy paste in 2
areas and standardizing its behavior/backend.

## Why It's Good For The Game

I wanted to generalize this behavior so I can use it for tracking
players in https://github.com/tgstation/tgstation/pull/77713 - This
helps me do that.
Also the current state of AI tracking code is pretty poor and hopefully
this improves that area.

Closes https://github.com/tgstation/tgstation/issues/42355

## Changelog

🆑
refactor: AI's player-tracking eyes received an unwanted obligatory
update, and should now not tell you that a player is untrackable when
they clearly obviously can be.
/🆑
2023-08-21 12:59:28 +00:00
Bloop
ed8445a312 Adds sanity checking to prefs checks, fixing a bug that can cause emotes to stop displaying intermittently (#76946)
## About The Pull Request

This PR adds a bunch of sanity checking to the `prefs.chat_toggles` var
accesses.

Prefs can be null when client is creating/deleting and this causes a
runtime where you might not be able to use emotes.


![image](https://github.com/tgstation/tgstation/assets/13398309/d89649d4-19c7-439f-b080-332709196505)

EDIT: as per suggestion I stopped masking the issue and added stack
traces instead. And made them into helper procs to avoid code
duplication.

For some of these procs it is important that we are able to continue
running to get to the end. **A ghost having null prefs should not stop
everyone else from hearing/seeing the emote.**

So now they will put the stack trace and keep on trucking if that issue
occurs. This is the main 'point' of the PR, which has seemingly gotten
bogged down in the creation of the two helper procs--apologies.

See https://github.com/tgstation/tgstation/pull/70404 for essentially
the same issue but applied to chat messages. I have gone back and
replaced the duplicated code from that to use the new helper procs
instead.

## Why It's Good For The Game

Anything chat related is a bad place to runtime. Some messages can take
a while to type out and to have it not display is frustrating at worst,
possibly detrimental if you have to communicate something urgently.

## Changelog

🆑
fix: fixes a bug that can cause emotes to stop working if a client is
being created or deleted
/🆑
2023-08-14 22:30:35 +02:00
GoldenAlpharex
43d63c399f Fixes the formatting for ghost PDA messages (#77590)
## About The Pull Request
It was in all bold, now it no longer is. It also was only being
displayed to dedicated observers, which means that it didn't show to
players that died and ghosted out.


![image](https://github.com/tgstation/tgstation/assets/58045821/8f00197e-1911-461f-a819-7debb0f622e2)


## Why It's Good For The Game
It's just much nicer, and looks like it used to look before, rather than
being entirely bold.

## Changelog

🆑 GoldenAlpharex
fix: The formatting on PDA messages displayed to observers is now back
to what it used to be, rather than being all bold.
fix: PDA messages are now displayed to observers from dead players, and
not just dedicated observers.
/🆑

---------

Co-authored-by: distributivgesetz <distributivgesetz93@gmail.com>
2023-08-14 21:28:12 +02:00
distributivgesetz
ebbc45b161 Improved PDA Direct Messenger (#75820)
## About The Pull Request

Fixes #76708, Closes #76729 (sorry Zephyr)

This PR expands the Direct Messenger UI, adding a chat screen for each
available messenger that you can find, and moving message sending over
to TGUI.

This chat screen includes a message log that displays messages sent by
you as well as messages received from the recipient. This gets rid of
the previous chat log, which just had all messages thrown together that
you received or have sent, in one big list.

Furthermore, all messaging is now done inside the UI. This kills all
TGUI popups you would ever need to send messages forever (except for
quick replies). Use the input bar on the bottom, press Enter or the Send
button, and it sends your message. Spam mode is now done in the UI too,
via a text field you can find in the contacts list.

Additionally, because I have a habit of blowing things massively out of
scope, I've also completely refactored how messages and chat logs are
stored in the PDA messenger. I plan on using this in a PR that merges
the chat client with the messenger, sometime in the future. Sorry this
took so long.

Stuff left to do before I open this PR for review:
- [x] Add "recent messages"
- [x] Add "unread messages"
- [x] Add message drafts
- [x] Make photo sending not shit
- [x] Implement the edge cases for automated and rigged messages
- [x] Make sure shit isn't fucked
- [x] Profit

<details>
  <summary>Screenshots</summary>
  

![dreamseeker_HIrEfrap5X](https://github.com/tgstation/tgstation/assets/47710522/97c713b7-dda3-44d3-a8f5-d0ec11c92668)

![qIOWhVld4l](https://github.com/tgstation/tgstation/assets/47710522/3ab4e2c1-a38f-4b20-8e9f-509ea14c0434)

![dreamseeker_LIqwi05i4O](https://github.com/tgstation/tgstation/assets/47710522/c051c791-b595-4166-a4d3-82cb7568411f)

![BIYxNVjGL7](https://github.com/tgstation/tgstation/assets/47710522/b9c97eab-52b5-449f-b00f-a0d8aa5f865c)

![dreamseeker_IWdoSsUinC](https://github.com/tgstation/tgstation/assets/47710522/2a4cd76a-2bdc-4283-b642-09e92476fef5)

![L9DxzFHDEF](https://github.com/tgstation/tgstation/assets/47710522/6a5b0e29-d535-4c7e-a88e-e9b71198719b)

![rAuDgqBLNE](https://github.com/tgstation/tgstation/assets/47710522/128a0291-91da-4f9e-9bc5-a65cf411ea6d)

![dreamseeker_voui6S8MUf](https://github.com/tgstation/tgstation/assets/47710522/6e3ba044-b8df-492d-b58d-6c73ab07233d)

![image](https://github.com/tgstation/tgstation/assets/47710522/522c1d85-b9cf-4e0e-9588-9d3993eea03f)

</details>

## Why It's Good For The Game

The UI has largely stayed the same since modular tablets were added a
year ago. Even better, direct messaging has been the same since PDAs
were first added *more than a decade ago*. Imagine that.

Now we finally actually (!) make use of those brand new features that we
got from the TGUI switch in this regard.
## Changelog
🆑 distributivgesetz
add: Updated Direct Messenger to v6.5.3. Now including brand new
individual chat rooms, proper image attachments and a revolutionary
message input field!
add: Added a "Reset Imprint" option to the PDA painter.
refactor: Refactored PDA imprinting code just a bit.
fix: PDAs should now properly respond to rigged messages.
/🆑

---------

Co-authored-by: Jeremiah <42397676+jlsnow301@users.noreply.github.com>
2023-08-03 14:43:31 -07:00
Ghom
5ff475afbc Sets a saner length limit to ID assignments and paintings' titles. (#76723) 2023-07-27 05:31:53 -04:00
MrMelbert
8850e657fa Dehardcodes HR core blacklist (#77075)
## About The Pull Request

Alternative to / closes #77069 

Their PR reminded me I wanted to de-hardcode this list at some point and
make it rely on a flag set on the jobs. So this pr does that.

I also made a combination flag of the flags copied across all station
jobs. Makes it easier to see at a glance which jobs have a unique flag
set and which are just copied across everything.

## Why It's Good For The Game

Makes it more maintainable for future us / downstreams to add new jobs
which may potentially be in this blacklist.

## Changelog

🆑 Melbert
fix: Prisoner slots can no longer be controlled by Plexagon HR Core.
(special things to distributivgesetz)
fix: HoPs can open more assistant job slots if a non-assistant job is
the overflow role
code: Dehardcode the HR core blacklist for jobs which cannot have more
slots opened by the HoP
/🆑
2023-07-25 15:07:42 -06:00
John Willard
e55c077b8c Clear PDAs now specify they are a crystal PDA in messenger (#76675)
## About The Pull Request

When you say "sent from my PDA" in messenger, if it's through a clear
PDA, it will instead say "Sent from my Crystal PDA". This is so the
recipient knows they are in the presence of a crystal pda.

## Why It's Good For The Game

Bragging rights for having a crystal PDA. Minor interaction I think
would be funny.

## Changelog

🆑
add: The 'Sent from my PDA' message is different for Clear PDAs now
(specifying they are crystal).
/🆑
2023-07-16 01:14:28 +01:00
Zephyr
f71ea26f72 Machine list is now stored in SSmachines | Remove excessive use of global lists for specific machine types (#76822)
## About The Pull Request

Removes all of the duplicate global lists for specific machine types
where the only thing they do is store all machines of that type.
Adds machine tracking to SSmachines in the form of a list for all
machines, and then an associative list for machines by their type.
Previously we have machines in multiple global lists, such as airlocks
being in GLOB.doors, GLOB.airlocks, GLOB.machines.
This makes that not a thing, and also means that iterating through
GLOB.machines looking for a specific type is no longer as expensive.
2023-07-15 16:17:46 -04:00
John Willard
ee78ceea95 Clear PDA now has all themes (#76674)
## About The Pull Request

Gives all themes to clear PDAs

## Why It's Good For The Game

Clear PDAs are found/purchased late into a round and theme apps would
generally already be found and installed in PDAs. This means there's
nothing left to install in the crystal PDA, so instead I thought why
shouldn't they just get all themes?

## Changelog

🆑
qol: Clear PDAs now has all themes in their themify app by default.
/🆑
2023-07-10 18:26:22 +01:00
LemonInTheDark
0b29e77985 Adds user feedback for going over order limits in cargo console (#76344)
## About The Pull Request
This'll prevent weird "above the max by accident" cases, and also uses
defines instead of hardcoded stuff. This code is often duped, wish we
had a better way of handling it.

Oh also removes a few safety copies before for loops that aren't
actually needed (for x in list copies the list)

## Why It's Good For The Game

Better UX, slightly saner code
2023-07-05 18:26:56 -06:00
MrMelbert
a036da78c8 Small security / code passover for radar mod pc program (#76299)
## About The Pull Request

I saw this line "randomly" and thought "well that can't be safe" 


971fbf9362/code/modules/modular_computers/file_system/programs/radar.dm (L67-L68)

So I went through and added a sanity check for it to ensure it's only
getting passed `ref`s being tracked in the objects list

This accompanied some general code improvements

## Why It's Good For The Game

Just some extra safety
Some of these apps do a follow up check that the selected ref is a valid
ref to track, but not all of them (notably the Fission 360). It's
unlikely this can be abused but it's good to have

## Changelog

🆑 Melbert
qol: Scanning apps (Lifeline app) start with a scan
fix: Fixes a potential exploit in radar apps
/🆑
2023-06-27 20:36:40 -06:00
John Willard
8229972398 Tablet apps are now deleted when necessary & removes console preset. (#75863)
## About The Pull Request

Apps now properly delete themselves when removed, so they don't exist in
nullspace anymore.
Chat client now actually updates the uid, because its New() didn't call
parent.
Deletes the 'console' subtype of modular computer
Updates how downloading and transferring files are handled
Fixes being able to infinitely upload apps to a disk

## Why It's Good For The Game

Fixes some more bugs I found with apps and prevents spamming apps in a
disk.

## Changelog

🆑
fix: Maintenance data disks now properly transfer from PC to disk
fix: Disks can no longer be flooded with the same app repeatedly.
/🆑
2023-06-19 22:59:09 -07:00
Pepsilawn
dcbe081f64 Cannot use departmental budget cards as source of credit withdraw (#76113)
Currently you can put cargo's budget card into your PDA, go into NT Pay
and send over the budget to any pay token you want including yours. This
just adds a check to ensure you aren't using that kind of card as
withdrawal source.
2023-06-18 08:18:20 +00:00
jimmyl
b0aa56e4cb ""Fixes"" Siliconnect log UI updating (#75890)
i dont think borg logs are static why are they in static update
changes them to normal ui update
2023-06-15 04:00:58 +00:00
LemonInTheDark
ae5a4f955d Pulls apart the vestiges of components still hanging onto signals (#75914)
## About The Pull Request

Signals were initially only usable with component listeners, which while
no longer the case has lead to outdated documentation, names, and a
similar location in code.

This pr pulls the two apart. Partially because mso thinks we should, but
also because they really aren't directly linked anymore, and having them
in this midstate just confuses people.

[Renames comp_lookup to listen_lookup, since that's what it
does](102b79694f)

[Moves signal procs over to their own
file](33d07d01fd)

[Renames the PREQDELETING and QDELETING comsigs to drop the parent bit
since they can hook to more then just comps
now](335ea4ad08)

[Does something similar to the attackby comsigs (PARENT ->
ATOM)](210e57051d)

[And finally passes over the examine
signals](65917658fb)

## Why It's Good For The Game

Code makes more sense, things are better teased apart, s just good imo

## Changelog
🆑
refactor: Pulled apart the last vestiges of names/docs directly linking
signals to components
/🆑
2023-06-09 06:14:31 +00:00
LemonInTheDark
cb4a836d41 Removes all uses of text() (#75766)
## About The Pull Request

Apperantly it's deprecated. Also people misunderstand how to use it,
which leads to silly looking code and redundant wraps.

It is potentially useful to do a sort of format style string embedding,
but we don't have anything that really warrents it IMO.

## Why It's Good For The Game

Maybe byond will break on version upgrade slightly less now.
Also the code's less cluttered, and boomer posting has been excised.


![image](https://github.com/tgstation/tgstation/assets/58055496/c630e522-962c-4344-80f7-36d5df00a8b5)

![image](https://github.com/tgstation/tgstation/assets/58055496/f4cb3eb5-f07f-4489-8813-f59b19406bda)

![image](https://github.com/tgstation/tgstation/assets/58055496/6df7eb62-dae8-43b5-a511-1130ab4a2870)
2023-06-01 16:13:33 -04:00
Profakos
fe27d3198e Cargo category cleanup (#75374)
## About The Pull Request

I accidentally discovered that when #55504 removed cargo export
categories being a thing during export value evaluation, in two
instances, they forgot to remove passing over the now defunct export
categories, causing it to be passed in as the elasticity value, and by
sheer coincidence, this was not causing problems (due to being overriden
by a named argument in the pirates case, and cargo_exports being
evaluated as true in another).

This PR fixes the arguments, preventing possible bugs in the future.
This also removes the code that set if the cargo shuttle could sell
contraband and emagged items, as that is no longer a thing. I talked
with @ArcaneMusic about this, and they agreed, albeit with the caveat
that if someone finds a good use case for this feature, it could be
saved.

This PR also autodocs several export related files, and cleans up
various single and two letter vars.

## Why It's Good For The Game

Cleaner code, unused code removed.

## Changelog

🆑
code: cleaned up cargo export code a bit
/🆑
2023-05-12 20:43:00 -06:00
John Willard
4ffef6be6d Fixes issues with closing apps on tablets (#75117)
## About The Pull Request

- Fixes background apps not reloading the UI
- Standardizes opening/closing/backgrounding apps
- Simplifies the way apps are closed instead of having 2 procs, one on
the PC and one on the program, being named the same thing (wtf)
- Removes program states. They existed so computers can know to update
their UI every process tick, but since we now do this event based, this
is no longer needed, which is good.
- Replaces the 'forced' arg from kill_program as it was completely
unused, with ``reload_ui``, which is now used to open the UI on close,
and not to when we don't want it to.
- Closing background apps no longer reloads the entire UI
- Responding to an NT Message will no longer open the UI on your face.

## Why It's Good For The Game

Closes https://github.com/tgstation/tgstation/issues/75046
Closes https://github.com/tgstation/tgstation/issues/75108

Makes tablet UIs more responsive and lag less, not checking if a program
is closed every process to close it, and makes responding to messages
not a hassle every time.
Also makes the code easier to understand/read,

## Changelog

🆑
fix: Tablets' minimize apps feature works again.
/🆑
2023-05-06 01:56:14 -07:00
John Willard
1c4166c81c Tablet UI update (mostly fixes) (#74844)
## About The Pull Request

Tablet UIs are now changed when opening/closing an app, instead of
constantly checking for a UI change every ui update.

Program UI acts no longer call parent, as it was unnecessary, Computers
are the ones that should be calling it.

Fixes a ton of problems with static data not updating, such as in
Messenger, ID management, Siliconnect, and Chat client

Chat Client's Admin mode also works again, which was broken when
accesses to check was turned into a list.

Turns a few lists in Robocontrol into static ones when we aren't
changing anything, and makes it actually scan your ID's access.

Fixes budget ordering being unable to show the cart/call the cargo
shuttle.

## Why It's Good For The Game

While I can't seem to find a single issue report on any of the above,
these are still problems that should be fixed.

## Changelog

🆑
fix: SiliConnect can download borg logs again.
fix: The RD can once again enable Admin mode on Wirecarp
fix: NT IRN can once again see the shopping cart and call the cargo
shuttle.
fix: Chat Client, ID Management and Messenger should now update their
UIs properly.
code: PDAs will hopefully not lag as much when clicking on buttons (such
as in ID management).
/🆑
2023-04-26 23:29:20 -06:00
Gear
ef959b28d2 Relocate alarm monitor display update code to the signal handler instead of process tick (#74824)
## About The Pull Request
This very simply makes alarm monitor UI and icon updates event based
instead of updating them with the processing loop.
The original proc also included unnecessary conditionals, these have
been worked out.
## Why It's Good For The Game
Instead of updating alarm monitors every single program tick, we could
instead update them only when alarms actually update. This improves
responsiveness for when alarms go off (we don't wait for the next
program tick and instead update immediately), and prevents us from
running unnecessary conditionals and icon updates.
## Changelog
🆑
code: Update active alarm monitor computers only when alarms are
actually changed instead of every program tick
/🆑

---------

Co-authored-by: Gear <gear@gear.is>
2023-04-20 17:21:37 -06:00
Iamgoofball
1acbfb5d52 Improves the immersion on PDA messages (#74721)
🆑
fix: PDA messaging is now more immersive based on age
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
2023-04-17 18:57:27 -07:00
oranges
4c48966ff8 Renames delta time to be a more obvious name (#74654)
This tracks the seconds per tick of a subsystem, however note that it is
not completely accurate, as subsystems can be delayed, however it's
useful to have this number as a multiplier or ratio, so that if in
future someone changes the subsystem wait time code correctly adjusts
how fast it applies effects

regexes used

git grep --files-with-matches --name-only 'DT_PROB' | xargs -l sed -i
's/DT_PROB/SPT_PROB/g'
git grep --files-with-matches --name-only 'delta_time' | xargs -l sed -i
's/delta_time/seconds_per_tick/g'
2023-04-11 21:31:07 -07:00
Pinta
4bca7fc729 (Fix) The crew manifest now properly updates after ID modifications. (#74518)
## About The Pull Request
This PR makes it so that the access modification program now updates the
crew manifest once the inserted ID is ejected. Additionally, when the ID
trim is changed, the manifest is updated.
## Why It's Good For The Game
Demoted heads would still show up on the manifest as their job
pre-demotion, this fixes that.
## Changelog
🆑
fix: The crew manifest now properly updates after ID modifications.
/🆑
2023-04-05 22:23:23 -06:00
san7890
ccef887efe Lints Against Unmanaged Local Defines (#74333)
# MAINTAINER - USE THE BUTTON THAT SAYS "MERGE MASTER" THEN SET THE PR
TO AUTO-MERGE! IT'S MUCH EASIER FOR ME TO FIX THINGS BEFORE THEY SKEW
RATHER THAN AFTER THE FACT.

## About The Pull Request

Hey there,

This took a while to do, but here's the gist:

Python file now regexes every file in `/code` except for those that have
some valid reason to be tacking on more global defines. Some of those
reasons are simply just that I don't have the time right now (doing what
you see in this PR took a few hours) to refactor and parse what should
belong and what should be thrown out. For the time being though, this PR
will at least _halt_ people making the mistake of not `#undef`ing any
files they `#define` "locally", or within the scope of a file.

Most people forget to do this and this leads to a lot of mess later on
due to how many variables can be unmanaged on the global level. I've
made this mistake, you've made this mistake, it's a common thing. Let's
automatically check for it so it can be fixed no-stress.

Scenarios this PR corrects:

* Forgetting to undef a define but undeffing others.
* Not undeffing any defines in your file.
* Earmarking a define as a "file local" define, but not defining it.
* Having a define be a "file local" define, but having it be used
elsewhere.
* Having a "local" define not even be in the file that it only shows up
in.
* Having a completely unused define*

(* I kept some of these because they seemed important... Others were
junked.)
## Why It's Good For The Game

If you wanna use it across multiple files, no reason to not make it a
global define (maybe there's a few reasons but let's assume that this is
the 95% case).

Let me know if you don't like how I re-arranged some of the defines and
how you'd rather see it be implemented, and I'd be happy to do that.
This was mostly just "eh does it need it or not" sorta stuff.

I used a pretty cool way to detect if we should use the standardized
GitHub "error" output, you can see the results of that here
https://github.com/san7890/bruhstation/actions/runs/4549766579/jobs/8022186846#step:7:792
## Changelog
Nothing that really concerns players.

(I fixed up all this stuff using vscode, no regexes beyond what you see
in the python script. sorry downstreams)
2023-03-29 10:17:03 -07:00
John Willard
05efe0b872 Curators now have D-notice newscaster access, Officers can issue warrants (#74269)
## About The Pull Request

Newscasters now have Library access for handing out D-Notices, and
Security access for Wanted issues, instead of both being tied to Armory
access.

Also allows Ntos Newscaster to work if ran by someone without Library
access, so Curator can download the app for others if they want.

## Why It's Good For The Game

- Newscasters have turned into one of the Curator's largest gameplay
aspects and it would be nice if they were able to moderate it as well,
instead of being the Warden who has absolutely no interest in
Newscasters.
- Allowing Officers to send out Wanted issues is more just in hopes it
will result in it being used more, though it seems like a very similar
feature to the wanted posters, maybe we can merge these two together one
day.
- The Ntos Newscaster access change is more of an oversight, I like it
when people can download apps for eachother as it gives a reason to seek
others and lend them your PDA for an application you want, blocking the
person from using the app after getting a Curator to download it for
them kinda sucks in-game.

## Changelog

🆑
balance: Curators/HoP can now manage Newscaster D-Notices (previously
was Warden/HoS).
balance: Security Officers/Detectives can now issue Wanted notices on
Newscasters.
balance: Ntos Newscaster now requires Library access only to download,
not to run.
/🆑
2023-03-28 12:12:48 +01:00
John Willard
3e41388e20 Removes networks from the game (#74142)
## About The Pull Request

This is a continuation of
https://github.com/tgstation/tgstation/pull/74085 - I announced in the
comments there that this would be my next PR, and this is it.

Removes SSnetwork, ``/datum/ntnet``,
``/datum/component/ntnet_interface``, ``var/network_root_id``, the
network unit test, and a lot of other things related to networks.

- NTNet circuits now check for an Ntnet relay, and uses signals to
operate.
- Logs in Wirecarp is now only for PDA and Ntnet Relay things, so you
can no longer see what ruins exist using it (why should Wirecarp know
that Oldstation spawned? The flavor is that they dont know its there).
- Removed it from MULEbots entirely, I don't think it even did anything
for them? Botkeeper seems to work without it, so it's possibly there
from pre-tgui PDAs.
- Moves assigning random names to a base proc instead of being tied to
network, this is things like random-naming scrubbers/vents. The behavior
hasn't changed at all.
- Makes Ntos work for consoles when relays are down, as the comments
said they're supposed to (because they're wired). I think this was an
accidental change on my part, so this is a revert of that.

## Why It's Good For The Game

Ntnet is ancient code that hasn't given us much that we can't do with
already existing alternatives, we've been slowly moving away from it for
init times, and though a large portion of that was limited to airlocks,
I still don't think this is a system worth keeping around.
It's way too complex to expect feature coders to do anything with it,
and too old with better alternatives for anyone to want to improve any
of it.

## Changelog

🆑
fix: Computers are now properly connected to Ethernet, and can use Ntos
when Relays are down.
refactor: Removes Ntnet and Ntnet interfaces, which was only used by
Ntnet circuits (which now directly checks for a Relay to work) and
MULEbots, which did nothing with it.
balance: Wirecarp no longer tells you what ruins spawned in a round,
instead it's limited to PDA logs, and tells you the source too. This
means the RD can catch someone running illegal programs if they don't
make any attempt at hiding it.
qol: Wirecarp logs is now set to save 300 at once, instead of 100 and
being increased to 300 by the RD during the round. This is pretty
insignificant, since there's no reason to NOT want as many logs as
possible.
/🆑

---------

Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com>
2023-03-26 03:02:28 -07:00
John Willard
4462f4d5be Removes more NTNet from Tablets and removes a ton of dead code (#74085)
## About The Pull Request

Removes NtNet softwaredownload/communication because they did nothing,
so this also removes the feature to shut them off from Wirecarp

I removed tablets from being added to networks, Tablets already generate
logs for actions they do, which is already enough for the effects it has
in-game (just being visible to Wirecarp), once NtNet is deleted from
everything else then we can move it to ModPCs and limit logging to only
ModPC actions.

Fixes shutting off ntnet relays from Wirecarp, now you can properly shut
off Ntnet, and the warning that it kicks you out of the program is now
true.

Gives the Holodeck it's own network root define and fixes Syndicate
network showing up on Wirecarp

Wirecarp's PDA logs now shows the source of an action

## Why It's Good For The Game

Moves ModPCs further from NTNet so we can move towards deleting it
entirely
Makes Wirecarp more responsible and trustworthy
Removes useless stuff that never gets used, simplifying a overthought
overcomplicated system.

## Changelog

🆑
balance: Wirecarp now properly shuts off NtNet remotely.
balance: Wirecarp now shows the source of a PDA that does an action.
fix: Wirecarp can no longer be used to see if Nukies exist through their
networks.
del: Removes Software downloading and communication Ntnet networks, as
they were pretty worthless.
/🆑
2023-03-21 09:50:47 +13:00
MrMelbert
ccc144a08e Fixes malf camera upgrade appearing on security camera consoles (#73970)
## About The Pull Request

Wow that was easier than I thought

Malf AI camera upgrade no longer shows up camera consoles. 
Advanced Camera consoles probably still show it but those are harder to
get so someone else can fix those

## Why It's Good For The Game

It is admittedly very funny to instantly valid a malf ai but probably
not fun

## Changelog

🆑 Melbert
fix: Malf AI's xray camera upgrade no longer shows on station security
camera consoles
/🆑
2023-03-14 17:00:33 -07:00
Antonio Tosti
73172f8836 Re-implements Physical and Mental statuses in crewmember Medical Records (#73882)
## About The Pull Request
These changes re-implement the functionality for Physical and Mental
Statuses, which used to be present in Medical Records (visible via
medical filing cabinents, medical records consoles, and MED-HUDs). These
Physical/Mental statuses can once again be updated through examining a
crewmember (while wearing a Med-HUD), or through the new TGUI interface
for medical records consoles.

## Why It's Good For The Game
Primarily, this resolves the bugs mentioned in [Issue
#73477](https://github.com/tgstation/tgstation/issues/73477), and
restores functionality which appears to have been accidentally removed
via [PR #72725](https://github.com/tgstation/tgstation/pull/72725).
Additionally, the re-implementation of these statuses allows for more
in-depth medical RP (and bureaucracy), especially in regards to the
Psychiatrist role and managing crewmember sanity.

## Changelog
🆑
fix: Re-implements physical and mental statuses in crewmember medical
records.
fix: Re-implements changing a crewmember's physical/mental status via a
Med-HUD.
/🆑

Edit: Image of the new TGUI buttons which now handle Physical/Mental
statuses.

![medical-records-symbols-circled](https://user-images.githubusercontent.com/5588048/224860672-43486b9e-3b71-4ea5-8a71-b86545e08632.png)

Closes #73477
2023-03-13 19:21:55 -06:00
John Willard
5b63228b9a Tablets don't close their UI when changing program (and some fixes) (#73635)
## About The Pull Request

- Tablets now refresh their page when changing programs, this means the
UI will no longer close and reopen itself several times (or even have
several UIs open if shit broke hard enough).
- Removed tablet's attack self because interact already does everything
it had to do.
- Header programs now close when minimized (as there's no button to
close them in the main menu.
- Removed a lot of program UI stuff, it's now handled by the PC itself,
such as header data and ui host.
- Cut off asset sending from TGUI into it's own proc so I can re-send
assets when changing programs
- Added an ejection button for machine computers
- Fixed ID not ejecting into the user's hand when using 'Eject ID'
- Fixes a minor runtime when opening the MODsuit application without a
MODsuit already connected.

## Why It's Good For The Game

Fixes some bugs that I found with tablets

UIS now won't be flickering as bad in front of them, or have
inconsistent placement (like when you move your main menu UI, go to
Messenger, then it's back to the center of the screen).

Video of it in action

https://user-images.githubusercontent.com/53777086/221301417-78321149-0c10-475e-bd29-79f5a4ba0597.mp4

## Changelog

🆑
fix: Being in an application now properly uses the tablet's battery.
fix: Messenger and Themify apps now close when minimized, so don't count
towards the running app limit.
fix: Tablet UIs will now no longer spam open/close the UI when changing
applications
fix: Using the Eject ID button on tablets now ejects into your hand.
fix: Computers now have an Eject ID button
refactor: Cut down a lot of copy paste in tablet & program code, now
it's mostly done by the tablet.
/🆑
2023-03-01 00:16:26 -07:00
Jeremiah
96715a5797 Fixes ui_data on ntosrecords [NO GBP] (#73670)
## About The Pull Request
Missed this while redoing records, this makes it match what the UI is
expecting
## Why It's Good For The Game
Bug fixes
## Changelog
🆑
fix: Fixes NTOS records program receiving bad medical disability data
/🆑

Co-authored-by: Jeremiah <jlsnow301@pm.me>
Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com>
2023-02-27 14:35:24 -07:00
John Willard
ed70994d87 Messenger fixes (#73503)
## About The Pull Request

- Photos now show up in the chat to the person recieving them as a
(Photo) like how it used to be
- Outgoing messages now properly say who it's outgoing to, instead of
saying it's to themselves.
- Messenger now clears photos after sending an image with them, so you
don't accidentally send the same photo 50 times.
- AIs can now send an image from the messenger menu (code stolen from
https://github.com/BeeStation/BeeStation-Hornet/pull/7550)
- Added a balloon alert when you uploaded a photo so it doesn't just
silently pass and you have no idea if it worked or not.

## Why It's Good For The Game

Closes https://github.com/tgstation/tgstation/issues/70140 - an issue
report I've had open for months and kept procrastinating on working on.
Closes https://github.com/tgstation/tgstation/issues/70264

Messenger now properly works as it was originally supposed to.

## Changelog

🆑 JohnFulpWillard and itsmeow
fix: Messenger now clears photos after you send it, so you don't send a
photo repeatedly until you manually clear it.
fix: Sending a photo now has a hyperlink in chat for the target to see
(like with old PDAs)
fix: AIs can now select photos in their Messenger app.
fix: Messenger no longer says you're sending outgoing messages to
yourself.
/🆑
2023-02-19 14:06:48 -07:00
Profakos
339d4638a9 Fixes revelation program (#73463)
## About The Pull Request

#70678 removed hard drives from the game, and made the files be stored
directly on the computer. However, revelation has not been updated in
this regard. This PR once again makes it delete all files.

In addition, revelation also had a big red button yelling "activate"
that did nothing, and an option in ui_act that said "PRG_activate", that
wasn't used by anything, so I have linked up the two, allowing you to
revelate immediately. This does not feel like a real change, since you
could do this by arming, closing, and then reopening the program.

## Why It's Good For The Game

Fixes #72682

## Changelog

🆑
fix: Revelation once again wipes the stored files on the computer
/🆑
2023-02-17 15:04:37 -07:00
Tim
a1ada2c9ef Refactor, improve, and rename canUseTopic to be can_perform_action (#73434)
This builds on what #69790 did and improved the code even further.
Notable things:
- `Topic()` is a deprecated proc in our codebase (replaced with
Javascript tgui) so it makes sense to rename `canUseTopic` to
`can_perform_action` which is more straightforward in what it does.
- Positional and named arguments have been converted into a easier to
use `action_bitflag`
- The bitflags adds some new checks you can use like: `NEED_GRAVITY |
NEED_LITERACY | NEED_LIGHT` when you want to perform an action.
- Redundant, duplicate, or dead code has been removed.
- Fixes several runtimes where `canUseTopic` was being called without a
proper target (IV drips, gibber, food processor)
- Better documentation for the proc and bitflags with examples
2023-02-16 20:22:14 -05:00
John Willard
c58cbb4dfb Reworked PDA menu & NtOS themes (#73070)
## About The Pull Request

This is a port/rework of
https://github.com/yogstation13/Yogstation/pull/15735 - I changed a lot
of how it acted (some themes are locked behind maintenance apps).

The original author allowed this port to happen, and I really liked how
it looked there so I'd like to add it here.

### Applications

Removes the hardware configurator application, as all it did was show
you your space and battery now that all hardware was removed. These are
things your PC does by default, so it was just a waste of space.
Adds a Theme manager application instead, which allows you to change
your PDA's theme at will.
Adds a new Maintenance application that will give a new theme, however
it will also increase the size of the theme manager app itself as it's
bloatware.

### Menu

There's now a bar at the top of the menu showing 'special' tablet apps
which, for one reason or another, should stand out from the rest of the
apps. Currently this is PDA messenger and the Theme manager

Flashlight and Flashlight color is now only an icon, and is shown on the
same line as Updating you ID


https://cdn.discordapp.com/attachments/961874788706574386/1069621173693972551/2023-01-30_09-10-52.mov


![image](https://user-images.githubusercontent.com/53777086/215501361-5ea3086e-2ff5-4ab1-bde4-8a3d14014fce.png)

### Themes

Adds a lot of themes to choose from, although SOME are hidden behind
Maintenance applications, which will give you a random theme. These are
bloatware however, so they come with some extra cost to the app's
required space storage.

Themes are now supported on ALL APPLICATIONS! If you have a computer
theme, you will have that theme in EVERY app you enter, rather than just
a select few.
ALSO also, emagging the tablet will automatically set & unlock the
Syndicate theme, which makes your PDA obvious but you can disguise it if
you wish through just re-painting it to something else.


https://cdn.discordapp.com/attachments/828923843829432340/1069565383155122266/2023-01-30_05-29-53.mov

### Preferences

This also adds a pref for theme, reworking the ringtone code to work
with it as well. I also removed 2 entirely unused PDA prefs just 'cause.

Screenshot not up-to-date, they now have proper names.

![image](https://user-images.githubusercontent.com/53777086/215463669-0fe9951a-71f8-4b71-a97d-b79b5a2f945a.png)

### Other stuff

Made defines for device_themes
Added support for special app-side checks to download files
Fixed programs downloading themselves TWICE because defines all had the
same definition
Removes the Chemistry computer disk as it was empty due to chemistry
app's removal
Removes the 'run_emag' proc, since apps can directly refer to the
computer to check for emag status instead.
Moved over and added better documentation on data computer files, and
moved the ordnance ones to the same file as the others.

## Why It's Good For The Game

It makes PDAs a lot more customizable while adding more features to
maintenance applications. I think the themes look cool and it fits with
PDAs being "personal" anyways.

I also explained most of my other arguments in the about section, such
as the hardware configuration application.

## Changelog

🆑 Chubbygummibear & JohnFulpWillard
add: A ton of new NtOS themes, which are accessible by the new Themify
application that comes with all PCs.
add: Emagging a PC now defaults it to the Syndicate option (and adds it
to go back to it if you wish)
add: There's a new maintenance app that gives you rarer themes
qol: The NtOS Main menu was moved around, added "header" applications
that are shown where the Flashlight is, such as your Theme manager and
PDA messenger.
code: Made defines for device_themes
code: Added support for special app-side checks to download files
code: Removes the 'run_emag' proc, since apps can directly refer to the
computer to check for emag status instead.
fix: Programs no longer download twice.
del: Removes the Chemistry computer disk as it was empty due to
chemistry app's removal
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
2023-02-17 01:14:24 +00:00
John Willard
4c9c28b58d Fixes modsuit control application (#73071)
## About The Pull Request

Fixes the modsuit control app not properly working

Accidentally caused it in a late commit on maintenance applications

## Why It's Good For The Game

Closes https://github.com/tgstation/tgstation/issues/72980

## Changelog

🆑
fix: the MODsuit control maint app now links up to MOdsuits.
/🆑
2023-01-31 09:45:07 +01:00
John Willard
4fcedc9226 R&D Monitoring console TGUI + Can see RD consoles (#72987)
## About The Pull Request

I wrote this while constantly rushing lol

This PR does many things, the largest is that the R&D Monitoring console
(the RD's one) is now TGUI
It also changes how researching loggings work, bringing the RD console
and NtosRD app on par with eachother

The type of person is also logged differently, instead of ``Cyborg:
[name]`` and ``User: [name]``, humans do not have a prefix and cyborgs
will say ``CYBORG [name]``. ``research_logs`` also works differently now
to make it easier to reference each needed data from the list.

Lastly, I added the ability to see R&D consoles from the console, and
the ability to remotely un/lock them down. This currently is pretty
useless as it can't control the tablet app variant, and anyone with
Science access can just unlock it, however with some minor future
changes I think this can be turned into a good way for the RD to get
control of their department.

Video demonstration, mostly (I made a few edits after this):

https://user-images.githubusercontent.com/53777086/215005387-817106f4-5237-4f2e-b0ac-da28e6a17f9c.mp4

## Why It's Good For The Game

This console is overhyped by the game, being hidden behind an RD-locked
Command-colored door, in the same room as one of the most damaging theft
objectives, yet it is one of the most useless and forgotten consoles in
R&D if you don't count everything outside of researching, experiments
and robotics.

This adds a nice TGUI menu while making it a little more worthwhile to
use.

## Changelog

🆑
balance: The R&D monitoring console now shows R&D consoles and their
locations.
refactor: The R&D monitoring console now has a nice TGUI menu.
/🆑
2023-01-29 10:19:57 -08:00