It is currently May 2nd, 2024, 1:16 am

First Skin Help "Mumble Skin"

Get help with creating, editing & fixing problems with skins
Ominae
Posts: 6
Joined: February 1st, 2012, 2:35 pm

First Skin Help "Mumble Skin"

Post by Ominae »

Hi there folks.

TBH i am new to the rainmeter and makin skins for it but
i run a few mumble servers for clans so i dicided to try and
make a mumble skin so i could monitor one or 2 of them.

the skin atm is loading but not showing any any of the server infomation
i would appreciate it if some one could look over what i have done
and point out where i have gone wrong.

all i have written has come from guides and using the Enigma bits as my
reference points.

this is my ini file.

Code: Select all

;=================================================
; Rainmeter configuration file
; Updated Feb 01, 2012
;=================================================

;[BEGIN CONFIG FILE]==============================

[Rainmeter]
Author=Mark Dransfield
Update=1000

;Metadata added by RainBrowser
;http://rainmeter.net/RainCMS/?q=Rainmeter101_AnatomyOfASkin

[Metadata]
Name=Eodo 808
Config=
Description=A skin to view who is on a given Mumble voice server.
Instructions=Run and away you go
Version=0.1
Tags=
License=None
Variant=
Preview=

;End of added Metadata

[Variables]
URL="http://viewer.mymumble.de/?i=82"
FontColor=225,225,225,255
FontFace=
Substitute="&":"&",""":"","&Quot;":"","<br>":"","![CDATA

[":"","]]":"","...":"","<":"",">":"","/PRE>":"","PRE>":"","<":""
GET=<img src="classes/output/xhtml/icons/talking_on.png" alt="" />\s*([a-zA-Z_.\-]+)

;[WEBSITE MEASURES]==============================

[MeasureWebsite]
Measure=Plugin
Plugin=Plugins\WebParser.dll
UpdateRate=60
Url=#URL#
RegExp="(?si)<div class="mumble_server">(.*)</div>"
Debug=1

[MeasurePerson]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
RegExp="(?si)#GET##GET##GET##GET##GET#"
ErrorString="Error Brad Broke This"


[1Person]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasurePerson]
StringIndex=1

[2Person]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasurePerson]
StringIndex=2

[3Person]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasurePerson]
StringIndex=3

;[DISPLAY METERS]===============================

[MeterBackground]
Meter=IMAGE
X=1
Y=1
H=340
W=180
SolidColor=255,255,255,205

[Meter1Person]
MeasureName=1Person
Meter=STRING
X=1
Y=1
FontColor=#FontColor#
FontSize=18
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1

[Meter2Person]
MeasureName=2Person
Meter=STRING
X=1
Y=25
FontColor=#FontColor#
FontSize=18
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1

[Meter3Person]
MeasureName=3Person
Meter=STRING
X=1
Y=50
FontColor=#FontColor#
FontSize=18
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1
many thanx for takin the time guys an gals.
User avatar
Brian
Developer
Posts: 2689
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: First Skin Help "Mumble Skin"

Post by Brian »

There are several things going on here.
1. If you look at the source of your URL (http://viewer.mymumble.de/?i=82), it does not contain the '<div class="mumble_server">' you defined in your Regexp.
2. You have an extra layer of child webparser measures that don't need to be there.
3. <img src="classes/output/xhtml/icons/talking_on.png" alt="" /> is not found in the source.
4. And you have a white background displaying white text.

So to fix it do this:
1. Delete the extra child measure, just do your regular expressions in the parent measure.
2. Revise your regular expressions to grab the data you want (I am going to assume you want the user name)
3. Change either the background color, or font color.

Here is something to get you started.

Code: Select all

;=================================================
; Rainmeter configuration file
; Updated Feb 01, 2012
;=================================================

;[BEGIN CONFIG FILE]==============================

[Rainmeter]
Author=Mark Dransfield
Update=1000

;Metadata added by RainBrowser
;http://rainmeter.net/RainCMS/?q=Rainmeter101_AnatomyOfASkin

[Metadata]
Name=Eodo 808
Config=
Description=A skin to view who is on a given Mumble voice server.
Instructions=Run and away you go
Version=0.1
Tags=
License=None
Variant=
Preview=

;End of added Metadata

[Variables]
URL="http://viewer.mymumble.de/?i=82"
FontColor=225,225,225,255
FontFace=
Substitute="&":"&",""":"","&Quot;":"","<br>":"","![CDATA[":"","]]":"","...":"","<":"",">":"","/PRE>":"","PRE>":"","<":""
GET=(?(?=.*<img.* />).*<img.* />(.*)</div>)

