It is currently April 19th, 2024, 11:48 am

Football (soccer...) skin

Get help with creating, editing & fixing problems with skins
User avatar
Chiripa
Posts: 12
Joined: March 23rd, 2021, 3:49 pm

Re: Football (soccer...) skin

Post by Chiripa »

hola a todos, soy nuevo con esto del Rainmeter apenas supe de su existencia este año, poco a poco me fue llamando la atencion y empece a hacer mis propios skins no muchos un par nada mas copiandome cosas de otros obviamente, lo cierto es que ahora les muestro lo que llevo hasta ahora

Image

entonces mi pregunta es la siguiente y espero que porfavor alguien me ayude

como puedo hacer para que al presionar un boton pase de una fecha a otra sin errar??? me explico

fecha = 20210430 + 1 = 20210431 :thumbdown:
fecha = 20210430 + 1 = 20210501 :thumbup:

para los que necesiten los archivos para hacer sus propios skins la info esta en estes link

https://mega.nz/file/YFY3DCgY#VDO195IuE_ds8pbTAFc83-ta5DeWWeCF3LNGNVilXxM
User avatar
Yincognito
Rainmeter Sage
Posts: 7125
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Football (soccer...) skin

Post by Yincognito »

Chiripa wrote: April 9th, 2021, 2:32 am hola a todos, soy nuevo con esto del Rainmeter apenas supe de su existencia este año, poco a poco me fue llamando la atencion y empece a hacer mis propios skins no muchos un par nada mas copiandome cosas de otros obviamente, lo cierto es que ahora les muestro lo que llevo hasta ahora

Image

entonces mi pregunta es la siguiente y espero que porfavor alguien me ayude

como puedo hacer para que al presionar un boton pase de una fecha a otra sin errar??? me explico

fecha = 20210430 + 1 = 20210431 :thumbdown:
fecha = 20210430 + 1 = 20210501 :thumbup:

para los que necesiten los archivos para hacer sus propios skins la info esta en estes link

https://mega.nz/file/YFY3DCgY#VDO195IuE_ds8pbTAFc83-ta5DeWWeCF3LNGNVilXxM
Please, use English on this forum, so everybody can understand what you mean ;)
Por favor, use el inglés en este foro para que todos puedan entender lo que quiere decir ;)

First, this is a really nice skin, good work. :thumbup:
Secondly, despite "fecha" (I assume, the date) is today, aka fecha=20210409 in the Update.ini of the skin, the table isn't quite up to date, probably because the hour of retrieval is not included (LiveScore vs Futbol Skin comparison) - I also set the date to one day later as suggested, i.e. 20210410, and it's the same:
La Liga - LiveScore.jpg
La Liga - Futbol Skin.jpg
Third, it isn't quite nice that one of the PHPs used by the skin(s) tries to make hardcoded folders in the Users path, a better approach would have been to use the current user's Documents folder, instead of your own - I'm sure PHP can get that:
Local Folders.jpg
Fourth, this does indeed help this topic, since the web address used in the skin provides a nice JSON that anyone can parse with WebParser or format for better viewing the structure, using an online formatter like Web Formatter, and that seems to be up to date (La Liga used for https://www.fotmob.com/leagues?id=87&tab=overview&type=league - having an ID of 87, but one can change that, for example Serie A is 55 and so on):
Futbol Source Site - Formatted JSON.jpg
All in all, thanks for replying here - if the OP hasn't finished his skin yet, he might find this (and the JSON provided by the URL) very useful. ;-) Very nice skin, again. :thumbup:
You do not have the required permissions to view the files attached to this post.
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth
User avatar
Chiripa
Posts: 12
Joined: March 23rd, 2021, 3:49 pm

Re: Football (soccer...) skin

Post by Chiripa »

I'm glad that you understood me, I tried to use the json with the webparser but I almost ended in suicide, it costs me a lot, the personal address in the file is because obviously I have not finished it yet if they make a file not to use the php please let me know,
Regarding the date, I do not understand how to do it
User avatar
Yincognito
Rainmeter Sage
Posts: 7125
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Football (soccer...) skin

Post by Yincognito »

Chiripa wrote: April 9th, 2021, 10:55 pm I'm glad that you understood me, I tried to use the json with the webparser but I almost ended in suicide, it costs me a lot, the personal address in the file is because obviously I have not finished it yet if they make a file not to use the php please let me know,
Regarding the date, I do not understand how to do it
Actually, it's quite easy to do it without PHP (WebParser can parse such files too), using an user specific folder (which Rainmeter can get as well, using its path variables), and without bothering with the date (since the source site takes the current date and time as references anyway, no need to input them anywhere): you can directly parse the address above (i.e. https://www.fotmob.com/leagues?id=87&tab=overview&type=league for La Liga, but you can iterate leagues just by putting the league ID in a Rainmeter variable) with Rainmeter's WebParser. I understand that you don't like regex very much, but I already enumerated the methods that one uses to build the regex patterns appropriately for any site providing a suitable source data. The hard thing is here to actually find such a site (which you already did, as it provides both correct tables and fixtures), designing one or a couple of regexex to parse it is not that difficult. Also, there is MUCH less work than having a ton of files to code (PHP, INC, INI) like you have now in your skin, this thing can be done (images aside) in just a single INI file, really. :confused:

I'm a bit busy now with my own Lua tasks (which are a success already, now it's about adding stuff), but I'll see what I can do to help - if you don't figure things out already in the meantime, that is... :sly:
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth
User avatar
Chiripa
Posts: 12
Joined: March 23rd, 2021, 3:49 pm

