Skip to content

Commit

Permalink
Truncate strings longer than 31 characters
Browse files Browse the repository at this point in the history
  • Loading branch information
justarandomgeek committed Mar 5, 2017
1 parent 5d5973a commit 912769b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions control.lua
Expand Up @@ -52,6 +52,11 @@ string_to_signals = function(str,extrasignals)
local s = string.upper(str)
local letters = {}
local i=1

if #s>31 then
s=s:sub(1,31)
end

while s do
local c
if #s > 1 then
Expand Down
2 changes: 1 addition & 1 deletion info.json
@@ -1,6 +1,6 @@
{
"name": "signalstrings",
"version": "0.14.1",
"version": "0.14.2",
"factorio_version": "0.14",
"title": "Signal Strings Library",
"author": "justarandomgeek",
Expand Down

0 comments on commit 912769b

Please sign in to comment.