topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Sunday December 15, 2024, 4:59 am
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Last post Author Topic: DONE: RandomPlayer - play a mp3 file at (almost) random intervals  (Read 44770 times)

wr975

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 369
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #25 on: February 05, 2011, 07:03 PM »
Well, works here. Did you restart the script after changing the ini?

What is the tray tip saying (if you hover the mouse cursor over the icon)?

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #26 on: February 06, 2011, 02:15 AM »
Well, works here. Did you restart the script after changing the ini?

I started with a new ini due to the changes/updates, so yes.

What is the tray tip saying (if you hover the mouse cursor over the icon)?

It wanted to play the next file in x minutes, so no sign of sleep mode there either. I'll do some more testing.

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #27 on: February 11, 2011, 02:30 AM »
Last night RandomPlayer ignored the sleep times again. I hovered over the tray icon after that happened: no sign of sleep mode.

I then reloaded the script, and the info changed to sleep mode.

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #28 on: February 13, 2011, 02:10 AM »
Last night I looked at the tray info, and this time it was correctly in sleep mode, but displaying the time in a strange way: "Sleep mode between -HHMM..." (HHMM being the no_sounds_end time)

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #29 on: February 16, 2011, 08:12 AM »
Two more feature ideas:

- a right-click option at the top of the tray menu: "Replay last file" (that doesn't influence when the next file is being played)
- a settings option where you can select if "Replay last file" or "Reload script" is the default action for double-clicking the icon

wr975

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 369
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #30 on: February 17, 2011, 03:57 AM »


I hope the problems with the "sleep" function are gone, after my bug fix.

The issue with the locked file should be resolved now, with using "Soundplay,...,wait".

I've added the "repeat last sound" function in the tray menu, and also made "stop sound" and "force next". "force next" will just play the next sound without waiting, but won't do anything while in "sleep mode".

Default tray action (double-click) can be configured in the ini file.


So, that's it with the script. Unless you find a serious bug, I won't touch it again. :-)

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #31 on: February 17, 2011, 08:21 AM »
Awesome! I'll update right away and will post again should any bug show up.

Thank you, this turned out into a great coding snack!  :up:

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #32 on: September 20, 2011, 02:49 AM »
I love this little program!  :-*

We could debate if this is a *serious* bug, but IF you ever touch the code again, please fix this:
- "force next song" doesn't override blacklisted processes (there's no way you can *make it* it play the next file while a blacklisted process is active)


wr975

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 369
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #33 on: September 20, 2011, 04:48 AM »
There's no need to argue, it's clearly a design bug.  ;)

So, there, here you have it. "Force next" as it should be, ignoring everything and just play the next sound.

It's completely untested, but I hope it works.


brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #34 on: September 20, 2011, 05:32 AM »
A big thank you!


brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #35 on: December 28, 2011, 07:16 AM »
Not sure if this really is a bug, but I feel RandomPlayer could play stuff more random than it does. It's more of a feeling than an exact measure... so maybe it's just selective attention.  8)

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 5,287
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #36 on: December 28, 2011, 03:23 PM »
Welcome to the pseudo-random random of computers.   :D

wr975

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 369
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #37 on: December 28, 2011, 03:42 PM »
Welcome to the pseudo-random random of computers.   :D

I hate it when I put 20h of music in Winamp, click "shuffle" and within two hours I hear the same song three times. ;-)

Not sure if this really is a bug, but I feel RandomPlayer could play stuff more random than it does. It's more of a feeling than an exact measure... so maybe it's just selective attention.

The script writes a history file to remember what it played. Let's say you got 15 files in your songlist. It won't repeat any file, until it played all 15 files. Then it erases its history file and starts again. Of course, this is not perfect. If you're in bad luck, file 15 and file 01 can be the same file. Guess such situations happen to you ocassionally, making you wonder why it's sometimes "less random".

If it wouldn't erase the history file, but keep the last 5 entries, it would be better. But this would've been more code lines than the whole "random history" thing.

Anyway, adding more files to your playlist is the best you can do.

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #38 on: January 03, 2012, 10:23 AM »
The script writes a history file to remember what it played. Let's say you got 15 files in your songlist. It won't repeat any file, until it played all 15 files. Then it erases its history file and starts again. Of course, this is not perfect. If you're in bad luck, file 15 and file 01 can be the same file. Guess such situations happen to you ocassionally, making you wonder why it's sometimes "less random".
I had that too once :) What I meant though is that I got the impression that the list itself is not always randomized, like when 2 files that are listed below each other (out of 50+ total) are picked directly after each other more often than what would feel random to me.

Since I don't know what randomization code/method you use I have no idea if that could influence it.

wr975

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 369
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #39 on: January 03, 2012, 12:40 PM »
I'd like to test it. Could you zip all files (including sound files) and send it to me (attached to a PM)?

brotherS

  • Master of Good Ideas
  • Honorary Member
  • Joined in 2005
  • **
  • Posts: 2,261
    • View Profile
    • Donate to Member
Re: DONE: RandomPlayer - play a mp3 file at (almost) random intervals
« Reply #40 on: January 03, 2012, 04:11 PM »
That sadly won't work since a lot of the files are quite personal to me.