Page 1 of 1
Text messages for 1 player map?
Posted: Mon Jan 06, 2003 5:42 pm
by cjrs
Allllllrighty. I'm wondering something. My map has you trapped in a jail cell until an AI comes to rescue you. He opens the door, but i'd like to know how to get a text message to appear? Do I have to put down a trigger somewhere?
Posted: Mon Jan 06, 2003 6:14 pm
by Angex
Do you mean like when it says "An objective has been added.", in the top left corner.
To do this you could add a trigger with a target of setthread message (You might be able to add the target field to the door instead of using a trigger, you'd have to try it.), then add a thread to your mapname.scr file which looks like this:
--------------------------------------------
message:
iprint_noloc "You have been rescued !"
end
--------------------------------------------
Or you could add in this line somewhere appropriate in your exsisting script (assuming you've scripted it) :
iprint_noloc "You have been rescued !"
Posted: Tue Jan 07, 2003 6:35 pm
by cjrs
I mean, like if I were playing a 1 player map, subtitles. Of course the other way would work too
Posted: Tue Jan 07, 2003 6:56 pm
by jv_map
I think the only way you can use subtitles is my creating a sound alias

.
Wouldn't advise so unless you really have to.

Posted: Tue Jan 07, 2003 7:12 pm
by Angex
What about huddraw:
Script Commands - huddraw
Commands Summary
----------------
huddraw_shader <index> <shader name>
This sets the shader to use for a particular huddraw element.
huddraw_align <index> <horizontal> <vertical>
This sets the alignment of the huddraw element.
Valid values for horizontal alignment are "left", "center", and "right".
Valid values for vertical alignment are "top", "center", and "bottom".
huddraw_rect <index> <X position> <Y position> <width> <height>
This sets the position and size of the huddraw element. X and Y specify the position of
the upper left corner position. Higher values of X move it to the right, and higher
values of Y move it down. When you set the alignment, the XY position specified is
relative to that alignment. For example, if you align it to the right edge of the hud,
the X position should be less than zero so that it the upper left corner will be brough
back to the left onto the screen.
huddraw_virtualsize <index> <virtual>
This let's you set the huddraw element's size and position according to a virtual screen
resolution of 640x480. What this means is that it lets you treat the hud like it's always
at 640x480, and it will be properly resized and positioned according to the actual resolution.
huddraw_color <index> <red> <green> <blue>
This set the color of the huddraw element. Each color channel should be between 0 and 1.
huddraw_alpha <index> <alpha>
This set the alpha of the huddraw element. It should be set between 0 and 1. This is also
used to turn off a huddraw element that is no longer wanted by setting the alpha to 0.
huddraw_string <index> <string>
This sets the huddraw element to display a string instead of a shader graphic. The size
of the font can not be adjusted, but the color and alpha settings do affect the text.
The width and height parameters of huddraw_rect are only used for alignment centering,
Not for setting the size of the string.
huddraw_font <index> <fontname>
This sets the font for a string displaying huddraw element to use. The names of available
font can be gotten from the game/main/fonts folder. The file names of the .ritualfont files
in there are the names used for the fonts.
Posted: Tue Jan 07, 2003 7:14 pm
by jv_map
Hmm yah that actually got a change of working

.
Nice one Angex.
Posted: Wed Jan 08, 2003 5:56 am
by cjrs
jv_map wrote:I think the only way you can use subtitles is my creating a sound alias

.
Wouldn't advise so unless you really have to.

I don't think i'd go that far.
I'll use the first method.