<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.fortress-forever.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Info_ff_script%3Adropitemcmd</id>
	<title>Info ff script:dropitemcmd - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.fortress-forever.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Info_ff_script%3Adropitemcmd"/>
	<link rel="alternate" type="text/html" href="https://www.fortress-forever.com/wiki/index.php?title=Info_ff_script:dropitemcmd&amp;action=history"/>
	<updated>2026-08-08T12:50:05Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.35.11</generator>
	<entry>
		<id>https://www.fortress-forever.com/wiki/index.php?title=Info_ff_script:dropitemcmd&amp;diff=9067&amp;oldid=prev</id>
		<title>Crazycarl: New page: ==info_ff_script:dropitemcmd(owner_entity)==  Whenever a player uses the drop items command (&#039;&#039;c&#039;&#039; by default), any item(s) he is carrying will fire this function. Within the scope of this...</title>
		<link rel="alternate" type="text/html" href="https://www.fortress-forever.com/wiki/index.php?title=Info_ff_script:dropitemcmd&amp;diff=9067&amp;oldid=prev"/>
		<updated>2009-05-12T18:44:34Z</updated>

		<summary type="html">&lt;p&gt;New page: ==info_ff_script:dropitemcmd(owner_entity)==  Whenever a player uses the drop items command (&amp;#039;&amp;#039;c&amp;#039;&amp;#039; by default), any item(s) he is carrying will fire this function. Within the scope of this...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==info_ff_script:dropitemcmd(owner_entity)==&lt;br /&gt;
&lt;br /&gt;
Whenever a player uses the drop items command (&amp;#039;&amp;#039;c&amp;#039;&amp;#039; by default), any item(s) he is carrying will fire this function. Within the scope of this callback, the keyword &amp;#039;&amp;#039;entity&amp;#039;&amp;#039; refers to the entity that fired the callback.&lt;br /&gt;
&lt;br /&gt;
===Example===&lt;br /&gt;
&amp;lt;pre&amp;gt;function baseflag:dropitemcmd( owner_entity )&lt;br /&gt;
	if allowdrop == false then return end&lt;br /&gt;
&lt;br /&gt;
	-- throw the flag&lt;br /&gt;
	local flag = CastToInfoScript(entity)&lt;br /&gt;
	flag:Drop(FLAG_RETURN_TIME, FLAG_THROW_SPEED)&lt;br /&gt;
	&lt;br /&gt;
	-- remove flag icon from hud&lt;br /&gt;
	local player = CastToPlayer( owner_entity )&lt;br /&gt;
	RemoveHudItem( player, flag:GetName() )&lt;br /&gt;
&lt;br /&gt;
	self.status = 2&lt;br /&gt;
	self.carriedby = &amp;quot;&amp;quot;&lt;br /&gt;
	self.droppedlocation = player:GetLocation()&lt;br /&gt;
	self:refreshStatusIcons(flag:GetName())&lt;br /&gt;
	LogLuaEvent(player:GetId(), 0, &amp;quot;flag_thrown&amp;quot;,&amp;quot;flag_name&amp;quot;,flag:GetName(), &amp;quot;player_origin&amp;quot;, (string.format(&amp;quot;%0.2f&amp;quot;,player:GetOrigin().x) .. &amp;quot;, &amp;quot; .. string.format(&amp;quot;%0.2f&amp;quot;,player:GetOrigin().y) .. &amp;quot;, &amp;quot; .. string.format(&amp;quot;%0.1f&amp;quot;,player:GetOrigin().z) ), &amp;quot;player_health&amp;quot;, &amp;quot;&amp;quot; ..player:GetHealth());&lt;br /&gt;
	&lt;br /&gt;
	-- clear the objective icon&lt;br /&gt;
	UpdateObjectiveIcon( player, nil )&lt;br /&gt;
end	&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[Category:Lua_Callbacks]]&lt;br /&gt;
[[Category:Info_ff_script]]&lt;/div&gt;</summary>
		<author><name>Crazycarl</name></author>
	</entry>
</feed>