Please login or register.

Login with username, password and session length
Advanced search  

News:

Latest WME version: WME 1.9.1 (January 1st, 2010) - download

Pages: 1 [2] 3  All

Author Topic: Nitpicking from and ex Agast user.  (Read 23585 times)

0 Members and 1 Guest are viewing this topic.

deadworm222

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 197
  • Wintermute Army
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #15 on: August 09, 2003, 07:39:02 AM »

Because our musician doesn't want looping from the beginning of the file to the end of the file, but seamless looping, the way it's done in Grim Fandango & other LucasArts games. And adjusting the looplength variable wouldn't work, because the gap is not in the file, but is generated by the PlayMusic function (or some other function, like SetMusicPosition) (maybe because it buffers something?)

EDIT: Removing the PlaySound from inside the while-loop helped a little, but now the loop starts from a wrong place. I'll also try Sound files, if they would be better.
« Last Edit: August 09, 2003, 08:32:56 AM by deadworm222 »
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re:Nitpicking from and ex Agast user.
« Reply #16 on: August 09, 2003, 09:31:02 AM »

Try removing the second PlayMusic call. It should give you a seemless transition.

The way it's written now you are forcing the engine to reinitialize the sound file everytime which takes a few milliseconds, hence the gap.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

deadworm222

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 197
  • Wintermute Army
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #17 on: August 09, 2003, 03:34:51 PM »

Read my post above - I did. Now the file plays a bit past the point I specified where it should stop, and then starts to loop. There seems to be no other way of fixing it than changing the looptime (which should be exactly correct, but apparently isn't).
« Last Edit: August 09, 2003, 03:36:22 PM by deadworm222 »
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re:Nitpicking from and ex Agast user.
« Reply #18 on: August 09, 2003, 05:05:19 PM »

Read my post above - I did.
Sorry, I misinterpreted your last post.


Now the file plays a bit past the point I specified where it should stop, and then starts to loop.
For the first time or everytime? How much does it go wrong, approximately?
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

creatorbri

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 61
  • I'm a llama!
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #19 on: August 09, 2003, 10:14:12 PM »

I'm planning to allow the user to make a connection between those two to reduce the scripting needed for the most common situations.

That would be very handy.

The function must be present in a script it's being called from. If you need to share some functions between multiple scripts, put them into a separate file and use the

  #include "path\filename.script"

construct to insert them to another script.

So even though the scripting language is basically object oriented, there's no way to define custom methods for objects? For instance I want to add a few methods to my Actor's script beyond the defaults like "Talk" and "GoTo". One is called "TalkList", which cycles through a given list of dialogue lines each time the "Talk" action is performed. It seems like I ought to be able to add these to my actor.script, thus making them accessible to other scripts by calling:
Code: [Select]
actor.TalkList(self.commentList);
Logged

deadworm222

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 197
  • Wintermute Army
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #20 on: August 10, 2003, 07:54:59 AM »

Read my post above - I did.
Sorry, I misinterpreted your last post.


Now the file plays a bit past the point I specified where it should stop, and then starts to loop.
For the first time or everytime? How much does it go wrong, approximately?

I believe that I'm this close to solving the problem, whatever system I will use. Could you tell me how long the gap is? Because I now think the problem comes from the gap in the beginning of the PlayMusic function, because the script should wait for as many milliseconds as defined in loopend, but it waits for loopend+gap. At least, that's what I think. I might be able to find out the length of the gap myself...
Logged

creatorbri

  • Occasional poster
  • **
  • Karma: 0
  • Offline Offline
  • Posts: 61
  • I'm a llama!
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #21 on: August 10, 2003, 05:27:51 PM »

But how are you going to eliminate that gap? Regardless of how long it is, the gap is always going to be there when you call the PlayMusic function. The only solution I can see is to play and pause the music, and set its position, before you actually need it.

In fact, it might be handy to have a parameter for PlayMusic, in a future version of Wintermute, that tells the music to start Paused..
Logged

McCoy

  • The cocido eater
  • Frequent poster
  • ****
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 365
  • Spurrrrrrring
    • View Profile
    • Spur Games
Re:Nitpicking from and ex Agast user.
« Reply #22 on: August 10, 2003, 05:38:44 PM »

In fact, it might be handy to have a parameter for PlayMusic, in a future version of Wintermute, that tells the music to start Paused..

Well, I think that using Game.PauseMusic(); right after Game.PlayMusic(fileName,looping); will do the same effect...
Logged

Click here to sign my sig!

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re:Nitpicking from and ex Agast user.
« Reply #23 on: August 11, 2003, 01:17:32 PM »

So even though the scripting language is basically object oriented, there's no way to define custom methods for objects? For instance I want to add a few methods to my Actor's script beyond the defaults like "Talk" and "GoTo". One is called "TalkList", which cycles through a given list of dialogue lines each time the "Talk" action is performed. It seems like I ought to be able to add these to my actor.script, thus making them accessible to other scripts by calling:
Code: [Select]
actor.TalkList(self.commentList);

No, no custom methods, just attributes. I'd have to deal with global functions first.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re:Nitpicking from and ex Agast user.
« Reply #24 on: August 11, 2003, 01:18:42 PM »

I believe that I'm this close to solving the problem, whatever system I will use. Could you tell me how long the gap is? Because I now think the problem comes from the gap in the beginning of the PlayMusic function, because the script should wait for as many milliseconds as defined in loopend, but it waits for loopend+gap. At least, that's what I think. I might be able to find out the length of the gap myself...

That's weird, because when the Sleep gets executed the sound is already initialized...
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

deadworm222

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 197
  • Wintermute Army
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #25 on: August 11, 2003, 02:00:47 PM »

Now that I tried Brian's suggestion, it's WORKING! Great! But still, it'd be nice if some future versin of WinterMute supported more sophisticated looping. For example, now there's a small click-sound in the beginning, and I have to deal with it by setting global music volume to 0. Not exactly eloquent...
Logged

deadworm222

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 197
  • Wintermute Army
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #26 on: August 12, 2003, 02:01:31 PM »

Our musician says that the intro file - which at the moment has to be a wav-file - can last for up to fifteen seconds, and this results in huge filesizes and also in a drop of quality when the OGG loop is played, never mind the script being really unsophisticated. Therefore we'd like there to be a play music function where the loop beginning and end points could be set. Like this Game.PlayMusic("filename", true, beginning of loop in milliseconds, end of loop in milliseconds) First it would play the file from the very beginning and then get on with the loop.

Is this feature possible to add to the future versions of WinterMute?
« Last Edit: August 12, 2003, 02:03:32 PM by deadworm222 »
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re:Nitpicking from and ex Agast user.
« Reply #27 on: August 13, 2003, 07:09:07 AM »

Ok, I'll try something. But not as a function with lots of parameters but rather a parallel text file describing the extended properties of the sound/music. It's more flexile that way.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

deadworm222

  • Regular poster
  • ***
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 197
  • Wintermute Army
    • View Profile
Re:Nitpicking from and ex Agast user.
« Reply #28 on: August 24, 2003, 06:30:56 PM »

Thanks  :D
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re:Nitpicking from and ex Agast user.
« Reply #29 on: August 24, 2003, 09:25:49 PM »

"It's certainly better to tell me, instead of going to some godforsaken forum in the middle of internet saying that 'WME sucks because the graphics look ugly on my computer' ;-) " - WME User Manual

Just wanted to point out that this note was not aimed at you, but rather at certain post on certain other forum ;) It has been written long long time before you started posting here. And if you don't believe me, I can give you a link :)
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave
Pages: 1 [2] 3  All
 

Page created in 0.047 seconds with 18 queries.