Kanon DS (51)

1 Name: Nagato : 2009-03-22 01:28 ID:KXg3k5uQ (Image: 256x384 png, 42 kb) [Del]

src/1237710518607.png: 256x384, 42 kb

Hey guys, for the past few days I've been working on a Reallive -> VNDS converter. So far it's going pretty well but I doubt it'll work on some of the more complex stuff. I want to try out some other stuff pretty soon so I'll try to update this thread with the status of that.

Anyway, as my test subject, I chose Kanon. I'll probably release a full Shiori route later once I get around to testing the rest of the scripts. I will only be using the scripts finished by NDT so please do not ask me for unfinished routes.

This beta demo only includes 2 scripts: Prologue and January 7th.

Known problems:

  • Audio glitches out toward the end for some reason. Notably the BGM, which will either loop again mid-play or make weird sounds. I also experienced a problem with voices while I was heavily using the skip feature. The voices would stutter sometimes, or play static at the beginning.
  • BGM started looping twice once I finished the demo and went back into seen0050.scr for the second time.

Kanon DS takes advantage of new commands added to VNDS 1.4.3 (released on 3/21/09) so please remember to upgrade to the latest version or it will not work properly.

If you find bugs or want to ask me a question, leave a message here or contact me on IRC (#ndt@irc.ppirc.net).

Beta download: http://www.mediafire.com/?rwnmtoymz14

anoNL: If you could look into the audio related problems I'm having, that'd be great. I ran with verbose level set and I didn't see anything that would be causing the problems to occur (like music being called repeatedly, etc) so I'm at a loss as to what the problem is.

2 Name: Nagato : 2009-03-22 02:42 ID:KXg3k5uQ (Image: 256x384 png, 64 kb) [Del]

src/1237714968642.png: 256x384, 64 kb

Update: Basic support for AIR. There's quite a bit of different functions used, mostly image related. A job for tomorrow I guess. :3

3 Name: anoNL : 2009-03-22 05:38 ID:7Ca3LQu+ [Del]

>anoNL: If you could look into the audio related problems I'm having, that'd be great. I ran with verbose level set and I didn't see anything that would be causing the problems to occur (like music being called repeatedly, etc) so I'm at a loss as to what the problem is.

Looping and glitching seem to both be caused by buffer underruns in vnds' sound code. A quick attempt at fixing:
http://www.weeaboo.nl/external/vndsx-1.4.4-r114.nds

The glitching gets worse near the end because the files at the end of the directory take much longer to open than those at the beginning. vnds supports storing files in uncompressed zip archives. For zip archives the filenames are stored (sorted) in RAM, so finding files is much faster.

4 Name: Anonymous : 2009-03-23 10:06 ID:7Ca3LQu+ [Del]

5 Name: Nagato : 2009-03-23 12:48 ID:bgW5DlOx (Image: 256x384 png, 65 kb) [Del]

src/1237837737214.png: 256x384, 65 kb

>>4
Thanks for the update.

I think I might've found a problem but I'm not entirely sure. I'm having trouble setting a string in a variable. I tried multiple methods (one without quotes, one with 's, and one with "s) and all of them set the variable to 0.

The code for strings in variables appears to be implemented (in VNDS::SetVar) but it doesn't seem to be working. Am I doing it wrong or something? There's nothing in the manual about storing strings so maybe I'm using the wrong syntax.

Pic related to thread: Updated my program a bit to support images in AIR as well as double character sprites.

6 Name: anoNL : 2009-03-23 15:35 ID:7Ca3LQu+ [Del]

>>5
You're right, string vars didn't work -- they were always interpreted as ints giving them the value 0.

Type inference is used to distinguish between vars, ints and strings. Vars are used if a var with the same name exists, ints are used if the argument is of the form /(-)?[0-9]+/ and otherwise strings. If the argument is recognized as an int, its string value also gets set, if the argument is a string, its int value is 0.

setvar c = 0
text setvar c
setvar c + blah
text setvar c + blah
text $c

This should print "0blah"

Fixed version:
http://www.weeaboo.nl/external/vndsx-1.4.4-r116.nds

7 Name: Nagato : 2009-03-23 15:51 ID:bgW5DlOx [Del]

>>6
I think something went wrong when compiling.

Guru Meditation Error!
undefined instruction!

I can give all the numbers if requested.

8 Name: anoNL : 2009-03-23 16:56 ID:7Ca3LQu+ [Del]

9 Name: Nagato : 2009-03-23 17:30 ID:bgW5DlOx (Image: 256x384 png, 65 kb) [Del]

src/1237854600074.png: 256x384, 65 kb

>>8
Thank you very much. :D This works perfectly.

10 Name: Anonymous : 2009-03-23 18:13 ID:HWrs8fuP [Del]

I noticed the string problem the other day when I was trying to get $var stuff to work in commands not just text.

it was driving me mad cause I kept thinking I broke something.

11 Name: Nagato : 2009-03-23 18:25 ID:bgW5DlOx [Del]

>>10
Doesn't work in this version either. :( It's something I was also interested in. I talked to Jake about it a little the other day but I'm not sure of the status on it.

12 Name: Anonymous : 2009-03-23 18:32 ID:HWrs8fuP [Del]

>>11
I was waiting for anoNL to upload the code for fixed sound, but I can upload it now if you want.

13 Post deleted by user.

14 Name: Nagato : 2009-03-23 18:47 ID:bgW5DlOx [Del]

>>12
Ah, I see. I look forward to it! :D Time to update my program in anticipation.

15 Name: Tales : 2009-03-23 19:07 ID:Wz+2HfLZ [Del]

I look forward a new manual script_format help...and waiting for the new version

16 Name: anoNL : 2009-03-23 19:18 ID:7Ca3LQu+ [Del]

>>12
fixed sound + string vars + using $var in text commands
http://www.weeaboo.nl/external/vndsx-src-r118.7z

17 Name: Tales : 2009-03-23 19:28 ID:Wz+2HfLZ [Del]

>>16
not including .nds file?

18 Name: Tales : 2009-03-23 19:32 ID:Wz+2HfLZ [Del]

>>17
Sorry I miss >>8

19 Post deleted by user.

20 Name: Nagato : 2009-03-23 19:39 ID:bgW5DlOx [Del]

Ignore 19, was a fail on my part.

I just uploaded a new version of the Kanon beta if anyone cares. This one uses ZIPs to store data and some small changes in the script output. This one should work perfectly coupled with the NDS file provided in >>8.

Download: http://www.mediafire.com/?zmjzmnz3nwi

21 Post deleted by user.

22 Name: Tales : 2009-03-23 20:06 ID:Wz+2HfLZ [Del]

>>21
I have downloaded:)
And I delete lots of vars such as a part of 'intF[]' 'intZ' which control the bgload effect/CG mode/music mode.
I worry about if I use a lot of useless vars,it will use more memory(?).Because the Chinese font was already too large......

