PDA

View Full Version : ONScripter syntactic error


K&S
2010-04-16, 21:09
Hi, I'm not sure if this is the right section to post this but...
We're having trouble translating something made with NScripter but for translating purposes we decided to use the ONScripter-EN version 2010.3.9.0 and experienced several issues some of which we already figured out on our own.

The first half of our English translation plays smoothly up until a certain point, it immediately cancels itself and displays an error in Japanese. Depending on what line of Japanese text we replaced with English it'll either say:

構文エラー (syntactic error)

数字がくるべきところに数字がありません。

099.txt line:2011

|[$850](……って…うわ!こっち見た!!)

|[怪しい二人]じーーっ
>[$850](Why?

Another syntactic error:
構文エラー (syntactic error)

不正な"jo"命令です

099.txt line:2010

|[$850](……なんかコソコソしてものすご~く怪しい……!!)
|[$850](……って…うわ!こっち見た!!)
>[怪しい二人] Jo

It always seems to change depending on the text that was exchanged like I said earlier. Here's it again in a screen shot: **NOTE: We were trying to upload the images to Photobucket but can't seem to access the control panel at the moment so we'll edit this topic and put it on tomorrow.** EDIT: http://i837.photobucket.com/albums/zz294/princepanic/error1.gif
http://i837.photobucket.com/albums/zz294/princepanic/error2.gif
http://i837.photobucket.com/albums/zz294/princepanic/theproblem-1.gif
THIS PROBLEM HAS BEEN SORTED OUT!
Here's a picture of our workspace: http://i837.photobucket.com/albums/zz294/princepanic/workspacewithapostrophesadded.gif The solution was to just add an apostrophe at the start of the text.

We would love to just ignore the error and continue translating but it just cancels instantly after previewing the English, and there's no way to skip or go around the obstacle. It's strange though because the first half has no problem.

It's very hard to explain in writing but if someone does understand even just a little, please post or if there's anything important that we forgot to mention let us know.
Another thing is a lot of the text appears jammed up together, probably because Japanese doesn't space it like English does but we don't know how to go about fixing that either. We fixed the crammed text it was also because we had forgotten to add an apostrophe but now we encountered another problem: http://i837.photobucket.com/albums/zz294/princepanic/textgoesoffthescreentolargeofafont.gif The text appears cut off because the font is too large is there anyway to decrease the font size? Another example of it happening: http://i837.photobucket.com/albums/zz294/princepanic/Nameisoverlappingthebackground.gif

To just clear up a few things, we didn't have the "|" or ">" signs in the document for some reason it showed up in the error.

pbsaffran
2010-04-17, 02:01
Hmmm.
Are those "|" signs supported in ONScripter ?
And I thought you were supposed to start english lines with a `, not with a >.

Anyway, it might be that you have to write the ">" sign -after- the [] labels.

To be honest, it just sounds to me like you don't use the proper tags to switch between jp mode and en mode.

Roto
2010-04-17, 10:50
Text size is controlled by several interrelated parameters in the setwindow (http://onscripter.denpa.mobi/api/NScrAPIm.xml#setwindow) command. ONScripter-EN (as well as ONScripter and NScripter, for that matter) has poor support for switching between font sizes on-the-fly. You could look at what windows your *customsel routine is using to display the choices, and try to tweak them to use smaller text. It would pretty much be a global change, though; not just for that option.

I notice that all of the error windows you've posted are NScripter errors, not ONScripter-EN. Be aware that NScripter's English support is very limited and trying to test your translation in NScripter itself is probably not very meaningful.

Are those "|" signs supported in ONScripter ?
And I thought you were supposed to start english lines with a `, not with a >.

I think those characters are just NScripter's way of highlighting which line contains the error that it's pointing out ^_^

K&S
2010-04-17, 15:06
Text size is controlled by several interrelated parameters in the setwindow (http://onscripter.denpa.mobi/api/NScrAPIm.xml#setwindow) command. ONScripter-EN (as well as ONScripter and NScripter, for that matter) has poor support for switching between font sizes on-the-fly. You could look at what windows your *customsel routine is using to display the choices, and try to tweak them to use smaller text. It would pretty much be a global change, though; not just for that option.

I notice that all of the error windows you've posted are NScripter errors, not ONScripter-EN. Be aware that NScripter's English support is very limited and trying to test your translation in NScripter itself is probably not very meaningful.



I think those characters are just NScripter's way of highlighting which line contains the error that it's pointing out ^_^

I don't quite understand, could you specify it better? What would this customsel look like? What part of it would be the text resizing?

The setwindow is:

setwindow 40,365,27,4,20,20,0,3,20,0,1,#FFFFFF,18,354,626,477

An image and explanation of what (and where) the text we want to edit is:
http://i837.photobucket.com/albums/zz294/princepanic/setwindow.gif

When we edited the setwindow it only seemed to resize the text inside the box, not where the names appear or the options (which we are trying to change.)

Roto
2010-04-17, 16:38
When you call csel (http://onscripter.denpa.mobi/api/NScrAPIm.xml#csel), it jumps to a routine labeled *customsel (http://onscripter.denpa.mobi/api/NScrAPIm.xml#*customsel) to actually handle the choice selection. The idea is that NScripter provides a pretty basic selection routine with select (http://onscripter.denpa.mobi/api/NScrAPIm.xml#select), and if a game wants to override it for a fancier display, it can define a *customsel routine and use csel instead of select. In the *customsel routine, cselbtn (http://onscripter.denpa.mobi/api/NScrAPIm.xml#cselbtn) is used to specify where the choice buttons will be displayed, in the text coordinates of the current window. There are likely multiple setwindow (http://onscripter.denpa.mobi/api/NScrAPIm.xml#setwindow) commands in your script that define the various locations where text is displayed (such as at the beginning of the *customsel routine.)

K&S
2010-04-17, 16:58
When you call csel (http://onscripter.denpa.mobi/api/NScrAPIm.xml#csel), it jumps to a routine labeled *customsel (http://onscripter.denpa.mobi/api/NScrAPIm.xml#*customsel) to actually handle the choice selection. The idea is that NScripter provides a pretty basic selection routine with select (http://onscripter.denpa.mobi/api/NScrAPIm.xml#select), and if a game wants to override it for a fancier display, it can define a *customsel routine and use csel instead of select. In the *customsel routine, cselbtn (http://onscripter.denpa.mobi/api/NScrAPIm.xml#cselbtn) is used to specify where the choice buttons will be displayed, in the text coordinates of the current window. There are likely multiple setwindow (http://onscripter.denpa.mobi/api/NScrAPIm.xml#setwindow) commands in your script that define the various locations where text is displayed (such as at the beginning of the *customsel routine.)

It was found under customsel, yes. But we had to find a certain line called getcselstr and modify the width and height and it corrected the problem we were experiencing with the options. Then we went onto finding how to change the text displaying in the name window and basically found the same line and changed it the same way. That seems to solve everything. Thank you very much for your time.