From 5c59f3c7e8bfd4b240d1a540e2d0cca406cdde42 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 19 Jun 2016 21:12:03 +0300 Subject: hercules: parse shop names with non ascii chars. Also allow use -1 as shop id. --- hercules/code/server/tmw/npcs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hercules/code/server/tmw/npcs.py b/hercules/code/server/tmw/npcs.py index 32fb85b..24fe46c 100644 --- a/hercules/code/server/tmw/npcs.py +++ b/hercules/code/server/tmw/npcs.py @@ -25,8 +25,8 @@ scriptRe2 = re.compile("^(((?P[^/](.+))[.]gat,([ ]*)(?P[\d]+),([ ]*)(?P< "(((?P[\d-]+)((,((?P[\d-]+),(?P[\d-]+)))|)(|,)(|[ \t]))|){(|[ ])$") shopRe = re.compile("^(?P[^/](.+)),([ ]*)(?P[\d]+),([ ]*)(?P[\d]+),([ ]*)(?P[\d]+)(|,(?P[\d]+))" + - "[|](?Pshop)[|](?P[\w#' ]+)[|]" - "(?P[\d]+),(?P(.+))$") + "[|](?Pshop)[|](?P[^|]+)[|]" + "(?P[\d-]+),(?P(.+))$") shopRe2 = re.compile("^(?P[^/](.+))[.]gat,([ ]*)(?P[\d]+),([ ]*)(?P[\d]+),([ ]*)(?P[\d]+)" + "[\t](?Pshop)[\t](?P[\w#'\\[\\] ]+)[\t]" -- cgit v1.2.3-70-g09d2