23 Name: Nagato : 2009-03-24 09:59 ID:bgW5DlOx (Image: 256x384 png, 51 kb) [Del]

src/1237913964266.png: 256x384, 51 kb

1.4.4 solved the remaining difficulty I was having. Hopefully I don't run across anything else. :) Here's a picture from a scene I was having trouble with, I would have to manually edit the SCR file before uploading before. x_x

Yay!

24 Name: Nagato : 2009-03-25 13:40 ID:bgW5DlOx [Del]

Just finished play testing all of Shiori's route. Here's a list of problems I had which may or may not be related to my scripts.

Along the way I would have random data abort errors. No idea what the cause of this is. It really was random.

VNDS would also freeze while trying to save or take a screenshot and after waiting a few minutes, it still did nothing. No error messages during these times and I was able to use my CycloDS's soft reset menu to get out of it.

At random times, saving screenshots doesn't work, giving the cannot save error. Sometimes fixed itself.

Sometimes it would take a ridiculously long time to save or load. My guess is the huge amount of variables I'm trying to save/load? Here's a save file from just before the epilogue: http://www.privatepaste.com/7a0KlAPecR

String variables get saved as ints.

I'm going to try cleaning out the output a bit now that it's for the most part complete so maybe some of these bugs will disappear along the way.

25 Name: Anonymous : 2009-03-25 23:35 ID:6gGTyX0K [Del]

on the topic of string vars, is it possible to use them in filenames?

for example, i made it so that a string variable is set to either o or a, depending from what choice i select, and then i want a file to be called that includes it in its filename. something like filename+variable.ext