Re: Football (soccer...) skin

Post by Chiripa »

Thank you very much for the help!!! I if I wanted it to be totally independent, but I'm not really a programmer, I know a bit of everything and it costs me because there are things that I don't understand, even if you help me with the grateful regex! Fotmob really is a good application for android, it has everything and more, but there is none for pc that I know of, as for the number of leagues, they are all identified

this code brings you all the results every 15 or 30 seconds
https://www.fotmob.com/matches?date=20210410

https://images.fotmob.com/image_resources/logo/teamlogo/8636.png you get the team logo

https://www.fotmob.com/leagues?id="teamcode"&tab=overview&type=league the table also brings all the matches and the scorers' ranking

https://www.fotmob.com/leagues?id="teamcode"&tab=matches&type=league&timeZone=America%2FCaracas
It is brought all the days and can be adjusted to local time

I am translating with google translator I hope it is not so annoying I do not know much about English
User avatar
Yincognito
Rainmeter Sage
Posts: 7125
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Football (soccer...) skin

Post by Yincognito »

Chiripa wrote: April 10th, 2021, 3:28 pm Thank you very much for the help!!! I if I wanted it to be totally independent, but I'm not really a programmer, I know a bit of everything and it costs me because there are things that I don't understand, even if you help me with the grateful regex! Fotmob really is a good application for android, it has everything and more, but there is none for pc that I know of, as for the number of leagues, they are all identified

this code brings you all the results every 15 or 30 seconds
https://www.fotmob.com/matches?date=20210410

https://images.fotmob.com/image_resources/logo/teamlogo/8636.png you get the team logo

https://www.fotmob.com/leagues?id="teamcode"&tab=overview&type=league the table also brings all the matches and the scorers' ranking

https://www.fotmob.com/leagues?id="teamcode"&tab=matches&type=league&timeZone=America%2FCaracas
It is brought all the days and can be adjusted to local time

