diff --git a/assets/js/search-data.json b/assets/js/search-data.json
index 345a04b7..30f69dba 100644
--- a/assets/js/search-data.json
+++ b/assets/js/search-data.json
@@ -113,7 +113,7 @@
},"16": {
"doc": "Audio",
"title": "Functions",
- "content": ". | eax_available | play_sfall_sound | set_eax_environment | stop_sfall_sound | . eax_available . int eax_available() . Obsolete since sfall 2.1a. Always returns 0. play_sfall_sound . int play_sfall_sound(string file, int mode) . Used to play mp3/wav/wma files. The path given is relative to the Fallout folder. Specify mode as 1 to loop the file continuously, 2 to replace the current background game music with playing the specified file in loop mode, or 0 to play the file once. If you don’t wish to loop, play_sfall_sound returns 0. If you do loop, it returns an id which can be passed back to stop_sfall_sound when you want to stop the effect. All sounds effects will be stopped on game reload, looping or not. Does not require AllowDShowSound to be set to 1 in ddraw.ini. Starting from sfall 4.2.8/3.8.28, you can pass a value in the mode argument for a reduced sound volume. To set the volume, You need to convert the number to hexadecimal and use the argument format 0xZZZZ000Y, where ZZZZ is the volume reduction value in range from 0 to 32767 (the value 32767 is mute), and Y is the playback mode. set_eax_environment . void set_eax_environment(int environment) . Obsolete since sfall 2.1a. Has no effect. stop_sfall_sound . void stop_sfall_sound(int soundID) . Stops looping mp3/wav/wma files previously launched by play_sfall_sound. All sounds effects will be stopped on game reload, looping or not. Does not require AllowDShowSound to be set to 1 in ddraw.ini. ",
+ "content": ". | eax_available | play_sfall_sound | set_eax_environment | stop_sfall_sound | . eax_available . int eax_available() . Obsolete since sfall 2.1a. Always returns 0. play_sfall_sound . int play_sfall_sound(string file, int mode) . Used to play mp3/wav/wma files. The path given is relative to the Fallout folder. Specify mode as 1 to loop the file continuously, 2 to replace the current background game music with playing the specified file in loop mode, or 0 to play the file once. If you don’t wish to loop, play_sfall_sound returns 0. If you do loop, it returns an ID which can be passed back to stop_sfall_sound when you want to stop the effect. All sounds effects will be stopped on game reload, looping or not. Does not require AllowDShowSound to be set to 1 in ddraw.ini. Starting from sfall 4.2.8/3.8.28, you can pass a value in the mode argument for a reduced sound volume. To set the volume, You need to convert the number to hexadecimal and use the argument format 0xZZZZ000Y, where ZZZZ is the volume reduction value in range from 0 to 32767 (the value 32767 is mute), and Y is the playback mode. set_eax_environment . void set_eax_environment(int environment) . Obsolete since sfall 2.1a. Has no effect. stop_sfall_sound . void stop_sfall_sound(int soundID) . Stops looping mp3/wav/wma files previously launched by play_sfall_sound. All sounds effects will be stopped on game reload, looping or not. Does not require AllowDShowSound to be set to 1 in ddraw.ini. ",
"url": "/sfall/audio/#functions",
"relUrl": "/audio/#functions"
@@ -925,7 +925,7 @@
},"132": {
"doc": "Perks and traits",
"title": "Functions",
- "content": ". | add_trait | apply_heaveho_fix | clear_selectable_perks | get_perk_available | get_perk_owed | has_fake_perk | has_fake_trait | hide_real_perks | perk_add_mode | remove_trait | seq_perk_freq | set_fake_perk | set_fake_trait | set_perk_agl | set_perk_chr | set_perk_desc | set_perk_end | set_perk_freq | set_perk_image | set_perk_int | set_perk_lck | set_perk_level | set_perk_level_mod | set_perk_name | set_perk_owed | set_perk_per | set_perk_ranks | set_perk_skill1 | set_perk_skill1_mag | set_perk_skill2 | set_perk_skill2_mag | set_perk_stat | set_perk_stat_mag | set_perk_str | set_perk_type | set_perkbox_title | set_pyromaniac_mod | set_selectable_perk | set_swiftlearner_mod | show_real_perks | . add_trait . sfall.h . void add_trait(int traitID) . adds the specified trait to the player . apply_heaveho_fix . void apply_heaveho_fix . clear_selectable_perks . void clear_selectable_perks() . Restores the “select a perk” box to its default state. get_perk_available . int get_perk_available(int perk) . get_perk_owed . int get_perk_owed . has_fake_perk . int has_fake_perk(string name) . Returns the number of levels the player has of the perks with the given name or ID of extra perk. has_fake_trait . int has_fake_trait(string name) . Returns the number of levels the player has of the traits with the given name or ID of extra trait. hide_real_perks . void hide_real_perks() . Prevent the “select a perk” box from displaying any of the original 119 perks. perk_add_mode . void perk_add_mode(int type) . Modifies what happens when a fake perk is selected from the perks dialog. It is treated as a set of flags - if bit 1 is set then it is added to the player’s traits, if bit 2 is set it is added to the player’s perks, and if bit 3 is set it is removed from the list of selectable perks. The default is 0x2. remove_trait . void remove_trait(int traitID) . seq_perk_freq . void seq_perk_freq(int value) . Sets the number of levels between each perk. set_fake_perk . void set_fake_perk(string name, int level, int image, string desc) . Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric id that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower. set_fake_trait . void set_fake_trait(string name, int active, int image, string desc) . Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric id that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower. set_perk_agl . void set_perk_agl(int perkID, int value) . set_perk_chr . void set_perk_chr(int perkID, int value) . set_perk_desc . void set_perk_desc(int perkID, string value) . set_perk_end . void set_perk_end(int perkID, int value) . set_perk_freq . void set_perk_freq(int value) . Sets the number of levels between each perk. Setting to 0 will reset it back to the default. This overrides the effects of the skilled trait. Not saved into the save game, so needs to be called once per reload. Be careful not to let the player obtain a perk when no perks are available to pick, or the game may crash. set_perk_image . void set_perk_image(int perkID, int value) . set_perk_int . void set_perk_int(int perkID, int value) . set_perk_lck . void set_perk_lck(int perkID, int value) . set_perk_level . void set_perk_level(int perkID, int value) . set_perk_level_mod . void set_perk_level_mod(int levels) . Sets a modifier between +25 and -25 that is added/subtracted from the player’s level for the purposes of deciding which perks can be chosen. set_perk_name . void set_perk_name(int perkID, string value) . set_perk_owed . void set_perk_owed(int value) . set_perk_per . void set_perk_per(int perkID, int value) . set_perk_ranks . void set_perk_ranks(int perkID, int value) . set_perk_skill1 . void set_perk_skill1(int perkID, int value) . set_perk_skill1_mag . void set_perk_skill1_mag(int perkID, int value) . set_perk_skill2 . void set_perk_skill2(int perkID, int value) . set_perk_skill2_mag . void set_perk_skill2_mag(int perkID, int value) . set_perk_stat . void set_perk_stat(int perkID, int value) . set_perk_stat_mag . void set_perk_stat_mag(int perkID, int value) . set_perk_str . void set_perk_str(int perkID, int value) . set_perk_type . void set_perk_type(int perkID, int value) . set_perkbox_title . void set_perkbox_title(string title) . Used to change the title of the “select a perk” box, or by using “” it will be set back to the default. set_pyromaniac_mod . void set_pyromaniac_mod(int bonus) . set_selectable_perk . void set_selectable_perk(string name, int active, int image, string desc) . Used to add additional items to “select a perk” box by setting the ‘active’ parameter to 1, and to remove them again by setting it to 0. set_swiftlearner_mod . void set_swiftlearner_mod(int bonus) . show_real_perks . void show_real_perks() . Reverts the effect os hide_real_perks. ",
+ "content": ". | add_trait | apply_heaveho_fix | clear_selectable_perks | get_perk_available | get_perk_owed | has_fake_perk | has_fake_trait | hide_real_perks | perk_add_mode | remove_trait | seq_perk_freq | set_fake_perk | set_fake_trait | set_perk_agl | set_perk_chr | set_perk_desc | set_perk_end | set_perk_freq | set_perk_image | set_perk_int | set_perk_lck | set_perk_level | set_perk_level_mod | set_perk_name | set_perk_owed | set_perk_per | set_perk_ranks | set_perk_skill1 | set_perk_skill1_mag | set_perk_skill2 | set_perk_skill2_mag | set_perk_stat | set_perk_stat_mag | set_perk_str | set_perk_type | set_perkbox_title | set_pyromaniac_mod | set_selectable_perk | set_swiftlearner_mod | show_real_perks | . add_trait . sfall.h . void add_trait(int traitID) . adds the specified trait to the player . apply_heaveho_fix . void apply_heaveho_fix . clear_selectable_perks . void clear_selectable_perks() . Restores the “select a perk” box to its default state. get_perk_available . int get_perk_available(int perk) . get_perk_owed . int get_perk_owed . has_fake_perk . int has_fake_perk(string name) . Returns the number of levels the player has of the perks with the given name or ID of extra perk. has_fake_trait . int has_fake_trait(string name) . Returns the number of levels the player has of the traits with the given name or ID of extra trait. hide_real_perks . void hide_real_perks() . Prevent the “select a perk” box from displaying any of the original 119 perks. perk_add_mode . void perk_add_mode(int type) . Modifies what happens when a fake perk is selected from the perks dialog. It is treated as a set of flags - if bit 1 is set then it is added to the player’s traits, if bit 2 is set it is added to the player’s perks, and if bit 3 is set it is removed from the list of selectable perks. The default is 0x2. remove_trait . void remove_trait(int traitID) . seq_perk_freq . void seq_perk_freq(int value) . Sets the number of levels between each perk. set_fake_perk . void set_fake_perk(string name, int level, int image, string desc) . Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric ID that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower. set_fake_trait . void set_fake_trait(string name, int active, int image, string desc) . Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric ID that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower. set_perk_agl . void set_perk_agl(int perkID, int value) . set_perk_chr . void set_perk_chr(int perkID, int value) . set_perk_desc . void set_perk_desc(int perkID, string value) . set_perk_end . void set_perk_end(int perkID, int value) . set_perk_freq . void set_perk_freq(int value) . Sets the number of levels between each perk. Setting to 0 will reset it back to the default. This overrides the effects of the skilled trait. Not saved into the save game, so needs to be called once per reload. Be careful not to let the player obtain a perk when no perks are available to pick, or the game may crash. set_perk_image . void set_perk_image(int perkID, int value) . set_perk_int . void set_perk_int(int perkID, int value) . set_perk_lck . void set_perk_lck(int perkID, int value) . set_perk_level . void set_perk_level(int perkID, int value) . set_perk_level_mod . void set_perk_level_mod(int levels) . Sets a modifier between +25 and -25 that is added/subtracted from the player’s level for the purposes of deciding which perks can be chosen. set_perk_name . void set_perk_name(int perkID, string value) . set_perk_owed . void set_perk_owed(int value) . set_perk_per . void set_perk_per(int perkID, int value) . set_perk_ranks . void set_perk_ranks(int perkID, int value) . set_perk_skill1 . void set_perk_skill1(int perkID, int value) . set_perk_skill1_mag . void set_perk_skill1_mag(int perkID, int value) . set_perk_skill2 . void set_perk_skill2(int perkID, int value) . set_perk_skill2_mag . void set_perk_skill2_mag(int perkID, int value) . set_perk_stat . void set_perk_stat(int perkID, int value) . set_perk_stat_mag . void set_perk_stat_mag(int perkID, int value) . set_perk_str . void set_perk_str(int perkID, int value) . set_perk_type . void set_perk_type(int perkID, int value) . set_perkbox_title . void set_perkbox_title(string title) . Used to change the title of the “select a perk” box, or by using “” it will be set back to the default. set_pyromaniac_mod . void set_pyromaniac_mod(int bonus) . set_selectable_perk . void set_selectable_perk(string name, int active, int image, string desc) . Used to add additional items to “select a perk” box by setting the ‘active’ parameter to 1, and to remove them again by setting it to 0. set_swiftlearner_mod . void set_swiftlearner_mod(int bonus) . show_real_perks . void show_real_perks() . Reverts the effect os hide_real_perks. ",
"url": "/sfall/perks-and-traits/#functions",
"relUrl": "/perks-and-traits/#functions"
@@ -1191,7 +1191,7 @@
},"170": {
"doc": "Windows and images",
"title": "Functions",
- "content": ". | art_frame_data | create_win | draw_image | draw_image_scaled | get_window_attribute | get_window_under_mouse | interface_art_draw | interface_overlay | interface_print | message_box | set_window_flag | win_fill_color | . art_frame_data . sfall.h . array art_frame_data(string/int artFile/artId, int frame, int rotation) . | returns the dimensions of a given PCX or FRM frame as a temp array in the form [width, height] | 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) optional arguments: | frame: frame number, the first frame starts from zero | rotation: rotation to get the frame for, useful when reading FRM files by path | . create_win . sfall.h . void create_win(string winName, int x, int y, int width, int height, int flags) . flags argument is optional. Works just like vanilla CreateWin function, but creates a window with MoveOnTop flag if the flags argument is not specified, and allows to set additional flags for the created window. MoveOnTop flag allows the created window to be placed on top of the game interface. draw_image . sfall.h . void draw_image(string/int artFile/artId, int frame, int x, int y, bool noTransparent) . | displays the specified PCX or FRM image in the active window created by vanilla CreateWin or sfall’s create_win script function | 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) optional arguments: | frame: frame number, the first frame starts from zero | x/y: offset relative to the top-left corner of the window | noTransparent: pass True to display an image without transparent background | NOTE: to omit optional arguments starting from the right, call the functions with different sfall_funcX (e.g. sfall_func4(\"draw_image\", pathFile, frame, x, y)) | . draw_image_scaled . sfall.h . void draw_image_scaled(string/int artFile/artId, int frame, int x, int y, int width, int height) . | displays the specified PCX or FRM image in the active window created by vanilla CreateWin or sfall’s create_win script function | 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) optional arguments: | frame: frame number, the first frame starts from zero | x/y: offset relative to the top-left corner of the window | width/height: the new width/height to scale the image to. Pass -1 to either width or height to keep the aspect ratio when scaling | NOTE: to omit optional arguments starting from the right, call the functions with different sfall_funcX (e.g. sfall_func4(\"draw_image\", pathFile, frame, x, y)) | if called without x/y/width/height arguments, the image will be scaled to fit the window without transparent background | . get_window_attribute . int sfall_func1(\"get_window_attribute\", int winType) . Alternative form: int sfall_func2(\"get_window_attribute\", int winType, int attrType) Returns the attribute of the specified interface window by the attrType argument. | winType: the type number of the interface window (see WINTYPE_* constants in sfall.h) | attrType: 0 - checks and returns a value of 1 if the specified interface window is created by the game (same as without the argument) 1 - X position, 2 - Y position (relative to the top-left corner of the game screen) 3 - interface width size, 4 - interface height size 5 - window ID (to compare with get_window_under_mouse) -1 - returns an associative array of keys (left, top, right, bottom) and values that define the position of the window rectangle (use standard syntax to access array values, e.g. winRect.top, winRect.bottom) | returns -1 if the specified attribute cannot be obtained | . get_window_under_mouse . int get_window_under_mouse() . Returns internal ID of a top-most window under mouse cursor. interface_art_draw . int sfall_func4(\"interface_art_draw\", int winType, string artFile/int artID, int x, int y) . 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 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 (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: . | frame: frame number, the first frame starts from zero | param: an array which specifies additional parameters, where: 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 | . interface_overlay . sfall_func2(\"interface_overlay\", int winType, int mode) . Alternative form: int sfall_func6(\"interface_overlay\", int winType, 2, int x, int y, int width, int height). Creates an additional drawing surface above the graphic layer of the specified interface window. All subsequent calls of interface_art_draw and interface_print functions will draw on it. | winType: the type number of the interface window (see WINTYPE_* constants in sfall.h) | mode: 1 - creates a new overlay surface 2 - clears the overlay area or the specified rectangle defined by the x, y, width, height arguments 0 - destroys the created overlay surface (frees up the memory allocated to the surface) | . interface_print . int sfall_func5(\"interface_print\", string text, int winType, int x, int y, int color) . 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 | 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 the game 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 (optional): the maximum width of the text. The text will be wrapped to fit within the specified width | . message_box . 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!\") 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 the game palette. `color1` sets the text color for the first line, and `color2` for all subsequent lines of text (default color is 145) . set_window_flag . sfall.h . void set_window_flag(string winName/int winID, int flag, bool value) . Changes the specified flag for the created script or game interface window. | winName: the window name, assigned to the window by the CreateWin/create_win function | winID: the ID number of the interface or script window obtained with the get_window_under_mouse function, or 0 for the current game interface | flag: the flag to change (see WIN_FLAG_* constants in define_extra.h) | value: True - set the flag, False - unset the flag | . win_fill_color . int win_fill_color(int x, int y, int width, int height, int color) . Fills the rectangle area of the currently selected script window with the specified color, or clears the window with transparent (index 0) color (call the function without arguments). | color: the color index in the game palette (from 0 to 255) | . ",
+ "content": ". | art_frame_data | create_win | draw_image | draw_image_scaled | get_window_attribute | get_window_under_mouse | interface_art_draw | interface_overlay | interface_print | message_box | set_window_flag | win_fill_color | . art_frame_data . sfall.h . array art_frame_data(string/int artFile/artId, int frame, int rotation) . | returns the dimensions of a given PCX or FRM frame as a temp array in the form [width, height] | 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) optional arguments: | frame: frame number, the first frame starts from zero | rotation: rotation to get the frame for, useful when reading FRM files by path | . create_win . sfall.h . void create_win(string winName, int x, int y, int width, int height, int flags) . flags argument is optional. Works just like vanilla CreateWin function, but creates a window with MoveOnTop flag if the flags argument is not specified, and allows to set additional flags for the created window. MoveOnTop flag allows the created window to be placed on top of the game interface. draw_image . sfall.h . void draw_image(string/int artFile/artId, int frame, int x, int y, bool noTransparent) . | displays the specified PCX or FRM image in the active window created by vanilla CreateWin or sfall’s create_win script function | 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) optional arguments: | frame: frame number, the first frame starts from zero | x/y: offset relative to the top-left corner of the window | noTransparent: pass True to display an image without transparent background | NOTE: to omit optional arguments starting from the right, call the functions with different sfall_funcX (e.g. sfall_func4(\"draw_image\", pathFile, frame, x, y)) | . draw_image_scaled . sfall.h . void draw_image_scaled(string/int artFile/artId, int frame, int x, int y, int width, int height) . | displays the specified PCX or FRM image in the active window created by vanilla CreateWin or sfall’s create_win script function | 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) optional arguments: | frame: frame number, the first frame starts from zero | x/y: offset relative to the top-left corner of the window | width/height: the new width/height to scale the image to. Pass -1 to either width or height to keep the aspect ratio when scaling | NOTE: to omit optional arguments starting from the right, call the functions with different sfall_funcX (e.g. sfall_func4(\"draw_image\", pathFile, frame, x, y)) | if called without x/y/width/height arguments, the image will be scaled to fit the window without transparent background | . get_window_attribute . int sfall_func1(\"get_window_attribute\", int winType) . Alternative form: int sfall_func2(\"get_window_attribute\", int winType, int attrType) Returns the attribute of the specified interface window by the attrType argument. | winType: the type number of the interface window (see WINTYPE_* constants in sfall.h) | attrType: 0 - checks and returns a value of 1 if the specified interface window is created by the game (same as without the argument) 1 - X position, 2 - Y position (relative to the top-left corner of the game screen) 3 - interface width size, 4 - interface height size 5 - window ID (to compare with the get_window_under_mouse function) -1 - returns an associative array of keys (left, top, right, bottom) and values that define the position of the window rectangle (use standard syntax to access array values, e.g. winRect.top, winRect.bottom) | returns -1 if the specified attribute cannot be obtained | . get_window_under_mouse . int get_window_under_mouse() . Returns the internal ID of the top-most window under mouse cursor. interface_art_draw . int sfall_func4(\"interface_art_draw\", int winType, string artFile/int artID, int x, int y) . 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 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 (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: . | frame: frame number, the first frame starts from zero | param: an array which specifies additional parameters, where: 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 | . interface_overlay . sfall_func2(\"interface_overlay\", int winType, int mode) . Alternative form: int sfall_func6(\"interface_overlay\", int winType, 2, int x, int y, int width, int height). Creates an additional drawing surface above the graphic layer of the specified interface window. All subsequent calls of interface_art_draw and interface_print functions will draw on it. | winType: the type number of the interface window (see WINTYPE_* constants in sfall.h) | mode: 1 - creates a new overlay surface 2 - clears the overlay area or the specified rectangle defined by the x, y, width, height arguments 0 - destroys the created overlay surface (frees up the memory allocated to the surface) | . interface_print . int sfall_func5(\"interface_print\", string text, int winType, int x, int y, int color) . 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 | 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 the game 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 (optional): the maximum width of the text. The text will be wrapped to fit within the specified width | . message_box . 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!\") 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 the game palette. `color1` sets the text color for the first line, and `color2` for all subsequent lines of text (default color is 145) . set_window_flag . sfall.h . void set_window_flag(string winName/int winID, int flag, bool value) . Changes the specified flag for the created script or game interface window. | winName: the window name, assigned to the window by the CreateWin/create_win function | winID: the ID number of the interface or script window obtained with the get_window_under_mouse function, or 0 for the current game interface | flag: the flag to change (see WIN_FLAG_* constants in define_extra.h) | value: True - set the flag, False - unset the flag | . win_fill_color . int win_fill_color(int x, int y, int width, int height, int color) . Fills the rectangle area of the currently selected script window with the specified color, or clears the window with transparent (index 0) color (call the function without arguments). | color: the color index in the game palette (from 0 to 255) | . ",
"url": "/sfall/windows-and-images/#functions",
"relUrl": "/windows-and-images/#functions"
diff --git a/audio/index.html b/audio/index.html
index 2e881851..65426ecf 100644
--- a/audio/index.html
+++ b/audio/index.html
@@ -1,5 +1,5 @@
Used to play mp3/wav/wma files. The path given is relative to the Fallout folder. Specify mode as 1 to loop the file continuously, 2 to replace the current background game music with playing the specified file in loop mode, or 0 to play the file once. If you don’t wish to loop, play_sfall_sound returns 0. If you do loop, it returns an id which can be passed back to stop_sfall_sound when you want to stop the effect. All sounds effects will be stopped on game reload, looping or not. Does not require AllowDShowSound to be set to 1 in ddraw.ini.
Starting from sfall 4.2.8/3.8.28, you can pass a value in the mode argument for a reduced sound volume. To set the volume, You need to convert the number to hexadecimal and use the argument format 0xZZZZ000Y, where ZZZZ is the volume reduction value in range from 0 to 32767 (the value 32767 is mute), and Y is the playback mode.
set_eax_environment
voidset_eax_environment(intenvironment)
+
Used to play mp3/wav/wma files. The path given is relative to the Fallout folder. Specify mode as 1 to loop the file continuously, 2 to replace the current background game music with playing the specified file in loop mode, or 0 to play the file once. If you don’t wish to loop, play_sfall_sound returns 0. If you do loop, it returns an ID which can be passed back to stop_sfall_sound when you want to stop the effect. All sounds effects will be stopped on game reload, looping or not. Does not require AllowDShowSound to be set to 1 in ddraw.ini.
Starting from sfall 4.2.8/3.8.28, you can pass a value in the mode argument for a reduced sound volume. To set the volume, You need to convert the number to hexadecimal and use the argument format 0xZZZZ000Y, where ZZZZ is the volume reduction value in range from 0 to 32767 (the value 32767 is mute), and Y is the playback mode.
set_eax_environment
voidset_eax_environment(intenvironment)
Obsolete since sfall 2.1a. Has no effect.
stop_sfall_sound
voidstop_sfall_sound(intsoundID)
Stops looping mp3/wav/wma files previously launched by play_sfall_sound. All sounds effects will be stopped on game reload, looping or not. Does not require AllowDShowSound to be set to 1 in ddraw.ini.
diff --git a/feed.xml b/feed.xml
index 659ab371..322ff974 100644
--- a/feed.xml
+++ b/feed.xml
@@ -1 +1 @@
-Jekyll2024-06-01T20:14:58+00:00/sfall/feed.xmlsfallSfall documentation
\ No newline at end of file
+Jekyll2024-06-02T01:14:06+00:00/sfall/feed.xmlsfallSfall documentation
\ No newline at end of file
diff --git a/perks-and-traits/index.html b/perks-and-traits/index.html
index dac595db..64657d10 100644
--- a/perks-and-traits/index.html
+++ b/perks-and-traits/index.html
@@ -10,8 +10,8 @@
Modifies what happens when a fake perk is selected from the perks dialog. It is treated as a set of flags - if bit 1 is set then it is added to the player’s traits, if bit 2 is set it is added to the player’s perks, and if bit 3 is set it is removed from the list of selectable perks. The default is 0x2.
Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric id that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower.
Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric id that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower.
set_perk_agl
voidset_perk_agl(intperkID,intvalue)
+
Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric ID that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower.
Used to add additional traits and perks to the character screen. They will be saved correctly when the player saves and reloads games, but by themselves they will have no further effect on the character. For perks, the allowed range for levels is between 0 and 100; setting the level to 0 removes that perk. For traits, the level must be 0 or 1. The image is a numeric ID that corresponds to an entry in skilldex.lst. The name is limited to 63 characters and the description to 255 characters by sfall, but internal Fallout limits may be lower.
flags argument is optional. Works just like vanilla CreateWin function, but creates a window with MoveOnTop flag if the flags argument is not specified, and allows to set additional flags for the created window. MoveOnTop flag allows the created window to be placed on top of the game interface.
displays the specified PCX or FRM image in the active window created by vanilla CreateWin or sfall’s create_win script function
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) optional arguments:
frame: frame number, the first frame starts from zero
x/y: offset relative to the top-left corner of the window
noTransparent: pass True to display an image without transparent background
NOTE: to omit optional arguments starting from the right, call the functions with different sfall_funcX (e.g. sfall_func4("draw_image", pathFile, frame, x, y))
displays the specified PCX or FRM image in the active window created by vanilla CreateWin or sfall’s create_win script function
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) optional arguments:
frame: frame number, the first frame starts from zero
x/y: offset relative to the top-left corner of the window
width/height: the new width/height to scale the image to. Pass -1 to either width or height to keep the aspect ratio when scaling
NOTE: to omit optional arguments starting from the right, call the functions with different sfall_funcX (e.g. sfall_func4("draw_image", pathFile, frame, x, y))
if called without x/y/width/height arguments, the image will be scaled to fit the window without transparent background
Alternative form: int sfall_func2("get_window_attribute", int winType, int attrType) Returns the attribute of the specified interface window by the attrType argument.
winType: the type number of the interface window (see WINTYPE_* constants in sfall.h)
attrType: 0 - checks and returns a value of 1 if the specified interface window is created by the game (same as without the argument) 1 - X position, 2 - Y position (relative to the top-left corner of the game screen) 3 - interface width size, 4 - interface height size 5 - window ID (to compare with get_window_under_mouse) -1 - returns an associative array of keys (left, top, right, bottom) and values that define the position of the window rectangle (use standard syntax to access array values, e.g. winRect.top, winRect.bottom)
returns -1 if the specified attribute cannot be obtained
get_window_under_mouse
intget_window_under_mouse()
-
Returns internal ID of a top-most window under mouse cursor.
Alternative form: int sfall_func2("get_window_attribute", int winType, int attrType) Returns the attribute of the specified interface window by the attrType argument.
winType: the type number of the interface window (see WINTYPE_* constants in sfall.h)
attrType: 0 - checks and returns a value of 1 if the specified interface window is created by the game (same as without the argument) 1 - X position, 2 - Y position (relative to the top-left corner of the game screen) 3 - interface width size, 4 - interface height size 5 - window ID (to compare with the get_window_under_mouse function) -1 - returns an associative array of keys (left, top, right, bottom) and values that define the position of the window rectangle (use standard syntax to access array values, e.g. winRect.top, winRect.bottom)
returns -1 if the specified attribute cannot be obtained
get_window_under_mouse
intget_window_under_mouse()
+
Returns the internal ID of the top-most window under mouse cursor.