plugin/startup event crash?

Help each other out

plugin/startup event crash?

Postby S Pittaway on Fri Mar 24, 2006 5:43 pm

i wrote a little plugin to give me discite on offs for milkdrop, shuffle etc and it works fine, apart from 1 funny...

i wanted to start xlobby with repeat, shuffle, snap tack all turned un, so i added a call to my plugin in the startup event and xlobby hangs on the starting screen...

i dug a litle deeper and
m_Helper.SendCommand("command:music:repeat:");
m_Helper.SendCommand("command:music:shuffle:");
m_Helper.SendCommand("command:music:snap track:");
All cause xlobby to hang when i call it from the startup event?


The plubin is really simple, they are all varients on -

protected m_Repeat = false;

public void Execute(string command)
{
if (command.StartsWith("repeat"))
{
bool NewValue;

if (!bool.TryParse(command.Substring(6), out NewValue))
NewValue = !m_Repeat;

if (NewValue != m_Repeat)
{
m_Repeat = !m_Repeat;
m_Helper.SendCommand("command:music:repeat:");
}
}
}


Am i doing something stupid?

Cheers, Sean.
S Pittaway
 
Posts: 651
Joined: Wed Jan 25, 2006 11:08 am
Location: Manchester, England

Postby Colby on Fri Mar 24, 2006 10:04 pm

what is "...give me discite on offs... "? What does that mean?

I dont know about plugins, but if you want Xlobby to start with events on, the you could make startup events, or maybe a page event for the splash screen? Anyway, just add those commands like shuffle, etc to your startup event.
Colby
 
Posts: 929
Joined: Mon Feb 02, 2004 7:42 am
Location: Brookline Station, MO, USA

Postby S Pittaway on Fri Mar 24, 2006 11:42 pm

by discrete i mean i want to be able to set it on or off not just toggle it...

ie, whenever i hit play on a album i always turn shuffle off, if i hit jukebox it playes all of the songs on my hard disk, but they are shuffled.

Using shuflle, if i hit the jukebox button twice, it is no longer shuffled.

Is there a way bult into xlobby to let me do this?



Anyway, i do have repeat etc in the startup event, it would just be nicer set them via my plugin - i use it everywhere else.
S Pittaway
 
Posts: 651
Joined: Wed Jan 25, 2006 11:08 am
Location: Manchester, England

Postby S Pittaway on Fri Mar 24, 2006 11:46 pm

and i ment discrete not discite :wink:
S Pittaway
 
Posts: 651
Joined: Wed Jan 25, 2006 11:08 am
Location: Manchester, England