doing it like 01$var.ext gives a "can't find a 01var.ext file" though, so is there something additional i have to do to make it work, or is it impossible right now?

i ask that mostly because it'll save me from making a tree of ifelses.

26 Name: Anonymous : 2009-03-26 00:38 ID:HWrs8fuP [Del]

>>25
variables expect a space at the end of them.

make the .ext part of the variable value and it should work.

setvar var = asdf
setvar var + .ext
text 01$var
should work

27 Name: Anonymous : 2009-03-26 02:59 ID:6gGTyX0K [Del]

>>26
that works. thanks.

i did some testing, and the + part isn't really needed either. just setvar var = asdf.ext works.

the engine doesn't save the vars as string though (they got saved as int, and the value i had set reverted to 0), and for some reason variable detection didn't work either.

if var != asdf.ext

jump script.scr

fi

the var here was set to 0, but the check still got ignored and passed as if it was checking if var!=0

28 Name: Anonymous : 2009-03-26 06:47 ID:HWrs8fuP [Del]

>>27
I`ll look into it.

29 Post deleted by user.

30 Name: Nagato : 2009-03-26 07:40 ID:bgW5DlOx [Del]

Sleep posting ftl.

>>27
Are you using the latest version (1.4.4)? I make use of strings heavily in Kanon and it has been working fine. I haven't tried to use it as a condition though. Also, I think you might be able to do jump $var instead of using an if there (correct me if I'm wrong as I've only used a variable for bgload).

Status update:
I've optimized my output by about 1mb and things are running a little bit faster now. All that's left now is to fix the grpMulti command and do another play test. I should have a full Shiori route ready sometime next week hopefully.

31 Name: Anonymous : 2009-03-26 09:46 ID:6gGTyX0K [Del]

>>Are you using the latest version (1.4.4)?

yep, tried both 1.4.4 from here and the update from main dh site. the one from main site works as i described, while the release candidate ignores the variable in music command and prints an error.

>>Also, I think you might be able to do jump $var instead of using an if there (correct me if I'm wrong as I've only used a variable for bgload).

i doubt it. the if is there to send the player to a set up screen if the variable's not set. otherwise it ignores it and proceeds to the title screen.

i've been trying out this method to make exchanging resource sets easier. in the example i gave o was for original music tracks, a for arranged ones. with that i could just use music 01$music instead of two ifelses to exchange the music tracks easily.

the setup scr file is accessible normally from the title screen too, i just want it to be a forced choice on the first run.

that's why i made it so that the player has to select what set he wants to use if it's not set. 01a.mp3 or 01o.mp3 work, but just 01 doesn't.

32 Name: Nagato : 2009-03-26 11:14 ID:bgW5DlOx (Image: 256x384 png, 7 kb) [Del]

src/1238091250404.png: 256x384, 7 kb

Ah, I misunderstood what you were trying to do before. Sleep posting ftl. Here's what I came up with to get around the bug.

# Is it set?
if mverint == 0

choice Original|Arranged

# For some reason using selected to set a gsetvar doesn't work
if selected == 1
gsetvar mverint = 1
fi
if selected == 2
gsetvar mverint = 2
fi

fi

# Put this code at the beginning of scripts
if mver == 0

if mverint == 1
setvar mver = o.mp3
fi
if mverint == 2
setvar mver = a.mp3
fi

fi

music 01$mver (important space right there)

33 Name: Anonymous : 2009-03-26 11:14 ID:7Ca3LQu+ [Del]

>>31
It seems to be because the variable compare functions erroneously use int comparison when you compare a string with an int. (and using undefined variables inits them as int:0)

34 Name: qwerty : 2009-03-27 05:33 ID:WCryau7G [Del]

Another port of a key game? AnoNL, or Jake, if this is finished, pls. put it up in the home pge of VNDS, ok? Just live Saya no Uta.

35 Name: qwerty : 2009-03-27 05:33 ID:WCryau7G [Del]

Another port of a key game? AnoNL, or Jake, if this is finished, pls. put it up in the home pge of VNDS, ok? Just live Saya no Uta.

36 Name: qwerty : 2009-03-27 05:34 ID:WCryau7G [Del]

oh, sorry for the double post.

37 Name: anoNL : 2009-03-28 17:32 ID:7Ca3LQu+ [Del]

I've uploaded a new vnds version:
http://www.weeaboo.nl/index.php?aid=23
http://www.mediafire.com/?twyzdmymttw

This should fix all var-related weirdness except: "Using global vars in setvar or local vars in gsetvar doesn't work". For some reason I forgot to write it on my todo list (whoops).

38 Name: Kirbysuperstar : 2009-03-28 18:44 ID:zqT7TSQp [Del]

I noticed a couple of things last night when I was playing through this.

  • Saves don't work properly. I had a save when talking to the brown haired girl (Ayu, was it?), but when I loaded it, her picture appeared, but the games started over from the beginning of SEEN0070.
  • When Nayuki jumps on you after lunch, for some reason it shows her outside in her winter gear, then shows you back at the house.
  • Uh... I'm sure there was something else... Oh well.

39 Name: Nagato : 2009-03-28 18:58 ID:GDa7ZKx2 [Del]

>>37
Thanks for the update.

>>38
The second thing you listed I'm aware of. This was a problem I had before functionality to use variables for commands because of the way I parsed things. It's fixed in the next version. The scene is the same one pictured in >>23.

The save problem, I'm not sure. I can only hope it'll fix itself with the next release I make. I can tell you that old saves won't be compatible though since these scripts are a major overhaul. I'm talking a HUGE chunk of stuff taken out.

If only I could drag myself away from my other games long enough to test. /sigh

40 Name: Nagato : 2009-03-28 20:24 ID:GDa7ZKx2 [Del]

>>37
I believe I found a bug related to the backgrounds. I don't know the cause but the background in one part turns black and doesn't display until the next time it changes the variable I'm using to call bgload. This same script works in the previous version of VNDS though. To make sure this wasn't a one time thing, I restarted from the beginning and the problem persisted.

The information related to the background does save properly so loading the save fixes it, although it's not a good fix.

41 Name: anoNL : 2009-03-29 02:47 ID:7Ca3LQu+ [Del]

>>40
Can you give an example script that has the problem? I think I may have found the problem, but I'm not sure...

42 Name: Tales : 2009-03-29 08:31 ID:hNO54+OQ [Del]

>>37
Thanks for update.
Could you add an optional parameter to control the fading effect?
For example:
bgload 1.jpg (0)
bgload 1.jpg 1
The last parameter is optional.1 means no fading and 0 is with fading.If there's no argument in the end,the default is 0.

43 Name: Nagato : 2009-03-29 09:00 ID:GDa7ZKx2 [Del]

>>41
http://www.privatepaste.com/d2hvrzehsg

Should work with the last beta version I uploaded (with the ZIPs). Might have a graphic at the very beginning missing. The problem occurs around label @390. I just realized I need to fix up some of the setvar and if commands which do comparisons. /another sigh

44 Name: Anonymous : 2009-05-15 12:10 ID:dkaJLa5t [Del]

So, Nayuki route is out...
How's the port going? :)

45 Name: Anonymous : 2009-05-15 14:52 ID:eOE9qUtc [Del]

it was dubbed the "strawberry" edition.

46 Name: Anonymous : 2009-05-21 08:41 ID:DqB+NUj2 [Del]

I wonder if Nagato is still around...

47 Name: Nagato : 2009-06-03 04:48 ID:SPFbdFTe [Del]

>>46
I am. I lost interest mostly in porting stuff to the DS though. I was getting frustrated with VNDS at the time I was working on it, with the weird audio and visual glitches it had each release.

I've been directing my attention to working on the Kanon and Cross Channel translations plus a few things here and there when people ask for help.

>>44
Sad to say I don't know when, or if, I'll finish it. I don't have all of the updated source scripts or I'd upload an untested version of the 3 routes we've released on the PC.

Sorry to disappoint anyone who was waiting for this. If it's of any consolation, the PC version is getting done at least (about time, right?). :)

48 Name: Anonymous : 2009-06-03 05:25 ID:5215yQ9T [Del]

>>47
If you're stopping to develop it, could you please release the incomplete code as it is now?

49 Name: Ichi : 2009-12-28 11:00 ID:oSqV/TkK [Del]

Yeah, it would be nice

50 Name: Ikkimashou : 2010-03-11 21:33 ID:DAM92i2s [Del]

Hm... Been a while now. Any progress on the port at all? Or is it just simply impossible for this port?

51 Post deleted by moderator.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:
Image: