Commit Graph

64 Commits

Author SHA1 Message Date
ShizCalev
d927f28951 Makes update_icon_updates_onmob more robust (#75324)
Safeguards against #74965 happening in the future.

Noticed a bunch of these were using ITEM_SLOT_HANDS. This is incorrect,
as the element already automatically updates held items. grep'd it to
catch future instances.

Likewise, a number of objects weren't passing slot_flags to the element,
meaning it wasn't actually updating those things properly when they were
being worn. I've simplified this so now the element will automatically
update all slot_flags, and passing an additional slot to the element
when being added is only needed for additional slots that might need to
be updated. This also means if slot_flags change, the element will now
update correctly as well.

🆑 ShizCalev
code: The update_icon_updates_onmob element will now automatically
update all slots in an item's slot_flags var. This does fix multiple
things that weren't updating properly. Passing a slot to the element is
now only necessary if you want to add additional slots to be updated.
/🆑
2023-05-10 18:36:01 -06:00
san7890
7b0917dcd6 Lints against UpdatePaths Scripts without a numeric prefix (#75066)
I forgot this for like the third time in #75001 and I'm sick of never
remembering to do it so I'm adding a lint so I never forget again (and
will also help other people never forget to add the PR-number prefix).
## Why It's Good For The Game

UpdatePaths scripts should have a prefix with the PR number that adds
them, but since you don't know the PR number when you're making the
script (since I make the script very early in my development process),
it's often forgotten (especially since no one really looks at file
names). Let's end forgetfulness by failing CI if a script without a
numeric prefix is detected.
2023-05-03 14:49:22 +00:00
BlueMemesauce
6bd192fe49 Fixes some miscapitalization of Nanotrasen (#75026)
## About The Pull Request

Fixes #75019

Also fixes it in a drink, the ethereal lore, and some photocopier
paperwork.

And also adds "NanoTrasen" to common spelling mistakes

## Why It's Good For The Game

Nanotrasen is the correct capitalization
## Changelog
🆑
spellcheck: Fixed Nanotrasen being miscapitalized in traitor posters, a
drink, the ethereal lore, and some photocopier paperwork
/🆑
2023-04-30 04:16:29 +00:00
Zephyr
7fd64dcf3d Auxtools is now a config opt-in (#74501)
See https://github.com/tgstation/tgstation/pull/74497

Causes auxtools to not be a default part of the server environment and
requires server operators to manually enable it.

---------

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2023-04-05 15:36:26 -07:00
san7890
03bb726a80 Lints for Empty Variable-Edit "List" in the TGM Syntax + Fixes Occurrence in Codebase (#73831)
## About The Pull Request

Caused by #73758 due to improper search-and-delete (presumably) without
running mapmerge or something to catch it, very sad. Let's add a linter
to make sure this doesn't occur again.

More information on what exactly was broken may be found here:
https://github.com/tgstation/tgstation/pull/73758#issuecomment-1457508565
## Why It's Good For The Game


![image](https://user-images.githubusercontent.com/34697715/223326428-7f02ea8d-a881-4fa8-b87d-717b39e1fff2.png)

makes me sad to see it, it's ugly, and mapmerge will fix it away anyways
over the next few months since it's an invalid/bugged case. let's just
prevent it from happening again. (hopefully this hasn't been impacting
the map loader at all? i don't see why it would but I know this case
isn't exactly accounted for). i noticed that we're able to flatten a lot
more keys now as well since we don't have literally nothing preventing
that flattening, which is a plus.
## Changelog
Nothing that concerns players.
2023-03-09 13:51:06 +13:00
Tim
7cf5a73771 Add grep linter for can_perform_action arguments (#73527)
## About The Pull Request
This adds a linter to check for missing arguments with the
`can_perform_action` proc since several people had used it with no
arguments provided and it caused persistent runtimes over several years.

## Why It's Good For The Game
Less runtimes in the future.

## Changelog
Not needed.
2023-02-21 08:51:49 -08:00
Zephyr
a8f5a6d158 Fix a merge skew on armor datums (#72909)
## About The Pull Request

And also add a check grep to find it in the future
## Why It's Good For The Game
## Changelog
2023-01-28 19:34:11 -05:00
MrMelbert
0007686bf5 Adds checkgrep for improper or missing atom Initialize args (mapload) (#72846)
## About The Pull Request

Adds a grep for atom initialize overrides which does not include mapload

Regex used
`^/(obj|mob|turf|area|atom)/.+/Initialize\((?!mapload).*\)`

Also replaced some space indentation with some tab indentation in some
other greps


![image](https://user-images.githubusercontent.com/51863163/213883049-ef6d953a-e11f-4876-9852-c09633ddc289.png)

## Why It's Good For The Game

See #69107, #61759, #61623

## Changelog

No player facing changes
2023-01-26 13:58:47 -08:00
san7890
9beb09a33a Adds Lint Against Non-TXT UpdatePaths Scripts (#72785)
Prevents Regression Found In #72779 (someone putting an UpdatePaths
script that doesn't end in .txt through) from happening again.
2023-01-22 22:00:16 +00:00
SyncIt21
ec5c9dfd10 Stock Part Datumization Complete (#72559)
So i accidently reverted all my commits in #72511 when resolving a merge
conflict So ummm yeah fuck my bad anyway

## About The Pull Request
Finishes what was started in #71693 and completes the
[initiative](https://github.com/tgstation/dev-cycles-initiative/issues/1)

Except for `obj/item/stock_parts/cell` and its subtypes. All machines
now use `datum/stock_part` for its requested components & component
parts

Not sure if i caught every machine & stuff in the game so merge with
caution
## Changelog
🆑
code: datum stock part for every obj stock part
refactor: all machines & dependent experiments to use datum stock parts
/🆑
2023-01-11 07:53:36 -08:00
Zephyr
aa10d9d756 Forgot to specify files to check in check grep (#72277) 2023-01-04 05:43:58 +00:00
Mothblocks
6f07ae305b Replace nearly every map grep with a YML file that actually respects structure, and fixes the massive amount of failures that were never caught (#72372)
[Documentation
here](https://github.com/Mothblocks/tgstation/blob/maplint/tools/maplint/README.md)

We should not be using greps to the capacity that we currently are. If
you are not smarter than a parser, then you should not try to beat one.
DMM files should NOT be treated as text files that can be parsed with
any old Unix tool. They are a structured language. Because of our abuse
of greps, check_greps is full of hard to read, hard to maintain checks
that do not consistently work, because they all make very specific
assumptions about how TGM works, which are provably untrue.

This format is mostly straightforward for the lints people write, and
easily extensible to the ones people will want to write.

🆑
fix: Fixes a bunch of cases of windows not being where they were
supposed to be, tables/chairs stacking on each other, and other very
small stuff you've never noticed before.
/🆑
2023-01-03 21:21:37 -08:00
Mothblocks
e9351f6ae0 Add lints for idiomatic balloon alert usage (#72280)
Adds lints for `balloon_alert(span_xxx(...))` (which is always wrong),
and balloon alert where the first letter is a capital (which is usually
wrong). Fixes everything that failed them. As a reminder, abbreviations
like "AI" and "GPS" shouldn't be capitalized in a balloon alert.

In cases where this is intentional for flavor (there was one case), you
can `UNLINT` like so:

Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com>
2022-12-29 19:01:45 +00:00
san7890
d0ebefcbde Updates check_grep to guard against unparsed map variables (#72161)
## About The Pull Request

In `/datum/parsed_map/proc/parse_constant()` (via
b3851d607f/code/modules/mapping/reader.dm (L930)'),
we do not check (ignore) five different things: `new()`, `newlist()`,
`icon()`, `matrix()`, and `sound()`. Since it's completely useless to
put it in a map and expect to see it code-side now-a-days, let's lint
against it just to be safe in the future.
## Why It's Good For The Game

Prevents silliness like in #72157 (which this PR is also reliant on for
checks to pass).

no changelog needed
2022-12-24 02:41:04 -08:00
Zephyr
5c18606d9b [FUCK] Linters work again, V3 (#71748)
Get linters working again, I was never using the correct directory
expansion syntax for checks, so why some of them still worked anyway is
beyond me.

Fixes https://github.com/tgstation/tgstation/issues/71695
2022-12-06 01:05:52 -08:00
Zephyr
1900eb9484 Unit Tests use a consistent human subtype (#71515)
title
2022-11-26 20:36:20 +01:00
Zephyr
1aded37cfc Changes check_grep to use ripgrep and reformats/cleans up the check_grep file (#71324)
## About The Pull Request

I fucked up the check_grep entry for docking ports.
default grep doesn't support newlines and so I need to use `pcregrep -M`

## Why It's Good For The Game

linters working good
## Changelog

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
Co-authored-by: san7890 <the@san7890.com>
2022-11-21 11:46:22 -08:00
Zephyr
58b4b07ef0 [MDB Ignore] Corrects Automatic Shuttle Boundary Generation (#71220)
When you load a map template, it does many things before considering
itself finalized.
One of these steps is to iterate over all the loaded items and
initialize/process them.
Unfortunately because a shuttle setups the bounds after
initTemplateBounds is called, the mobile docking port ends up being
initialized before the bounds are actually setup correctly.
The solution to this is to explicitly ignore the mobile docking port,
and have it initialize immediately after calculating the bounds.
2022-11-16 01:36:05 +00:00
AnturK
4d6a8bc537 515 Compatibility (#71161)
Makes the code compatible with 515.1594+

Few simple changes and one very painful one.
Let's start with the easy:
* puts call behind `LIBCALL` define, so call_ext is properly used in 515
* Adds `NAMEOF_STATIC(_,X)` macro for nameof in static definitions since
src is now invalid there.
* Fixes tgui and devserver. From 515 onward the tmp3333{procid} cache
directory is not appened to base path in browser controls so we don't
check for it in base js and put the dev server dummy window file in
actual directory not the byond root.
* Renames the few things that had /final/ in typepath to ultimate since
final is a new keyword

And the very painful change:
`.proc/whatever` format is no longer valid, so we're replacing it with
new nameof() function. All this wrapped in three new macros.
`PROC_REF(X)`,`TYPE_PROC_REF(TYPE,X)`,`GLOBAL_PROC_REF(X)`. Global is
not actually necessary but if we get nameof that does not allow globals
it would be nice validation.
This is pretty unwieldy but there's no real alternative.
If you notice anything weird in the commits let me know because majority
was done with regex replace.

@tgstation/commit-access Since the .proc/stuff is pretty big change.

Co-authored-by: san7890 <the@san7890.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2022-11-15 03:50:11 +00:00
Mothblocks
e75fa446c8 Add support for running tests on alternate versions (#71177)
Adds support for additional byond versions tests
2022-11-09 07:57:46 +01:00
san7890
b6a801a888 Fixes Raw Turf in Tramstation + Patches Lint for Raw Turf (#70998) 2022-11-02 19:53:31 -07:00
ShizCalev
af26d38749 Fixes voice of god runtime when a target resists the command (#69921)
* Fixes voice of god runtime when a target resisted your command and adds a grep to avoid it being a problem again in the future.
2022-09-15 22:19:09 -04:00
Vire
a495cb8b34 Removing trailing / from several mapping regexes (#69448)
* Removing trailing / from several mapping check regexes

So we have check_grep.sh which helpfully checks for a bunch of common map mistakes, including doubled up items. This adjusts them to capture doubled up base types which might be mapped in.

* Commit before pushing next time
2022-09-09 12:01:53 -04:00
ShizCalev
6ef3599254 adds grep check for improperly used timer flags. (#69668) 2022-09-05 02:55:22 -07:00
ShizCalev
d82b6e23d6 adds structure spawners for electrified grilles, adds greps for some fulltile window spawners (#69528)
* adds structure spawner for electrified grilles

* sdmm key cleanup
2022-09-01 02:48:15 +02:00
Y0SH1M4S73R
4e6e1f090e [Ready for Review] Admin lua scripting (#65635)
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2022-07-19 15:45:23 -07:00
san7890
1e1244fad8 Updates check_grep.sh to have more clarity and contrast (#68387)
* Updates check_grep.sh to have more clarity

Hey there,

One issue with check_grep is that it was very inconsistent in how it handled the error conditions and echos to the end user. Some of them didn't have ERROR:, some of them didn't have two echos to separate them from the actual grep result, etc.

This should add more clarity to all of it by making each error line exit with a RED color, the boilerplate lines with a BLUE color, having an echo in each line to separate, etc. This should be much easier to see for anyone at a glance. This works on my local machine, and I suppose we'll find out how it looks on GitHub.
2022-07-17 01:16:31 -07:00
oranges
ed642a9311 The lint for whitespace issues now shouts louder (#68386) 2022-07-13 15:34:45 +12:00
san7890
dc6b4aba47 Merge Conflict Markers - The Explicit Pathing, Layering, Iconing, Warning. (#68039)
* Merge Conflict Markers - The Explicit Pathing

Hey there,

This PR corrects an issue I've been having with mapmerge2 these last few months. Basically, what it does is create a base `/obj` that is given the name `---Merge Conflict Marker---`. This is fine and all, but the problem is that the base `/obj` is set to a certain plane. This does mean that sometimes, this VERY IMPORTANT marker is covered up by rocks or other objects. So, this seeks to get rid of that potential flaw, as well as do some other things.

Sometimes, when objects are rendered via GAGS or other code-means, they tend to have the same default Purple/White Sprite that any object without a valid icon_state has. This has caused me some confusion, so I have decided to create a new icon for conflict markers. This icon was designed to be as ugly as possible, while creating as much contrast as possible with the background by incorporating several colors into its design. I hope you find merge conflicts as unpleasant as I do.

I also updated mapmerge2 to have it so you can set the specified path of the object, as well as a small comment on the warnings if you do not heed it. I'm keeping the fact that mapmerge2 adds a name to the object just in case someone else really needs that. I also updated the linters to check for this path as well (even though the name and description should suffice for linting), and it should all be gravy from here.

* Adds further contrast to the DMI.

* Splits the merge conflict marker into a generic /obj

I also added a thing where if it didn't get caught by linters and it showed up on Initalize, it would error to mapping logs, spit out an error in world, and do all sorts of stuff to remind you.

* python new line

* forgot to add a tab
2022-07-05 01:29:44 -04:00
Mothblocks
7cab049dd1 Screenshot tests (#67679)
Adds screenshot visual testing workflow and scripts.
2022-06-11 00:02:30 +02:00
Son-of-Space
2fb96ab772 Greps to check for commonly misplaced structures in closed turfs (#67447)
Adds some checks for structures that are commonly misplaced inside walls. One of the more recent updatepaths also replaced a bunch of posters with windoors in walls so this will help find all those.

I also edited the one that checks for lattices to look for closed turfs, because we really don't want the structures we're looking for to be in any closed turfs anyways.

We don't want to look for all structures like this because things like transit tubes exist.
2022-06-02 17:27:22 -06:00
Son-of-Space
dab0cb6396 Greps for double firelocks and airlocks (#67374)
Adds the greps for firelocks and airlocks so we don't double stack them.

* Greps for double firelocks and airlocks

* Update tools/ci/check_grep.sh

Co-authored-by: Pepsilawn <reisenrui@gmail.com>

* Update tools/ci/check_grep.sh

Co-authored-by: Pepsilawn <reisenrui@gmail.com>

* fixes two double firelocks on iceboxstation

Co-authored-by: Pepsilawn <reisenrui@gmail.com>
2022-05-29 19:19:01 -06:00
san7890
e1f9602439 Adds Greps for Multiple Areas/Turfs on the same tile. (#67173)
Hey there,

Even though mapmerge2 (through behavior introduced in #39889) should automatically check for "stacked turfs", they still slip through somehow. Not really sure how, but let's make sure that doesn't happen again with the power of grep.
2022-05-26 16:52:11 -04:00
Son-of-Space
01a745027f [MDB IGNORE] More greps for commonly misplaced structures (#67252) 2022-05-26 10:03:47 -07:00
Son-of-Space
e3fd627615 [MDB IGNORE] The Grand Airlock Naming Audit (#67235)
I manually audited all 4,710 instances of airlocks across all maps for upper casing

You'll never guess what I found.

UPDATE: We now have a grep to check for mistitled airlocks, and it's in this PR!
2022-05-25 00:29:24 -06:00
Tastyfish
d8d29f6701 Test all maps in parallel integration tests (#66864) 2022-05-12 00:12:02 -07:00
Tastyfish
56ac3113aa Adds CI for inverted conveyor belt (#66672) 2022-05-05 13:53:09 -07:00
MrMelbert
1d3ec7d663 Fixes some improper balloon alerts, adds a grep to prevent future bad balloon alert calls (#66214) 2022-04-23 18:22:01 -07:00
san7890
ccb377750a Creates Linters for (bad) Commented Out Lines in Maps (#65888)
* Creates CI Linters for Commented Out Lines in Maps

Creates Linters for (bad) Commented Out Lines in Maps

Hey there,

This PR is made because what happened in #65837 was fucking horrible awful shit that I'm still dealing with a few days after I fixed it. This _should hopefully_ add a new linter for commented out lines of code in a .DMM file, and HOPEFULLY doesn't flag the commented line that prevents unwanted TGM > DMM conversion.

As a proof to see if it works, I'll be adding a comment to Line 2 of IcemoonUnderground_Above.dmm. Hopefully, on the first CI check, it'll fail. I'll remove that line so it doesn't make its way into production (it will suck).
2022-04-05 19:46:01 -07:00
Pepsilawn
ea700eb5d1 Removes lattices from our walls (#65150) 2022-02-26 11:40:31 -07:00
Tastyfish
2687a76c5a Fixes a bunch map log runtimes, adds CI to catch some more potential map issues (#64599)
* Fixes APC offsets in template maps, airlock note placer helper

* also hellfactory

* remove doubled lavaland mining cable

* Updates CI grep checks for cable check to work, and also check lattices and identical pipes

* Add APC pixel offset checking

* mass apc offset fixes
2022-02-02 05:24:53 -08:00
Maurukas
7ee0debc45 Add merge conflict markers to linter (#61669)
Updates check_grep.sh with a case for the /obj mapmerge2 creates on merge conflicted tiles. You're supposed to fix all of these before you continue a merge, but there's zero warning if you don't clear them all. As a result they can end up in the commit pushed to github, and they can hide quite easily in a PR that otherwise looks fine.

Your average map file is about 3 megabytes of raw text, or 160,000 lines. I don't want to have to read them all to prevent this from happening again.
2021-09-27 12:30:10 -07:00
mokulus
e6e38ec4e5 Exit on DreamMaker warnings in CI Windows build (#61025)
Added an option to tools/build/build to treat DreamMaker warnings as errors. Enabled this option only for Windows Build (tools/ci/build.ps1).

Co-authored-by: Aleksej Komarov <stylemistake@gmail.com>
2021-08-26 12:08:26 +03:00
Aleksej Komarov
e5ae0667bf Juke Build 0.8.1 (#60404) 2021-08-15 15:17:11 -07:00
oranges
3801c24229 Update rust-g version to latest release (#59863)
* Update rust version to latest release

This should fix the fact our docker build has been failing for the past
10 days

* Make wget not be quite so noisy
2021-06-29 01:44:43 -07:00
Timberpoes
0964976685 Revert "Builds SDMM for CI instead of using releases. (#58963)" (#59035)
This reverts commit 308be58017.
2021-05-10 20:02:08 -07:00
AnturK
308be58017 Builds SDMM for CI instead of using releases. (#58963) 2021-05-10 18:09:50 -07:00
Celotajs
76fb2e1712 Convert changelog to TGUI (#58593)
This pull request converts the changelog to TGUI. 
Note: Old unused changelog files will be automatically removed on the next changelog run
Why It's Good For The Game

More consistent UI, ability to view all historic logs.
Changelog

cl Celotajs
refactor: Converted the changelog popup to TGUI
/cl
2021-04-27 08:41:56 +12:00
AnturK
7fef33c459 Adds easy to extend custom svg font. (#57717)
Just throw in svgs into tgui/packages/tgfont/icons directory and you can use them in tgui with tg- prefix.

Co-authored-by: Style Mistake <stylemistake@gmail.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2021-03-18 15:20:59 +02:00
Qustinnus
931a32ffb3 Experi-Sci: Techweb nodes may now require you to perform "scientific" experiments (#54093)
Co-authored-by: Brett Williams <bobbahbrown@gmail.com>
Co-authored-by: Jordan Brown <Cyberboss@users.noreply.github.com>
Co-authored-by: ArcaneMusic <41715314+ArcaneMusic@users.noreply.github.com>
Co-authored-by: Aleksej Komarov <stylemistake@gmail.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
2021-02-23 13:30:24 -08:00