FAQ Search Memberlist Usergroups
Jolt Country Forum Index
Register Profile Log in to check your private messages Log in
Log in Log in

Kent or Whomever

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Jolt Country Forum Index -> Hugo's House of Horrors
View previous topic :: View next topic  
Author Message
Debaser



Joined: 25 Jun 2002
Posts: 878
Location: Aurora, IL

PostPosted: Thu Jun 24, 2004 10:53 pm    Post subject: Kent or Whomever Reply with quote

Oddly, when I tried to steal the help menu code for use in the table of contents in a book, it didn't work. Code replicated here:

Code:
routine DoReadGrimoire
{
 if (diogrimoire in player)
 {
   "You recognize the familiar scrawl of your own, cramped handwriting upon the pages of this grimoire.  You peruse its contents thoughtfully, hoping to find a trick or secret to get you out of your current predicament..."
   pause
   local a = 1

   TEXTCOLOR = BRIGHT_WHITE
   BGCOLOR = BLACK

   MENU_TEXTCOLOR = DEF_FOREGROUND
   MENU_BGCOLOR = DEF_BACKGROUND
   MENU_SELECTCOLOR = DEF_SL_FOREGROUND
   MENU_SELECTBGCOLOR = DEF_SL_BACKGROUND

   while true
   {
      menuitem[0] = "BOOK OF SECRETS"
      menuitem[1] = "Preface"
      menuitem[2] = "A Desperate Invocation"
      a = Menu(2, 0, a)
      select a

      case 0
      {
         TEXTCOLOR = DEF_FOREGROUND
         BGCOLOR = DEF_BACKGROUND
         color TEXTCOLOR, BGCOLOR
         window 0
         cls
         PrintStatusline
         DescribePlace(location)
         return
      }
      case 1:  GrimPreface
      case 2:  GrimDesperate
   }
 }
 else { "You need to be carrying your grimoire to reference it." }
}

routine GrimPreface
{
 CenterTitle("\BPreface\b")
 "\nAt the time I put pen to paper on this"
 pause
}

routine GrimDesperate
{
  "a"
  pause
}


Somehow, changing "routine DoReadGrimoire" to "replace DoHelp" fixed it. While the help menu logic doesn't seem sufficient to cover eveything the menu does, I'm also completely lost as to how a replaced help routine is activating the super-secret library codes I need to get things to work right.

Any explanations and/or tricks to getting more than one help-menu style menu in one game? Thanks in advance.
Back to top
View user's profile Send private message Send e-mail AIM Address
Kent



Joined: 27 Jun 2003
Posts: 119

PostPosted: Fri Jun 25, 2004 5:39 am    Post subject: Re: Kent or Whomever Reply with quote

Debaser wrote:
Oddly, when I tried to steal the help menu code for use in the table of contents in a book, it didn't work.
[...]
Somehow, changing "routine DoReadGrimoire" to "replace DoHelp" fixed it.

What does "it didn't work" mean here? Because that's kind of weird.
Back to top
View user's profile Send private message
Debaser



Joined: 25 Jun 2002
Posts: 878
Location: Aurora, IL

PostPosted: Fri Jun 25, 2004 7:18 am    Post subject: Reply with quote

The menu comes up, but selecting an option doesn't actually do anything. The screen stays static and doesn't activate the option. Robb reports memories of similar problems back when he was coding ACS, and he was the one who suggested switching the routine back to help.
Back to top
View user's profile Send private message Send e-mail AIM Address
Ice Cream Jonsey



Joined: 27 Apr 2002
Posts: 20088
Location: Colorado

PostPosted: Sun Jun 27, 2004 4:52 pm    Post subject: Reply with quote

Yes, it's quite odd. There's nothing "hard coded" into Hugo regarding the help routine's use of menus, is there?
_________________
the dark and gritty...Ice Cream Jonsey!
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Kent



Joined: 27 Jun 2003
Posts: 119

PostPosted: Sun Jun 27, 2004 9:48 pm    Post subject: Example Reply with quote

Is there any chance you can send me some compilable source that demonstrates this?

(In response to ICJ--no, there's nothing in the engine hardwiring-wise which should affect this, at all.)

--Kent
Back to top
View user's profile Send private message
Debaser



Joined: 25 Jun 2002
Posts: 878
Location: Aurora, IL

PostPosted: Sun Jun 27, 2004 10:02 pm    Post subject: Re: Example Reply with quote

Kent wrote:
Is there any chance you can send me some compilable source that demonstrates this?


What's your addy?
Back to top
View user's profile Send private message Send e-mail AIM Address
Kent



Joined: 27 Jun 2003
Posts: 119

PostPosted: Mon Jun 28, 2004 12:24 pm    Post subject: Oops Reply with quote

Good point. tessman@hotmail.com
Back to top
View user's profile Send private message
Debaser



Joined: 25 Jun 2002
Posts: 878
Location: Aurora, IL

PostPosted: Mon Jun 28, 2004 4:31 pm    Post subject: Reply with quote

Um... nevermind. I guess, somehow, in the process of cutting out the requisite bits of code into a shell for you to look at, I fixed whatever problem I was experiencing. Haven't the faintest clue what I did. Odd that, but I guess I shouldn't look gift code in the mouth. Thanks anyway.
Back to top
View user's profile Send private message Send e-mail AIM Address
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Jolt Country Forum Index -> Hugo's House of Horrors All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001 phpBB Group

Theme by Kage Musha - RPG Garden

Copyrights and trademarks are all of the belonging company. No copyright Infringement intended