Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
0 registered members (), 17,758 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
snd_tune doesnt work? #201210
04/07/08 15:30
04/07/08 15:30
Joined: Jan 2008
Posts: 49
Sweden
K
Kenchu Offline OP
Newbie
Kenchu  Offline OP
Newbie
K

Joined: Jan 2008
Posts: 49
Sweden
 Code:
SOUND* ambient = snd_create("somesound.ogg");
var ambient_handle = snd_loop(ambient, 0, 0);

snd_tune(ambient_handle, 100, 0, 0);


I know it's a silly piece of code here. But the gist of it is that I want to create a sound with volume 0, and then increase that volume. The example above will not work. It works if I do it the other way around, so it seems I have to have 100 volume in snd_loop. Why is that?

Re: snd_tune doesnt work? [Re: Kenchu] #201234
04/07/08 17:45
04/07/08 17:45
Joined: Jan 2002
Posts: 4,225
Germany / Essen
Uhrwerk Offline
Expert
Uhrwerk  Offline
Expert

Joined: Jan 2002
Posts: 4,225
Germany / Essen
When you give 0 for any of the params in snd_tune the corresponding value won't ba changed at all. So the semantic of 0 is "don't change the current value" in this special case. Try beginning with a volume of 1 instead of 0. This will do the same, as a sound with volume 0 won't be heard anyways.


Always learn from history, to be sure you make the same mistakes again...
Re: snd_tune doesnt work? [Re: Uhrwerk] #201238
04/07/08 18:40
04/07/08 18:40
Joined: Jan 2008
Posts: 49
Sweden
K
Kenchu Offline OP
Newbie
Kenchu  Offline OP
Newbie
K

Joined: Jan 2008
Posts: 49
Sweden
I tried that but it wouldnt work either. 2 would work however. Anyway, Im using media_loop instead. It works with volume 0. \:\)


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1