\rhead{\bf MC\_CopyAgent()}
\noindent
\vspace{5pt}
\rule{6.5in}{0.015in}
\noindent
\phantomsection
{\LARGE \bf MC\_CopyAgent()\index{MC\_CopyAgent()}}\\
\addcontentsline{toc}{section}{MC\_CopyAgent()}

\noindent
{\bf Synopsis}\\
{\bf \#include $<$libmc.h$>$}\\
{\bf int MC\_CopyAgent}({\bf MCAgent\_t} $agent\_out$, {\bf MCAgent\_t*} $agent\_in$);\\

\noindent
{\bf Purpose}\\
Copies an agent.\\

\noindent
{\bf Return Value}\\
The function returns 0 on success and non-zero otherwise.\\

\noindent
{\bf Parameters}
\vspace{-0.1in}
\begin{description}
\item
\begin{tabular}{p{10 mm}p{145 mm}} 
$agent\_out$ & A copied agent. \\
$agent\_in$ & The agent to copy.
\end{tabular}
\end{description}

\noindent
{\bf Description}\\
This function is used to perform a deep copy on an Mobile-C agent. It is useful
in conjunction with functions that retrieve agents from agencies, since
those functions only retrieve a reference to the agent: Not a full copy. 

\noindent
{\bf Example}\\
\noindent
{\footnotesize\verbatiminput{../demos/miscellaneous/multiple_agency_example/server.c}}

\noindent
{\bf See Also}\\

%\CPlot::\DataThreeD(), \CPlot::\DataFile(), \CPlot::\Plotting(), \plotxy().\\