;[WEBSITE MEASURES]==============================

[MeasureWebsite]
Measure=Plugin
Plugin=Plugins\WebParser.dll
UpdateRate=60
Url=#URL#
RegExp="(?siU)(?(?=.*<div class="viewer">).*<div class="viewer">#GET##GET##GET##GET##GET#)"
ErrorString="Error Brad Broke This"

[1Person]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=1

[2Person]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=2

[3Person]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=3

;[DISPLAY METERS]===============================

[MeterBackground]
Meter=IMAGE
X=1
Y=1
H=340
W=180
SolidColor=0,0,0,255

[Meter1Person]
MeasureName=1Person
Meter=STRING
X=1
Y=1
FontColor=#FontColor#
FontSize=18
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1

[Meter2Person]
MeasureName=2Person
Meter=STRING
X=1
Y=25
FontColor=#FontColor#
FontSize=18
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1

[Meter3Person]
MeasureName=3Person
Meter=STRING
X=1
Y=50
FontColor=#FontColor#
FontSize=18
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1
As you can see, I changed your regexp code to incorporate look ahead assertions. I also changed your background to black for readability.

-Brian
Ominae
Posts: 6
Joined: February 1st, 2012, 2:35 pm

Re: First Skin Help "Mumble Skin"

Post by Ominae »

chears for that dude...

though i have to admit i understand a fraction of what your sayin loool
steep learning curve hahahah 3 days with rainmeter an 1 day tryin to
read up on the skin makin lol... prity much wrote the skin with out understanding
a thing :P



once agen though Many thanx i will sit down iwth it and see how i get one..

mark :)

Edit: "slowly comin to life for 3 fo the channels visible now :P "
Ominae
Posts: 6
Joined: February 1st, 2012, 2:35 pm

Re: First Skin Help "Mumble Skin"

Post by Ominae »

okay gettin stuck on somin here.

sat down with the code agen trying to get this sorted
you will ahve to forgive me being rather stupid on this
but anyway trying to make the changes you sujested,
atm if i load the skin as it is i see 3 entries from my server
the first 3 channels or 2 channels and a user.

i try to make changes and the whole skin seems to crash
also the auto refresh rate dun seem to be working :S
i have to manuely refresh the skin to see any change
on the server.....

will keep trying though but i think i am in over my ehad with this project


many thanx mark

Edit Update polling sorted now wish i could drop an iiframe in there lol that would make my life easyer haha
Last edited by Ominae on February 1st, 2012, 8:00 pm, edited 1 time in total.
User avatar
Brian
Developer
Posts: 2689
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: First Skin Help "Mumble Skin"

Post by Brian »

The problem is on my end. I gave you the wrong information. What happened is when I checked that webpage, it did not show any users, and I assumed the channel was a user. That is my bad. Having said that, what exactly is the information you want to display? Just the users? Or Users per channel?

-Brian
User avatar
Brian
Developer
Posts: 2689
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: First Skin Help "Mumble Skin"

Post by Brian »

If you want to just display the player names, then change the "GET" variable to this:
GET=(?(?=.*player_image).*player_image.*>(.*)<div)

If you want to display the player under each channel, then the code is going to get a bit more difficult. I will work on this code and post it when finished.

-Brian
Ominae
Posts: 6
Joined: February 1st, 2012, 2:35 pm

Re: First Skin Help "Mumble Skin"

