Axe Software Forums
  Quest Developer Forum
  Anyone Question


Author Topic:   Anyone Question
fiton posted 31-07-2001 06:02 GMT     
Okay, I put in commands> I test out the game like this: I pick up an item item gone from screen, item doesn't pop up in inventory.

And how do you do this: Ask there name then it pops up in the game?

MaDbRiT posted 31-07-2001 08:02 GMT          
In q2.x you have to make anything you want the player to carry about an ITEM as well as making it a takeable object. This is a bit odd - and Q3 changes it for the better.

For Q2.x - I'll put a little demo of how this is done, and how to ask the player for their name on line for download later on.

My Tutorial (which is for coding Quest manually admittedly) explains this and more.

Al

Luridii posted 31-07-2001 09:20 GMT          
I'm talking a lot 2day!

Ok, first you have to set the item up as an actual item
so if ur writing in asl put item (im using Sword as example)
items <Sword>
If ur using qdk go to the edit menu, Game, items and set the Sword item up there.

then for the Sword item itself (shown in asl)

define object <Sword>
look <A shiny Sword>
take {
give <Sword> (puts item in inventory)
hide <Sword> - (so it is no longer seen in the room)
msg <you take the sword>} (just so the player knows they've picked it up)
end define


the stuff ive written in () is just to show what the command does.


As for the name in the startscript of my game is enter #name#. What the player enters is put in the string variable name, and whenever you want a character to adress him/her you type #name# eg.

define character <Bob>
speak say <hi #name#>
end define

MaDbRiT could probably have explained it better but i'm just telling you the basics for the moment :)

Computer Whizz posted 31-07-2001 11:55 GMT          
Well, talking about inventory items, in ASL 284 and 285, does the look command still work when the object is in the inventory? Or does it need to be coded like in Q2.x??

Ok... for one, don't worry too much about picking objects up. When QDK3 comes out then you won't need to put anything in there.... it just picks it up automatically! As for the name input, well it would be best if you put it in the "player enters room" script. That way when the player enters the start room, it asks him for his name. Now go into the room properties, go down to actions (right?) go into "player enters room" and a window should open. This has the option to "Add Action" in the top right hand corner. Now click it and press on the menu arrow. Keep going down until you see "Put what the player types into a string" and click it. Then type in PLAYERNAME or something like that... You might also want the player to know that he should enter his name, so you have to add another action. This action is "put message on the screen" and is the first choice! Now just put enter name in the text box. After you click OK, select the action you just made (printing the message) and move it above the other action by pressing "move up" on the right hand side!
Do you understand?

--CW