Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Voicedlc - Custom URL for boombox youtube etc


HowlingWolf
 Share

Recommended Posts

Hello. 

 

Is it possible for you guys, to check the possibility for making plugins for the new voice-dlc, that we can add our own url from such as youtube or other live feed radio-stations ? 

Link to comment
Share on other sites

Posted (edited)

You can add internet feeds e.g. my station RustRadio

boombox.serverurllist "RustRadio,http://listen.rustradio.co.uk:8000/stream"

in console obviously

Edited by MikeHawke
Link to comment
Share on other sites

Once I get some free time ill be looking into this.
I imagin something like this will work after having a quick look in dnspy.

Havn't tested yet since I have to many other things to fix at the moment due to the update.

       [ChatCommand("customstation")]
        void ChangeStation(BasePlayer player, string arg2, string[] args)
        {
            if (!player.IsAdmin) return;
            if (args.Length < 1)
            {
                player.ChatMessage("InvalidArgs");
                return;
            }
            RaycastHit rhit;
            if (!Physics.Raycast(player.eyes.HeadRay(), out rhit))
            {
                return;
            }
            var entity = rhit.GetEntity();
            if (entity == null)
            {
                return;
            }
            if (rhit.distance > 5f)
            {
                return;
            }
            if(entity.ShortPrefabName == "boombox.deployed")
            {
                DeployableBoomBox radio = entity as DeployableBoomBox;
                radio.SetFlag(DeployableBoomBox.Flag_HasPower, true);
                radio.ClientRPC<string>(null, "OnRadioIPChanged", args[0]);
                radio.SetFlag(global::BaseEntity.Flags.On, true);
            }
        }

 

  • Like 1
Link to comment
Share on other sites

13 hours ago, MikeHawke said:

You can add internet feeds e.g. my station RustRadio

boombox.serverurllist "RustRadio,http://listen.rustradio.co.uk:8000/stream"

in console obviously

yes, but.. not all admins wish to do this.. thats the sad part.. so thats why the question in here 🙂

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

About Us

Codefling is a forward-thinking platform for developers to share and monetize their work from plugins to game assets and everything in-between.

6,841 files sold to 616 customers and $99,224 of payments processed this year!

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.