Post by Ominae »

i want it to show the channels when no one is online and when some one is there
i would like it to update and show the online users also iff poss indented...

eg

AFK
General Chat
Gau
AD

that sorta thing but as it is atm it is limited to showin 3 items with the way it is set up
could i drop in a Iframe to the skin and do it that way????

Left my mumb client logged in so you can see


thanx mark
User avatar
Brian
Developer
Posts: 2689
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: First Skin Help "Mumble Skin"

Post by Brian »

This is quite tricky to implement. I am not very good with regular expressions, so maybe someone will some more expertise can help.

Here is what I have so far:

Code: Select all

;=================================================
; Rainmeter configuration file
; Updated Feb 01, 2012
;=================================================

;[BEGIN CONFIG FILE]==============================

[Rainmeter]
Author=Mark Dransfield
Update=1000
DynamicWindowSize=1

;Metadata added by RainBrowser
;http://rainmeter.net/RainCMS/?q=Rainmeter101_AnatomyOfASkin

[Metadata]
Name=Eodo 808
Config=
Description=A skin to view who is on a given Mumble voice server.
Instructions=Run and away you go
Version=0.1
Tags=
License=None
Variant=
Preview=

;End of added Metadata

[Variables]
URL="http://viewer.mymumble.de/?i=82"
FontColor=225,225,225,255

