Skip to content

Commit

Permalink
Fixes Tape Recorder failing to record when no language is given (#4663)
Browse files Browse the repository at this point in the history
# About the pull request

<!-- Remove this text and explain what the purpose of your PR is.

Mention if you have tested your changes. If you changed a map, make sure
you used the mapmerge tool.
If this is an Issue Correction, you can type "Fixes Issue #169420" to
link the PR to the corresponding Issue number #169420.

Remember: something that is self-evident to you might not be to others.
Explain your rationale fully, even if you feel it goes without saying.
-->

The very same proc has a check on the language existing two line further
up, because it's a potential use cases -- but fails to check it again
and runtimes further below.


# Explain why it's good for the game
Bugfix

# Testing Photographs and Procedure
Untested


# Changelog
:cl:
fix: Fixed Tape Recorder failing to record when no language information
is present.
/:cl:
  • Loading branch information
fira authored Oct 14, 2023
1 parent d06f537 commit a198920
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion code/game/objects/items/devices/taperecorder.dm
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@
mytape.timestamp += mytape.used_capacity
var/language_known = (M.universal_speak || (speaking && (speaking.name in known_languages)))
var/mob_name = language_known ? M.GetVoice() : "Unknown"
var/message = language_known ? msg : speaking.scramble(msg)
var/message = (!speaking || language_known) ? msg : speaking.scramble(msg)
mytape.storedinfo += "\[[time2text(mytape.used_capacity,"mm:ss")]\] [mob_name] [verb], \"[italics ? "<i>" : null][message][italics ? "</i>" : null]\""


Expand Down

0 comments on commit a198920

Please sign in to comment.