Loading Screens – Take On Helicopters

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Some wiki formatting)
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
[[Category:Take On Helicopters: Editing]]
[[File:tkoh loading.jpg|thumb]]
[[File:tkoh loading.jpg|thumb]]
== Images ==
== Images ==
Game lists through defined images in config order, only starting index is random.
Game lists through defined images in config order, only starting index is random.


Line 12: Line 12:


=== Global ===
=== Global ===
Displayed anywhere in game.
Displayed anywhere in game.
class CfgLoadingScreens
<syntaxhighlight lang="cpp">
{
class CfgLoadingScreens
{{codecomment|//--- Delay between images are swapped}}
{
refreshDelay = 20;
//--- Delay between images are swapped
refreshDelay = 20;
{{codecomment|//--- Classes with paths to image files}}
 
class Screen1 {text="hsim\ui_h\data\loading\loading_1_ca.paa";};
//--- Classes with paths to image files
class Screen2 {text="hsim\ui_h\data\loading\loading_2_ca.paa";};
class Screen1 { text = "hsim\ui_h\data\loading\loading_1_ca.paa"; };
};
class Screen2 { text = "hsim\ui_h\data\loading\loading_2_ca.paa"; };
};
</syntaxhighlight>


=== Mission Specific ===
=== Mission Specific ===
Achieved by setting ''loadScreen'' param in [[description.ext#loadScreen|Desciption.ext]]
 
loadScreen = "pictures\intro.paa";
Achieved by setting ''loadScreen'' param in [[Description.ext#loadScreen|Desciption.ext]]
<syntaxhighlight lang="cpp">loadScreen = "pictures\intro.paa";</syntaxhighlight>




== Texts ==
== Texts ==
Loading texts can be set both in global [[Config.cpp]] file or in mission specific [[Description.ext]]. Using mission loading texts will replace the global ones.
Loading texts can be set both in global [[Config.cpp]] file or in mission specific [[Description.ext]]. Using mission loading texts will replace the global ones.


Text is defined as [[String]], but displayed as [[Structured Text]]. Even this format offers many possibilities, bear in mind background is recolored according to user interface colors and using hardcoded colors in the text itself could make it unreadable.
Text is defined as [[String]], but displayed as [[Structured Text]].
class CfgLoadingTexts
Even this format offers many possibilities, bear in mind background is recolored according to user interface colors and using hardcoded colors in the text itself could make it unreadable.
{
<syntaxhighlight lang="cpp">
{{codecomment|//--- Delay between texts are swapped (by default same as delay for images)}}
class CfgLoadingTexts
refreshDelay = 20;
{
//--- Delay between texts are swapped (by default same as delay for images)
{{codecomment|//--- Loading text container}}
refreshDelay = 20;
class ThrottleBasic
 
{
//--- Loading text container
{{codecomment|//--- Hint title}}
class ThrottleBasic
title = $STR_HSIM_CfgLoadingTexts_ThrottleBasic_0;
{
//--- Hint title
{{codecomment|//--- Lines of text (<nowiki><br /></nowiki> will be placed inbetween them)}}
title = "$STR_HSIM_CfgLoadingTexts_ThrottleBasic_0";
text[] = {
 
$STR_HSIM_CfgLoadingTexts_ThrottleBasic_1,
//--- Lines of text (<nowiki><br /></nowiki> will be placed inbetween them)
$STR_HSIM_CfgLoadingTexts_ThrottleBasic_2,
text[] = {
$STR_HSIM_CfgLoadingTexts_ThrottleBasic_3
"$STR_HSIM_CfgLoadingTexts_ThrottleBasic_1",
};
"$STR_HSIM_CfgLoadingTexts_ThrottleBasic_2",
"$STR_HSIM_CfgLoadingTexts_ThrottleBasic_3"
{{codecomment|//--- Optional format params applied to all text lines (put here technical text to avoid its localization)}}
};
params[] = {
 
"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_OFF_ca.paa' size='1.5' />",
//--- Optional format params applied to all text lines (put here technical text to avoid its localization)
"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_IDL_ca.paa' size='1.5' />",
params[] = {
"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_ON_ca.paa' size='1.5' />"
"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_OFF_ca.paa' size='1.5' />",
};
"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_IDL_ca.paa' size='1.5' />",
"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_ON_ca.paa' size='1.5' />"
{{codecomment|//--- Enable diary record (e.g. text is atimatically added to 'Hints' category in notes)}}
};
isDiary = 1;
 
};
//--- Enable diary record (e.g. text is atimatically added to 'Hints' category in notes)
};
isDiary = 1;
};
};
</syntaxhighlight>
 


== Functions ==
== Functions ==
Displaying loading screens is handled by [[BIS_fnc_displayLoading]] function.
Displaying loading screens is handled by [[BIS_fnc_displayLoading]] function.
[[Category:Take On Helicopters: Editing]]

Latest revision as of 21:19, 13 March 2023

tkoh loading.jpg

Images

Game lists through defined images in config order, only starting index is random.

Same as overview images, loading screens system is also created to be simple and accessable for community, and producing the images themselves requires almost no knowledge of image editing programs.

Only requirements are:

  • 2:1 aspect ratio
  • Monochromatic (black & white) - images are recolored according to user interface colors.
  • High resolution (size of official images is 2048x1024)

Global

Displayed anywhere in game.

class CfgLoadingScreens
{
	//--- Delay between images are swapped
	refreshDelay = 20;

	//--- Classes with paths to image files
	class Screen1	{ text = "hsim\ui_h\data\loading\loading_1_ca.paa"; };
	class Screen2	{ text = "hsim\ui_h\data\loading\loading_2_ca.paa"; };
};

Mission Specific

Achieved by setting loadScreen param in Desciption.ext

loadScreen = "pictures\intro.paa";


Texts

Loading texts can be set both in global Config.cpp file or in mission specific Description.ext. Using mission loading texts will replace the global ones.

Text is defined as String, but displayed as Structured Text. Even this format offers many possibilities, bear in mind background is recolored according to user interface colors and using hardcoded colors in the text itself could make it unreadable.

class CfgLoadingTexts
{
	//--- Delay between texts are swapped (by default same as delay for images)
	refreshDelay = 20;

	//--- Loading text container
	class ThrottleBasic
	{
		//--- Hint title
		title = "$STR_HSIM_CfgLoadingTexts_ThrottleBasic_0";

		//--- Lines of text (<nowiki><br /></nowiki> will be placed inbetween them)
		text[] = {
			"$STR_HSIM_CfgLoadingTexts_ThrottleBasic_1",
			"$STR_HSIM_CfgLoadingTexts_ThrottleBasic_2",
			"$STR_HSIM_CfgLoadingTexts_ThrottleBasic_3"
		};

		//--- Optional format params applied to all text lines (put here technical text to avoid its localization)
		params[] = {
			"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_OFF_ca.paa' size='1.5' />",
			"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_IDL_ca.paa' size='1.5' />",
			"<img image='hsim\ui_h\data\igui\ico_cpt_thtl_ON_ca.paa'  size='1.5' />"
		};

		//--- Enable diary record (e.g. text is atimatically added to 'Hints' category in notes)
		isDiary = 1;
	};
};


Functions

Displaying loading screens is handled by BIS_fnc_displayLoading function.