Files
Bubberstation/code/__DEFINES/modular_computer.dm
SkyratBot 9e981753ca [MIRROR] Reworked PDA menu & NtOS themes [MDB IGNORE] (#19390)
* 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>

* Reworked PDA menu & NtOS themes

---------

Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
Co-authored-by: san7890 <the@ san7890.com>
2023-02-17 00:35:34 -08:00

97 lines
3.6 KiB
Plaintext

//NTNet stuff, for modular computers
// NTNet module-configuration values. Do not change these. If you need to add another use larger number (5..6..7 etc)
#define NTNET_SOFTWAREDOWNLOAD 1 // Downloads of software from NTNet
#define NTNET_COMMUNICATION 2 // Communication (messaging)
//NTNet transfer speeds, used when downloading/uploading a file/program.
#define NTNETSPEED_LOWSIGNAL 0.5 // GQ/s transfer speed when the device is wirelessly connected and on Low signal
#define NTNETSPEED_HIGHSIGNAL 1 // GQ/s transfer speed when the device is wirelessly connected and on High signal
#define NTNETSPEED_ETHERNET 2 // GQ/s transfer speed when the device is using wired connection
//Caps for NTNet logging. Less than 10 would make logging useless anyway, more than 500 may make the log browser too laggy. Defaults to 100 unless user changes it.
#define MAX_NTNET_LOGS 300
#define MIN_NTNET_LOGS 10
//Program bitflags
#define PROGRAM_ALL (~0)
#define PROGRAM_CONSOLE (1<<0)
#define PROGRAM_LAPTOP (1<<1)
#define PROGRAM_TABLET (1<<2)
//Program states
#define PROGRAM_STATE_KILLED 0
#define PROGRAM_STATE_BACKGROUND 1
#define PROGRAM_STATE_ACTIVE 2
//Program categories
#define PROGRAM_CATEGORY_CREW "Crew"
#define PROGRAM_CATEGORY_ENGI "Engineering"
#define PROGRAM_CATEGORY_SUPL "Supply"
#define PROGRAM_CATEGORY_SCI "Science"
#define PROGRAM_CATEGORY_MISC "Other"
#define DETOMATIX_RESIST_MINOR 1
#define DETOMATIX_RESIST_MAJOR 2
// NTNet connection signals
///When you're away from the station/mining base and not on a console, you can't access the internet
#define NTNET_NO_SIGNAL 0
///Low signal, so away from the station, but still connected
#define NTNET_LOW_SIGNAL 1
///On station, good signal
#define NTNET_GOOD_SIGNAL 2
///Using a Computer, ethernet-connected.
#define NTNET_ETHERNET_SIGNAL 3
/// The default ringtone of the Messenger app.
#define MESSENGER_RINGTONE_DEFAULT "beep"
/// The maximum length of the ringtone of the Messenger app.
#define MESSENGER_RINGTONE_MAX_LENGTH 20
///Default NtOS PDA theme
#define PDA_THEME_NTOS "ntos"
#define PDA_THEME_DARK_MODE "ntos_darkmode"
#define PDA_THEME_RETRO "ntOS95"
#define PDA_THEME_SYNTH "ntos_synth"
#define PDA_THEME_TERMINAL "ntos_terminal"
///Emagged/Syndicate NtOS (SyndiOS) PDA theme
#define PDA_THEME_SYNDICATE "syndicate"
//Maintenance-loot themes
#define PDA_THEME_CAT "ntos_cat"
#define PDA_THEME_LIGHT_MODE "ntos_lightmode"
#define PDA_THEME_SPOOKY "ntos_spooky"
//Defines for the names of all the themes
#define PDA_THEME_NTOS_NAME "NtOS"
#define PDA_THEME_DARK_MODE_NAME "NtOS Dark Mode"
#define PDA_THEME_RETRO_NAME "Retro"
#define PDA_THEME_SYNTH_NAME "Synth"
#define PDA_THEME_TERMINAL_NAME "Terminal"
#define SYNDICATE_THEME_NAME "Syndicate"
#define CAT_THEME_NAME "Cat"
#define LIGHT_THEME_NAME "NtOS Light Mode"
#define ELDRITCH_THEME_NAME "Eldritch"
///List of PDA themes that are accessible to everyone by default.
GLOBAL_LIST_INIT(default_pda_themes, list(
PDA_THEME_NTOS_NAME = PDA_THEME_NTOS,
PDA_THEME_DARK_MODE_NAME = PDA_THEME_DARK_MODE,
PDA_THEME_RETRO_NAME = PDA_THEME_RETRO,
PDA_THEME_SYNTH_NAME = PDA_THEME_SYNTH,
PDA_THEME_TERMINAL_NAME = PDA_THEME_TERMINAL,
))
///List of PDA themes that are accessible to everyone by default.
GLOBAL_LIST_INIT(pda_name_to_theme, list(
PDA_THEME_NTOS_NAME = PDA_THEME_NTOS,
PDA_THEME_DARK_MODE_NAME = PDA_THEME_DARK_MODE,
PDA_THEME_RETRO_NAME = PDA_THEME_RETRO,
PDA_THEME_SYNTH_NAME = PDA_THEME_SYNTH,
PDA_THEME_TERMINAL_NAME = PDA_THEME_TERMINAL,
SYNDICATE_THEME_NAME = PDA_THEME_SYNDICATE,
CAT_THEME_NAME = PDA_THEME_CAT,
LIGHT_THEME_NAME = PDA_THEME_LIGHT_MODE,
ELDRITCH_THEME_NAME = PDA_THEME_SPOOKY,
))