<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://wiki.hoggitworld.com/index.php?action=history&amp;feed=atom&amp;title=DCS_func_setUserCallbacks</id>
		<title>DCS func setUserCallbacks - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.hoggitworld.com/index.php?action=history&amp;feed=atom&amp;title=DCS_func_setUserCallbacks"/>
		<link rel="alternate" type="text/html" href="https://wiki.hoggitworld.com/index.php?title=DCS_func_setUserCallbacks&amp;action=history"/>
		<updated>2026-04-24T11:31:08Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.30.0</generator>

	<entry>
		<id>https://wiki.hoggitworld.com/index.php?title=DCS_func_setUserCallbacks&amp;diff=12879&amp;oldid=prev</id>
		<title>Grimes at 23:45, 14 May 2021</title>
		<link rel="alternate" type="text/html" href="https://wiki.hoggitworld.com/index.php?title=DCS_func_setUserCallbacks&amp;diff=12879&amp;oldid=prev"/>
				<updated>2021-05-14T23:45:09Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 23:45, 14 May 2021&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l13&quot; &gt;Line 13:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 13:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|par4=&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|par4=&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|desc= Adds the functions defined in the table to be run when the given event is called from the GameGUI environment. File is placed in Users\%YOURWINDOWSUSERNAME%\Saved Games\DCS\Scripts\Hooks folder. If this folder does not exist create it. &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|desc= Adds the functions defined in the table to be run when the given event is called from the GameGUI environment&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;. For each grouping of callbacks you create it needs to be added to a file placed in your saved games folder. This file is automatically loaded when the game starts&lt;/ins&gt;. File is placed in Users\%YOURWINDOWSUSERNAME%\Saved Games\DCS\Scripts\Hooks folder. If this folder does not exist create it. &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Grimes</name></author>	</entry>

	<entry>
		<id>https://wiki.hoggitworld.com/index.php?title=DCS_func_setUserCallbacks&amp;diff=12878&amp;oldid=prev</id>
		<title>Grimes: Created page with &quot;{{Template:DCS_server_funcs  |fName= setUserCallbacks  |vNum= 2.5.0  |par1= DCS  |par2=   |par3=   |par4=  |desc= Adds the functions defined in the t...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.hoggitworld.com/index.php?title=DCS_func_setUserCallbacks&amp;diff=12878&amp;oldid=prev"/>
				<updated>2021-05-14T23:37:54Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{Template:DCS_server_funcs  |fName= setUserCallbacks  |vNum= 2.5.0  |par1= &lt;a href=&quot;/index.php?title=DCS_singleton_control&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;DCS singleton control (page does not exist)&quot;&gt;DCS&lt;/a&gt;  |par2=   |par3=   |par4=  |desc= Adds the functions defined in the t...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Template:DCS_server_funcs&lt;br /&gt;
&lt;br /&gt;
|fName= setUserCallbacks&lt;br /&gt;
&lt;br /&gt;
|vNum= 2.5.0&lt;br /&gt;
&lt;br /&gt;
|par1= [[DCS_singleton_control|DCS]]&lt;br /&gt;
&lt;br /&gt;
|par2= &lt;br /&gt;
&lt;br /&gt;
|par3= &lt;br /&gt;
&lt;br /&gt;
|par4=&lt;br /&gt;
&lt;br /&gt;
|desc= Adds the functions defined in the table to be run when the given event is called from the GameGUI environment. File is placed in Users\%YOURWINDOWSUSERNAME%\Saved Games\DCS\Scripts\Hooks folder. If this folder does not exist create it. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''VERY IMPORTANT'''&lt;br /&gt;
&lt;br /&gt;
Some callbacks ''can'' have a return value. If returned in your code then that value will take precedence over any other callback that might be checking the same thing. It is best to return nothing unless you want to force a given action to occur. For example the callback onPlayerTryChangeSlot is used by the DCS UI for the prompt that occurs when trying to join another player's multicrew aircraft. If true or false is returned the pilot will never get the prompt to allow or deny the seat. &lt;br /&gt;
&lt;br /&gt;
'''List of Hooks:''' {{Template: listOfDCSHooks}}&lt;br /&gt;
&lt;br /&gt;
|rtnType= &lt;br /&gt;
&lt;br /&gt;
|rtnExample= &lt;br /&gt;
&lt;br /&gt;
|reqType1= table&lt;br /&gt;
&lt;br /&gt;
|reqName1= functions&lt;br /&gt;
&lt;br /&gt;
|reqType2= &lt;br /&gt;
&lt;br /&gt;
|reqName2=&lt;br /&gt;
&lt;br /&gt;
|optType1= &lt;br /&gt;
&lt;br /&gt;
|optName1= &lt;br /&gt;
&lt;br /&gt;
|optType2=&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
|related= &lt;br /&gt;
[[DCS_singleton_control|'''Control API:''']] {{listOfDCSControlFuncs}}&lt;br /&gt;
&lt;br /&gt;
|examples=   The following saves and modifies global values for the current mission name and a list of connected clients. &lt;br /&gt;
    local myCall = {}&lt;br /&gt;
    clients = {}&lt;br /&gt;
    function myCall.onMissionLoadBegin()&lt;br /&gt;
       current_mission = DCS.getMissionName()&lt;br /&gt;
    end&lt;br /&gt;
    function myCall.onPlayerConnect(id)&lt;br /&gt;
         clients[id] = {id = id, addr = net.get_player_info(id, 'ipaddr'), name = net.get_player_info(id, 'name'), ucid = net.get_player_info(id, 'ucid'), ip = net.get_player_info(id, 'ipaddr')}&lt;br /&gt;
    end  &lt;br /&gt;
    function myCall.onPlayerDisconnect(id)&lt;br /&gt;
        clients[id] = nil&lt;br /&gt;
    end &lt;br /&gt;
    DCS.setUserCallbacks(myCall)&lt;br /&gt;
&lt;br /&gt;
|notes= &lt;br /&gt;
}}&lt;br /&gt;
[[Category:DCS Control Functions|setUserCallbacks]]&lt;/div&gt;</summary>
		<author><name>Grimes</name></author>	</entry>

	</feed>