It is currently May 2nd, 2024, 4:50 am

LuaTimer-What do to when the countdown diminished the Bar

Get help with creating, editing & fixing problems with skins
User avatar
haibusa2005
Posts: 52
Joined: June 15th, 2011, 7:23 pm
Location: Bulgaria, Varna

Re: LuaTimer-What do to when the countdown diminished the Ba

Post by haibusa2005 »

Meh, I looked into the feeds and I have found out that it required a small change to the Atom parser. Also if this thing is ever going to be used it would need substitutions for the special characters and to remove parasite strings, good RegExps for the parse parts and so on. Don't get me wrong, I have no problem with Lua or anything. Actually right now I am reading documentation to understand its capabilities and I am trying to make scripts but for now the number of successful attempts is near 0.

Corrected code
[IndefAtom]
UpdateRate=1
UpdateDivider=300
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=#FeedURL#
RegExp="(?siU)<feed xmlns="(.*)""
ErrorString="-1"
StringIndex=1
Substitute="http://www.w3.org/2005/Atom":"1"
Disabled=1

[ParseAtom]
UpdateRate=1
UpdateDivider=300
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=#FeedURL#
RegExp="(?siU)<title>(.*)</title>.*<content(.*)>(.*)</content>"
Disabled=1

[AtomTitle]
UpdateRate=1
UpdateDivider=300
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[ParseAtom]
StringIndex=01

[AtomContent]
UpdateRate=1
UpdateDivider=300
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[ParseAtom]
StringIndex=03