Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: on Sat 09/10/2004 22:07:12

Title: Question about getting "look at" "walk to" etc interface
Post by: on Sat 09/10/2004 22:07:12
Sorry if this has been posted before, but I can't seem to find any information on the information bar that shows your inventory and all of the commands (look at, walk to, interact with etc). It it a gui? somthing else? Thanks!
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: Edwin Xie on Sat 09/10/2004 22:10:17
http://www.agsforums.com/yabb/index.php?topic=14369.0

It has all the information you need on doing this. If you still don't get it, ask me about it.
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: TerranRich on Sun 10/10/2004 01:59:38
Also, what about this very forum's own "LucasArts Style GUI" sticky thread? Or is that not what you meant?

If you mean the Sierra-style GUI (with icon buttons for the actions as well as a control panel and inventory, etc.), then that's default.

Or if you mean the early Sierra GUI, with a Windows/Mac-style menu feature, then that's another thing separately. If it's this one, then we'll try to help you out with it. It would invovle multiple GUIs called within each other.
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: on Sun 10/10/2004 20:38:27
Ok, that helps, however I do have one more question. How do I use the template to create my own game? Do I just overwrite all of the rooms/chars/etc??


Title: Re: Question about getting "look at" "walk to" etc interface
Post by: Goot on Sun 10/10/2004 23:10:45
Start a new game and choose the template instead of default game. Then add to it to create your game.
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: on Mon 11/10/2004 05:19:30
ok, scripting question. In the template, there is a script:

#sectionstart hotspot2_b  // DO NOT EDIT OR REMOVE THIS LINE
function hotspot2_b() {
  // script for hotspot2: Extended  hotspot
if (UsedMode(OPEN)){
  //GoTo(2);
  if (Go()){
  Display("Now its open");
  SetGlobalInt(1,1);
  }
  }
else if (UsedMode(CLOSE)){
  //GoTo(0);
  Display("Now its closed");
  SetGlobalInt(1,0);
  }

else Unhandled();

So you can open the door and close it. Now, how can I make it so that I can only go through the door once its open?

Title: Re: Question about getting "look at" "walk to" etc interface
Post by: Edwin Xie on Mon 11/10/2004 05:28:02
If there is a room that looks like:

________||___________

(the thing in the middle is the door)

then you would use "MoveCharacter(CHARID,x,y);" or something like that but if it's a door like this (in two rooms):
First Room:

_________||

Second room:

||_________

Then you would use "NewRoom (int newroom);" or "character[CHARID].room = int newrooom" or something like that.
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: on Mon 11/10/2004 09:39:17
Great help, thanks guys. I do have another quick question, How can I make it so that it fades out, displays a message (on a black background) then fades back in? I can't seem to do it using the Fade in fadeout commands, since I can't tell it to display somthing in between. (At least I tried, it just didn't listen)

Thanks
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: TerranRich on Mon 11/10/2004 14:01:22
use a black object that fades in, then fade in an object with text in sprite form, or Raw text, then change rooms with the Fade Transition set.
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: on Mon 11/10/2004 21:16:35
Alright...but how do I hide the character? Is there a script command to change the character to hidden?
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: on Mon 11/10/2004 21:43:10
N/f, I didn't know objects appear in front of the character. The fade transition set? Not sure what you mean...
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: on Mon 11/10/2004 22:37:34
Ok, got it figured out  ;D
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: TerranRich on Tue 12/10/2004 00:48:33
Cool. To answer your questions anyway, there is the SetRoomTransitition() function, but you obviously looked in the manual, which is what I would've told you to do. ;) And objects do appear in front of characters, but for future reference, the SetCharacterTransparency() function works well in this case, setting it to 100 (fully transparent and, therefore, invisible).
Title: Re: Question about getting "look at" "walk to" etc interface
Post by: strazer on Tue 12/10/2004 01:00:31
But remember that when using SetCharacterTransparency with 100, the character can still be interacted with despite being invisible.

Here are some more ideas on how to hide characters:

character[CHARID].room = -1; // remove character from game

or

character[CHARID].on = 0; // unsupported feature; it works like the "Hide player character" checkbox in the room settings

or

Assign a blank view

or

character[CHARID].x = -100; // place character outside of the screen