Skip to content

Commit

Permalink
[MDB Ignore] Manifest Destiny - The Final Tile Flattening (tgstation#…
Browse files Browse the repository at this point in the history
…74169)

Alt Title: The End Of The 12 Month War
## About The Pull Request

### Hey! Listen! This PR _will_ cause a merge conflict with your PR!
Please ensure that you have the knowledge on how to handle merge
conflicts, found here:
https://hackmd.io/@tgstation/ry4-gbKH5#Assured-Merge-Conflict-Resolution

Supercedes tgstation#74023 entirely.

Port of the tooling introduced in
BeeStation/BeeStation-Hornet#7970 (we already
had everything else), modified to meet /tg/'s requisites and culling
anything that was not entirely relevant (that I could see). It's not the
end of the world if I missed something tbh. Some aspects were commented
out since they may be relevant to downstreams who port this PR or to
enable (what I see to be) un-necessary warnings.

This is a culmination of a year's efforts, starting with _Red Rover,
Four Corners_ (tgstation#65290) and later _Opposing Corners_ (tgstation#65455). If you
don't understand why this PR exists or why it's necessary, I recommend
reading both of those.

Since then, several mappers (both in their own mapping as well as
tailored PRs) have worked on "flattening" out these tile turfs, however
I've continually wanted a function that would mass automate it (outlined
here https://tgstation13.org/phpBB/viewtopic.php?t=31872 - This
functionality might still be useful if added to UpdatePaths or another
type of script thereof, but I no longer have reason to keep the bounty
up).

It's finally here! Yippie! A new python file, courtesy of itsmeow at
BeeStation. Very awesome. As previously mentioned, a lot of alterations
had to be made for our mapping desires, but the results are quite
agreeable. There's a few assertions that this file makes that I had to
address:

* We have "colorless" tile decals. These are transparent, so they don't
do anything. By default, bee would make these "white tiles", but we have
no such thing. I decided to just add a maplint and an UpdatePaths to
guard against this silliness (only Delta and Tram) had it.
* For some reason, it labels already-converted decals with the default
direction as an error state. I might touch this up in the coming hours,
but for now I surpressed the error due to how many false warnings it was
spitting out.

There's a few ways this tool can be improved, but I lack the knowledge
on how to do so:
* Make it so that we can run the map merger to fix the keys of the map
in the `update_map` function, rather than run the fixer-upper python
file. We can live without this to be honest. It's actually slightly good
because it forces you to look at all of the MapMerge Warnings, and you
can ascertain any potential errors without it silently passing you by
and hitting the repository (or at least those that we haven't linted for
yet).
* Be able to pass in any regex to "flatten" anything. That's way out of
scope for what I want to do here though.

## How do you use this tool?

I made a readme.
https://github.com/tgstation/tgstation/blob/363852cb17fa46dad8fd20e261f8f665f3e008bb/tools/MapTileAggregator/readme.md
### Mapping March
oh hey it's pretty neat that this PR came out in mapping march, what a
nice qol for mappers as the month enters the home stretch. ckey is
san7890

## Why It's Good For The Game

slimmer DMM files, better mapping practices. cool new tool. so nice.
## Changelog
Nothing that really affects players, but a short summary for all those
reading this PR:

* All "corner" turf decals are flattened, and there's now a tool that we
store that you can re-run to keep stuff flat in case you like mapping
one way and want to fix it at the end.
* We (should) now lint against useless uncolored turf decals since that
was completely garbo as far as our codebase is concerned.
* UpdatePaths for fixing up uncolored turf decals, yippie!


If you want to review this PR, may I suggest the file filter. You don't
need to look at any of the DMM files I already did:

![image](https://user-images.githubusercontent.com/34697715/226787961-ab82cad4-5d6d-4788-a7bd-5071aac825c4.png)

---------

Co-authored-by: Zephyr <[email protected]>
  • Loading branch information
san7890 and ZephyrTFA authored Mar 24, 2023
1 parent bcf49ae commit 3156a04
Show file tree
Hide file tree
Showing 106 changed files with 16,860 additions and 29,033 deletions.
10 changes: 5 additions & 5 deletions _maps/RandomRuins/IceRuins/icemoon_surface_engioutpost.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -693,11 +693,11 @@
/turf/open/floor/iron/icemoon,
/area/ruin/planetengi)
"dr" = (
/obj/effect/mob_spawn/corpse/human/engineer/mod,
/obj/effect/decal/cleanable/blood/old,
/obj/effect/turf_decal/tile/yellow{
dir = 1
},
/obj/effect/mob_spawn/corpse/human/engineer/mod,
/obj/effect/decal/cleanable/blood/old,
/turf/open/floor/iron/icemoon,
/area/ruin/planetengi)
"ds" = (
Expand Down Expand Up @@ -784,10 +784,10 @@
/turf/open/misc/asteroid/snow/icemoon,
/area/icemoon/surface/outdoors/nospawn)
"kS" = (
/obj/effect/turf_decal/tile/yellow,
/obj/effect/turf_decal/box/corners{
dir = 1
},
/obj/effect/turf_decal/tile/yellow,
/turf/open/floor/iron/icemoon,
/area/ruin/planetengi)
"na" = (
Expand Down Expand Up @@ -830,8 +830,8 @@
/turf/open/floor/iron/icemoon,
/area/ruin/planetengi)
"Iy" = (
/obj/effect/turf_decal/tile/yellow,
/mob/living/simple_animal/hostile/construct/proteon,
/obj/effect/turf_decal/tile/yellow,
/turf/open/floor/iron/icemoon,
/area/ruin/planetengi)
"Je" = (
Expand All @@ -850,10 +850,10 @@
/area/ruin/planetengi)
"Nd" = (
/obj/structure/girder/displaced,
/obj/effect/turf_decal/box/corners,
/obj/effect/turf_decal/tile/yellow{
dir = 1
},
/obj/effect/turf_decal/box/corners,
/turf/open/floor/iron/icemoon,
/area/ruin/planetengi)
"UK" = (
Expand Down
Loading

0 comments on commit 3156a04

Please sign in to comment.