PLAYER=(?(?=.*player_image).*player_image.*>(.*)<div)
CHANNEL=(?(?=.*channel_lvl_1).*channel_lvl_1.*<img.*>(.*)</div>#PLAYER##PLAYER##PLAYER##PLAYER##PLAYER#)

;[WEBSITE MEASURES]==============================

[MeasureWebsite]
Measure=Plugin
Plugin=Plugins\WebParser.dll
UpdateRate=60
Url=#URL#
RegExp="(?siU)(?(?=.*<div class="viewer">).*<div class="viewer">#CHANNEL##CHANNEL##CHANNEL##CHANNEL##CHANNEL##CHANNEL##CHANNEL#)"
ErrorString="Error Brad Broke This"

[Channel1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=1

[Channel1Person1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
Substitute="":"No Players."
StringIndex=2

[Channel1Person2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=3

[Channel1Person3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=4

[Channel1Person4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=5

[Channel1Person5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=6

[Channel2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=7

[Channel2Person1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
Substitute="":"No Players."
StringIndex=8

[Channel2Person2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=9

[Channel2Person3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=10

[Channel2Person4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=11

[Channel2Person5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=12

[Channel3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=13

[Channel3Person1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
Substitute="":"No Players."
StringIndex=14

[Channel3Person2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=15

[Channel3Person3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=16

[Channel3Person4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=17

[Channel3Person5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=18

[Channel4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=19

[Channel4Person1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
Substitute="":"No Players."
StringIndex=20

[Channel4Person2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=21

[Channel4Person3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=22

[Channel4Person4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=23

[Channel4Person5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=24

[Channel5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=25

[Channel5Person1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
Substitute="":"No Players."
StringIndex=26

[Channel5Person2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=27

[Channel5Person3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=28

[Channel5Person4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=29

[Channel5Person5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=30

[Channel6]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=31

[Channel6Person1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
Substitute="":"No Players."
StringIndex=32

[Channel6Person2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=33

[Channel6Person3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=34

[Channel6Person4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=35

[Channel6Person5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=36

[Channel7]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=37

[Channel7Person1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
Substitute="":"No Players."
StringIndex=38

[Channel7Person2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=39

[Channel7Person3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=40

[Channel7Person4]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=41

[Channel7Person5]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[MeasureWebsite]
StringIndex=42

;[DISPLAY METERS]===============================

;added a meter style to condense code ;)
[ChannelStyle]
FontColor=#FontColor#
FontSize=18
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1
X=0
Y=0R

[PlayerStyle]
FontColor=#FontColor#
FontSize=10
StringAlign=LEFT
FontFace=#FontFace#
Antialias=1
X=10
Y=0R

[MeterBackground]
Meter=IMAGE
X=0
Y=0
H=340
W=225
SolidColor=0,0,0,255

[DisplayChannel1]
Meter=STRING
MeterStyle=ChannelStyle
MeasureName=Channel1
X=0
Y=0

[DisplayChannel1Person1]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel1Person1

[DisplayChannel1Person2]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel1Person2

[DisplayChannel1Person3]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel1Person3

[DisplayChannel1Person4]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel1Person4

[DisplayChannel1Person5]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel1Person5

[DisplayChannel2]
Meter=STRING
MeterStyle=ChannelStyle
MeasureName=Channel2

[DisplayChannel2Person1]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel2Person1

[DisplayChannel2Person2]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel2Person2

[DisplayChannel2Person3]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel2Person3

[DisplayChannel2Person4]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel2Person4

[DisplayChannel2Person5]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel2Person5

[DisplayChannel3]
Meter=STRING
MeterStyle=ChannelStyle
MeasureName=Channel3

[DisplayChannel3Person1]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel3Person1

[DisplayChannel3Person2]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel3Person2

[DisplayChannel3Person3]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel3Person3

[DisplayChannel3Person4]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel3Person4

[DisplayChannel3Person5]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel3Person5

[DisplayChannel4]
Meter=STRING
MeterStyle=ChannelStyle
MeasureName=Channel4

[DisplayChannel4Person1]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel4Person1

[DisplayChannel4Person2]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel4Person2

[DisplayChannel4Person3]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel4Person3

[DisplayChannel4Person4]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel4Person4

[DisplayChannel4Person5]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel4Person5

[DisplayChannel5]
Meter=STRING
MeterStyle=ChannelStyle
MeasureName=Channel5

[DisplayChannel5Person1]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel5Person1

[DisplayChannel5Person2]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel5Person2

[DisplayChannel5Person3]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel5Person3

[DisplayChannel5Person4]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel5Person4

[DisplayChannel5Person5]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel5Person5

[DisplayChannel6]
Meter=STRING
MeterStyle=ChannelStyle
MeasureName=Channel6

[DisplayChannel6Person1]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel6Person1

[DisplayChannel6Person2]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel6Person2

[DisplayChannel6Person3]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel6Person3

[DisplayChannel6Person4]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel6Person4

[DisplayChannel6Person5]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel6Person5

[DisplayChannel7]
Meter=STRING
MeterStyle=ChannelStyle
MeasureName=Channel7

[DisplayChannel7Person1]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel7Person1

[DisplayChannel7Person2]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel7Person2

[DisplayChannel7Person3]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel7Person3

[DisplayChannel7Person4]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel7Person4

[DisplayChannel7Person5]
Meter=STRING
MeterStyle=PlayerStyle
MeasureName=Channel7Person5
The idea is to display each channel, with up to five players per channel (indented a little). However, the problem with my code is that after each channel is found, a player is found even if its in another channel. So, the first 5 players will appear in the first channel even when they are not. I am not sure how to check whether a player is in the channel before it searches the next channel....Hope that made sense.

Maybe someone with some more experience with regular expressions can help out?

-Brian
Ominae
Posts: 6
Joined: February 1st, 2012, 2:35 pm

Re: First Skin Help "Mumble Skin"

Post by Ominae »

thanx for all the help brian.

you got further than i did on my own this is still a very steep
learning curve for me :S maybe a bit more than i shoulda taken
on :) but hey...

but as a side note i take it we carnt drop a HTML iframe or even
some java or php script as i have all 3 of these for the viewer
already :P



-mark
User avatar
Brian
Developer
Posts: 2689
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: First Skin Help "Mumble Skin"

Post by Brian »

Ominae wrote:i take it we carnt drop a HTML iframe or even
some java or php script as i have all 3 of these for the viewer
Rainmeter does not work like HTML, so no, those will not work.....however, Rainmeter does support Lua scripting, and I am positive that what you want can be done. Having said that, I am very very very new to Lua, so I can't help much with that right now.

-Brian