Lemma Soft Forums

Supporting creators of visual novels and story-based games since 2003.


Visit our new games list, blog aggregator, IRC, and wiki.
Activation problem? Email [email protected]
It is currently Tue May 21, 2013 1:01 am

All times are UTC - 5 hours [ DST ]


Forum rules


Ren'Py support questions should go here. This forum is for discussing changes to Ren'Py itself.



Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Sun Feb 06, 2011 3:19 pm 
Regular
User avatar

Joined: Wed Oct 20, 2010 12:34 am
Posts: 92
Location: Spokane, WA
I was looking through Clannad's(Which is a Visual Novel made by Visual Art's/Key)gameexe file's code and notice that they declare their music in this format:
Code:
# DSTRACK = 00000000 - 99999999 - 00269364 = "BGM01" = "BGM01"
# DSTRACK = 00000000 - 99999999 - 00297558 = "BGM02A" = "BGM02A"
# DSTRACK = 00000000 - 99999999 - 07612858 = "BGM02B" = "BGM02B"
# DSTRACK = 00000000 - 99999999 - 00000000 = "BGM02C" = "BGM02C"
# DSTRACK = 00000000 - 99999999 - 00165459 = "BGM03A" = "BGM03A"


In a manual someone made for the RealLive game Engine this is what it means

Quote:
#CDTRACK = from - to - loop = "name"

Defines track name to be CD audio. from, to, and loop define the start, end, and position to return to when looping respectively; each is of the form track:m:s:ms, where track is a track on the CD, and m:s.ms defines a position in minutes, seconds, and milliseconds.

name is an arbitrary string, which is passed to music playback functions (described in 5.9.2) to operate on this track.

#DSTRACK = from - to - loop = "file" = "name"

Defines track name to be DirectSound audio, usually in the VisualArt's nwa format.

The track is taken from file; from, to, and loop define positions in that file, as in #CDTRACK, but in this case each is a single integer. (I'm not sure what the unit is.)

name has the same semantics as in #CDTRACK; it need not be related to file in any way. DirectSound music is played using the same functions as CD audio.


So with this setup you can have a music file that has an introduction in it with out creating a separate file to do so. Because it will loop back at the point to tell it to loop back to.'DSTRACK', which was the example code, uses an interger but we could set it up with using a timestamp(hh:mm:ss). Like this example:

Code:
#configure.renpycd = ("START", "FINISH", "LOOP_TO", "PATH/TO/FILE", "NAME"
configure.renpycd = ("00:00:00", "00:03:47", "00:00:04", "BGM/BGM01.ogg", "BGM01")


Then you could just treat like any other file like you would with images.

Code:
label start:
    play music "BGM01"
    return


Just an idea I had for future features that could help improve Ren Py' system. What do you guy think about it?

_________________
The artist's world is limitless. It can be found anywhere, far from where he lives or a few feet away. It is always on his doorstep.
--Paul Strand


Top
 Profile Send private message  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Protected by Anti-Spam ACP
Powered by phpBB® Forum Software © phpBB Group