Jump to content

Media on a Prim


Zousug Corvinus
 Share

You are about to reply to a thread that has been inactive for 374 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hey all,

I have a item that when clicked on comes up with a menu to do a few different things.

attached is another prim that has a face thats set to media, was wondering..

How can i change the media on prim url?

Also, can i hide the bar that shows *stop play home etc*?

And any way to have it only play when the play button is pressed in the menu system i have?

 

thanks in advanced

Link to comment
Share on other sites

2 hours ago, Zousug Corvinus said:

How can i change the media on prim url?

llSetLinkMedia()

PRIM_MEDIA_CURRENT_URL

2 hours ago, Zousug Corvinus said:

Also, can i hide the bar that shows *stop play home etc*?

PRIM_MEDIA_PERMS_CONTROL, PRIM_MEDIA_PERMS_NONE

2 hours ago, Zousug Corvinus said:

And any way to have it only play when the play button is pressed in the menu system i have?

If the URL is set only when the button is pressed, and the media face is turned off otherwise, and the viewer has auto-play enabled. Not necessarily recommended for general use.

  • Thanks 1
Link to comment
Share on other sites

54 minutes ago, Quistess Alpha said:

llSetLinkMedia()

PRIM_MEDIA_CURRENT_URL

PRIM_MEDIA_PERMS_CONTROL, PRIM_MEDIA_PERMS_NONE

If the URL is set only when the button is pressed, and the media face is turned off otherwise, and the viewer has auto-play enabled. Not necessarily recommended for general use.

Thanks for the reply, was about to make a quick update post hehe

I have the code in to set the url and its set auto play = false.. I then have these two buttons

            if(msg == "Radio On")
            {
                llSetLinkMedia(2, 2, [PRIM_MEDIA_CURRENT_URL, msg, PRIM_MEDIA_AUTO_PLAY, TRUE]);
            }
            else if(msg == "Radio Off")
            {
                llSetLinkMedia(2, 2, [PRIM_MEDIA_CURRENT_URL, ""]);
            }
            else
            {

The Radio On option works, makes it so it plays but radio off is not taking the URL away to turn it off.. *is there away to change it to HOME which should always be blank as away to switch it off?*

 

Iv had the off set to PRIM_MEDIA_CURRENT_URL as well with no url just "" and still dont work

Edited by Zousug Corvinus
Link to comment
Share on other sites

12 minutes ago, Quistess Alpha said:

https://wiki.secondlife.com/wiki/LlClearLinkMedia should work. Also, I think most viewers ignore the PRIM_MEDIA_AUTO_PLAY setting. It's a helpful suggestion to the viewer, but don't rely on it too heavily.

I have llClearLinkMedia(2, 2); in yet when i edit the prim and face it still shows the url under current page.. *also my on dosnt seem to turn it on no more lol*

Link to comment
Share on other sites

3 minutes ago, Zousug Corvinus said:

llClearLinkMedia(2, 2);

I'd recommend not using literal faces and links except for basic testing. However, if you don't mind clearing ALL media, try

llClearLinkMedia(LINK_SET, ALL_SIDES);

Link to comment
Share on other sites

27 minutes ago, Zousug Corvinus said:
if(msg == "Radio On")
{   llSetLinkMedia(2, 2, [PRIM_MEDIA_CURRENT_URL, msg, PRIM_MEDIA_AUTO_PLAY, TRUE]);
}

you're using msg (which has just been confirmed to have the value "Radio On") as the CURRENT_URL when you probably intend a variable representing the URL.

  • Like 1
Link to comment
Share on other sites

5 minutes ago, Quistess Alpha said:

you're using msg (which has just been confirmed to have the value "Radio On") as the CURRENT_URL when you probably intend a variable representing the URL.

oh drats.. lol i think i fixed it..

 

 llSetLinkMedia(2, 2, [PRIM_MEDIA_CURRENT_URL, music_url, PRIM_MEDIA_AUTO_PLAY, TRUE]); still dosnt play lol

  • Like 1
Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 374 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...