Ulysses

Ulysses Stuff => Releases => Ulysses Release Archives => Topic started by: RynO-SauruS on October 18, 2010, 10:39:59 PM

Title: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on October 18, 2010, 10:39:59 PM
NOTICE
This addon is broken because I haven't updated it for GMod 13, and I'm sorry to say that I've dropped development on it.



YouTube music player by RynO-SauruS


This ULX module allows players to play music from YouTube (the audio from any YouTube video) on the server.


Features:

Client-side GUI player controls (Volume, mute/unmute, shows current time in song/song length):

    (http://i53.tinypic.com/2zxqjpu.jpg)

    Note: the button with the arrows does nothing.

    UPDATE 1.1: The button with the arrows AND the pause/play button have been removed.
    (this is so different clients' position in the song will stay synced with each other, and to keep the player from being auto-hidden before the song is over)
    Also updated with 1.1, the controls are no longer visible when a video isn't playing, and it fades in and out, nice and pretty.



Play videos with a ULX command (<url> argument should be a link to any YouTube video, command is by default admin-only):

    Console: ulx playvid <url>
    Chat: !playvid <url>


New with 1.1:

    Play videos client-side with a ULX command (<url> argument should be a link to any YouTube video, and by default, anyone can use this):

        Console: ulx playvidcl <url>
        Chat: !playvidcl <url>


    Automatically plays in HD (high quality) if the video supports it
    UPDATE 1.1: You can now set the quality manually. (see CVars section)

    Works with videos that have embedding disabled

    Prints the URL and title of the YouTube video in the chat when you play it


Command to stop the video that's playing for all clients (by default, admin-only):

    Console: ulx stopvid
    Chat: !stopvid

    UPDATE 1.1 (changed command name!):
    Console: ulx stopvidall
    Chat: !stopvidall


Command to stop the video client-side (for the player who types it), if a player doesn't want to hear the video (by default, anyone can use this):

    Console: ulx stop
    Chat: !stop

    UPDATE 1.1 (changed command name!):
    Console: ulx stopvid
    Chat: !stopvid


New with 1.1:

Playlist, allows you to save videos to the server and play them later, with a nice little music menu.


    Image:
    (http://i55.tinypic.com/2uyh9pe.jpg)


    "music" command:

        Console: ulx music
        Chat: !music

        Opens the music menu, allowing you to play videos saved on the server.


    "savevid" command:

        Console: ulx savevid <url>
        Chat: !savevid <url>

        Saves the specified video to the server's playlist.


    "savecurvid" command:

        Console: ulx savecurvid
        Chat: !savecurvid

        Saves the currently playing video to the server's playlist.


    "removevid" command:

        Console: ulx removevid <url>
        Chat: !removevid <url>

        Removes a video on the server's playlist.


    "renamevid" command:

        Console: ulx renamevid <url> <new title>
        Chat: !renamevid <url> <new title>

        Renames a video on the server's playlist.

CVars:

    CVar "ulx_songplayer_enable", enabled/disables the music player client-side. (default = "1", enabled)


    CVar "ulx_songplayer_quality", sets the quality of videos client-side. (default = "large", 480p)

        Possible values: "small" = 240p, "medium" = 360p, "large" = 480p, "hd720" = 720p, "hd1080" = 1080p, "highres" = highest quality


Requirements:

Latest ULX and ULib (SVN versions!)


Installation (Scroll down for SVN!):

Extract the attached .rar file to garrysmod/addons.


Changelog:

Code: [Select]

UPDATE 1.41:
-Removed: Debug messages ("Status:", etc.).. Sorry for that.

UPDATE 1.4:
=Fixed: Again, videos not playing since a YouTube update.. and it shouldn't break this time!

UPDATE 1.3:
=Fixed: Videos not playing since the YouTube interface update.. Sorry this took so long!

UPDATE 1.2:
+Addition: "Play for all" and "Play client-side" options to the playlist right-click menu.
*Change: Changed some file names to reflect the current official name of this addon (it was initially called "ULX SongPlayer"). IMPORTANT: This means you MUST remove the folder for the old version before installing this one!
*Change: The shared code is a LOT more clean and efficient, thanks to Megiddo's new logging system.

UPDATE 1.1:
+Addition: A playlist feature has been added! Save a video to the server's playlist with "ulx savevid <url>" (console) or "!savevid <url>" (chat), or save the currently playing video with "ulx savecurvid" (console) or "!savecurvid" (chat), and play saved music by opening the music menu with "ulx music" (console) or "!music" (chat).
+Addition: Added a new ULX command, "ulx playvidcl <url>" (console), "!playvidcl <url>" (chat), plays a video CLIENT-SIDE. By default, anyone can use this.
+Addition: Added 2 client-side CVars, "ulx_songplayer_enable" (enables/disables the music player client-side), and "ulx_songplayer_quality" (sets the quality of videos client-side)
Possible values: "small" = 240p, "medium" = 360p, "large" = 480p, "hd720" = 720p, "hd1080" = 1080p, "highres" = highest quality
*Change: The player controls now automatically hides itself when a video is not playing, with a nice fade in/out.
*Change: Changed the "stop" command (stops video client-side) to "stopvid", and therefore changed the old "stopvid" (stops video for everyone) to "stopvidall".
=Semi-fix: DRASTICALLY reduced the frequency of client crashes (almost never crashes now) when playing or stopping a video.

UPDATE June 26th, 2012 - SVN created. Checkout link:
http://ulx-youtube-jukebox.googlecode.com/svn/trunk/ (EDIT: link fixed, sorry)

Installation instructions:
Install Tortoise SVN (Download (http://tortoisesvn.net/downloads.html)) if you haven't already, create a folder in your "garrysmod/garrysmod/addons" folder named "ULX_YouTube_Jukebox" or whatever you want, then right-click the new folder and select "SVN Checkout...", paste the checkout link I've posted above, and click OK.

Special thanks to:

Megiddo, for answering various questions of mine through Steam PM.
HellFox, for his advice/assistance on this, and giving me some ideas for things, including the "video debug" feature.  :)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Megiddo on October 19, 2010, 09:09:20 AM
Glad you decided to release this Ryno! Hopefully I helped you over Steam more than I confused you. ;)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on October 19, 2010, 04:25:40 PM
Yay! Awesome!
Now Stickly man can direct me to nice Trance tunes while I'm coding Gmod and I won't have to switch screens to input the URL.
Shame I rarely have urge to code much anymore.
:P
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on October 19, 2010, 04:54:00 PM
Thanks!  ;D
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Stickly Man! on October 19, 2010, 06:32:21 PM
Very nice! ;D

Definitely a much better alternative from the full 3D youtube players and such when using it just for music!

Just a few suggestions from me though--

Are the controls supposed to be visible even when there is no song playing? If plausible, you should make it hidden while paused, or maybe even implement a clientside bind/chat command to show/hide it.

Also, perhaps you should consider using the command "ulx playvid stop" or something to that effect instead of "ulx stop" because if admins/users come across the "ulx stop" command in their help, or in XGUI or something, they may be initially confused as to what it does.

Other than that, excellent work! :D

(Oh btw JamminR, I heard this really awesome song the other-- Nevermind, I should wait until you're very very busy and on steam chat before I bug you with more tunes :P)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on October 19, 2010, 10:48:04 PM
Thank you!
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on November 20, 2010, 09:13:50 PM
Big update!

Code: [Select]
UPDATE 1.1:
+Addition: A playlist feature has been added! Save a video to the server's playlist with "ulx savevid <url>" (console) or "!savevid <url>" (chat), or save the currently playing video with "ulx savecurvid" (console) or "!savecurvid" (chat), and play saved music by opening the music menu with "ulx music" (console) or "!music" (chat).
+Addition: Added 2 client-side CVars, "ulx_songplayer_enable" (enables/disables the music player client-side), and "ulx_songplayer_quality" (sets the quality of videos client-side)
Possible values: "small" = 240p, "medium" = 360p, "large" = 480p, "hd720" = 720p, "hd1080" = 1080p, "highres" = highest quality
*Change: The player controls now automatically hides itself when a video is not playing, with a nice fade in/out.
*Change: Changed the "stop" command (stops video client-side) to "stopvid", and therefore changed the old "stopvid" (stops video for everyone) to "stopvidall".
=Semi-fix: DRASTICALLY reduced the frequency of client crashes (almost never crashes now) when playing or stopping a video.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on November 21, 2010, 12:20:09 AM
Some nice updates there Ryno.

How does your play for all work? Does it load the script locally for them?
(Sorry, I've not actually looked at the code/used it)

I may have enhancement suggestion depending on how you do it already.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on November 21, 2010, 06:37:22 AM
The server sends a usermessage to all clients connected, and when they receive the usermessage, their client loads a small block of HTML code in an HTML frame (which has player controls).
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on November 21, 2010, 10:47:48 AM
Ah ok. I'd figured that was playing locally.

Few ideas to get some more thought process going. :D

Perhaps add a way to play to an individual or individuals?
Doing it in 'standard' ULX style would require you move some parameter/variables around in passing to functions.
ulx playvid <player(s)> <url>
Those who use it now would have to get used to it, using ^ for themselves, but would allow admins a bit more control if you wrote that in.

To me, Playvid seems like it would be better served by those with special access/admin privileges.
I wouldn't want a player interjecting on each other on a server I'd run.
So, what about playvidlocal for clients side only?
Write in additional code that allows players to play stuff they want locally. Stored locally on thier machine.
Make there own playlist perhaps, make a separate menu, whatever, yet still allow playing stuff from the server.
If you wanted to get really complicated, allow a client option to 'suggest for server' that would allow server admins to see suggestions for the server/approve later.
Or some type of share command. One player plays non-server stored song. Makes comment to others about how awesome it is and to explain why he's bunny hopping around the map. :P
Others ask to hear it. Player listening runs sharevid <player(s)> <url> and the other players don't get forced to play it, but script asks them if they want to listen.

Ok. That's enough to get your mind going for now. Some of that now that I look back seems to complicate it (ULX Motto, striving for simplicity), but thinking you might find nice
compromises.

These mind stream of thoughts brought to you by The Glitch Mob - How to Be Eaten by a Woman (http://www.youtube.com/watch?v=HFTYu9x66es&hd=1)
(Though they have a few good ones I've been jamming (see, see, "Jammin"R) to last night and this morning, that one was cranked while writing the above.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on November 21, 2010, 12:30:13 PM
Aw man! I was wondering why you didn't seem to know about the "ulx playvidcl" command! This is something I also added with 1.1.
Then I realized.. I forgot that pre-1.1 didn't have it, so I didn't think to mention it in the update news. Whoops! I'll update that now. ;)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: StanTheMan on December 20, 2010, 05:43:50 PM
Hi there!

Is it possible to hide that "play bar".
People said its gettin realy annoying after a while.  :o

Stan
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on January 08, 2011, 08:22:06 PM
Hi there!

Is it possible to hide that "play bar".
People said its gettin realy annoying after a while.  :o

Stan

Hi!

Sorry I took so long to respond. I made it auto-hide the player bar when a song is playing in the latest version, you just need to update.
The download link is in the first post.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Ronin on February 13, 2011, 03:35:26 PM
I'd want to report a bug whereas when the music doesn't play for me, but the video is showing the time going through the vid still, and I attempt to stop it, that causes my listen server to crash, and I would expect it to happen for dedicated servers as well probably.  Just something I wanted to address as an issue I am having currently. 

EDIT:  Not necessarily crash, but freezes my game, and always ending up where I have to ctrl-alt-delete myself out of it, I'll try to let it stay and see what happens, if the client-side disconnect time gets reached, then that's the real issue.

Other than that, I truly love this dude :D
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on August 07, 2011, 07:40:28 PM
Here's "two" updates! (I actually coded 1.2 several months ago, and somehow forgot to post it :-[)

Important: You MUST remove the folder for the old version before installing this one!

Code: [Select]
UPDATE 1.3:
=Fixed: Videos not playing since the YouTube interface update.. Sorry this took so long!

UPDATE 1.2:
+Addition: "Play for all" and "Play client-side" options to the playlist right-click menu.
*Change: Changed some file names to reflect the current official name of this addon (it was initially called "ULX SongPlayer"). NOTE: This means you MUST delete the addon folder for the old version before installing this one!
*Change: The shared code is a LOT more clean and efficient, thanks to Megiddo's new logging system.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on August 08, 2011, 12:21:18 AM
I was wondering if you could make a playlist feature.

Also if you can make it so more videos can be added to a play list that is playing.

It would also be interesting if you added a command like PlayX's '!ytlast' so when a guest posts a YouTube link into chat I can just type the command and it will play the last link that was posted in chat.

Please and Thank you.

Edit: You Finally hit 2 pages.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on August 08, 2011, 10:43:40 AM
I was wondering if you could make a playlist feature.

Also if you can make it so more videos can be added to a play list that is playing.

It would also be interesting if you added a command like PlayX's '!ytlast' so when a guest post a YouTube link into chat I can just type the command and it will play the last link that was posted in chat.

Please and Thank you.

Edit: You Finally hit 2 pages.

By "playlist feature", do you mean a queue? A list of videos that will automatically play one after another?
The problem with this would be that when one video is "over", and a client has had to buffer the video at some point, then their current video will likely still be playing.
So playing the next video in the queue, would cut off some of what was playing first. I don't think there's any way to tell when the client's video has finished playing, other than setting a timer of the length of the video right at the start. (this is how it auto-hides the player controls.. but when the player controls are hidden, it doesn't stop the video, to avoid cutting it off)

The "!ytlast" command.. I'll look into that. I would obviously need to find a way to get the last YouTube link that was posted.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on August 08, 2011, 02:31:39 PM
By "playlist feature", do you mean a queue? A list of videos that will automatically play one after another?
The problem with this would be that when one video is "over", and a client has had to buffer the video at some point, then their current video will likely still be playing.
So playing the next video in the queue, would cut off some of what was playing first. I don't think there's any way to tell when the client's video has finished playing, other than setting a timer of the length of the video right at the start. (this is how it auto-hides the player controls.. but when the player controls are hidden, it doesn't stop the video, to avoid cutting it off)

The "!ytlast" command.. I'll look into that. I would obviously need to find a way to get the last YouTube link that was posted.

I would say make it wait at max 30 seconds before playing the next video, because I don't see people ever having delays that big unless they are crashing. I also suggest getting the next video to be pre-loaded in the background, that would help to avoid buffering delay.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on August 08, 2011, 02:35:16 PM
I would say make it wait at max 30 seconds before playing the next video, because I don't see people ever having delays that big unless they are crashing. I also suggest getting the next video to be pre-loaded in the background, that would help to avoid buffering delay.

Good idea.. this playlist idea is going to take a lot of work if I decide to do it :D
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Stickly Man! on August 08, 2011, 04:12:47 PM
Easiest way to get the last link is to hook every chat message (lowest priority with ULib) then parse the message for a valid YouTube link. If none, then ignore it. If there is one, then store in in a variable. Piece of cake! (assuming you can figure out regex or other string searching methods supported by gmod Lau. That's also assuming I am correctly understanding how the chat hook works :P  )
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Willdy on August 21, 2011, 11:02:47 AM
I support the playlist, make it shuffle and pick a random song to play :O
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Kazter on December 21, 2011, 06:30:47 PM
How do i install dis?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Aaron113 on December 21, 2011, 06:47:52 PM
The download link appears to be broken.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on December 22, 2011, 10:06:22 PM
How do i install dis?

The download link appears to be broken.

The download link works fine for me, and to install this, just drag and drop it into, your add-ons folder.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Aaron113 on December 23, 2011, 09:41:50 AM
(http://aaron113.com/images/Screenshot-0020.png)
That is what I get when I try to download it.

EDIT:  Looks like attachments are broken for Firefox?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Megiddo on December 23, 2011, 01:08:24 PM
Works fine for me and Stickly Man who is running Firefox. Based off how I assume SMF implements attachments, I think you might have security settings set too high in FF or something in your browser is broken.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on December 23, 2011, 02:32:09 PM
Works fine for me running firefox 6 something.
Looks like your mime encoding recognition is off keel. Try saving the index.php as "ULX_YouTube_music_player1.3.rar".
I'm betting you'd still get the file.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Aaron113 on December 23, 2011, 02:47:56 PM
Hmmm...  Looks like you're right.

(http://aaron113.com/images/Screenshot-0022.png)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on December 23, 2011, 04:57:45 PM
So, on to next question... it still working?
Ryno's at least checked the forums lately. If it's not working due to actual Gmod updates (or ULib), he's likely paying attention.

Offside-..Aaron.. might I recommend 7z instead of Winrar?
It's (bonus!) an open source application. Will pack to zip for compatibility, and unpack rar files using a (not open source of course) special usage license.
Many features I've never even researched. http://www.7-zip.org/ .. good stuff.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: AviZ on January 02, 2012, 04:18:30 PM
i just installed this, no player box when choosing the song to play and no sound either.

is there a fix for this?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: pikkip on January 12, 2012, 07:14:03 AM
uhm it seems to this don't work anymore D= me sad! me dint try it yet! >:(
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on January 14, 2012, 11:51:04 AM
i just installed this, no player box when choosing the song to play and no sound either.

is there a fix for this?

uhm it seems to this don't work anymore D= me sad! me dint try it yet! >:(

Hey folks! Sorry, it seems this has yet again been broken by YouTube updates. I'm currently working on this situation. Sorry I took so long to reply.


Tech-savvy people:
The reason this is happening is because of my rather hackish method of playing the videos, which involves embedding YouTube's .swf flash player directly, rather than using their official "embedded player" (embed code). I was doing it this way because it actually bypassed YouTube's restrictions on some videos, that don't allow them to be embedded.

The problem is, it seems that the location of the .swf file (http://s.ytimg.com/yt/swfbin/watch_as3-vflk8NbNX.swf for example) seems to change alot, and when it does, obviously, it breaks my code.
Does anyone have any ideas of how I might be able to achieve this (play videos that have embedding disabled), and it not be broken with YouTube updates? =/
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on January 14, 2012, 06:06:56 PM
So, this is even more technical than my general capability, but, I'm good with ideas.
What allows the Youtube actual player code to play that 'embedded' won't.
Is it a encrypted code within the player, or is it just some Youtube server expection (POST/GET blah.swf?I_AM_THE_REAL_THING_BABY!).
If not encrypted within the player...can it be faked?

And, on to next idea if a better answer can't be found to your question and my ideas above.
Use RSS feed/embedded player code for most items. The RSS API is prob less likely to change as often.
Find some way to detect (or at worst, teach human using your functions) if the original didn't play due to 'no embed allowed', have second function run that attempts using the 'Youtube' code.
Though it is just as likely to break if/when Youtube updates again, it's less likely to break ALL of this player. :)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on January 14, 2012, 06:21:00 PM
Unfortunately, I haven't the slightest clue what it would take to get the "embedded player" to play videos that have embedding disabled. I suppose it's probably written into the encrypted .swf code to check whether embedding is allowed or not. Because when I play videos by manually embedding the .swf that's used when you play videos on YouTube.com, it doesn't mind whether embedding is enabled or not.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: pikkip on January 14, 2012, 06:21:47 PM
I might got an idea try something like this:

"http://www.youtube.com/watch?v=FEDlSJ-0vr0"

When you use that kind of link... it will use it as something like this:

"<iframe width="560" height="315" src="http://www.youtube.com/embed/FEDlSJ-0vr0?rel=0" frameborder="0" allowfullscreen></iframe>"

also basically where it finds the "http://www.youtube.com/" and uses the other text in another line so it will put in "embed/" and uses that normal youtube code to play the video...

I do not know a lot about this, i am more to e2, HTML5, php, and css3

Hopefully this gave you some ideas ;3
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on January 14, 2012, 06:29:14 PM
Hmm.. I might be able to make it retrieve the location of the .swf automatically from the video page's HTML. Pikkip, I'm not sure if that's what you meant. Could you clarify?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: pikkip on January 14, 2012, 06:31:23 PM
Hmm.. I might be able to make it retrieve the location of the .swf automatically from the video page's HTML. Pikkip, I'm not sure if that's what you meant. Could you clarify?

Uhm... kinda like it finds what is the dirrections, and what is the website...

so it will seperate those 2 to make it put in "embed/" to make it work with the other kind of code i sended you... maybesomething like that or else... its a bit hard to explane
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on January 14, 2012, 07:19:48 PM
Oh, are you just saying play the videos from http://www.youtube.com/embed/ , only in an iframe? I'll try that.

Edit: Nope, playing videos in http://www.youtube.com/embed/ still gives you errors if embedding is disabled. :(

Edit 2: But there is something that seems somewhat promising: http://www.youtube.com/watch_popup?v=97S66xee0U8

The watch_popup page ignores whether embedding is enabled or not. The biggest problem with this is that I can't seem to find a way to make it not hide the player controls. =/ I've tried putting &autohide=0 in the URL (the usual parameter for this, if you're working with the .swf), but sadly it doesn't do anything. =(
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on January 14, 2012, 10:00:07 PM
While tinkering looking for a way to hide the controls (did ya know there's a Javascript API?? Are you already looking into it?), I found this tidbit.
Might be handy for my 'function 1 for embed allowed, function 2 for non allowed' determination idea.
From http://code.google.com/apis/youtube/player_parameters.html#ExampleUsage
BOLD is my doing -
Quote from: Example Usage
If you are using the YouTube Data API, you can programmatically construct these URLs by retrieving the <yt:videoid> tag value in an API entry and replacing the VIDEO_ID text in the URLs above with that value. You should also confirm that the feed entry for the video contains a <media:content> tag for which the value of the yt:format attribute is 5. The absence of that tag indicates that the video owner had disabled embedding for the video.

EDIT - Ryno, the popup video link you included in previous post, 97S66xee0U8 ... does it allow embedding?
If not, using http://code.google.com/apis/youtube/youtube_player_demo.html and pasting in that on the right "load or cue video" field, allows it to play using the javascript API.
This MIGHT be because its hosted on the Google domain, but, worth looking into, maybe.
Now that I think about it, gmod html doesn't allow javascript, does it.
Ah well...still has brain cells burning
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on January 14, 2012, 11:26:25 PM
It uses the YouTube Data API to retrieve the video name and length.  :) And you're right, using the API, it would be relatively simple to determine whether or not embedding is enabled.

As for the popup link, no, that video doesn't allowing embedding because it's from VEVO. Look: http://www.youtube.com/v/97S66xee0U8?autoplay=1
If only autohide=0 worked on that! :'(


Edit: If worse comes to worst, I'll simply use the official embedded player, and implement playback error messages based on info in the YouTube Data API. Then atleast it'll be stable.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on March 28, 2012, 01:26:14 PM
Update! (1.4) Too lazy to make a full changelog right now. :P I will note that I've fixed videos not playing (sorry for this), and have retained the ability to play videos that have embedding disabled. =)
Also, it shouldn't break this time!

Edit: Uploaded 1.41, removes the "Status:" debug messages I forgot to remove...
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ViktorK on March 31, 2012, 07:58:31 AM
Hi,
this is awesome addon, thanks for fix! :)
BTW. How about add automatic playback function? :) Ive got server with your addon, and I want to play my songs automaticaly when I am not in server... This would be great feature.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on June 17, 2012, 12:16:50 PM
Are there any more updates planned for this? Because I have a few ideas for this.

Code: [Select]
1. Players should be able to vote, if they want to play music server side.
2. When music is played server side the mics on the server should be dimmed. ( as in made quieter. )
^ I know this will kinda be offset because of Youtube loading, but this brings me to the next suggestion...
3. The ability to pre-load a video before it actually plays. This can probably be done with internet cache files, and then the video will be played from the clients cache instead of using the internet.
4. Entities, I thought a cool feature would be is for a radio entity, one that has initial volume, and distance offset. What I mean is, that people who are 2 far away from the radio will not hear the music. In fact the music wont even be loading for them. But people who are close will be able to hear it, at in altered volume based on distance.

I am willing to make 1 and 2, but I have no idea how to do 3 and 4. o3o

Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on June 17, 2012, 01:05:46 PM
Could have sworn I saw #4, or at least something extremely like it, on Krook's server one time. Thought it was this release. Though I don't think it wasn't loading/playing on the 'distance' player, I do remember it wasn't heard.

Krooks, you read new threads? Was it this addon? Or another Youtube addon? Or was it a custom mix of Youtube addons?

Whatever it was, you could 'attach' youtube vids to several objects. Plasma TVs, the old timey tv from HL2, overhead projector and CSS office projector (would 'project' the vid onto a wall), and I think a little radio if sound only.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on June 17, 2012, 09:22:46 PM
Could have sworn I saw #4, or at least something extremely like it, on Krook's server one time. Thought it was this release. Though I don't think it wasn't loading/playing on the 'distance' player, I do remember it wasn't heard.

Krooks, you read new threads? Was it this addon? Or another Youtube addon? Or was it a custom mix of Youtube addons?

Whatever it was, you could 'attach' youtube vids to several objects. Plasma TVs, the old timey tv from HL2, overhead projector and CSS office projector (would 'project' the vid onto a wall), and I think a little radio if sound only.

Your talking about PlayX, but I was thinking some thing more realistic, with dynamic sound for RP or some thing...

Also I noticed that its not really working on my server... its like the video is paused or some thing...

You should use an external hackish thing that lets you embed, any thing. ( Like PlayX. )
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ntdave71694 on June 20, 2012, 12:08:19 AM
Looks like this isn't working again. Video stays at 0:00, and never starts  :-\
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on June 20, 2012, 08:30:37 PM
Are there any more updates planned for this? Because I have a few ideas for this.

Code: [Select]
1. Players should be able to vote, if they want to play music server side.
2. When music is played server side the mics on the server should be dimmed. ( as in made quieter. )
^ I know this will kinda be offset because of Youtube loading, but this brings me to the next suggestion...
3. The ability to pre-load a video before it actually plays. This can probably be done with internet cache files, and then the video will be played from the clients cache instead of using the internet.
4. Entities, I thought a cool feature would be is for a radio entity, one that has initial volume, and distance offset. What I mean is, that people who are 2 far away from the radio will not hear the music. In fact the music wont even be loading for them. But people who are close will be able to hear it, at in altered volume based on distance.

I am willing to make 1 and 2, but I have no idea how to do 3 and 4. o3o

To all the people who are saying... just use playX, playX drops FPS, quite allot.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on June 21, 2012, 06:13:46 AM
I have found a player that can probably fix allot of problems for you.

The website I am about to link you to generates a code like this...

Code: [Select]
<script type='text/javascript' src='jwplayer.js'></script>
 
<div id='mediaspace'>This text will be replaced</div>
 
<script type='text/javascript'>
  jwplayer('mediaspace').setup({
    'flashplayer': 'player.swf',
    'file': 'http://www.youtube.com/watch?v',
    'backcolor': '000000',
    'frontcolor': 'FFFFFF',
    'skin': 'black',
    'controlbar': 'bottom',
    'width': '470',
    'height': '320'
  });
</script>

Here is the site... http://www.longtailvideo.com/support/jw-player-setup-wizard
---
You can also download it here, http://www.longtailvideo.com/players/jw-flv-player/

Good Luck, and Happy Coding.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on June 26, 2012, 10:18:32 AM
Hello everyone. Sorry about the problem with many videos not playing yet again... This was due to YouTube adding a check to make sure the video box isn't too small. If you could've seen the actual video portion, it says "Video player is too small." They keep finding different ways to break my code, don't they? >:(

Anyway, I've fixed this issue in the latest version. I've created an SVN repository on Google Code, because this addon seems to require semi-frequent updates, and this makes it a lot easier and faster. Here is the checkout link: http://ulx-youtube-jukebox.googlecode.com/svn/trunk/ (EDIT: link fixed, sorry)

In case you don't know how to use SVN, to install this, you need to install Tortoise SVN (Download (http://tortoisesvn.net/downloads.html)) if you haven't already, create a folder in your "garrysmod/garrysmod/addons" folder named "ULX_YouTube_Jukebox" or whatever you want, then right-click the new folder and select "SVN Checkout...", paste the checkout link I've posted above, and click OK.


Since the changes I made between the latest release and when I created the SVN aren't logged, I'll try to list them as I remember them:
Code: [Select]
Added a Lua volume slider to the menu, and disabled mouse input on the player box.


Now, here's the current SVN changelog as of this post:
Code: [Select]
rev 7:
Added YouTube video "debug" feature, allows you to debug the YouTube video that's playing (client-side) by showing what's on the screen (YouTube errors for example).
Fixed many videos not playing due to the "Video player is too small" error.
Made the player box smaller.
Fixed being able to open the menu multiple times.
Switched to the new name in a few more places, including the title of the menu.

rev 6:
Fixed changelog.txt (FAIL)

rev 5:
Fixed changelog.txt

rev 4:
Fixed changelog.txt

rev 3:
Changed name from ULX YouTube music player to ULX YouTube Jukebox.
Allowed manual text entry into Volume slider.
Volume is now saved (remembered) via a CVar, and the video volume is automatically set accordingly when a video is loaded.

rev 2:
Initial commit.

rev 1:
Initial directory structure.

Special thanks to HellFox for his advice/assistance on this, and giving me some ideas for things, including the "video debug" feature.  :)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on June 26, 2012, 12:27:29 PM
The http://code.google.com/p/ulx-youtube-jukebox/source/browse/trunk will give you an error that looks like...

Code: [Select]
Server sent unexpected return value (405 Method Not Allowed) in response to
OPTIONS request for 'http://code.google.com/p/ulx-youtube-jukebox/source/browse/trunk'

Use this checkout link instead... https://ulx-youtube-jukebox.googlecode.com/svn/trunk/
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on June 26, 2012, 12:43:14 PM
The http://code.google.com/p/ulx-youtube-jukebox/source/browse/trunk will give you an error that looks like...

Code: [Select]
Server sent unexpected return value (405 Method Not Allowed) in response to
OPTIONS request for 'http://code.google.com/p/ulx-youtube-jukebox/source/browse/trunk'

Use this checkout link instead... https://ulx-youtube-jukebox.googlecode.com/svn/trunk/

OK, I fixed the link, sorry about that.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ntdave71694 on June 29, 2012, 01:15:07 AM
I appreciate this greatly as I don't like using PlayX.

Thanks for the great work  8)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ViktorK on July 12, 2012, 02:35:02 AM
Nice work! but I am again not able to play a video ://
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on July 18, 2012, 01:12:08 PM
Nice work! but I am again not able to play a video ://

If videos are not working remove the "http://" part, because apperently garry broke comment blocking and when you input some thing like this...

Code: [Select]
http://www.youtube.com/watch?v=OFUdKVN4ivQ
the server sees this...

Code: [Select]
http:
Other wise it should work unless your getting a plugin related error. ( Probably meaning you need to install or update flash player. )
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: gte6495 on July 24, 2012, 07:01:23 PM
Hey everyone, I'm having a few issues with my friends not being able to hear/see the videos playing on my server.  One friend, who plays Gmod on a mac is completely unable to see or hear the videos, I'm assuming this is a problem with Flash Player, but I got him to uninstall/install older versions/update Flash and nothing would fix the problem.

The other friend is perfectly capable of seeing the videos in debug mode, but he has zero audio.  He's able to hear other instances of Flash such as in his firefox browser, his volume slider does not affect it at all.

I don't know what kind of logs or screenshots I can give you, any advice to get these guys hearing?

Also: Great job on this plugin, from what I'm able to personally experience, it seems much smoother than using Playx, and less taxing on your machine.

Thanks!

EDIT: I'm running SVN ULX/ULib, and used the latest SVN of this plugin.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: pa1n on November 06, 2012, 08:44:41 PM
An update to gmod 13 for this would be great. Any info or plan on it being updated at all?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on November 07, 2012, 02:14:20 PM
It might be a good idea to look at an author's last active time, and if older than a while before GM13 released, send ONE private message, which usually sends the user an email (by default).
(Click the author's name link)
Quote from: Ryno-saurus profile
Last Active:
    July 12, 2012, 10:49:53 PM

Unless they just happen to come by, it's likely they'll never see the update request.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on November 11, 2012, 09:33:13 PM
An update to gmod 13 for this would be great. Any info or plan on it being updated at all?

Hi there. I'm sorry to say that for the time being, I'm just not interested in GMod anymore, which results in a lack of motivation to continue to maintain this addon. I never really know when I'll regain interest in certain games again, maybe I will some time in the future. I'll try to post back here if I regain interest and start work on an update for GMod 13, but another issue is that I haven't coded anything for GMod 13 yet.

I'm sorry for the inconvience.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: RynO-SauruS on November 12, 2012, 01:11:48 AM
I'm going to let HellFox release his own updated version of this, presumably for GMod 13.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on November 12, 2012, 01:15:50 AM
I'm going to let HellFox release his own updated version of this, presumably for GMod 13.

Yes, I will be working with this code for a bit until RynO decides to...

A: Take over for me on my version.

or

B: Continue working on this one.

I don't know when I will release the updated player tho because I have allot of things to do before that. (Setting up a server, doing stuff with steam groups, and school, and other things...)
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: pa1n on November 15, 2012, 07:22:22 PM
Thank you so much.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: PAL-18 on November 25, 2012, 01:45:37 PM
This addon doesnt work  :(

When i try playing a video my console shows these errors:


[ERROR] ...ic_player/lua/ulx/modules/cl/youtube_music_player_cl.lua:124: attempt to call field 'Get' (a nil value)
  1. unknown - ...ic_player/lua/ulx/modules/cl/youtube_music_player_cl.lua:124

Timer Failed! [Simple][@addons/ulx_youtube_music_player/lua/ulx/modules/cl/youtube_music_player_cl.lua (line 122)]
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on November 25, 2012, 03:16:52 PM
This addon doesnt work  :(

When i try playing a video my console shows these errors:


[ERROR] ...ic_player/lua/ulx/modules/cl/youtube_music_player_cl.lua:124: attempt to call field 'Get' (a nil value)
  1. unknown - ...ic_player/lua/ulx/modules/cl/youtube_music_player_cl.lua:124

Timer Failed! [Simple][@addons/ulx_youtube_music_player/lua/ulx/modules/cl/youtube_music_player_cl.lua (line 122)]

This ad-don currently wont work with Gmod 13 sorry. :(

I will be working on getting it into Gmod 13, but I am not 100% sure that it would work out because I have not messed around with using HTML elements in gmod 13 lua yet.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: pa1n on November 29, 2012, 05:50:27 AM
I guess this is not fixable? I contacted the original author but he never responded.

To the above poster I hope you get it working.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: LuaTenshi on November 30, 2012, 08:23:59 AM
Here's "two" updates! (I actually coded 1.2 several months ago, and somehow forgot to post it :-[)

Important: You MUST remove the folder for the old version before installing this one!

Code: [Select]
UPDATE 1.3:
=Fixed: Videos not playing since the YouTube interface update.. Sorry this took so long!

UPDATE 1.2:
+Addition: "Play for all" and "Play client-side" options to the playlist right-click menu.
*Change: Changed some file names to reflect the current official name of this addon (it was initially called "ULX SongPlayer"). NOTE: This means you MUST delete the addon folder for the old version before installing this one!
*Change: The shared code is a LOT more clean and efficient, thanks to Megiddo's new logging system.

So does this work in Garry's mod 13 yet, or is their still stuff that needs fixing before it can work?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on December 01, 2012, 02:45:36 PM
So does this work in Garry's mod 13 yet, or is their still stuff that needs fixing before it can work?
I will be working on getting it into Gmod 13

You tell us?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ntdave71694 on December 05, 2012, 07:04:48 AM
Fixed :3

Not sure if I should attach it, but it's there.

-Changed http.Get to http.Fetch
-Fixed a timer

EDIT: Moved to Dropbox http://dl.dropbox.com/u/18804041/admin_ulx%20youtube.7z
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Megiddo on December 05, 2012, 09:26:13 AM
Fixed :3

Not sure if I should attach it, but it's there.

Ryno hasn't been on the forums in almost a month, but I doubt he will mind.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ntdave71694 on December 05, 2012, 11:32:58 AM
This time it works 100% :D

All of the things that broken were due to syntax changes in gm 13 (I didn't keep track).

EDIT: Moved to Dropbox http://dl.dropbox.com/u/18804041/admin_ulx%20youtube.7z
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Vizzy on December 09, 2012, 02:17:17 PM
This time it works 100% :D

All of the things that broken were due to syntax changes in gm 13 (I didn't keep track). Anyways the file is attached below, enjoy :)

it does seem to work

i get

Code: [Select]
[ERROR] ...x youtube/lua/ulx/modules/cl/youtube_music_player_cl.lua:423: attempt to call global 'ValidEntity' (a nil value)
  1. fn - ...x youtube/lua/ulx/modules/cl/youtube_music_player_cl.lua:423
   2. Call - addons/ulib/lua/ulib/shared/hook.lua:168
    3. fn - addons/ulib/lua/ulib/cl_init.lua:54
     4. func - addons/ulib/lua/ulib/client/cl_util.lua:22
      5. unknown - lua/includes/modules/net.lua:31
when opening it sometimes using 'ulx music'


also the playlist reverts to blank after map change ;(
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ntdave71694 on December 10, 2012, 10:40:36 AM
Yeah I just noticed that the favorites list doesn't actually save the videos. I'll look at this today. As far as that list of errors...

Are you using the latest revision of ULX and ULib?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Vizzy on December 11, 2012, 07:26:13 PM
I dont believe so, maybe 1 revision old

Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ntdave71694 on December 12, 2012, 12:57:28 AM
I've fixed the playlist issue. I'm still not sure what the deal is with all those other errors you were getting  ???

Anyways here it is http://dl.dropbox.com/u/18804041/admin_ulx%20youtube.7z
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Vizzy on December 13, 2012, 04:16:32 PM
I updated ulx to the latest and all is well

playlist saves too, thank you
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: PAL-18 on December 20, 2012, 02:10:57 PM
This addon is awesome!

Can you add the ability to associate volumes with specific urls (in the save list).
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: PAL-18 on December 22, 2012, 01:00:31 PM
When i open the music menu i get the following script error:

Quote
[ERROR] ...x youtube/lua/ulx/modules/cl/youtube_music_player_cl.lua:422: attempt to call global 'ValidEntity' (a nil value)
  1. fn - ...x youtube/lua/ulx/modules/cl/youtube_music_player_cl.lua:422
   2. Call - addons/ulib/lua/ulib/shared/hook.lua:183
    3. fn - addons/ulib/lua/ulib/cl_init.lua:54
     4. func - addons/ulib/lua/ulib/client/cl_util.lua:22
      5. unknown - lua/includes/modules/net.lua:31

Aside from this error, it works fine.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on December 22, 2012, 02:55:02 PM
Error reported already by vizzy.
http://forums.ulyssesmod.net/index.php/topic,4992.msg27274/topicseen.html#msg27274
Error he gives is off by a line # or two, but, the code was modified after he reported it.
And if you work your way down the posts, it seems ntdave gave code/dropbox links that may have fixed it, along with Vizzy using latest greatest ULX/Ulib

I've fixed the playlist issue. I'm still not sure what the deal is with all those other errors you were getting  ???

Anyways here it is http://dl.dropbox.com/u/18804041/admin_ulx%20youtube.7z
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: PAL-18 on December 22, 2012, 06:34:54 PM
Some players can't hear any music (and they haven't stopped it) any idea why they cant?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on December 22, 2012, 10:34:20 PM
Some players can't hear any music (and they haven't stopped it) any idea why they cant?
Just a wild guess..perhaps this script's sound is affected by Gmod's new additional sv_alltalk features?
See http://forums.ulyssesmod.net/index.php/topic,5822.msg26990.html#msg26990
Again, just a wild guess.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: ntdave71694 on December 28, 2012, 02:23:44 AM
Some players can't hear any music (and they haven't stopped it) any idea why they cant?

They don't have Flash player for other browsers, that's my guess.

http://get.adobe.com/flashplayer/otherversions/
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: mhupfauer on May 27, 2013, 02:49:45 PM
I get this error:

You are running ULib version 2.50.
[ULIB] Loading SHARED module: ulx_init.lua
[ULX] Loading CLIENT module: motdmenu.lua
[ULX] Loading CLIENT module: uteam.lua
[ULX] Loading CLIENT module: xgui_client.lua
[ULX] Loading CLIENT module: xgui_helpers.lua
[ULX] Loading CLIENT module: xlib.lua
[ULX] Loading CLIENT module: youtube_music_player_cl.lua
[ULX] Loading SHARED module: chat.lua
[ULX] Loading SHARED module: fun.lua
[ULX] Loading SHARED module: menus.lua
[ULX] Loading SHARED module: rcon.lua
[ULX] Loading SHARED module: teleport.lua
[ULX] Loading SHARED module: user.lua
[ULX] Loading SHARED module: userhelp.lua
[ULX] Loading SHARED module: util.lua
[ULX] Loading SHARED module: vote.lua
[ULX] Loading SHARED module: youtube_music_player_sh.lua
[ULIB] Loading SHARED module: urequest.lua
[ULIB] Loading CLIENT module: urequest_cl.lua
Hey '*******' - You're in the 'superadmin' group on this server.
Client "*********" spawned in server (******)<STEAM_0:0:*****>.
ULX version 3.60 loaded.
Welcome to DarkRP|EU-Server|FASTDL|CUSTOME JOBS! We're playing rp_downtown_v4c.
[DarkRP] ***** (STEAM_0:0:*******) has joined the game

///////////////////////////////////////
//  ULX GUI -- Made by Stickly Man!  //
///////////////////////////////////////
// Loading GUI Modules...            //
//   bans.lua                        //
//   commands.lua                    //
//   groups.lua                      //
//   maps.lua                        //
//   settings.lua                    //
// Loading Setting Modules...        //
//   client.lua                      //
//   server.lua                      //
// Loading Gamemode Module(s)...     //
//   sandbox.lua                     //
//   No module found!                //
// Modules Loaded!                   //
///////////////////////////////////////

Compact freed 860160 bytes
Redownloading all lightmaps
Noclip allowed
]
]
Unknown command: _ulx_songplayer
No YouTube videos have been played since you joined

[ERROR] addons/ulx/lua/ulx/modules/cl/youtube_music_player_cl.lua:124: attempt to call field 'Get' (a nil value)
  1. unknown - addons/ulx/lua/ulx/modules/cl/youtube_music_player_cl.lua:124

Timer Failed! [Simple][@addons/ulx/lua/ulx/modules/cl/youtube_music_player_cl.lua (line 122)]
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on May 27, 2013, 03:32:31 PM
Because your using the original post code meant for Gmod12 pre October 2012.
Please see this post october 2012 thread here - http://forums.ulyssesmod.net/index.php/topic,4992.msg27297.html#msg27297

As you browse our forums, please look for releases/posts after Oct 2012.
Many pre-Gm13 releases were 'fixed' by others than the original authors in posts later in the threads.
Just look a bit when you find something you think you might like.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: mhupfauer on May 28, 2013, 01:52:41 PM
Because your using the original post code meant for Gmod12 pre October 2012.
Please see this post october 2012 thread here - http://forums.ulyssesmod.net/index.php/topic,4992.msg27297.html#msg27297

As you browse our forums, please look for releases/posts after Oct 2012.
Many pre-Gm13 releases were 'fixed' by others than the original authors in posts later in the threads.
Just look a bit when you find something you think you might like.

Thanks alot JamminR.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: DooBiiE on May 31, 2013, 06:01:52 PM
is this upto date now and working with gmod ?
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on May 31, 2013, 10:06:14 PM
Read the last few pages, post october 2012 Gm13 update.
Heck, I even answered your question about 2 posts ago.
Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: PAL-18 on June 22, 2013, 01:23:00 PM
Is there a limit to how many songs can exist on the player list?  If so, i think i hit it :(

Title: Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: kpjVideo on July 20, 2013, 05:53:52 PM
Hello, every time I try to add a video to the YouTube jukebox addon nothing happens and it dosn't play at all. I have been on servers that have working version but I cannot seen to get mine to work.
Does anyone have a working version or a way of fixing this?
Thank you very much!  8)
Title: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on July 20, 2013, 06:08:11 PM
Tried this?
http://forums.ulyssesmod.net/index.php/topic,4992.msg27297.html#msg27297

(also, I merged your question - when having problems getting a specific plugin to work, please post in the original release post (unless of course you're asking about something that's locked, and then I'd recommend dev corner or off topic, since, it was locked for a reason)
Title: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: kpjVideo on July 20, 2013, 06:50:35 PM
Tried this?
http://forums.ulyssesmod.net/index.php/topic,4992.msg27297.html#msg27297

(also, I merged your question - when having problems getting a specific plugin to work, please post in the original release post (unless of course you're asking about something that's locked, and then I'd recommend dev corner or off topic, since, it was locked for a reason)
Ahh okay and yes I have tried this but I still receive this error:
Code: [Select]
[ERROR] addons/ulx/lua/ulx/modules/cl/youtube_music_player_cl.lua:129: attempt to call field 'Get' (a nil value)
  1. unknown - addons/ulx/lua/ulx/modules/cl/youtube_music_player_cl.lua:129

Any ideas  :-\
Title: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on July 20, 2013, 09:38:49 PM
Looks like you're still using the old code from the first post.
The link I've linked to several times over the past few posts, both for you, and for others, line 129 is blank, and the 'update' fixes a Gmod12 function http.Get to a Gmod13 function http.Fetch.

Make sure you're using the latest on the server.
Line 128, 129, and 130 of the file that error shows should look like below.
Code: [Select]
local getTheLength = function()

http.Fetch( "http://gdata.youtube.com/feeds/api/videos/" .. video_id .. "?v=2", function( content, length, headers, returncode )

129 is actually blank, but, I'm not sure if Gmod returns the line before the error, or actual line of.
Title: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: Wubsy on August 19, 2013, 07:46:05 PM
] ulx playvid www.youtube.com/watch?v=IJNR2EpS0jw
Warning: Unhandled usermessage 'ulx_playvid'
Title: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
Post by: JamminR on September 03, 2013, 07:49:39 PM
It was kind of a tough decision to move this to the archives.
However, due to its age, even with the after-Gmod13 fixes, it's due a new coder pick it up (or, if Ryno ever comes back, he's more than welcome to revive it)