Music-Script Problem

Maps and the art of mapmaking.
Cancellor
Leprechaun
Leprechaun
Posts: 7
Joined: 25 May 2012

Music-Script Problem

Unread postby Cancellor » 28 Nov 2012, 17:21

I tried to start exact music during the battle.
But my battle script is not working:

Code: Select all

VOICEOVER_TEST_MUSIC ="/Editor/H5MMods/TestScript4/Maps/SingleMissions/TestScript4/TestScript4_Test_Sound.xdb#xpointer(/Sound)";


function Music
Play2DSound( VOICEOVER_TEST_MUSIC );
end;

startThread ("Music");
print ("Music plays");
Any idea how to fix it?

Thx for promt reply ;)
Knop

User avatar
markkur
Demon
Demon
Posts: 335
Joined: 14 Oct 2011

Unread postby markkur » 28 Nov 2012, 20:09

I am looking into H5 music myself. You may be interested un this:

http://www.celestialheavens.com/forums/ ... php?t=9166

I've not tried it yet, but I came across this on my own search and yea, the link is still active.

My thanks to its maker :D

Cancellor
Leprechaun
Leprechaun
Posts: 7
Joined: 25 May 2012

Unread postby Cancellor » 29 Nov 2012, 10:57

Thx but I know how to change music during battle, terrain explore etc.
I just wanted to know how to change music battle ONLY AT EXACT battle I want.
I've changed script to:

Code: Select all

VOICEOVER_TEST_MUSIC ="/Editor/H5MMods/TestScript4/Maps/SingleMissions/TestScript4/TestScript4_Test_Sound.xdb#xpointer(/Sound)";


function Music()
Play2DSound( VOICEOVER_TEST_MUSIC );
end;

startThread (Music);
print ("Music plays"); 
But it still not working. Error:
"Script ERROR: '(' expected;
last token read: 'Play2DSound' at line 2 in string "DoString script"
Script failed, unknown error"
Any idea?

User avatar
markkur
Demon
Demon
Posts: 335
Joined: 14 Oct 2011

Unread postby markkur » 29 Nov 2012, 14:15

Ok, sorry for the mis-direct.

One last thought. I thought a music script had to list the desired ogg file? Is that not true?

Cancellor
Leprechaun
Leprechaun
Posts: 7
Joined: 25 May 2012

Unread postby Cancellor » 30 Nov 2012, 09:10

Well, normally in game it's connected to .xdb file which follows .ogg file.
But I will check that.

C'mon scripters, help me ;)


Return to “Mapmaking Guild”

Who is online

Users browsing this forum: No registered users and 1 guest