Enhanced Gamebook

Deckrect
25 Mar 2016, 15:46
Hello everyone!

I have been around for about two years now dealing with Quest here and there but never finding a project really worthy of sharing.

Now I have been working on two different projects at the same time and both are planned as Gamebooks.

I know the general comunity prefers creating and dealing with text adventures instead of Gamebooks and I understand a lot of the programming advantages of doing so, however, in my understanding, adventures are for scenario exploration, allowing players trying many ways and manipulate objects. So, I prefer working with Gamebooks because I prefer running a story and giving players the option to steer things one side or another.

However, there is a Gamebook I am currently working on that some of the text adventure resources would be interesting. I feel I could do it on a game book, but I am having a hard time finding how, what is frustrating as I wish to be forging the story and not programming.

Basically, what I want doing in this Gamebook is having three simple variables which one with a numeric level and the display it to the player when required. Putting in a better way, I want the player be able on checking the character sheet.

I am also planning to place string variables to keep track of clothing, weapons and gears, but I guess displaying all this stuff will be easy. I guess! The hard problem is having a page dedicated to show this dinamic character sheet (as it changes during the game ) and then have a link to the same page the player was before, whatever page that was.

I tried a variable which I named as 'tracer' in order to have this mutating page link at the character sheet page, but as the game progresses, the alterations to the character sheet get messed and displayed with wrong values or in a scrambled format.

Does anyone has a better idea or advice to me? How may I insert a character sheet to a Gamebook or how could I use a text adventure in order to tell a story pretty much like a Gamebook?

Thanks in advance.

HegemonKhan
25 Mar 2016, 17:39
There is a 'hybrid gamebook' Library that you can use, which is a Text Adventure (having all of the features/abilities) which looks/feels like a Gamebook

------

with using a Gamebook, you do scripting via:

'whatever' Page -> Page Type: [script] or [script+text]

I can't remember if you can do the:

'game' Game Object -> 'Scripts' Tab -> 'Start' Script

or not in a Gamebook to initiially create/setup your Attributes at the start of the game.

if not, then just have your first page do so, aka:

'your first page' Page -> Page Type: [script] or [script+text]

-----

if you can handle/follow this directly or through using the GUI~Editor, then this will help explain the scripting needed:

viewtopic.php?f=18&t=5559 (Attributes and the If Script)

-----

By using Attributes, your changes to their values should be preserved...

so, you can just jump to your '[script] or [script+text]' character/game/stat sheet Page, when you need to.

the more challenging part is how to jump back to the previous page...

this is done by storing that previous page, which is done via an Attribute.

run as script -> add new script -> variables -> 'set a variable or attribute' Script -> [EXPRESSION] -> (see below)

