Commit Graph

24 Commits

Author SHA1 Message Date
SkyratBot
bad4c9168c [MIRROR] Mafia rebalance and backend refactor [MDB IGNORE] (#20631)
* Mafia rebalance and backend refactor (#74640)

## About The Pull Request

Turns all Mafia abilities into datums, instead of being a bunch of
shitcode on every single job.
This means it's easier to add new roles
Gives new names to some defines (such as the signal order, to make it
easier to tell when something is fired)
Adds support for modular Mafia jobs with their abilities being in a
certain order (Escort is now properly first).
De-snowflakes Changeling killing abilities and day voting, they're now
actions that are tallied when necessary.

Turns time vars into defines
Generalizes a lot of behavior for abilities, now all abilities can
properly undo their action at night

Fixes problems with the UI (Thoughtfeeder had 2 buttons during night and
they overlapped with names, that's been fixed).

### Behavior changes

- Doctor/Officer can now protect themselves 1 night, because it gives
them a way to protect themselves.
- Lawyer/Warden/Ect now choose their abilities at night, rather than the
day before. The suspense building up towards the end of the night is
part of the game, telling you that it happened at the very start is
quite lame (in the case of Lawyer, anyway).
- Admin setup now uses TGUI instead of html inputs.
- Cut night time by like, 5 seconds, because I found it a little long
lol.
- HoP doesn't count as votes to win until they reveal, because it makes
no sense an unrevealed HoP has their unrevealed votes tallied. I also
like those 1v1 Mayor V. Evil scenarios where dead chat goes crazy, and
hope to replicate that here.
- Mafia now needs 6 people to start instead of 4, because 4 players is
just not enough to play a Mafia round that will do anything but annoy
people.
- The game no longer ends if it's in a standoff with 1 Town, 1 Mafia,
and 1 Neutral, as you've got a kingmaker and they should decide who
wins.

### Things I want to change in the future
Every time night starts/ends, it checks the entire ``GLOB.airlocks`` for
doors with the "mafia" ID. This is stupid.
Rework ``check_victory()`` to make it make more sense, and be more fun
for players.
A visible death animation?
I want to use something similar to admin popup for messages about people
being on stand, and decluttering the UI in general
Also more use of balloon alerts instead of to chat messages for
everything.
Also also, making the UI more responsive to players. Button should be
red when a player is selected, so they know that's who they've selected,
if they want to unselect.
Are votes public when you first cast them? They shouldn't be wtf.
Can we also make the description for roles not be a to chat message? It
can just say when you hover over the '?' come on.
User-written wills instead of auto-generated, and able to send them in
chat
Add support for roleblock-immune roles

## Why It's Good For The Game

Updates a lot of old code to modern standards
Makes it considerably easier to work with Mafia and add new roles
Makes things less prone to breaking as easily.
Code also looks a lot cleaner now.

## Changelog

🆑
refactor: [Mafia] All Mafia abilities have been overhauled in the
backend, it's now much easier to understand what each role's ability can
do and how it works.
admin: [Mafia] Admin setup of Mafia is now in TGUI
balance: [Mafia] Doctors/Officers can protect themselves once per game.
Be careful around them!
fix: [Mafia] Thoughtfeeder's UI buttons at night won't overlap with
eachother.
fix: [Mafia] HoP's votes now actually matter, instead of being purely
visual.
qol: [Mafia] Lawyers, Wardens, etc. now perform their night ability at
night, instead of the day prior.
qol: [Mafia] Night time now lasts 40 seconds instead of 45.
/🆑

* Mafia rebalance and backend refactor

---------

Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
2023-04-17 22:00:53 -07:00
SkyratBot
3464b6bfb2 [MIRROR] Refactors Regenerate Organs, and a few organ helpers [MDB IGNORE] (#20094)
* Refactors Regenerate Organs, and a few organ helpers

* MERGE CONFLICTS

* GETORGANSLOT > GET_ORGAN_SLOT

* GETORGAN > get_organ_by_type

* lint repairs

* more lint

* Update tgstation.dme

* Update surgery_step.dm

---------

Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com>
Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
2023-04-01 02:51:06 +01:00
SkyratBot
1132a363ae [MIRROR] Revert "Unit tests radio, saymode, and language prefix keys" [MDB IGNORE] (#17793)
* Revert "Unit tests radio, saymode, and language prefix keys" (#71474)

Reverts tgstation/tgstation#71328 (@ Zonespace27 )

Departmental shorthand (.h/:h) is a convenience alias that should apply
to all jobs and all race types and all classifications. ITS SUPPOSE TO
FUCKING CONFLICT.

if you are ai and not in a holopad, it should go to binary.

if you are ai and in a holopad, it should go to the holopad.

if you are borg it should go to binary

if you are xeno it should go to alien

Removing it from the AI over a stupid need to made universal broad
reaching rules that can be declared upon the code was stupid.

This entire unittest is needlessly overboard and over generic putting
"rules" that are not backed up by logic on the codebase in a way that
hinders making good UX, not help.

The datumized saymode system not being able to handle this complexity
when the old hardcoded system could is a problem with the datumized
saymode system and not the fucking :h shortcut for holopad.

🆑 Common fucking sense
fix: The changes to Mafia and holopad say prefixes was reverted.
spellcheck: Mafia changeling say prefix has no longer been changed to
.1, and has been returned to .j
spellcheck: AI Holopad say has no longer been changed to .2, and has
been returned to .h
/🆑

* Revert "Unit tests radio, saymode, and language prefix keys"

Co-authored-by: Kyle Spier-Swenson <kyleshome@gmail.com>
2022-11-28 06:30:50 +00:00
SkyratBot
93a9440a70 [MIRROR] Unit tests radio, saymode, and language prefix keys [MDB IGNORE] (#17650)
* Unit tests radio, saymode, and language prefix keys (#71328)

## About The Pull Request
This PR unit tests radio/saymode prefixes together, and language
prefixes on their own, for any possible overlaps and duplicates

Moved mafia saymode key to :1 and holopad key to :2, we're running out
of radio keys and i'm too afraid to move to 2-letter

## Why It's Good For The Game
1. Unit tests are good
2. https://github.com/tgstation/tgstation/pull/71326 this is bad

🆑
spellcheck: Mafia changeling say prefix is now :1, and holopad say is
now :2
/🆑

Co-authored-by: Zephyr <12817816+ZephyrTFA@ users.noreply.github.com>

* Unit tests radio, saymode, and language prefix keys

* guild now uses :p

Co-authored-by: Zonespace <41448081+Zonespace27@users.noreply.github.com>
Co-authored-by: Zephyr <12817816+ZephyrTFA@ users.noreply.github.com>
Co-authored-by: Tastyfish <crazychris32@gmail.com>
2022-11-22 13:43:51 -05:00
SkyratBot
ad95183a1e [MIRROR] The Link to the Changeling Hivemind has been Reestablished [MDB IGNORE] (#16551)
* The Link to the Changeling Hivemind has been Reestablished (#70193)

Readds the changeling hivemind, but in a simplified form.

    There is no linglinking. It was rarely used and imma be real with you, stupid.
    Hivemind isn't an unlocked ability, it is just a default.
    Bz still mutes lings
    Fallen changelings now get an agonizing message about being locked out. We love fallen changeling flavor
    Changelings have their Honorific names back! Hello, Mr. Omnicron!
    This does NOT readd changeling team objectives, or really anything encouraging teaming beyond the hivemind itself.

    I think antagonists have generally lost a lot of power versus the station, and this is one big way to pump up the heat for this antag in particular. Changelings, given an ability to possibly team up, are much MUCH scarier.
    One reason it was removed years ago was because teaming was too often, but back then there were entire gamemodes about changelings having team objectives and many other things to encourage it. I'm bringing us back to a point BEFORE all those design ideas were explored, because I don't think they worked out.

Add information about the changeling hivemind, and the dangers of being turned into a fallen changeling if you get betrayed to the Changeling Antag Info UI

Changelog

add: Changelings once again have reestablished their changeling hivemind, and can secretly communicate between each other.
fix: Fixed up the Changeling UI a bit, like for example some dimmers would never render.

* The Link to the Changeling Hivemind has been Reestablished

* Update horror_form.dm

Co-authored-by: tralezab <40974010+tralezab@users.noreply.github.com>
Co-authored-by: Zonespace <41448081+Zonespace27@users.noreply.github.com>
2022-09-29 19:26:41 -07:00
SkyratBot
0a1f06a2d1 [MIRROR] This tail refactor turned into an organ refactor. Funny how that works. [MDB IGNORE] (#14017)
* This tail refactor turned into an organ refactor. Funny how that works.

* Firstly, fixing all the conflicts.

* Fixes all our maps (hopefully)

* Actually, this should fix pod people hair :)

* Almost everything is working, just two major things to fix

* Fixed a certain kind of external organ

* Cleaning up some more stuff

* Turned tail_cat into tail because why the fuck are they separate?

* Moved all the tails into tails.dmi because that was just dumb to have like 3 in a different file

* Adds relevant_layers to organs to help with rendering

* Makes stored_feature_id also check mutant_bodyparts

* Fixes the icon_state names of ALL the tails (pain)

* Fixes wagging, gotta refactor most mutant bodyparts later on

* I Love Added Failures

* Fixed some organs that slipped through my searches

* This could possibly fix the CI for this?

* It doesn't look like it did fix it

* This will make it pass, even if it's ugly as sin.

* Fixed Felinids having a weird ghost tail

* Fixes instances of snouts and tails not being properly colored

Co-authored-by: Kapu1178 <75460809+Kapu1178@users.noreply.github.com>
Co-authored-by: GoldenAlpharex <jerego1234@hotmail.com>
2022-06-11 23:20:16 -04:00
SkyratBot
f42d424b49 [MIRROR] Removes swarmers from the game [MDB IGNORE] (#10645)
* Removes swarmers from the game

* Removes swarmers from the game

Co-authored-by: Jeremiah <42397676+jlsnow301@users.noreply.github.com>
Co-authored-by: Tom <8881105+tf-4@users.noreply.github.com>
2022-01-15 17:19:18 +00:00
SkyratBot
7d74dadd0d [MIRROR] Removes monkey mode, neuters Jungle Fever into Jungle Flu [MDB IGNORE] (#10504)
* Removes monkey mode, neuters Jungle Fever into Jungle Flu

* Fixing the conflict

* There you go one-click antag

* Whoops forgot one

Co-authored-by: tralezab <40974010+tralezab@users.noreply.github.com>
Co-authored-by: GoldenAlpharex <jerego1234@hotmail.com>
2022-01-09 15:42:53 -05:00
SkyratBot
404a603dc2 [MIRROR] runtime fix for borgs cryoing with upgrade modules + no more mmi laying around after they cryo, and various other runtime fixes [MDB IGNORE] (#8975)
* runtime fix for borgs cryoing with upgrade modules + no more mmi laying around after they cryo, and various other runtime fixes

* Fixing conflicts

Co-authored-by: Seris02 <49109742+Seris02@users.noreply.github.com>
Co-authored-by: GoldenAlpharex <jerego1234@hotmail.com>
2021-10-23 00:25:25 +01:00
SkyratBot
7d1d0e1fad [MIRROR] Refactors most spans into span procs (#6315)
* Refactors most spans into span procs

* AA

* a

* AAAAAAAAAAAAAAAAAAAAAA

* Update species.dm

Co-authored-by: Watermelon914 <37270891+Watermelon914@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-06-16 00:24:49 +01:00
SkyratBot
2ab15aecb5 [MIRROR] Remove all gamemodes except Dynamic (#5173)
* Remove all gamemodes except Dynamic

* qaaaaaaaa

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-04-25 21:20:30 +01:00
SkyratBot
1763ebc411 [MIRROR] You can('t) whisper into comms in crit. (#2009)
* You can('t) whisper into comms in crit. (#54970)

* Stops critted people from speaking into the radio.

* Whitelist implementation and removal of unreachable/unused code.

* Woops.

* You can('t) whisper into comms in crit.

* Update living_say.dm

Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
Co-authored-by: Azarak <azarak10@gmail.com>
2020-12-02 23:49:34 +01:00
SkyratBot
68625a452e [MIRROR] Removes changeling teams and hivemind channel (#1503)
* Removes changeling teams and hivemind channel (#54054)

* Removes changeling teams and hivemind channel.

* More cleanup

* some more stuff

* Removes changeling teams and hivemind channel

* Update horror_form.dm

* Update horror_form.dm

* Update horror_form.dm

Co-authored-by: skoglol <33292112+kriskog@users.noreply.github.com>
Co-authored-by: Azarak <azarak10@gmail.com>
2020-10-31 16:29:12 +01:00
SkyratBot
b8d9874c27 [MIRROR] Converts all A && A.B into A?.B (#1292)
* Converts A && A.B into A?.B (#54342)

Implements the ?. operator, replacing code like A && A.B with A?.B

BYOND Ref:
When reading A?.B, it's equivalent to A && A.B except that A is only evaluated once, even if it's a complex expression like a proc call.

* Converts all A && A.B into A?.B

Co-authored-by: ZeWaka <zewakagamer@gmail.com>
2020-10-13 23:19:25 +02:00
tralezab
fd9b5efae7 Mafia: a minigame for ghosts to sign up for while dead (#51788)
* pre-removal of mafia_game_signups

* redoes the whole joining system, start of the role popup datum

* MAPMERGE 💪

* bundle fix + working on a fix

* even more testing

* lobby working, fail text, comments out 2>3 player test setup

* mapmerge

* uhhh maybe?

* updates mafia controls panel

* megafix + megafeature pack

* lint, small fix bundle. should compile after this

* bye test setup

* big changes, no revs yet though

* godmode, why not

* bundle frick off man

* SORRY

* doesn't send rev messages and mafia messages if they don't exist

* removes revs, improves tgui by a shit ton

* mostly mafia panel stuff

* maps + improvements

* disables this map because bugs

* bundle, take that

* Apply suggestions from stylemistake code review

Co-authored-by: Aleksej Komarov <stylemistake@gmail.com>

* 1/2 review

* bad maps gone

* goodbye game ID

* e

* finally done

* voila

* don't forget bundle!

* e

* last commit before i irrevocably BOUNDS myself to death

* Rebuild tgui

Co-authored-by: Aleksej Komarov <stylemistake@gmail.com>
2020-07-06 19:02:45 +03:00
IndieanaJones
0ec9805760 Update saymode.dm 2020-03-06 01:34:33 -05:00
vuonojenmustaturska
fb45b7a017 Turns trait accessors into defines, fixes some bugs (#43820)
It's free performance.
2019-05-06 19:44:05 -04:00
ShizCalev
013a44eed6 resettispaghetti 2018-11-16 13:56:02 -05:00
ShizCalev
d87ee8d293 Changeling messages now use the proper style (#41148) 2018-10-26 17:01:28 -04:00
Patrick Chieppe
2c8248575a Logging system refactor and improvement (#39521)
* Refactor several log lines to use datum_info_line and atom_loc_line

* Add default return strings from datum_info_line and atom_loc_line

* Add parentheses around atom_loc_line data

* Change more logs to use atom_loc_line

* Add check in atom_loc_line for turfs to avoid calling get_turf on them

* Re-add removed 'at'

* Replace datum_info_line with key_name and atom_loc_line with loc_name

* Refactor logging functions

* Avoid double-logging self-interactions

* Fallback to simple stringification if all else fails in key_name()

* Rewrite muscle spasm logging to use log_message

* Standardize logging of martial arts

* Tweak individual logging panel look

* Fix individual logging panel source

* When I typed || I really meant &&

* Fix Telecomms logging always showing client logs in the panel

* Reverts addition of buggy ownership log to panel

* Remove colon

* Fix missing log_directed_talk tag

* Add warning for missing type in log_direted_talk

* Change warnings to stack_traces

* Add square brackets around fallthrough key_name() case to help parsing

* Allow atom arguments/src in log_*() functions

* Change log_combat call with null argument to log_message

* Change mecha types' log_message() arguments to match atom and mob version

* Add key_name() case for atoms

* Fix resist_grab() unsetting pulledby before log_combat gets a chance to use it

* Fix log_globally logic

* Add logging for hitting objects with items

* Move log_combat() to atoms.dm

* Use utility functions for object stringification in log_combat()

* Use utility functions for object stringification in log_combat()

* Add missing logs for interacting with display cases

* Rewrite log_combat() comment

* Add missing space in log_combat()

* Add logging for hitting grilles barehanded

* Add missing ..()
2018-08-12 21:41:09 +02:00
vuonojenmustaturska
9df47d0962 Buffs BZ gas by allowing it to interfere with lings' hivemind access and chem regen (#35061) 2018-01-29 14:32:10 -02:00
MoreRobustThanYou
d3aacc2a54 [READY] Monkey mode overhaul (#32916)
* Monkey mode overhaul

* Fix some runtimes

* Clean up code a bit

* Woops!

* WOOPS #2

* Fix stuff.

* Antag datum!

* Fixes

* Fix a runtime

* Fix leaders not being monkeyfied

* ...

* Logging

* Monkey major/minor victory

* Ventcrawling, etc etc

* REEEE

* Forgot a "user".

* handle ninjanomnom's review

* .
2017-12-16 13:34:51 +13:00
MoreRobustThanYou
87009ef45d [s] Fix changeling chat (#33305)
* Fix changeling chat

* Update say.dm
2017-12-05 14:42:07 -05:00
MoreRobustThanYou
36414ac1e6 Datumizes saymodes (#33013)
* Datumized saymodes!

* Update living.dm

* ...
2017-12-03 13:55:03 -05:00