LucasForums

LucasForums (http://www.lucasforums.com/index.php)
-   JA Coding (http://www.lucasforums.com/forumdisplay.php?f=539)
-   -   Music help (http://www.lucasforums.com/showthread.php?t=204545)

supermegafernandator 07-01-2010 04:45 PM

Music help
 
Hi im making a sp mod, I am using Icarus Behaved to make some scripts and I want to know if there is a way to play a music file, not the dinamic music state, something like when you are playing in single player and you put in the console music and the mp3 file do you want to play. I am using a mp map.

nizwiz 07-01-2010 09:42 PM

One way to do it is to add a target_play_music entity like this
Code:

{
    "classname" "target_play_music"
    "targetname" "WhateverNameYouFancy"
    "music" "music/mymusic.mp3"
    "origin" "x y z"
}

and then do a
Code:

use ( "WhateverNameYouFancy" );
from within the script. Don't know if there's a better way than that (probably so).

supermegafernandator 07-02-2010 03:00 AM

Quote:

Originally Posted by nizwiz (Post 2736155)
One way to do it is to add a target_play_music entity like this
Code:

{
    "classname" "target_play_music"
    "targetname" "WhateverNameYouFancy"
    "music" "music/mymusic.mp3"
    "origin" "x y z"
}

and then do a
Code:

use ( "WhateverNameYouFancy" );
from within the script. Don't know if there's a better way than that (probably so).

Yes, but i mean only using Icarus Behaved, without modifying the map. Some type of code inside the script to run when you are ingame puting in the console runscript " "

Didz93 07-02-2010 05:28 AM

I think the proper way to do it is like this:
Code:

sound ( CHAN_MUSIC, "music/t1_sour/dealsour_action.mp3" );


All times are GMT -4. The time now is 09:39 AM.

Powered by vBulletin®
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
LFNetwork, LLC ©2002-2011 - All rights reserved.