<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
	<id>https://rage.grandroleplay.ru/index.php?action=history&amp;feed=atom&amp;title=Ui%3A%3AsetHeadDisplayWanted</id>
	<title>Ui::setHeadDisplayWanted - История изменений</title>
	<link rel="self" type="application/atom+xml" href="https://rage.grandroleplay.ru/index.php?action=history&amp;feed=atom&amp;title=Ui%3A%3AsetHeadDisplayWanted"/>
	<link rel="alternate" type="text/html" href="https://rage.grandroleplay.ru/index.php?title=Ui::setHeadDisplayWanted&amp;action=history"/>
	<updated>2026-07-25T01:39:53Z</updated>
	<subtitle>История изменений этой страницы в вики</subtitle>
	<generator>MediaWiki 1.43.9</generator>
	<entry>
		<id>https://rage.grandroleplay.ru/index.php?title=Ui::setHeadDisplayWanted&amp;diff=15336&amp;oldid=prev</id>
		<title>imported&gt;Shr0x в 09:31, 2 ноября 2024</title>
		<link rel="alternate" type="text/html" href="https://rage.grandroleplay.ru/index.php?title=Ui::setHeadDisplayWanted&amp;diff=15336&amp;oldid=prev"/>
		<updated>2024-11-02T09:31:18Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{ClientsideJsFunction}}&lt;br /&gt;
{{JSContainer|&lt;br /&gt;
&lt;br /&gt;
The `setHeadDisplayWanted` function displays a wanted star icon above a specified player&amp;#039;s head, indicating their wanted level. This function is useful for displaying visual cues above a player&amp;#039;s head to signify their wanted status in roleplay or law enforcement scenarios.&lt;br /&gt;
&lt;br /&gt;
The wanted level can range from 0 (no stars) to 5 (maximum wanted level), and it provides other players with a clear visual indicator of someone’s wanted status, enhancing the realism and interaction possibilities within gameplay.&lt;br /&gt;
&lt;br /&gt;
=== Required Params ===&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;headDisplayId:&amp;#039;&amp;#039;&amp;#039; {{RageType|int}} – The display ID representing the player or entity whose wanted level should be displayed.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;wantedlvl:&amp;#039;&amp;#039;&amp;#039; {{RageType|int}} – The wanted level to display (0–5), with 0 hiding the icon.&lt;br /&gt;
&lt;br /&gt;
=== Return Value ===&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Undefined&amp;#039;&amp;#039;&amp;#039; – This function does not return a value.&lt;br /&gt;
&lt;br /&gt;
== Syntax ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
mp.game.ui.setHeadDisplayWanted(headDisplayId, wantedlvl);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
// Example usage of setHeadDisplayWanted&lt;br /&gt;
&lt;br /&gt;
const headDisplayId = player.handle; // Get the display ID for the current player&lt;br /&gt;
const wantedLevel = 3;               // Set desired wanted level (e.g., 3 stars)&lt;br /&gt;
&lt;br /&gt;
// Display 3 wanted stars above the player&amp;#039;s head&lt;br /&gt;
mp.game.ui.setHeadDisplayWanted(headDisplayId, wantedLevel);&lt;br /&gt;
&lt;br /&gt;
// Confirm the action in chat&lt;br /&gt;
mp.gui.chat.push(`Wanted level set to ${wantedLevel} for player.`);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
== See Also ==&lt;br /&gt;
{{Ui_s_function_c}}&lt;br /&gt;
[[Category:Clientside API]]&lt;br /&gt;
[[Category:UI API]]&lt;br /&gt;
[[Category:TODO: Example]]&lt;/div&gt;</summary>
		<author><name>imported&gt;Shr0x</name></author>
	</entry>
</feed>