mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Fixed broken Print() script function
Fixed the background image of the character portrait on inv/char screens. Renamed "print_text" to "interface_print".
This commit is contained in:
@@ -729,7 +729,7 @@ optional argument:
|
||||
> int sfall_func4("message_box", string message, int flags, int color1, int color2)
|
||||
- creates a dialog box with text and returns the result of pressing the button: 0 - No (Escape), 1 - Yes/Done (Enter)
|
||||
- returns -1 if for some reason the dialog box cannot be created
|
||||
- message: the text in the dialog box. Use the \n control character to move text to a new line (example: "Hello\nWorld!")
|
||||
- message: the text in the dialog box. Use the '\n' control character to move text to a new line (example: "Hello\nWorld!")
|
||||
optional arguments:
|
||||
- flags: mode flags (see MSGBOX_* constants in define_extra.h). Pass -1 to skip setting the flags (default flags are NORMAL and YESNO)
|
||||
- color1/color2: the color index in Fallout palette. color1 sets the text color for the first line, and color2 for all subsequent lines of text (default color is 145)
|
||||
@@ -744,9 +744,9 @@ optional arguments:
|
||||
> int sfall_func4("interface_art_draw", int winType, string artFile/int artID, int x, int y)
|
||||
> int sfall_func5("interface_art_draw", int winType, string artFile/int artID, int x, int y, int frame)
|
||||
> int sfall_func6("interface_art_draw", int winType, string artFile/int artID, int x, int y, int frame, array param)
|
||||
- draws the specified PCX or FRM image in the game interface window, returns -1 in case of any error
|
||||
- draws the specified PCX or FRM image in the game interface window, returns -1 on any error
|
||||
- winType: the type number of the interface window (see WINTYPE_* constants in sfall.h)
|
||||
this also takes the value of the flag (0x10000) to prevent immediate redrawing of the interface window
|
||||
this also takes the value of the flag (0x1000000) to prevent immediate redrawing of the interface window
|
||||
- artFile/artId: path to the PCX/FRM file (e.g. "art\\inven\\5mmap.frm"), or its FRM ID number (e.g. 0x7000026, see specification of the FID format)
|
||||
- x/y: offset relative to the top-left corner of the window
|
||||
optional arguments:
|
||||
@@ -755,17 +755,19 @@ optional arguments:
|
||||
index 0 - sprite direction for multi-directional FRM
|
||||
index 1/index 2 - the new width/height to scale the image to. Pass -1 to use the original width/height
|
||||
|
||||
> int sfall_func5("print_text", string text, int winType, int x, int y, int color)
|
||||
> int sfall_func6("print_text", string text, int winType, int x, int y, int color, int width)
|
||||
> int sfall_func5("interface_print", string text, int winType, int x, int y, int color)
|
||||
> int sfall_func6("interface_print", string text, int winType, int x, int y, int color, int width)
|
||||
- displays the text in the specified interface window with the current font. Use vanilla SetFont function to set the font
|
||||
- text: the text to be printed. Use the \n control character to move text to a new line (example: "Hello\nWorld!")
|
||||
- returns the count of lines printed, or -1 on any error
|
||||
- text: the text to be printed. Use the '\n' control character to move text to a new line (example: "Hello\nWorld!")
|
||||
- winType: the type number of the interface window (see WINTYPE_* constants in sfall.h)
|
||||
- x/y: offset relative to the top-left corner of the window
|
||||
- color: the color index in Fallout palette. Pass 0 if the text color was previously set by vanilla SetTextColor function
|
||||
it can also take additional flags (via bwor) for displaying text:
|
||||
0x0010000 - adds a shadow to the text, the 'textshadow' compiler constant
|
||||
0x1000000 - prevents immediate redrawing of the interface window, the 'textdirect' compiler constant (works the other way around)
|
||||
0x2000000 - fills the background of the text with black color, the 'textnofill' compiler constant (works the other way around)
|
||||
- width: the maximum width of the text. The text will be wrapped to fit within the specified width
|
||||
- width (optional): the maximum width of the text. The text will be wrapped to fit within the specified width
|
||||
|
||||
------------------------
|
||||
------ MORE INFO -------
|
||||
|
||||
Reference in New Issue
Block a user