Which "ask" is current?
TriangleGames
28 Jun 2016, 20:47I came back to make repairs to Day Of Honor. It's "ask" function isn't working. I tried a couple of things, but no dice. At this point, it is written in as...
I think this game was originally created before version 5. At some point, I wanted to add something, and I updated it (including the "ASL version = " in the code. It is now a "version 5.5" file. I have discovered that the game has a lot of bugs I somehow didn't notice at the time, and I am finally trying to fix it. At this point, I have the current version (5.6.2) of Quest installed. I've been trying to read-up in the documentation, but at this point it is kind of messy and confusing. Unfortunately, this same sequence is repeated verbatim about a dozen times at different possible points of character death, and they all hang the game with an message about how ask was deprecated, but so far as I can tell, all that's different as far as usage is whether I use an upper or lower case "A/a" in the word ask, and neither one seems to want to work. Which version of ask should I be trying to use? Is there something about the way it's implemented that's interfering? Is that nested if/then business creating some kind of redundancy issue? I'm at a loss.
BTW: since it seems to be running the file, I have not changed the ASL version number in the code to 560 (562?). It is still listed as 550.
Sidenote: I really want to make a sequel to this now, but I feel like I should get "part 1" running smoothly first.
wait {
if (ask("Try again?")) {
MoveObject (crystal shard, player)
ClearScreen
MoveObject (player, outside the temple)
}
else {
finish
}
}
I think this game was originally created before version 5. At some point, I wanted to add something, and I updated it (including the "ASL version = " in the code. It is now a "version 5.5" file. I have discovered that the game has a lot of bugs I somehow didn't notice at the time, and I am finally trying to fix it. At this point, I have the current version (5.6.2) of Quest installed. I've been trying to read-up in the documentation, but at this point it is kind of messy and confusing. Unfortunately, this same sequence is repeated verbatim about a dozen times at different possible points of character death, and they all hang the game with an message about how ask was deprecated, but so far as I can tell, all that's different as far as usage is whether I use an upper or lower case "A/a" in the word ask, and neither one seems to want to work. Which version of ask should I be trying to use? Is there something about the way it's implemented that's interfering? Is that nested if/then business creating some kind of redundancy issue? I'm at a loss.
BTW: since it seems to be running the file, I have not changed the ASL version number in the code to 560 (562?). It is still listed as 550.
Sidenote: I really want to make a sequel to this now, but I feel like I should get "part 1" running smoothly first.
HegemonKhan
29 Jun 2016, 01:10the version in code should be:
..., 540, 550, 560
so, if you're using '5.6.2', it should be: <asl version="560">
if the '560' doesn't work... then try '550' instead
----------
there's: 'ask' and 'Ask'
'ask' is a popup menu window, and 'Ask' is in-line (in the big text box as hyperlinks) ... or I got them reversed, lol
-------
the 'ask/Ask' works like this:
-------
here's the change in syntaxes from version 530 to 540:
http://docs.textadventures.co.uk/quest/ ... notes.html
mainly they're the List/Dictionary Attribute syntaxes
..., 540, 550, 560
so, if you're using '5.6.2', it should be: <asl version="560">
if the '560' doesn't work... then try '550' instead
----------
there's: 'ask' and 'Ask'
'ask' is a popup menu window, and 'Ask' is in-line (in the big text box as hyperlinks) ... or I got them reversed, lol
-------
the 'ask/Ask' works like this:
ask ("Are you a male?") {
// choices: yes (true) or no (false)
// quest automatically (hidden from you) sets the built-in 'result' Variable for you: result = (your selection of yes:true/no:false)
if (result) { // the left is the shortened syntax of this: if (result = true) {
msg ("You are a male.")
} else { // or: if (result = false) {
msg ("You are a female.")
}
}
Ask ("Are you a male?") {
// choices: yes (true) or no (false)
// quest automatically (hidden from you) sets the built-in 'result' Variable for you: result = (your selection of yes:true/no:false)
if (result) { // the left is the shortened syntax of this: if (result = true) {
msg ("You are a male.")
} else { // or: if (result = false) {
msg ("You are a female.")
}
}
-------
here's the change in syntaxes from version 530 to 540:
http://docs.textadventures.co.uk/quest/ ... notes.html
mainly they're the List/Dictionary Attribute syntaxes
TriangleGames
29 Jun 2016, 03:20Thanks for the info!
So, with the knowledge that both versions of ask/Ask are now available, I determined that the problem was caused by the arrangement of putting the ask inside the if. So, I got that switched, and it seems to be working. Huzzah! There are other problems to deal with, such as replacing the Pauses I had in there with the newer set timeout, but I'm on my way to a full update.
Also, it seems to want me to keep the ASL as 550, just for the record.
UPDATE: the new and improved (and repaired) Day Of Honor has been uploaded. Thanks for the help!
Now I can begin work on "Day After Honor."
So, with the knowledge that both versions of ask/Ask are now available, I determined that the problem was caused by the arrangement of putting the ask inside the if. So, I got that switched, and it seems to be working. Huzzah! There are other problems to deal with, such as replacing the Pauses I had in there with the newer set timeout, but I'm on my way to a full update.
Also, it seems to want me to keep the ASL as 550, just for the record.
UPDATE: the new and improved (and repaired) Day Of Honor has been uploaded. Thanks for the help!
Now I can begin work on "Day After Honor."
HegemonKhan
29 Jun 2016, 22:53ya, I guess even though the newest quest version is 5.6.2 (in the 560's), it's updates must be only minor changes, allowing for we to still use the old 550's version in/for our game / game_code's tag: <asl version="550">entire game code/content</asl>