Hyperlinks
Spindraft
26 Dec 2013, 15:56This is the way it is done in the objects "look at" section
Not really knowing what the reaction of this gruff, shadowy person might be you speak in a cautioned voice, asking about {object:fog, wall, corridor, door, stranger}
When I put this in a any other script box it does not work, why?
TriangleGames
26 Dec 2013, 17:20If it still isn't doing what you want, please provide a specific example of what you're doing that is NOT working so we can look at that.

jaynabonne
26 Dec 2013, 17:50{object:fog, wall, corridor, door, stranger}
That will not work. You have to list the objects out separately:
{object:fog} {object:wall} {object:corridor} {object:door} {object:stranger}
Are you sure that's working for you?
Spindraft
26 Dec 2013, 19:35It goes like this
{once:Overcoming your initial shock you begin to formulate many questions you would like to ask this gruff, shadowy stranger.} {object:stranger}
Click on "stranger"
SwitchOn (leapinter2b)
NewText (speak)
msg ("Not really knowing what the reaction of this gruff, shadowy person might be you speak in a cautioned voice, asking about {command:leapinterdoor:the door}")
click on "the door"
msg ("You ask'" + if there is an exit from this corridor? + "'")
The function is listed as type "string"
The command has a pattern of "the door #text#" but this is only because "regular expression did not work either and this is what is set to right now.
I have followed the directions both in wiki and on forum.
The deal is I only want these links to show when certain things have happened. I am still trying to figure out menu's and lists.