I am translating with google translator I hope it is not so annoying I do not know much about English
Hehe, don't worry - I already started to see what can be done about it:
- I didn't know about the first link (the one with the date)
- I already figured out how to - dynamically - get the team logos (your 2nd link)
- already got the teams in nice regexes - just not the team details yet, but those are easy (your 3rd link)
- I'm not quite sure if I'm interested in the 4th link, since the 3rd link (which I'm using now) brings a ton of data, including all the 380 fixtures in the league (in case of Spanish La Liga).

So, the fixtures exist in the source JSON of the 3rd link. However, I might be interested in the time zone feature / parameter. I just checked, and it seems it can be applied to the 3rd link as well, like (for La Liga):

Code: Select all

https://www.fotmob.com/leagues?id=87&tab=overview&type=league&timeZone=America%2FCaracas
Too bad the time zone thing doesn't seem to work with numerical values, like 1, 2, etc. It seems to expect the time zone name...

Anyway, things are more than ok at the moment, all the source data is parsed, just not at the lower levels (i.e. the details) yet. This is how my Variables.inc looks like (you can see the regexes and the variables used in those regexes there):

Code: Select all

[Variables]
; Football Site
FootballSite=https://www.fotmob.com/leagues?id=[#LeagueID]&tab=overview&type=league
; League ID
LeagueID=87
; Various Patterns
Stop=(?>,|\{|\[|\]|\}|$)
TrimUnwanted='(?:^\s*"|"\s*$)':""
GetLogoID="(?siU)^.*\/teams\/(.*)\/.*$":"[\x200B]\1[\x200B]"
Cleaner="(?:^[^[\x200B]].*|.*[^[\x200B]]$)":"","(?:^[\x200B]|[\x200B]$)":"","(?:^\\\d+|\\\d+$)":""
; Level 3 Patterns
Team=(?(?=.*\{).*\{(.*)\})
; Level 2 Patterns
Table=(?siU)^.*#Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team##Team#.*$
; Level 1 Patterns
Fixtures=(?(?=.*"fixtures":\[\{).*"fixtures":\[\{(.*)\}\])
News=(?(?=.*"news":\[\{).*"news":\[(\{.*\})\])
TableData=(?(?=.*"tableData":\{).*"tableData":\{.*"tables":\[\{.*"legend":\[(\{.*\})\].*"table":\[(\{.*\})\].*\}\})
TopPlayers=(?(?=.*"topPlayers":\{).*"topPlayers":\{([^\{\[\]\}]*\[.*\][^\{\[\]\}]*)\})
; Football Pattern
Football=(?siU)^.*\{.*"details":\{.*"name":(.*),.*"country":(.*)\}#Fixtures##News##TableData##TopPlayers#.*\}.*$
; Visual Configuration
BackColor=48,48,48,255
EditColor=32,32,32,255
PushColor=64,64,64,255
Padding=5
Visually, it's nothing really done, the skin just shows the name of the league (LaLiga) and the logo for the 1st place in that league (currently, Atletico Madrid), as the visuals were used just for testing stuff for now, but the measure values (those measures that were written already) are all there in the Log:
Football.jpg
Although not yet complete or even half complete, for the record, here's the current INI code (besides the one of Variables.inc above):

Code: Select all

[Variables]
@IncludeVariables=#@#Variables.inc

[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1
BackgroundMode=2
SolidColor=#BackColor#
SkinWidth=800
SkinHeight=600

---Measures---

[FootballSite]
Measure=WebParser
Url="#FootballSite#"
UserAgent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.106 Safari/537.36
RegExp=#Football#
UpdateRate=3600
FinishAction=[!UpdateMeasureGroup "SiteGroup"][!CommandMeasure Logo01 "Update"][!UpdateMeter *][!Redraw]
OnConnectErrorAction=[!UpdateMeasureGroup "SiteGroup"][!CommandMeasure Logo01 "Update"][!UpdateMeter *][!Redraw]
OnRegExpErrorAction=[!UpdateMeasureGroup "SiteGroup"][!CommandMeasure Logo01 "Update"][!UpdateMeter *][!Redraw]
DynamicVariables=1

[League]
Group=SiteGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=1
UpdateDivider=-1
RegExpSubstitute=1
Substitute="#TrimUnwanted#"

[Country]
Group=SiteGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=2
UpdateDivider=-1
RegExpSubstitute=1
Substitute="#TrimUnwanted#"

[Fixtures]
Group=SiteGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=3
UpdateDivider=-1

[News]
Group=SiteGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=4
UpdateDivider=-1

[Legend]
Group=SiteGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=5
UpdateDivider=-1

[Table]
Group=SiteGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
UpdateDivider=-1

[Players]
Group=SiteGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=7
UpdateDivider=-1

[Team01]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=1
UpdateDivider=-1
LogSubstringErrors=0

[Team02]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=2
UpdateDivider=-1
LogSubstringErrors=0

[Team03]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=3
UpdateDivider=-1
LogSubstringErrors=0

[Team04]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=4
UpdateDivider=-1
LogSubstringErrors=0

[Team05]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=5
UpdateDivider=-1
LogSubstringErrors=0

[Team06]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=6
UpdateDivider=-1
LogSubstringErrors=0

[Team07]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=7
UpdateDivider=-1
LogSubstringErrors=0

[Team08]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=8
UpdateDivider=-1
LogSubstringErrors=0

[Team09]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=9
UpdateDivider=-1
LogSubstringErrors=0

[Team10]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=10
UpdateDivider=-1
LogSubstringErrors=0

[Team11]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=11
UpdateDivider=-1
LogSubstringErrors=0

[Team12]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=12
UpdateDivider=-1
LogSubstringErrors=0

[Team13]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=13
UpdateDivider=-1
LogSubstringErrors=0

[Team14]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=14
UpdateDivider=-1
LogSubstringErrors=0

[Team15]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=15
UpdateDivider=-1
LogSubstringErrors=0

[Team16]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=16
UpdateDivider=-1
LogSubstringErrors=0

[Team17]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=17
UpdateDivider=-1
LogSubstringErrors=0

[Team18]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=18
UpdateDivider=-1
LogSubstringErrors=0

[Team19]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=19
UpdateDivider=-1
LogSubstringErrors=0

[Team20]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=20
UpdateDivider=-1
LogSubstringErrors=0

[Team21]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=21
UpdateDivider=-1
LogSubstringErrors=0

[Team22]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=22
UpdateDivider=-1
LogSubstringErrors=0

[Team23]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=23
UpdateDivider=-1
LogSubstringErrors=0

[Team24]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=24
UpdateDivider=-1
LogSubstringErrors=0

[Team25]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=25
UpdateDivider=-1
LogSubstringErrors=0

[Team26]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=26
UpdateDivider=-1
LogSubstringErrors=0

[Team27]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=27
UpdateDivider=-1
LogSubstringErrors=0

[Team28]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=28
UpdateDivider=-1
LogSubstringErrors=0

[Team29]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=29
UpdateDivider=-1
LogSubstringErrors=0

[Team30]
Group=SiteGroup | TableGroup
Measure=WebParser
Url=[FootballSite]
StringIndex=6
RegExp=#Table#
StringIndex2=30
UpdateDivider=-1
LogSubstringErrors=0

[PageUrl01]
Group=SiteGroup
Measure=String
String="/teams/9906/overview/atletico-madrid"
UpdateDivider=-1

[LogoID01]
Group=SiteGroup
Measure=String
String="[PageUrl01]"
UpdateDivider=-1
RegExpSubstitute=1
Substitute="#GetLogoID#","#Cleaner#"
DynamicVariables=1

[Logo01]
Group=SiteGroup
Measure=WebParser
URL=https://images.fotmob.com/image_resources/logo/teamlogo/[&LogoID01]_xsmall.png
Download=1
UpdateDivider=-1
DynamicVariables=1

---Styles---

[TextStyle]
FontFace=Consolas
FontColor=255,255,255,255
FontSize=8
Padding=#Padding#,#Padding#,#Padding#,#Padding#
AntiAlias=1
ClipString=1

---Meters---

[Title]
Meter=String
MeterStyle=TextStyle
X=(#CURRENTCONFIGWIDTH#/2)
W=(#CURRENTCONFIGWIDTH#*0.75)
FontSize=10
FontWeight=700
StringAlign=Center
MeasureName=League
Text="%1"
UpdateDivider=-1

[Logo01Image]
Meter=Image
X=(#CURRENTCONFIGWIDTH#/2)
Y=(#CURRENTCONFIGHEIGHT#/2)
MeasureName=Logo01
UpdateDivider=-1
The idea is to make it work for ANY league that exists in the source data, not just for the big ones, To be able to scroll with the mouse (or click some arrows) through the leagues, display the current league table and other features like all the fixtures and their data, top player stats, even the clickable news that one could then open and read in his browser. At the moment, it became quite easy to do, having the base regexes built, but there will be a TON of measures/meters, a lot of copy paste and modify small bits of data, since my suggestion regarding a #CURRENTSECTIONINDEX# variable that could make lots of copy pasted stuff easier fell on deaf ears.
You do not have the required permissions to view the files attached to this post.
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth
User avatar
Chiripa
Posts: 12
Joined: March 23rd, 2021, 3:49 pm

Re: Football (soccer...) skin

Post by Chiripa »

O.O :jawdrop :o What a hell, I like 300 years to do that minimum! that you did in a few hours. Now it's like what I did is useless haha and what you did I hardly understand! I do not know what to do now :confused: :?
User avatar
Yincognito
Rainmeter Sage
Posts: 7125
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Football (soccer...) skin

Post by Yincognito »

Chiripa wrote: April 11th, 2021, 2:07 pm O.O :jawdrop :o What a hell, I like 300 years to do that minimum! that you did in a few hours. Now it's like what I did is useless haha and what you did I hardly understand! I do not know what to do now :confused: :?
What you did is NOT useless! There are multiple ways of achieving something, and both your way and mine are valid. Sure, various ways have different advantages and disadvantages, but that alone doesn't make a way or another useless. I worked in PHP as well many years ago, and I liked it, though I probably forgot many things in the meantime, so I know it's powerful.

Regarding the fact that you don't understand what I did, that can be solved, LOL. I can explain it to you, if you really want to wrap your head around the methods - that's not a problem. I fully believe that once someone understands the "basics", or the key elements of the method and how they work, the whole thing becomes much easier. What I'm trying to say is that you don't need to understand any of those regexes as a whole right now - all you need to do is to understand what each little notation in regex does (and they're not so many, it's like less than 10 mini-patterns that are commonly used, really), and then you'll be able to realize what the bigger parts do. Apart from the regexes, you probably do understand better the Rainmeter parts, right?

Anyway, right now things did indeed become longer and a bit more complex in certain areas, but don't worry, most of the stuff is just a lot of copy paste anyway...

Variables.inc:

Code: Select all

[Variables]
; Football Site
FootballSite=https://www.fotmob.com/leagues?id=[#LeagueID]&tab=overview&type=league
; League ID
LeagueID=87
; Various Patterns
TrimUnwanted='(?:^\s*[#"\[]|[\]"]\s*$)':""
Cleaner="(?:^[^[\x200B]].*|.*[^[\x200B]]$)":"","(?:^[\x200B]|[\x200B]$)":"","(?:^\\\d+|\\\d+$)":""
; Level 4 Patterns
RankData=(?siU)^.*"title":(.*),"color":(.*),"indices":(\[.*\])(?:,.*$|$)
TeamData=(?siU)^.*"qualColor":(.*),"idx":(.*),"name":(.*),"id":(.*),"pageUrl":(.*),"played":(.*),"wins":(.*),"draws":(.*),"losses":(.*),"scoresStr":(.*),"goalConDiff":(.*),"pts":(.*),"deduction":(.*)(?:,.*$|$)
; Level 3 Patterns
Item=(?(?=.*\{).*\{(.*)\})
; Level 2 Patterns
Legend=(?siU)^.*#Item##Item##Item##Item##Item##Item##Item##Item##Item##Item#.*$
Table=(?siU)^.*#Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item##Item#.*$
; Level 1 Patterns
Fixtures=(?(?=.*"fixtures":\[\{).*"fixtures":\[\{(.*)\}\])
News=(?(?=.*"news":\[\{).*"news":\[(\{.*\})\])
TableData=(?(?=.*"tableData":\{).*"tableData":\{.*"tables":\[\{.*"legend":\[(\{.*\})\].*"table":\[(\{.*\})\].*\}\})
TopPlayers=(?(?=.*"topPlayers":\{).*"topPlayers":\{([^\{\[\]\}]*\[.*\][^\{\[\]\}]*)\})
; Football Pattern
Football=(?siU)^.*\{.*"details":\{.*"id":(.*),.*"name":(.*),.*"country":(.*)\}#Fixtures##News##TableData##TopPlayers#.*\}.*$
; Visual Configuration (BW, BH = Background Width, Height; SW = Stroke Width; CR = Corner Radius; LS = League Logo Size; PerCol = Column Width Percent)
BW=800
BH=600
SW=4
CR=32
LS=32
Padding=5
PerCol01=0.1
PerCol02=0.1
PerCol03=0.1
PerCol04=0.1
PerCol05=0.1
PerCol06=0.1
PerCol07=0.1
PerCol08=0.1
PerCol09=0.1
PerCol10=0.1
BackColor=0,0,0,128
EditColor=32,32,32,255
PushColor=108,108,108,128
StroColor=128,128,128,192
TextColor=255,255,255,255
HexaAlpha=44
ArrowHoverColor=255,128,0,255
ArrowPressColor=255,160,0,255
; Logos (the ones saved / cached on disk, in the DownloadFile folder)
DskLeagueLogos=87,
DskTeamLogos=9906,8634,8633,
Football.ini (too many characters for a forum message, so I had to attach it):
Football.ini
Still not much on the visual side, but considering that now getting the table part of the data is largely functionally complete, it can be added to the skin bit by bit (or should I say, column by column and row by row) - as you can see, I only began adding the table header elements now, the elements themselves are visible in the Log measures:
Football Skin.jpg
Giving the increased amount of skin refreshes needed to seen how things look, the skin is now working locally (i.e. doesn't connect to the site for the time being, since the online options have been commented out), with the help of the following files placed in the @Resources folder of the skin (aka where Variables.inc is also located):
Football Skin - Local Source Data.rar
Also, the logos are accessed from the site only the first time. They are then downloaded / cached to the DownloadFile subfolder in the skin's folder:
DownloadFile.rar
and the following times the skin uses those logos, it does so locally without polling the site again just for that. The skin maintains a list with the locally downloaded logos in the DskLeagueLogos and DskTeamLogos variables from Variables.inc, so the contents of the DownloadFile folder above might be needed for the skin to show the (only 2, currently) logos.

That being said, what can I say regarding what you should do? It's up for you to decide. Generally, you should do the things you're most comfortable with, while also considering their efficiency. I will continue to work on this skin for now, irrespective if you use it or not, so no need to worry (I like football too, you know... ). I'll be able to better explain what each thing does later on, when I'm relatively satisfied with the current stage of the progress in the skin, e.g. at least once I have a fully functional table represented visually (this shouldn't take long, since it's all about the artistic design and adding stuff visually for the time being).
You do not have the required permissions to view the files attached to this post.
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth
User avatar
Chiripa
Posts: 12
Joined: March 23rd, 2021, 3:49 pm

Re: Football (soccer...) skin

Post by Chiripa »

Image

This is how the one I have currently looks, but I still need to move between days!
User avatar
Yincognito
Rainmeter Sage
Posts: 7125
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Football (soccer...) skin

Post by Yincognito »

Chiripa wrote: April 11th, 2021, 6:41 pmThis is how the one I have currently looks, but I still need to move between days!
Nice, I see development in your skin as well (the fixtures part, the qualification colors, and so on). :thumbup: Just curious, how are you displaying the matches just for a certain day? Is the site doing the filtering through the URL parameters or you're doing that filtering in PHP or otherwise? My idea in the related skin was to just display the whole 380 fixtures in a taller panel/skin toggled by pushing a button in the main table skin, and let the user move through that list at will, wherever he wants. Also, where do you get the minutes in the game? The links you provided don't show such fields...

EDIT: Maybe you're just subtracting the match starting time from the now time? But for that you'd have to take into account the half break.
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth