ULX

Author Topic: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)  (Read 87709 times)

0 Members and 1 Guest are viewing this topic.

Offline ntdave71694

  • Newbie
  • *
  • Posts: 7
  • Karma: 1
Looks like this isn't working again. Video stays at 0:00, and never starts  :-\

Offline LuaTenshi

  • Hero Member
  • *****
  • Posts: 545
  • Karma: 47
  • Just your ordinary moon angel!
    • Mirai.Red
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.
I cry every time I see that I am not a respected member of this community.

Offline LuaTenshi

  • Hero Member
  • *****
  • Posts: 545
  • Karma: 47
  • Just your ordinary moon angel!
    • Mirai.Red
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.
I cry every time I see that I am not a respected member of this community.

Offline RynO-SauruS

  • Jr. Member
  • **
  • Posts: 77
  • Karma: 17
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) 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.  :)
« Last Edit: June 26, 2012, 12:30:16 PM by RynO-SauruS »


YouTube music player by RynO-SauruS

Offline LuaTenshi

  • Hero Member
  • *****
  • Posts: 545
  • Karma: 47
  • Just your ordinary moon angel!
    • Mirai.Red
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/
I cry every time I see that I am not a respected member of this community.

Offline RynO-SauruS

  • Jr. Member
  • **
  • Posts: 77
  • Karma: 17
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.


YouTube music player by RynO-SauruS

Offline ntdave71694

  • Newbie
  • *
  • Posts: 7
  • Karma: 1
I appreciate this greatly as I don't like using PlayX.

Thanks for the great work  8)

Offline ViktorK

  • Newbie
  • *
  • Posts: 5
  • Karma: 0
Nice work! but I am again not able to play a video ://

Offline LuaTenshi

  • Hero Member
  • *****
  • Posts: 545
  • Karma: 47
  • Just your ordinary moon angel!
    • Mirai.Red
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. )
I cry every time I see that I am not a respected member of this community.

Offline gte6495

  • Newbie
  • *
  • Posts: 9
  • Karma: 1
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.

Offline pa1n

  • Newbie
  • *
  • Posts: 19
  • Karma: -1
Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
« Reply #55 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?

Offline JamminR

  • Ulysses Team Member
  • Hero Member
  • *****
  • Posts: 8096
  • Karma: 390
  • Sertafide Ulysses Jenius
    • Team Ulysses [ULib/ULX, other fine releases]
Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
« Reply #56 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.
"Though a program be but three lines long, someday it will have to be maintained." -- The Tao of Programming

Offline RynO-SauruS

  • Jr. Member
  • **
  • Posts: 77
  • Karma: 17
Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
« Reply #57 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.
« Last Edit: November 11, 2012, 09:35:43 PM by RynO-SauruS »


YouTube music player by RynO-SauruS

Offline RynO-SauruS

  • Jr. Member
  • **
  • Posts: 77
  • Karma: 17
Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
« Reply #58 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.


YouTube music player by RynO-SauruS

Offline LuaTenshi

  • Hero Member
  • *****
  • Posts: 545
  • Karma: 47
  • Just your ordinary moon angel!
    • Mirai.Red
Re: Re: [SVN ULX/ULib only] YouTube music player (UPDATED: June 26th, 2012)
« Reply #59 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...)
I cry every time I see that I am not a respected member of this community.