(you can use either 'game' or 'player' for your Object, and you can name the Attribute whatever you want, I'm naming it as 'previous_page', in this example)

set variable game.previous_page = [EXPRESSION] player.parent

you need to do this while still in the (current) page that you want to be able to jump back to, as this sets the page that you are in/at, as the page that is stored in the 'game.previous_page' Object Attribute. In other words, you're going to need every game-playable pages' Page Type be: [script] or [script+text], so you can store that page into your 'game.previous_page' Object Attribute.

(maybe there's a better way to do this... not sure if you can do a 'player.changedpage' Script or not with Gamebooks)

anyways... now that you got your current page stored, you can jump to your character sheet page, and then using your Attribute, jump back to your current page:

your 'character/game/stat' sheet page:

Page Type: [script] or [script+text]

in code example of it (pretend that your game is an rpg):

ClearScreen
msg ("CHARACTER SCREEN")
msg ("")
msg ("Name: " + player.alias)
msg ("Age: " + player.age_integer + " (" + player.age_string + ")")
msg ("Sex: " + player.sex)
msg ("Race: " + player.race)
msg ("Class: " + player.class)
msg ("Strength: " + player.strength)
msg ("Endurance: " + player.endurance)
// etc stats... dexterity, agility, intelligence, etc etc etc
msg ("Level: " + player.level)
msg ("Experience: " + player.experience)
msg ("Cash: " + player.cash)
// etc etc etc stats
wait {
ClearScreen
// whatever the Script is to jump back to your previous/current page, which you'll use the 'game.previous_page' Object Attribute as your Value for it.
}

// pretend output:

CHARACTER SCREEN

Name: HK
Age: 18 (adult) // I wish I was still 18, lol
Sex: male
Race: human
Class: warrior
Strength: 100
Endurance: 100
Level: 99
Experierence: 99999999999
Cash: 9999999999999

Deckrect
25 Mar 2016, 18:27
I have was Reading this attribute and scrip guide this morning!

I confess i am reading over and over again your post in order to understand all the options and suggestions.

I don't know what to do for now. I look at the Status Panel at the right of an Adventure game and i really appreciate that. Would be great having this in my gamebook. At other hand, i never risked used library and i fear a little bit what bad would come from trying to make a text adventure look like a gamebook.

Actually, i am planning of having two or three different types of things in the character sheet. There will be the usual attributes, indicted by numbers; there will be a sort of Traits list expressed by strings and finally, there perhaps would be a secondary list os Feats which the player character may perform. I suppose the string things will be represented by a string variable OR by a simple flag. I am not sure yet. There will be also some string variables to set the weapons and clothings, but it will be very simple, i guess.

I have been thinking that each page, perhaps, would contain a variable named "tracer" to be set on each page as the page's name. When the player proceeds to the character's record sheet, this page will have a link to a page which name is equals to the "tracer" variable. My min problem with this is that it cannot be done on any page which alters stats, because checking the record sheet will be systematically modifying the character's attributes.

The Pixie
25 Mar 2016, 20:12

Deckrect
25 Mar 2016, 21:34
Thank you, Pixie. I am taking a look and checking what are the differences. Actually, beyond turning off the command bar and the inventory and stats, what else does it do? It seems that there are room, but with pages in their names. That would be very useful. But can't a regular text adventure do that?

I am too inexperienced to see what are the differences.

HegemonKhan
25 Mar 2016, 22:11
Attributes and the If Script take some time to learn (as you're at least getting into the concept of coding/if thinking mindset, which takes a long time to train/teach your brain in doing), not an easy jump from the quest basics/tutorial to actual implementation of things (Attribute and If Script usage) on your own (XanMag made his tutorial game to try to bridge the huge gap from the tutorial to making your own game; implementing stuff on your own). Just the terminology is very confusing... and the information is too much, you're overwhelmed. (You can see my own difficulties when I started quest ~ 4 yrs ago in my "help me noob thread" old thread; it's easy to find as it has nearly ~ 1000 posts in it, lol).

And even then, my guides are not polished and well-organized, nor am I sure if they're even understandable/followable for new people, so feel free to ask if you need any help or explanation of things in any of my guides/posts/threads.

-------

if you want to take a look at the thread I made, when I was just starting out with quest:

viewtopic.php?f=10&t=3348

I moved quickly onto learning quest's coding, as I wanted to learn to code, hehe

Deckrect
26 Mar 2016, 04:10
Interesting! And funny too!

I feel that IF scripts are not a problem for me. I deal very well with it. About the attributes, i don't know what to think yet. i suppose i am doing good with the basics, but i see there are some details i do not deal easy, like having the stat attributes shown on the game. I had a hard time researching for achieve this one.

As i have not a long experience on Quest, i found my main problem is very very fundamental. I don't know all i can do and what would be the possible repercussion in long term by using a Text Adventure mode or a Gamebook Mode. Perhaps the only different is that by a Gamebook i know a little more about how to steer things.

My personal impression is that a text adventure is far more focused on exploring environment and solving puzzles. It is perfect when you think about the classical dungeon set, finding passages, treasures, puzzles and monsters. However i feel the mode itself compels the maker to keep things vague and there is a lack of continuity. Sometimes i even feel its more like a guessing game, where the player needs to guess what tying in order to proceed with the game. But on Quest, text adventures count on the best programming resources.

On the other hand we have the Gamebook. Very limited in programming resources, but i feel it is better on actually telling a story. As this story progresses, the game maker (I feel the need of calling this person a Game Master because my background) may present possible and reasonable options that will steer the game in one or other direction. For my taste, it has a better flowing. Also, it is much more favorable to deal with dialogs and NPCs, as there is no change of getting back into a room and watching the NPC reacting vaguely.

I had opted for the Gamebook as my favored mode to tell stories on Quest. However, i had to review my options when i decided to place two simple and combined elements to the game: a system and a character sheet to express this system. Engineering the system itself is not a problem, not just because my 30 years as RPG Game Master, but also because now days i have a "tender system" - one i actually prefer and chosen as a best option, digged in order to use by myself on play by forum games, names "FATE RPG System". I created a light and versatile version of this for online interactions and i am both planning to use it o my Quest games as perhaps preparing a post here soon in future as a suggestion about how other fellow "game designers" (or Game Masters) may use this system on their Quest games.

I suppose i became too old. Too old to begin a training. (Master Yoda, 1981) but i am doing my best on understanding some concepts. i try to stick to the user interface and avoid much coding, but of course no one is imune on sitting and creating by hand a "player.wits" attribute inside a Gamebook or the like. I suppose almost know how solving my main problems, but the solutions i came up with are not elegant enough to make me happy. Yet.

HegemonKhan
26 Mar 2016, 16:57
Ah, I was jsut speaking from a programming perspective (programming is not an easy subject, so 'if' and etc Scripting can be difficult, along with Attribute usage, and etc programming aspects).

I'm not that much of a game designer (lots of ideas but no actual experience/practice at it beyond what little I've tried thus far with using quest for it), never played D&D (never designed games as the "game master"), and etc stuff. I have played a lot of games, but no real experience with designing my own.

Gamebook is mostly for what I believe to be 'CYOA', you have text to read and you can make choices as to what text to read next, "story branching".

Whereas Text Adventure is the full programming, so you can do anything with it (well with what quest allows: I'm pretty sure quest can't create a 3D world to traverse/play within, lol), so long as you got the programming ability to do so.

------

you're not that old if you mean you were born in 81... the 80s and 90s were the golden years of movies, tv shows, and games, sighs... not impressed much with (american) entertainment in the new century, the quality is non-existant compared to the 80s and 90s.

-----

ah, yes, designing good systems/code isn't easy... and if you're a perfectionist like me, you're never happy with the programming that you're capable of, as you know that there's better designs you could ahve done... but you don't have the ability/knowledge yet to do them... so frustrating, never satisfied.

Oh, it's awesome when your code just works, but then you look at it, and you're like... argh... that's messy and ugly... then you're not so happy, laughs.

----------------

P.S.

if you like D&D, there's a really awesome mod of civ4 that Kael and co made, based off his/their years of D&D playing/designing:

http://forums.civfanatics.com/showthread.php?t=171398 (keep scrolling down, there's a lot of info just on this first page, and links to more info)
and also
http://kael.civfanatics.net/

he now has his own job for a gaming company

The Pixie
26 Mar 2016, 20:59
Deckrect wrote:Thank you, Pixie. I am taking a look and checking what are the differences. Actually, beyond turning off the command bar and the inventory and stats, what else does it do? It seems that there are room, but with pages in their names. That would be very useful. But can't a regular text adventure do that?

I am too inexperienced to see what are the differences.

Conceptually game books tend to be time based, while text adventures are geography based. In the text adventure, each choice advances the evolving plot, whilst text adventures involve exploring different locations.

In practical terms, Quest game books are pretty limited in what they can do, whilst Quest text adventures you can potentially do anything. For that reason, if I was going to do game book, I would do a text adventure that emulated a game book.

Deckrect
26 Mar 2016, 21:19
Thank you again, HK! I was born in 1976, five years before Yoda say that to Luke. :)

I will check the mod for fun because when I think about D&D on computers, I think about Never winter Nights. Awesome!

And thank you, Pixie. The difference between text adventure and Gamebook was very well placed. I still exploring your demo game to evaluate the possibilities about using a text adventure looking like a Gamebook. There are certain organizational problems I am facing that may harm my work flow on this option. For example, to name the links I tend to write a lot and it seems the space I have on the room alias to place all I want. At the other hand, became very handy on having the inventory and even the command bar back, as it solves my character's record sheet problem and also gives the player an interface to use certain commands.

I intent on writing erotic fiction so I consider the best tool for doing that is by using the Gamebook, as it makes more elegant to control the flow of the characters relationship and the story's main events in detriment of exploring the scenario.

Both of you, guys, were very helpful on showing me options. I guess my main problem all this time was picking up a good working base so I could build up a story over it. Thank you two.

TheDetails
01 Jun 2016, 16:46
HegemonKhan wrote:

By using Attributes, your changes to their values should be preserved...

so, you can just jump to your '[script] or [script+text]' character/game/stat sheet Page, when you need to.

the more challenging part is how to jump back to the previous page...

this is done by storing that previous page, which is done via an Attribute.

run as script -> add new script -> variables -> 'set a variable or attribute' Script -> [EXPRESSION] -> (see below)

(you can use either 'game' or 'player' for your Object, and you can name the Attribute whatever you want, I'm naming it as 'previous_page', in this example)

set variable game.previous_page = [EXPRESSION] player.parent

you need to do this while still in the (current) page that you want to be able to jump back to, as this sets the page that you are in/at, as the page that is stored in the 'game.previous_page' Object Attribute. In other words, you're going to need every game-playable pages' Page Type be: [script] or [script+text], so you can store that page into your 'game.previous_page' Object Attribute.

(maybe there's a better way to do this... not sure if you can do a 'player.changedpage' Script or not with Gamebooks)

anyways... now that you got your current page stored, you can jump to your character sheet page, and then using your Attribute, jump back to your current page:

your 'character/game/stat' sheet page:

Page Type: [script] or [script+text]



Hey there! I implemented this into my gamebook and it worked first try (holy crap, first time in my life something worked first try).

But I have a little problem:

If I visit the inventory page (or character sheet or whatever we're calling it) from multiple pages, the variable will stack (not sure of the lingo) in linking back. In other words, if I visit the "inventory page" from page 2, then go back to page 2 using your code, then I visit it later from page 20, the inventory page will have a link back to both page 2 and page 20. How do I 'reset' or 'clear' the instances of which pages I've visited the inventory page from (hopefully without having to name the Attribute something different from every page)? Does that make sense?

Thanks a million!

HegemonKhan
01 Jun 2016, 18:14
that's strange... what Attribute Type are you using?

if you only want to be able to return to a single page (aka, the previous page), then you only need to use an Object Attribute, as you only need to store a single Value (page name). This shouldn't be giving you a list of page choices... as that's a List Attribute, lol.

in reading your post, it seems however you've done the page linking (or how it is already built-in), is using a List Attribute, thus giving you the choices in that List Attribute, of which you have multiple choices, when you only want one choice (aka: no choice - you just go back to the previous page), right?

Working with a List Attribute, will be much more complex... as you'd have to iterate through the List Attribute, checking/comparing if any of the choices, match up with the Value in your Attribute that is (or is storing) your previous page's name, and if it's a match, then yo goto that page.

it'd be easier to not use the List Attribute, but I'm not quite sure how this would be need to be setup to work with the Game Book's built-in page linking (which is likely the source/reason that a List Attribute is being used, giving you the multiple choices).

---------

if you created your own setup/system (not just using the built-in setup/system), then I may need to see what you've done, to figure out why it's doing what it's doing and how to fix it up to what you want it to be doing.

TheDetails
01 Jun 2016, 18:27
Surely I'm doing it wrong :), perhaps this will help:

I simply have this script on pages that I want the player to have the ability to look at their inventory (using both 'player' and 'game' nets the same result):

player.exit_inventory = player.parent

And below that, a simple link to the inventory page.

____________________________________________________


On the inventory page I have this script:

AddPageLink (Inventory, player.exit_inventory, "Back")

And that's it.

____________________________________________________


It works: when I go to the inventory page, it's got a back link to the previous page I was on. Easy peasy! But if I've visited the inventory page from more than one page, the Back links start piling up. It will have multiple instances of the Back link, each one pointing to every page I've visited it from.

Is there an easy fix?

HegemonKhan
01 Jun 2016, 19:44
alright, thanks for that information, as it shows me how the built-in page linking works.

it indeed uses a List Attribute, which is what you're using, adding (more and more) choices to that List Attribute (which you have set to be labeled as 'Back', and thus you see multiple 'Back' choices to select from):

AddPageLink (Inventory, player.exit_inventory, "Back")

---------------

you store the current page you're in (via: player.parent, let's say it's Page1) to the 'player.exit_inventory' Object Attribute: player.exit_inventory = player.parent

and then you add that page (Page1) to your List Attribute: AddPageLink (Inventory, player.exit_inventory, "Back"), labeling the link choice (to Page1) as 'Back'.

now you goto another Page, and the same thing repeats:

you store the current page you're in (via: player.parent, let's say it's now Page2) to the 'player.exit_inventory' Object Attribute: player.exit_inventory = player.parent

and then you add that page (Page2) to your List Attribute: AddPageLink (Inventory, player.exit_inventory, "Back"), labeling the link choice (to Page12) as 'Back'.

and now you got as choices:

Back (takes you to Page1)
Back (takes you to Page2)

and repeating for more new pages:

Back (takes you to Page1)
Back (takes you to Page2)
Back (takes you to Page3)
Back (takes you to Page4)
etc etc etc

-------------------

thus, because you're working with a List Attribute... you're going to have to have a code line to remove all those other (old) page choices from your List Attribute:

(there should be some kind of) ~ 'RemovePageLink' Script/Function

you'll have to iterate (cycle) through the list and remove each item (page name), and then add in your new item (page name):

foreach (page_variable, Inventory) {
RemovePageLink (Inventory, page_variable)
}
AddPageLink (Inventory, player.exit_inventory, "Back")


HK edit:

actually, you shouldn't be using foreach, as you should just have a single choice in the List (your old choice, which you want to remove, so when you add in the new choice, it is the only choice in the List), but this will require a bit of work with when/how you update your 'old_page' Attribute. Using the 'foreach' method is easier to do, but in terms of coding efficiency, it shouldn't be needed/used, and so it'd be a wasteful/un-needed action (not efficient).

--------

or, even better, (if you can do so in the Game Book version), over-write the built-in List Attribute (thus erasing all of your old page-name choices), by creating a new List Attribute for it:

(for text adventure version: http://docs.textadventures.co.uk/quest/ ... glist.html , http://docs.textadventures.co.uk/quest/ ... lists.html )

Inventory = NewPageLink ()
AddPageLink (Inventory, player.exit_inventory, "Back")

or, maybe if there's no 'NewPageLink()' Function/Script, and there is the 'split' Function/Script, you can try using that too (as it creates/returns a List):

http://docs.textadventures.co.uk/quest/ ... split.html

Inventory = split ("temp", ";") // not sure if there's a default split (so you're not giving it, adding in, any items/choices): split (), as if you were to do this: split ("", ";"), you'd still get a 'whitespace/blank' choice, lol
AddPageLink (Inventory, player.exit_inventory, "Back")
RemovePageLink (Inventory, temp)

TheDetails
01 Jun 2016, 21:03
All I see with respect to lists in the game book is add print and remove.



Resulting in:



Or in code view:

list add (, )

and so forth. Not doable that way, no?

TheDetails
01 Jun 2016, 21:09
I don't want you to spend too much time on this though, holding newbie's little hand.

If I can't figure it out, I can always make an inventory page with an ever growing:

If HasSeenPage (remove link/add link)
...If HasSeenPage (remove link/add link)
......If HasSeenPage (remove link/add link)
.........If HasSeenPage (remove link/add link)
............If HasSeenPage (remove link/add link)

For every instance of the inventory link I make, and it'll do essentially the same thing. So no worries if you've (assuredly) got better things to do.

:)

HegemonKhan
01 Jun 2016, 21:14
if this is the case (sometimes functionality still exists even if it's not put into the GUI~Editor's options... such as with Object Lists in the Text Adventure version), then you're probably going to have to use the 'remove a value from a list' option (this would be somewhat similiarly labeled in code, to/as my 'RemovePageLink' in my post)... let me actually get on Game Book and see how this is to be done... give me hopefully 10 minutes at most... lol

TheDetails
01 Jun 2016, 21:17
HegemonKhan wrote:give me hopefully 10 minutes at most... lol



See ya next year! :wink:

HegemonKhan
01 Jun 2016, 21:20
and here's also this too, that I wrote in another post, as he/she was asking the same question:

(this is how it'd be done without using a List Attribute, you could do it this way instead, if you don't mind bypassing/ignoring the built-in page link movement using the List Attribute and the page-link hyperlink buttons, you'll have to use this script, shown in code: player.parent = player.previous_page, or in the GUI~Editor: add new script -> 'set a variable or attribute' Script choice -> set variable player.parent = [EXPRESSION] player.previous_page, to move back from your inventory page to your in to the previous page / the page you came from to the inventory page)

(the basic idea is that you've got to store the previous page's name in an Attribute, which you can then use to, goto/go-back-to, that page)

(before you go to a new page, you need to store the current page that you're in/on as this will become 'the previous page' when you goto a different page)

previous page: Page1
current page: Page1
goto Page2
previous page: Page1
current page: page2
goto Page3
previous page: Page2
current page: Page3

pseudo-code wise:

// you're in/on Page1:

player.previous_page = player.parent // storing the page you're in/on (Page1) into a 'previous page' Attribute
player.current_page = player.parent // storing the page you're in/on (Page2) into a 'current page' Attribute

// you goto Page2:

player.previous_page = player.current_page // storing the 'current page' Attribute's Value (Page1) into the 'previous page' Attribute

// and *THEN* (AFTER storing the the old page, Page1, into the 'previous page' Attribute) we now can update the 'current page' Attribute (from the old page, Page1) to the new current page (Page2) we're now currently in/on:

player.current_page = player.parent // storing the page you're in/on into a 'current page' Attribute (changing the stored 'current page' Attribute's Value from Page1 to Page2)

// you goto Page3:

player.previous_page = player.current_page // storing the 'current page' Attribute's Value (Page2) into the 'previous page' Attribute

// and *THEN* (AFTER storing the the old page, Page2, into the 'previous page' Attribute) we now can update the 'current page' Attribute (from Page2) to the new current page (Page3) we're now currently in/on:

player.current_page = player.parent // storing the page you're in/on into a 'current page' Attribute (changing the stored 'current page' Attribute's Value from Page2 to Page3)

HegemonKhan
01 Jun 2016, 22:51
sorry... took a bit more than 10 minutes... lol...

----------

okay... this is a bit complex... not sure if I can explain/guide well enough for you to follow along... I'll try but you may have to wait for someone who can explain and guide you through it better than I...

the built-in page linking, actually uses String Dictionary Attributes:

http://docs.textadventures.co.uk/quest/ ... aries.html
http://docs.textadventures.co.uk/quest/ ... onary.html
http://docs.textadventures.co.uk/quest/ ... y_add.html
http://docs.textadventures.co.uk/quest/ ... emove.html

new game code (sample part) of the built-in String Dictionary Attribute that the page linking uses:

<object name="Page1">
<options name="stringdictionary">
<item>
<key>Page2</key>
<value>This link goes to page 2</value>
</item>
<item>
<key>Page3</key>
<value>This link goes to page 3</value>
</item>
</options>
</object>


the good news is that it seems to have the same functionality as the Text Adventure... as I think I tested it correctly, getting it to work, but the bad news is that dictionaries are a bit more confusing than lists, and also this entire endeavor requires a bit of setup... hopefully you can follow along... HK crosses his fingers... as he's not good at explaining/guiding... lol

(I used red font to indicate it's what you type in into the text boxes)

'game' Game Object -> 'Script' Tab -> 'script when entering page' Script -> (see below)

add new script -> variables -> 'set a variable or attribute' Script -> [expression] -> (see below)

set variable player.previous_page = [expression] player.current_page

add new script -> variables -> 'set a variable or attribute' Script -> [expression] -> (see below)

set variable player.current_page = [expression] player.parent

add new script -> scripts -> 'if' Script -> [expression] -> (see below)

if [expression] player.current_page = Inventory

then,

-> add new script -> variables -> 'set a variable or attribute' Script -> [expression] -> (see below)

set variable player.parent.options = [expression] NewStringDictionary()

-> add new script -> 'add to dictionary' Script -> (see below)

Add to dictionary player.parent.options Key [expression] player.previous_page.name [EditorScriptsVariablesvalue] [expression] player.previous_page

and lastly, you also of course got to setup the 'current_page' and 'previous_page' Attributes on your 'player' Player Object, unless you can go into the code directly and know how to work with it, this means that you're going to need to use your first page, to set these Attributes on your 'player' Player Object. Hopefully, you won't get an error at the start of your game... if you do... let me know... as this would mean the 'on enter page' Script in the Game Object is running before your first page's scripts are setting the 'current_page' and 'previous_page' Attributes (which the 'on enter page' needs to be already created/setup, hence the error, if there is one).

--------

hopefully this will work for you..... leaving intact all of your normal page's links... only changing the Inventory Page links (so it is just a single link back to the page that you came from), which is hopefully what you wanted...