Jump to content

Custom Radio Station Works on PipBoy but Not Jukebox?


user826

Recommended Posts

So I managed to create my own custom radio station and I can hear the music when I select the station on the PipBoy, but if I make a custom vintage radio or jukebox and select my custom station from the drop-down menu, it doesn't work - I only get silence. There's a tutorial thread over on the New Vegas forum that says jukeboxes need to use an OGG file with "_mono" tacked on to the end of the file name but that doesn't work for me. Anyone have any ideas?

Link to comment
Share on other sites

Well, since I can't seem to figure this out, I'll share the alternate solution I employed, in case anyone in the future has the same problem and stumbles across this thread.

 

Instead of making it act like a radio, I wrote an object script to make it function more like an actual jukebox. Here's the script:

scn SCPTJukebox

short button
short checkButtons

begin onActivate
    if IsActionRef player == 1
        if (player.GetItemCount Caps001 >= 1)
            set checkButtons to 1
            showMessage MESGJukeboxMENU
        elseif (player.GetItemCount Caps001 < 1)
            showMessage MESGJukeboxNOCAPS
        endif
    endif
end

begin GameMode			
	if (checkButtons == 1)
		set button to getButtonPressed
		if button > -1
			if button == 0
				JukeboxREF.playSound3D MUSJukeboxTrack01
				player.RemoveItem Caps001 1
			elseif button == 1
				JukeboxREF.playSound3D MUSJukeboxTrack02
				player.RemoveItem Caps001 1
			elseif button == 2
				JukeboxREF.playSound3D MUSJukeboxTrack03
				player.RemoveItem Caps001 1
			elseif button == 3
				JukeboxREF.playSound3D MUSJukeboxTrack04
				player.RemoveItem Caps001 1
			elseif button == 4
				;Do nothing
			endif
		set checkButtons to 0
		endif
	endif
end

Basically, what it does is show a menu where you can choose the track, and then it'll deduct one cap from your inventory and play the song. If you have no caps, it'll display a failure message. You'll need to create a message box (Miscellaneous >> Message, in the GECK's Object Window) to function as the track selection menu, with one line of button text per track that you want the jukebox to play. You'll also need to create a new sound (Miscellaneous >> Sound) for each track you want to use.

 

This is a really rough and dirty script that will make the jukebox work but it won't be perfectly realistic. For one thing, if you select another track while one is already playing, it will play the second track anyway, on top of the first. As far as I know, the GECK does not have a 'StopSound' command, so I'm not sure how to proceed further here. If game immersion is super-important to you, you'll just have to be smart about it and not purposely try to break the sequence. I hope this helps somebody!

Edited by user826
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...