Axe Software Forums
  Quest Developer Forum
  Question about quest.currentroom.


Author Topic:   Question about quest.currentroom.
Computer Whizz posted 07-05-2001 00:46 GMT     
Hi, if I wanted to set quest.currentroom as a variable (so that after something has been done, the character can be returned to the same room) would I (in QDK) change the text contained in a certain string to quest.currentroom? ie:
beforeroom;#quest.currentroom#
or is it without the #'s?? Alex, you haven't put any default syntax in the advanced part!... TUT,tut, tut. :)
see you around...... um, in here!

--CW

Alex posted 07-05-2001 01:52 GMT          
The syntax you give should work properly.

QDK3, incidentally, has a much lovelier way of editing script commands which does away with all the nasty semicolons and gives handy prompts and drop-down lists. Alpha coming soon... probably.

MaDbRiT posted 07-05-2001 09:58 GMT          
quote:
would I (in QDK) change the text contained in a certain string to quest.currentroom? ie:
beforeroom;#quest.currentroom#

I use that syntax 'behind the scenes' in my "standard.lib" for Quest 2.x.. So not only should it work, I can assure you it does work. :-)

Have fun,

Al

Computer Whizz posted 07-05-2001 20:12 GMT          
hehe....probably!
oh and Madrabit, how do you use it in the standard.lib? I'm using it to get around some of my problems (so!? it's the easy way out... plus the ONLY way out I can see.).
But I should have a working demo of my system ONLY before October..... just before Alex releases QDK3 and the updated QX3 he's got stashed away! :)
anyway, better get back to it.

--CW

MaDbRiT posted 07-05-2001 20:53 GMT          
quote:
how do you use it in the standard.lib

Well in the rather convoluted code that deals with the checking of 'container' contents I needed to move the player to a dummy room to check its (and therefore the containers) contents.

I used a string variable called 'where_we_were' to hold the value of #quest.currentroom#, turned off output, moved the player, did my stuff and then read the value of #where_we_were# to return the player to his original location and turned on the display again.

If you want to see it, open standad.lib in a text editor and look at the procedure called Check_Contents_Proc, it starts at line 169 and is just 18 lines long.

Mind you it's very much a subroutine and is used by being called by another much hairier piece of code.

Al