jaynabonne
26 Dec 2013, 19:47
(For example, the last snippet you posted won't work, as you have literal text outside quotes.)
HegemonKhan
26 Dec 2013, 19:48Print a [MESSAGE] = everything is returned~recognized as text (a string)
whereas you should change it to:
Print a [EXPRESSION] = Commands and Attributes are recognized as such (as non-text), and what is within the "____" marks is recognized as text
-------------
if you want help with menus and lists, I'd be glad~happy to help you with them!

Spindraft
26 Dec 2013, 20:14 <object name="stranger">
<inherit name="editor_object" />
<usedefaultprefix type="boolean">false</usedefaultprefix>
<scenery />
<gender type="string"></gender>
<article type="string"></article>
<alt type="stringlist">
<value>owner of voice</value>
<value>person</value>
<value>man</value>
<value>owner of deep voice</value>
</alt>
<displayverbs type="stringlist" />
<usestandardverblist type="boolean">false</usestandardverblist>
<useindividualverblist type="boolean">false</useindividualverblist>
<look><![CDATA[{once:Overcoming your initial shock you begin to formulate many questions you would like to ask this gruff, shadowy stranger.} {object:stranger}<br/><br/>]]></look>
<leapdoor type="simplepattern">leapinterdoor</leapdoor>
<speak type="script">
SwitchOn (leapinter2b)
NewText (speak)
</speak>
<ask type="scriptdictionary">
<item key="corridor">
msg ("A yellow corridor")
</item>
<item key="wall">
msg ("as")
</item>
<item key="fog">
msg ("as")
</item>
<item key="door">
msg ("as")
</item>
<item key="mist">
msg ("as")
</item>
<item key="cloud">
msg ("as")
</item>
<item key="you">
msg ("as")
</item>
<item key="person">
msg ("as")
</item>
<item key="stranger">
msg ("as")
</item>
</ask>
</object>
<object name="wall3">
<inherit name="editor_object" />
<alias>wall</alias>
<alt type="stringlist">
<value>wall</value>
<value>walls</value>
<value>boundary</value>
<value>border</value>
<value>edge</value>
</alt>
<usedefaultprefix type="boolean">false</usedefaultprefix>
<scenery />
<gender type="string"></gender>
<article type="string"></article>
<look>The wall here is very hard and covered with a thick, wavy, yellow cloud which seems to mock the darkness of the corridors other wall.</look>
<kick>You nearly break all of your toes against the hard surface.</kick>
<rub>The wall is very strong, it feels like it is made from huge, well crafted stone blocks forming a formidable barrier.</rub>
<touch>The wall is very strong, it feels like it is made from huge, well crafted stone blocks forming a formidable barrier.</touch>
<punch>Left with nothing but bloody knuckles you discontinue this absurd behaviour.</punch>
</object>
<object name="leapinter2b">
<inherit name="editor_object" />
<inherit name="switchable" />
<visible type="boolean">false</visible>
<usedefaultprefix type="boolean">false</usedefaultprefix>
<scenery />
<gender type="string"></gender>
<article type="string"></article>
</object>
</object>
<verb>
<property>ask</property>
<pattern>ask</pattern>
<defaultexpression>"You can't ask " + object.article + "."</defaultexpression>
</verb>
<command name="leapinterdoor">
<unresolved type="string"></unresolved>
<pattern>door#text#</pattern>
<script>
msg ("Is there an exit from this corridor?")
</script>
</command>
<function name="NewText" parameters="speak" type="string">
msg ("Not really knowing what the reaction of this gruff, shadowy person might be you speak in a cautioned voice, asking about the {object:leap door}")
</function>
</asl>
I am trying to call a function that kicks in a command for the chosen link that is clicked. Eventually I want to be able to use this as an alternative to having to type ask questions all the time. In other words I want when the player looks at an NPC it triggers a response with a hyperlink for the character that when clicked now shows in its menu an option for "speak to", If this is clicked then all of the questions presently available to that NPC pop up in a clickable menu or list that the player can simply choose from. Clicking any of these ? links will trigger the conversation for that topic.

jaynabonne
26 Dec 2013, 20:55I notice that you have {object:leap door}, but I can't see an object named "leap door". I did some tests, and I found two things:
1) If you reference an object that doesn't exist, then it actually prints out the entire {object:xxx} part. Since you're not seeing that, I'll assume the object exists.
2) More to the point, if the object exists but *does not have any verbs*, then it is not shown as a hyperlink, since (I suspect) there is nothing to do when you click on it. So if your object "leap door" has no verbs, you won't see a link.
What you might want to try is having a simple test case (perhaps in the look script) where you have seen hyperlinks and then put in the various objects and make sure they actually have links in that context. Once you know they do actually show up with hyperlinks in that known good spot, then try moving them to the new place. If that doesn't work, then please give code for both places, along with the full object definition.
Spindraft
26 Dec 2013, 21:18Sent you one as well HegemonKhan
Spindraft
27 Dec 2013, 00:36HegemonKhan
27 Dec 2013, 05:01Quest uses XML (or at least that's what you choose for the language when using, ie within, notepad++, for quest coding), but I've no idea if XML and C++ are compatible or not...
this site's "Developer Forum": viewforum.php?f=15
"For core library, C#, VB.NET, ASP.NET or JavaScript developers contributing to the Quest open source project"
notepad++ link: http://notepad-plus-plus.org/

Pertex
27 Dec 2013, 12:41Spindraft wrote:Is it possible to write code in C++ and paste it into the code here or no?
No, this is not possible. You can only use the build in aslx scripting language within the editor. The game engine is written in C# and VB, so you could modify the Quest engine and build some more aslx scripting components.

jaynabonne
27 Dec 2013, 13:14Spindraft
27 Dec 2013, 21:22I'm not sure why, but I didn't get the email. (I even looked in my Spam folder.) Could you try again?
As far as the command goes, if it's set up properly, you should be able to just type it in at the command prompt as well (e.g. "leapinterdoor"). Be sure to set your command pattern to "leapinterdoor" to match what you're looking for.
BTW, if you're more familiar with C++, you will probably appreciate writing Quest outside the editor GUI interface. It may be good for novices, but I would go insane trying to code that way. ASLX files are just XML, so you can use any text editor you like (I use Visual Studio Express 2012). You can do some fairly powerful things with the scripts, once you learn the language. I'd be happy to assist a fellow coder if you'd like to go that route.
Awesome, should have figured to call a command as you would a function, the tutorial does not give clear info on this but such is the nature of coding tutorials.