Can't find the error in BookGUI!

If you feel like you're up to the challenge of building your own Ages in Blender or 3ds Max, this is the place for you!

Can't find the error in BookGUI!

Postby ametist » Sun Oct 19, 2008 1:39 am

My ageBooks won't open when I click them though there is a hotspot. The .pak file adds BookGUI.py, PageDefs.py and Jornals.py without problem.
If someone would be so kind to hint me ;) what to do next - I get the same 'error'message in python.elf despite I've deleted and re-created the BookGUI.py a dozen times. I've done it from scratch, I've done it by copying another BookGUI from my other age(which is working) and just filled in the different names, I've done it by using D'lanors template and just filled in my names. Still getting this message from .elf:
Show Spoiler


and this is my BookGUI - I haven't changed anything in those lines mentioned above: line 37 OnNotify,line101 InOpenBook

Show Spoiler


I can't figure this out by myself ;)
User avatar
ametist
 
Posts: 360
Joined: Fri Dec 28, 2007 6:55 am

Re: Can't find the error in BookGUI!

Postby D'Lanor » Sun Oct 19, 2008 3:50 am

The error is in PageDefs.py. Even if it is a journal the template needs an entry under LinkDestinations with all parameters set to None.
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am

Re: Can't find the error in BookGUI!

Postby ametist » Sun Oct 19, 2008 7:07 am

Thanks for answering D'Lanor! But... I have done that ;)

Here's from PageDefs.py:
Show Spoiler
User avatar
ametist
 
Posts: 360
Joined: Fri Dec 28, 2007 6:55 am

Re: Can't find the error in BookGUI!

Postby GPNMilano » Sun Oct 19, 2008 7:25 am

Paste the code for the bookpage. Its cutoff in the picture so you can't see it all that well. (Also, in your journal, make sure you have the correct string before its contents like
Code: Select all
DefKinnekulleJournal = "Your journa's contents"


Also, in that code. it should read
Code: Select all
(PageStart + DefKinnekulleJournal),
remove the extra "(" after PageStart.
You can't stop the truth. IC Blog
User avatar
GPNMilano
 
Posts: 1155
Joined: Mon Apr 21, 2008 5:50 am

Re: Can't find the error in BookGUI!

Postby D'Lanor » Sun Oct 19, 2008 7:57 am

It may be simply a syntax error in the journal text. For example an unsupported character that was not escaped properly. That usually chokes everything with a seemingly unrelated error message.
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am

Re: Can't find the error in BookGUI!

Postby ametist » Sun Oct 19, 2008 8:55 am

Thank you GPNMilano and D'lanor, much appreciate your efforts! :)
Here's the page with no 'cut offs' ;)
Show Spoiler


And I've checked my Journal - it starts ok with DefKinnekulleJournal = and then I actually have three ''' on each side of the line with text - which is red and that I've learnt say that it's correct?

Guess I can try with just two '' instead of three?
User avatar
ametist
 
Posts: 360
Joined: Fri Dec 28, 2007 6:55 am

Re: Can't find the error in BookGUI!

Postby D'Lanor » Sun Oct 19, 2008 11:05 am

Triple quotes are useful if you want to use normal line breaks instead of a single line with \n for line breaks. However, some programs get confused by them and they will no longer be able to spot syntax errors correctly. So it would be a good idea to use " instead.
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am


Return to Building

Who is online

Users browsing this forum: No registered users and 21 guests

cron