Skip to content

Commit

Permalink
(sqai_rail) FIX error pakset name unknown
Browse files Browse the repository at this point in the history
git-svn-id: svn://tron.homeunix.org/simutrans/simutrans/trunk@11040 8aca7d54-2c30-db11-9de9-000461428c89
  • Loading branch information
Andarix committed Jan 13, 2024
1 parent f466025 commit 0e70e10
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions simutrans/ai/sqai_rail/ai.nut
Original file line number Diff line number Diff line change
Expand Up @@ -321,9 +321,13 @@ function today_plus_months(m)
function get_set_name()
{
local pakset = get_pakset_name() // full string from ground.outside.pak
local s = pakset.find(" ")
pakset = pakset.slice(0, s)
pakset = pakset.tolower()
if ( pakset != null ) {
local s = pakset.find(" ")
pakset = pakset.slice(0, s)
pakset = pakset.tolower()
} else {
pakset = "unknown"
}

return pakset
}
Expand Down

0 comments on commit 0e70e10

Please sign in to comment.