Skip to content

Commit

Permalink
version bump (#1218)
Browse files Browse the repository at this point in the history
* [create-pull-request] automated change

* Lammas (#1219)

* poprawka kolorowania na listach gonczych (#1220)

* ogluch krolken fix (#1222)

* Token-hidden-fix (#1224)

* ogluch krolken fix

* fix na kolorowanie ukrytych

* ziola wrzucone w tokenizacje (#1225)

Co-authored-by: Delwing <Delwing@users.noreply.github.com>
Co-authored-by: Piotr <delwing@gmail.com>
  • Loading branch information
3 people authored Dec 3, 2021
1 parent 455964d commit 139d909
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 16 deletions.
2 changes: 1 addition & 1 deletion Arkadia.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14022,7 +14022,7 @@
<string>Uderzenie w glowe oglusza cie i powala na ziemie.</string>
<string>znienacka kopie cie w noge i kiedy tracisz rytm walki, przywala ci piescia prosto w nos.</string>
<string>Ktos bez zastanowienia uderza cie piescia w szczeke, robiac to z taka sila, ze niemal powala cie na ziemie.</string>
<string>silnym ciosem .* oglusza cie</string>
<string>silnym ciosem .* oglusza cie\b</string>
<string>Gigantyczny drapiezny troll pochyla leb i szarzuje, by uderzyc cie kreconymi rogami prosto w klatke piersiowa. Potezny cios odrzuca cie i wyrywa oddech z piersi.</string>
</regexCodeList>
<regexCodePropertyList>
Expand Down
2 changes: 1 addition & 1 deletion skrypty.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
scripts = scripts or { ver = "4.44" }
scripts = scripts or { ver = "4.45" }
scripts.event_handlers = scripts.event_handlers or {}

function alias_func_skrypty_help()
Expand Down
13 changes: 4 additions & 9 deletions skrypty/herbs/core.lua
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
function herbs:init_herbs()
if herbs["use_herb_triggers"] then
herbs:delete_triggers()
herbs:create_triggers()
end
herbs:v2_init_data()
Expand Down Expand Up @@ -100,18 +99,14 @@ end

function herbs:create_triggers()
for herb_long, herb_name in pairs(herbs.herbs_long_to_short) do
local regex = "(?:^|\\W)(?i)(".. herb_long .. ")(?:\\W|$)(?!\\((?:\\w+ ?)+)"
herbs.herb_trigg_ids[herb_long] = tempRegexTrigger(regex, function() herbs:process_trigger(matches[2], herb_name) end)
end
end

function herbs:delete_triggers()
for herb_long, herb_trigger_id in pairs(herbs.herb_trigg_ids) do
killTrigger(herb_trigger_id)
scripts.tokens:register(herb_long, function(current_match) herbs:process_trigger(current_match, herb_name) end, "herbs " .. herb_name)
end
end

function herbs:process_trigger(herb_match, herb_name)
if line:starts("|") then
return
end
selectString(herb_match, 1)
replace(herb_match .. " (" .. herb_name .. ")")
selectString(herb_name, 1)
Expand Down
2 changes: 1 addition & 1 deletion skrypty/misc/calendar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ misc["ishtar_calendar"] = {
["Birke"] = "Birke (wczesna wiosna)",
["Blathe"] = "Blathe (pozna wiosna)",
["Feainn"] = "Feainn (wczesne lato)",
["Lammas"] = "Lemmas (pozne lato)",
["Lammas"] = "Lammas (pozne lato)",
["Velen"] = "Velen (wczesna jesien)",
["Saovine"] = "Saovine (pozna jesien)",
["Yule"] = "Yule (wczesna zima)",
Expand Down
7 changes: 4 additions & 3 deletions skrypty/people/color_people.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ function scripts.people:process_person_color(text, name, guild, color, suffix_co
return
end
local selectedText, offset, len = getSelection()
if text:lower():title() ~= name:lower():title() then
if name and text:lower():title() ~= name:lower():title() then
local sub = text
if not suffix_color then
sub = string.format("<%s>%s<reset>", color, sub)
Expand Down Expand Up @@ -42,8 +42,9 @@ function scripts.people:color_person_build(item, color, guild_color)

scripts.tokens:register(item.short, function(current_match)
scripts.tokens:process_token(current_match, function()
scripts.people:process_person_color(current_match, item.name, guild_str, color, guild_color)
end, function(what, k) return not (line:find(what .. " chaosu", k) or line:find(" %(to chyba")) end)
local name = not line:find(" %(to chyba") and item.name
scripts.people:process_person_color(current_match, name, guild_str, color, guild_color)
end, function(what, k) return not line:find(what .. " chaosu", k) end)
end, "people" .. (item.name or ""))

if item.name and item.name ~= "" then
Expand Down
2 changes: 1 addition & 1 deletion skrypty/tokens.lua
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ function scripts.tokens:process_line(msg)
if table.is_empty(self.registered) then
return
end
local tokens = table.n_filter(ansi2string(msg):split("[ \n\t%.,!%?%*()/]"), function(item) return item ~= "" end)
local tokens = table.n_filter(ansi2string(msg):split("[ \n\t%.,!%?%*()/%[%]]"), function(item) return item ~= "" end)
local already_matched = {}
for i = 1, #tokens, 1 do
local current_match = {}
Expand Down

0 comments on commit 139d909

Please sign in to comment.