Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MIRROR] Machinery cannot be interacted with by AI when its turf is off-camera #1845

Merged
merged 1 commit into from
Feb 7, 2024

Conversation

Steals-The-PRs
Copy link
Collaborator

Mirrored on Nova: NovaSector/NovaSector#822
Original PR: tgstation/tgstation#81250

About The Pull Request

When an AI interacts with a machine, it will now check if the turf it occupies is on the cameranet. This should ensure that wallmounted machinery shouldn't be accessible from the other side of a wall.

This image summarizes what this applies to:

image

Blue APC should be visible. Red should not. Normally, if red is covered completely by static, it becomes inaccessible. The red APC remaining visible is only the result of the perspective. We can't black out the entire wall when it goes off-camera since it can still be seen from the other side. The blue APC is technically stationed on a turf in a different room and is the only one in camera view, which would also be blocked out and would be needlessly inaccessible. Walls that remain in view from only one "side" of the wall, have all of their wallmounts accessible to the AI despite not (logically) having a camera pointed at them.

Damn, when is the wallening gonna get here?

Anyways, since the AI cam is a top-down view that only technically respects cameras, you see things you aren't supposed to see. We can't solve it by covering the entire tile, or leaving it uncovered, so this is the best we got.

I got mixed up looking for where exactly to put this check. There might be a better solution for this but I do not see it at the moment.

Why It's Good For The Game

Wallmounts being accessible due to loopholes in perspective makes things confusing for players who don't see the world the same way.

It would also be dishonest of me not to mention why I started on this PR, and why this is marked as a balance PR - This was done to un-jank the pain of doing console hack objectives. It's a bit nonsensical to have to take out cameras on the other side of a wall just to make sure your APC doesn't get powered down.

Changelog

🆑 Rhials
balance: Wallmounts now respect cameranets, and cannot be accessed from a view of the adjacent wall.
/:cl:

…ff-camera (#822)

* Machinery cannot be interacted with by AI when its turf is off-camera (#81250)

## About The Pull Request

When an AI interacts with a machine, it will now check if the turf it
occupies is on the cameranet. This should ensure that wallmounted
machinery shouldn't be accessible from the other side of a wall.

This image summarizes what this applies to:


![image](https://github.com/tgstation/tgstation/assets/28870487/783d241b-c37f-4319-b4b3-8dde75cec528)

Blue APC should be visible. Red should not. Normally, if red is covered
completely by static, it becomes inaccessible. The red APC remaining
visible is only the result of the perspective. We can't black out the
entire wall when it goes off-camera since it can still be seen from the
other side. The blue APC is technically stationed on a turf in a
different room and is the only one in camera view, which would also be
blocked out and would be needlessly inaccessible. Walls that remain in
view from only one "side" of the wall, have all of their wallmounts
accessible to the AI despite not (logically) having a camera pointed at
them.

Damn, when is the wallening gonna get here?

Anyways, since the AI cam is a top-down view that only technically
respects cameras, you see things you aren't supposed to see. We can't
solve it by covering the entire tile, or leaving it uncovered, so this
is the best we got.

I got mixed up looking for where exactly to put this check. There might
be a better solution for this but I do not see it at the moment.
## Why It's Good For The Game

Wallmounts being accessible due to loopholes in perspective makes things
confusing for players who don't see the world the same way.

It would also be dishonest of me not to mention why I started on this
PR, and why this is marked as a balance PR - This was done to un-jank
the pain of doing console hack objectives. It's a bit nonsensical to
have to take out cameras on the other side of a wall just to make sure
your APC doesn't get powered down.
## Changelog
:cl: Rhials
balance: Wallmounts now respect cameranets, and cannot be accessed from
a view of the adjacent wall.
/:cl:

* Machinery cannot be interacted with by AI when its turf is off-camera

---------

Co-authored-by: Rhials <[email protected]>
@Iajret Iajret merged commit 291c081 into master Feb 7, 2024
24 checks passed
@Iajret Iajret deleted the upstream-mirror-822 branch February 7, 2024 23:31
AnywayFarus added a commit that referenced this pull request Feb 8, 2024
Iajret pushed a commit that referenced this pull request Apr 7, 2024
* Fix `/datum/dimension_theme/fancy` never applying  (#82485)

## About The Pull Request

It always runtimed due to `replace_floors` being `null`
and because it runtimed it never got to set `replace_floors` to a list

## Changelog

:cl: Melbert
fix: Fix fancy anomaly theme being broken
/:cl:

* Fix `/datum/dimension_theme/fancy` never applying

---------

Co-authored-by: MrMelbert <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants