Editing "wait for key press" display text

tlk
I've been doing some digging and experimenting and have learned enough about templates to change the text shown when you run a wait from "Continue..." to whatever I want, but for the life of me I can't figure out how to change the color of it from the default blue. Since it doesn't change with the default link color there must be somewhere separate that tells Quest what color to make it, but I can't seem to suss it out. It's obviously not a huge deal or a problem for functionality, but it would be nice to utilize a wait and have the text fit in with the game's color scheme (and to ideally be able to change the font as well, though color would be the bigger priority).

I know the whole <color color="colorname"></color> thing and how to use CDATA tags and all, but putting that into the template text just kills the "Continue..." text entirely. Am I missing something really obvious? I still find things like the Core and language libraries pretty daunting to look at.

george
I suggest you look at http://quest5.net/wiki/Modifying_the_UI_(Advanced) . Find out what kind of html element the "wait for.." is, and then style that in the CSS.


The Quest UI is HTML, just like any web page, and this means you can change the style of each component. If you are playing a Quest game, try right-clicking on it; you will see an option "view source". Select it and you will see the HTML code used to create what you can see.


Sora574
There is no <color> tag in HTML.
Use <font color=" [color] "></font> instead.
It should work in the template.

jaynabonne
Just a note: the HTML Developer Tools are much more useful than "View Source". You can find them under the View menu when a game is running, or you can just hit F9. Not only can you browse the HTML elements, but you can see the styles attached to them and even modify the styles on the fly. Very handy!

george
cool, that's helpful. I don't have F9 as a shortcut though, do you know why not?

edit: nevermind, I just had 5.4 instead of 5.4.1 .

tlk
Okay, so I've been trying stuff.

Sora574 wrote:There is no <color> tag in HTML.
Use <font color=" [color] "></font> instead.
It should work in the template.


This doesn't seem to work for the template either, and I tried it in a basic message too and just got all kinds of errors. <color color="colorname"></color> works fine for me for messages, though, and is what I normally use for bits of different colored text. Could this be because I'm still using 5.3?

Using the HTML Developer Tools, however, I can find exactly what I'm looking for and change it easily and it works and looks perfect until I stop the game, and then restarting it resets the changes. I'm guessing the idea is that all the information needed can be gathered from doing that to then write an HTML file to insert into the game like in the "Modifying the UI" page, but I don't understand HTML well enough to do that...at least not yet. Maybe there's some way of committing changes made with the Developer Tools to the game that I'm missing? I'm thinking at this point that what I'm trying to do might still be a bit above my skill level.

jaynabonne
No, the tools are just temporary. You'd have to code it yourself. 5.3 seems so long ago... :)

george
tlk wrote:I'm guessing the idea is that all the information needed can be gathered from doing that to then write an HTML file to insert into the game like in the "Modifying the UI" page, but I don't understand HTML well enough to do that...at least not yet.


The 'Modifying the UI' page is more straightforward than it looks at first glance I think.

If there aren't other game breaking things holding you back from 5.4 maybe you should just upgrade?

I attempted to write a little how to here for 5.4 (which does away with inserting HTML like the Modifying the UI tutorial), hopefully the more experienced Questers can correct any mistakes :). I cribbed most of it from this thread, viewtopic.php?f=10&t=3638&hilit=insert+html .

1. add a new object in the Quest GUI called "CSS'
2. go to the 'Attributes' tab of the CSS object and add an attribute called 'custom'
3. look up at the toolbar and hit the 'Code View' button (to the right of the 'Play' button). Or, just hit 'F9'.
4. find the 'CSS' object (if the file is big just hit control-F to search), and make it look like this:


<object name="CSS">
<inherit name="editor_object" />
<custom type="string">
<![CDATA[
<style type = "text/css">
a.cmdlink {color: red;}
</style>
]]>
</custom>
</object>


5. make a game start Print Message script that looks like this:

{CSS.custom}


(note the { } 's)

And you're good to go. Some notes:

1. make sure the {CSS.custom} runs before any wait scripts of course :). Best to put it first in the game start scripts.
2. read this caveat about clearing the screen, viewtopic.php?f=10&t=3638&hilit=insert+html#p24194 .
3. Sometimes you'll see people referring to things like msg (object.attribute). That's the same as doing a Print Message script of {object.attribute}

tlk
Gah! Success! With your last bit of advice, george, I got it to work with inserting HTML for the time being until I upgrade. I've been meaning to get to that, I'm just a procrastinator. It sounds like there are a lot of things made a lot easier though, so I'll have to make it a priority.

Thanks all! I can't stand putting my mind to figuring something out and not being able to do it, so you've saved me a lot of trial and error and teeth grinding today.

guzmere
Hi procrastinators rule the world eventually lol :D Happy Adventuring :D

This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums