|
Axe Software Forums
Quest Developer Forum Pictures and Money
|
Author | Topic: Pictures and Money |
JimGtzy |
posted 18-09-2001 22:01 GMT
I have two questions, and they're both bugging the crap outta me. 1.)How do I put pictures in? 2.)How do I make it so that when I check a kitchen countertop, have it say "you found 50 dollars", and make it say something different the next time i check it? I already have the money variables set, but my problem is that "you found 50 dollars"keeps repeating itself. If anybody can help me with this than please do. It would be greatly appreciated. |
MaDbRiT |
posted 18-09-2001 22:16 GMT
Before we can offer any useful advice, we need to know if you are using Quest 2 or 3 and if you are coding with QDK or by hand.. KInd of pointless to tell you how to do it in a way you don't use after all :-) Al |
JimGtzy |
posted 18-09-2001 22:32 GMT
Oh yea, sorry bout that. I'm using QDK 3.0. |
Alex |
posted 18-09-2001 22:50 GMT
1. At the relevant point in your game, use the script command "Show a picture", from the Multimedia category. 2. Presumably this is the text that's printed when the player types "look at countertop"? If so, you need to change the countertop's description. You can do this by changing the "look" property of the "countertop" object in the countertop's look script - the script command you need is "Change an object's (or room's) property" in the Objects category. Select the object "countertop" from the objectlist and enter "look=Whatever the new description is" in the "Property data" box. |
JimGtzy |
posted 18-09-2001 23:03 GMT
OK, thanks for you help on ?#2, but I got the picture command to work, but the attributes I type in have no effect on how the picture appears. The picture window is always the same size. Why is this? |
Alex |
posted 18-09-2001 23:16 GMT
Hmm... you're right. Something isn't working properly. Also I've noticed it doesn't display the script command correctly on the Script Commands Editor... which means we'll have a Quest/QDK 3.02 before too long. Thanks for pointing this out! |
JimGtzy |
posted 18-09-2001 23:20 GMT
No problem Alex. Sorry to bother you again, but the whole "Look Property" thing is confusing me. Here's my scenario. I have a counter and i want my character to look at it. When he looks at it, it will say "you found 50 dollars". Then it gives me 50 dollars. But my problem is, when i click LOOK again, the process repeats itself. Is there a way to switch it off and make it say "nothing is left on the counter"?? Thanks |
Computer Whizz |
posted 18-09-2001 23:42 GMT
Yes..... Almost, if not, ALL programmer's use this sort of thing! What you do is set it to check a variable, say "counter_money". Now when the game starts up you might want to set the variable. Computer Whizz |
MaDbRiT |
posted 19-09-2001 20:28 GMT
There are several ways to do the 'money on the counter' - here's how I'd do it. You can cut and paste the following and run it in Quest :-)
quote: All the 'trickery' is contained within the counter object. What I have done is set the counter to initially have a property of being 'cash-rich'. This is a boolean property and so is either 'true' or 'false', i.e. the counter is either cash rich (true) or not cash rich (false). Now when first looked at, the code tests to see if the counter is 'cash-rich' - if it is ('returns true' in code-speak) the code prints the message about finding money, increases the money by $50 and then sets the counter to be NOT cash-rich. Second or later time the counter is looked at - the 'is cash-rich' test now fails (returns false) and so the 'shiny but uninteresting' message gets printed. The cash-rich property (or any other method) when used in this 'true/false' way to indicate a condition is usually referred to as a 'flag'. Hope this helps! Al |
JimGtzy |
posted 20-09-2001 02:35 GMT
Well thanks Madrabbit, I understood everything you said, but how can I do that in QDK? Or WAS your description FOR QDK? |
MaDbRiT |
posted 20-09-2001 14:10 GMT
The code I supplied was hand written in TEXTPAD rather than generated with QDK. It is quite simple to create the same code with QDK - or it SHOULD be. I tried to create the code as above, it seemed to look O.K. when creating the game but the output file 'hung' with a too many "}" error when run in Quest. This has to be the infamous 'brackets' bug in QDK rearing its ugly head. I think a new Quest/QDK release addressing this issue amongst others is in the pipeline? Al |
JimGtzy |
posted 20-09-2001 20:57 GMT
Ok, now that QDK v3.02 is out, can you explain how to use that ASL code you wrote and apply it to QDK? |
MaDbRiT |
posted 21-09-2001 20:02 GMT
JimGtzy asked:
quote: I can try, sorry for the delay but the virus writers of the world are keeping people like me very busy at the moment - the morons. :- Anyway, here's what I did in QDK to get a working result. Assuming you know how to define the kitchen room, and basics like setting the startroom and defining the 'money' status variable, here is a blow-by-blow of how to create the 'counter' object with disappearing money in QDK.
quote: Note that I used ' single quotes to highlight stuff here, you don't ever type those! Hope this gets you up and running, the above looks confusing unless you are looking at QDK as you read it - I'd suggest you PRINT this and follow it through. Al |
JimGtzy |
posted 22-09-2001 22:47 GMT
Yo MadRabbit, You kick ass. Thanx for the tip. I'm not COMPLETELY stupid, i mean i knew i had to use a switch because i worked a lot with rpgmaker2000 before QDK, but i wasn't too familiar with this system. Your tip helped a lot thanx. Jim |