\hypertarget{structCondition}{\section{\-Condition \-Struct \-Reference}
\label{structCondition}\index{\-Condition@{\-Condition}}
}


{\ttfamily \#include $<$\-Condition.\-h$>$}



\-Collaboration diagram for \-Condition\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{structCondition__coll__graph}
\end{center}
\end{figure}
\subsection*{\-Public \-Member \-Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{structCondition_af11513db4fcbde93961fa0b65e7ab764}{\-Condition} ()
\item 
\hyperlink{structCondition_ad5b996c9a4192a38074887f6c3a9d182}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, bool expected\-Value=true)
\item 
\hyperlink{structCondition_a7778300d111346215892b597f913282f}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, int extra\-Value)
\item 
\hyperlink{structCondition_a93ce47507a42bf97f6c0234cbdd6a448}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, bool expected\-Value, int extra\-Value)
\item 
\hyperlink{structCondition_aad4afe8bfd1418ee2adf9921e9ff83bb}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, double extra\-Value)
\item 
\hyperlink{structCondition_a6a8c4d3c3eaad3fff137e839aa65d8ec}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, bool expected\-Value, double extra\-Value)
\item 
\hyperlink{structCondition_a7935a9272f7a4c31cb27a2e398f61189}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, \hyperlink{classBWAPI_1_1UnitType}{\-B\-W\-A\-P\-I\-::\-Unit\-Type} unit\-Type, int count=1)
\item 
\hyperlink{structCondition_a9c5f478325d747efd5732a58f6826282}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, \hyperlink{classBWAPI_1_1TechType}{\-B\-W\-A\-P\-I\-::\-Tech\-Type} tech)
\item 
\hyperlink{structCondition_a82ac5bde76ed7f93b8bb7eac7237d9a6}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, \hyperlink{classBWAPI_1_1UpgradeType}{\-B\-W\-A\-P\-I\-::\-Upgrade\-Type} upgrade, int level=1)
\item 
\hyperlink{structCondition_aaac979468467c656efe293bed673a091}{\-Condition} (\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} type, std\-::string string)
\item 
\hyperlink{structCondition_a480397eb6b46d01b0a730ee7d637196f}{\-Condition} (const \hyperlink{structCondition}{\-Condition} \&other)
\item 
\hyperlink{structCondition}{\-Condition} \& \hyperlink{structCondition_acff42edc68c70f109eb1e49d44679469}{operator=} (const \hyperlink{structCondition}{\-Condition} \&other)
\item 
bool \hyperlink{structCondition_a6c6104b9d291e3e8a1a798cbbb648e40}{evauluate} () const 
\item 
\hyperlink{structCondition}{\-Condition} \hyperlink{structCondition_a22cb417ae573c1642536effab488aff2}{operator\&\&} (const \hyperlink{structCondition}{\-Condition} \&other) const 
\item 
\hyperlink{structCondition}{\-Condition} \hyperlink{structCondition_a46704f5624901a81ba98c784f003af9f}{operator$|$$|$} (const \hyperlink{structCondition}{\-Condition} \&other) const 
\end{DoxyCompactItemize}
\subsection*{\-Private \-Member \-Functions}
\begin{DoxyCompactItemize}
\item 
bool \hyperlink{structCondition_a52c3090c83be44ef2c25a03c085543fa}{passes\-Value} () const 
\item 
\hyperlink{structCondition_aea57e253e2725e6afd2051831df32143}{\-Condition} (const \hyperlink{structCondition}{\-Condition} \&left, \hyperlink{structOperatorTypeDef_a7f4f6b4308a0690e22bec86ffa8e8a38}{\-Operator\-Type\-::type} op\-Type, const \hyperlink{structCondition}{\-Condition} \&right)
\end{DoxyCompactItemize}
\subsection*{\-Private \-Attributes}
\begin{DoxyCompactItemize}
\item 
\hyperlink{Condition_8h_a43f334faaa146015342cfcb96af9aceb}{\-Condition\-Test} \hyperlink{structCondition_a7bbc3eb4bc4f93c4b84cd8117e29c521}{m\-Type}
\item 
\hyperlink{OperatorType_8h_a115d5ff4cbe600f34dc09129b3cef792}{\-Operator\-Type} \hyperlink{structCondition_a0c4c6f75344ba14f06d0cbece4cb6860}{m\-Operator\-Type}
\item 
boost\-::scoped\-\_\-ptr$<$ \hyperlink{structCondition}{\-Condition} $>$ \hyperlink{structCondition_a15d544f10d4ed9fbf0d34a3b5d44fe6e}{m\-L\-Condition}
\item 
boost\-::scoped\-\_\-ptr$<$ \hyperlink{structCondition}{\-Condition} $>$ \hyperlink{structCondition_a68ee5c1ee5db0adae443bcb19aa4b102}{m\-R\-Condition}
\item 
bool \hyperlink{structCondition_a44e25c31a8176ae6fbdf8010c3724b3d}{m\-Needed\-Value}
\item 
int \hyperlink{structCondition_ae77e7c2401f44222ded87864836fa613}{m\-Extra\-Int}
\item 
double \hyperlink{structCondition_a302acfc53b5bcf0899be97a38d37edd7}{m\-Extra\-Double}
\item 
\hyperlink{classBWAPI_1_1UnitType}{\-B\-W\-A\-P\-I\-::\-Unit\-Type} \hyperlink{structCondition_ac65d6ec914e81ee1386c876419ddcb55}{m\-Unit\-Type}
\item 
\hyperlink{classBWAPI_1_1TechType}{\-B\-W\-A\-P\-I\-::\-Tech\-Type} \hyperlink{structCondition_a8c1846c5c7aaee4b86acc21f7a191474}{m\-Tech}
\item 
\hyperlink{classBWAPI_1_1UpgradeType}{\-B\-W\-A\-P\-I\-::\-Upgrade\-Type} \hyperlink{structCondition_a375ec1b2f899c8436d43c8a6d2e7b21d}{m\-Upgrade}
\item 
std\-::string \hyperlink{structCondition_a3a672bc99bd647965bcfd3ae9888f1a6}{m\-String}
\end{DoxyCompactItemize}


\subsection{\-Detailed \-Description}


\-Definition at line 46 of file \-Condition.\-h.



\subsection{\-Constructor \& \-Destructor \-Documentation}
\hypertarget{structCondition_af11513db4fcbde93961fa0b65e7ab764}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}\label{structCondition_af11513db4fcbde93961fa0b65e7ab764}


\-Definition at line 49 of file \-Condition.\-h.



\-Referenced by operator\&\&(), and operator$|$$|$().


\begin{DoxyCode}
: mType(ConditionTest::None), mOperatorType(OperatorType::None), mNeededValue(
      false) {}
\end{DoxyCode}


\-Here is the caller graph for this function\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=336pt]{structCondition_af11513db4fcbde93961fa0b65e7ab764_icgraph}
\end{center}
\end{figure}


\hypertarget{structCondition_ad5b996c9a4192a38074887f6c3a9d182}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{bool}]{expected\-Value = {\ttfamily true}}
\end{DoxyParamCaption}
)}}\label{structCondition_ad5b996c9a4192a38074887f6c3a9d182}


\-Definition at line 10 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(expectedValue)
        , mExtraInt(0)
        , mExtraDouble(0)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_a7778300d111346215892b597f913282f}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{int}]{extra\-Value}
\end{DoxyParamCaption}
)}}\label{structCondition_a7778300d111346215892b597f913282f}


\-Definition at line 25 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(false)
        , mExtraInt(extraValue)
        , mExtraDouble(0)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_a93ce47507a42bf97f6c0234cbdd6a448}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{bool}]{expected\-Value, }
\item[{int}]{extra\-Value}
\end{DoxyParamCaption}
)}}\label{structCondition_a93ce47507a42bf97f6c0234cbdd6a448}


\-Definition at line 40 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(expectedValue)
        , mExtraInt(extraValue)
        , mExtraDouble(0)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_aad4afe8bfd1418ee2adf9921e9ff83bb}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{double}]{extra\-Value}
\end{DoxyParamCaption}
)}}\label{structCondition_aad4afe8bfd1418ee2adf9921e9ff83bb}


\-Definition at line 55 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(false)
        , mExtraInt(0)
        , mExtraDouble(extraValue)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_a6a8c4d3c3eaad3fff137e839aa65d8ec}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{bool}]{expected\-Value, }
\item[{double}]{extra\-Value}
\end{DoxyParamCaption}
)}}\label{structCondition_a6a8c4d3c3eaad3fff137e839aa65d8ec}


\-Definition at line 70 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(expectedValue)
        , mExtraInt(0)
        , mExtraDouble(extraValue)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_a7935a9272f7a4c31cb27a2e398f61189}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{{\bf \-B\-W\-A\-P\-I\-::\-Unit\-Type}}]{unit\-Type, }
\item[{int}]{count = {\ttfamily 1}}
\end{DoxyParamCaption}
)}}\label{structCondition_a7935a9272f7a4c31cb27a2e398f61189}


\-Definition at line 84 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(false)
        , mExtraInt(count)
        , mExtraDouble(0)
        , mUnitType(unitType)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_a9c5f478325d747efd5732a58f6826282}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{{\bf \-B\-W\-A\-P\-I\-::\-Tech\-Type}}]{tech}
\end{DoxyParamCaption}
)}}\label{structCondition_a9c5f478325d747efd5732a58f6826282}


\-Definition at line 99 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(false)
        , mExtraInt(0)
        , mExtraDouble(0)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(tech)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_a82ac5bde76ed7f93b8bb7eac7237d9a6}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{{\bf \-B\-W\-A\-P\-I\-::\-Upgrade\-Type}}]{upgrade, }
\item[{int}]{level = {\ttfamily 1}}
\end{DoxyParamCaption}
)}}\label{structCondition_a82ac5bde76ed7f93b8bb7eac7237d9a6}


\-Definition at line 114 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(false)
        , mExtraInt(level)
        , mExtraDouble(0)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(upgrade)
        , mString()
{
}
\end{DoxyCode}
\hypertarget{structCondition_aaac979468467c656efe293bed673a091}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{{\bf \-Condition\-Test}}]{type, }
\item[{std\-::string}]{string}
\end{DoxyParamCaption}
)}}\label{structCondition_aaac979468467c656efe293bed673a091}


\-Definition at line 129 of file \-Condition.\-cpp.


\begin{DoxyCode}
        : mType(type)
        , mOperatorType(OperatorType::None)
        , mLCondition()
        , mRCondition()
        , mNeededValue(false)
        , mExtraInt(0)
        , mExtraDouble(0)
        , mUnitType(BWAPI::UnitTypes::None)
        , mTech(BWAPI::TechTypes::None)
        , mUpgrade(BWAPI::UpgradeTypes::None)
        , mString(string)
{
}
\end{DoxyCode}
\hypertarget{structCondition_a480397eb6b46d01b0a730ee7d637196f}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{const {\bf \-Condition} \&}]{other}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}\label{structCondition_a480397eb6b46d01b0a730ee7d637196f}


\-Definition at line 60 of file \-Condition.\-h.


\begin{DoxyCode}
                : mType(other.mType)
                , mOperatorType(other.mOperatorType)
                , mLCondition(other.mLCondition ? new Condition(*other.
      mLCondition) : NULL)
                , mRCondition(other.mRCondition ? new Condition(*other.
      mRCondition) : NULL)
                , mNeededValue(other.mNeededValue)
                , mExtraInt(other.mExtraInt)
                , mExtraDouble(other.mExtraDouble)
                , mUnitType(other.mUnitType)
                , mTech(other.mTech)
                , mUpgrade(other.mUpgrade)
                , mString(other.mString)
        {
        }
\end{DoxyCode}
\hypertarget{structCondition_aea57e253e2725e6afd2051831df32143}{\index{\-Condition@{\-Condition}!\-Condition@{\-Condition}}
\index{\-Condition@{\-Condition}!Condition@{\-Condition}}
\subsubsection[{\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-::\-Condition} (
\begin{DoxyParamCaption}
\item[{const {\bf \-Condition} \&}]{left, }
\item[{{\bf \-Operator\-Type\-::type}}]{op\-Type, }
\item[{const {\bf \-Condition} \&}]{right}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline, private\mbox{]}}}}\label{structCondition_aea57e253e2725e6afd2051831df32143}


\-Definition at line 133 of file \-Condition.\-h.


\begin{DoxyCode}
                : mType(ConditionTest::None)
                , mOperatorType(opType)
                , mLCondition(new Condition(left))
                , mRCondition(new Condition(right))
                , mNeededValue(false)
                , mExtraInt(0)
                , mExtraDouble(0)
                , mUnitType(BWAPI::UnitTypes::None)
                , mTech(BWAPI::TechTypes::None)
                , mUpgrade(BWAPI::UpgradeTypes::None)
                , mString()
        {}
\end{DoxyCode}


\subsection{\-Member \-Function \-Documentation}
\hypertarget{structCondition_a6c6104b9d291e3e8a1a798cbbb648e40}{\index{\-Condition@{\-Condition}!evauluate@{evauluate}}
\index{evauluate@{evauluate}!Condition@{\-Condition}}
\subsubsection[{evauluate}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf \-Condition\-::evauluate} (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}\label{structCondition_a6c6104b9d291e3e8a1a798cbbb648e40}


\-Definition at line 93 of file \-Condition.\-h.



\-References \-Operator\-Type\-Def\-::\-And, m\-L\-Condition, m\-Operator\-Type, m\-R\-Condition, \-Operator\-Type\-Def\-::\-None, \-Operator\-Type\-Def\-::\-Or, and passes\-Value().



\-Referenced by \-Unit\-To\-Produce\-::can\-Build\-Factory(), \-Unit\-To\-Produce\-::can\-Build\-Unit(), and \-Build\-Order\-::is\-Start\-Build().


\begin{DoxyCode}
        {
                if(mOperatorType == OperatorType::None)
                        return passesValue();
                else if(mOperatorType == OperatorType::And)
                        return mLCondition->evauluate() && mRCondition->
      evauluate();
                else if(mOperatorType == OperatorType::Or)
                        return mLCondition->evauluate() || mRCondition->
      evauluate();

                return false;
        }
\end{DoxyCode}


\-Here is the call graph for this function\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{structCondition_a6c6104b9d291e3e8a1a798cbbb648e40_cgraph}
\end{center}
\end{figure}




\-Here is the caller graph for this function\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{structCondition_a6c6104b9d291e3e8a1a798cbbb648e40_icgraph}
\end{center}
\end{figure}


\hypertarget{structCondition_a22cb417ae573c1642536effab488aff2}{\index{\-Condition@{\-Condition}!operator\&\&@{operator\&\&}}
\index{operator\&\&@{operator\&\&}!Condition@{\-Condition}}
\subsubsection[{operator\&\&}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition} \-Condition\-::operator\&\& (
\begin{DoxyParamCaption}
\item[{const {\bf \-Condition} \&}]{other}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}\label{structCondition_a22cb417ae573c1642536effab488aff2}


\-Definition at line 105 of file \-Condition.\-h.



\-References \-Operator\-Type\-Def\-::\-And, and \-Condition().


\begin{DoxyCode}
        {
                return Condition(*this, OperatorType::And, other);
        }
\end{DoxyCode}


\-Here is the call graph for this function\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=336pt]{structCondition_a22cb417ae573c1642536effab488aff2_cgraph}
\end{center}
\end{figure}


\hypertarget{structCondition_acff42edc68c70f109eb1e49d44679469}{\index{\-Condition@{\-Condition}!operator=@{operator=}}
\index{operator=@{operator=}!Condition@{\-Condition}}
\subsubsection[{operator=}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition}\& \-Condition\-::operator= (
\begin{DoxyParamCaption}
\item[{const {\bf \-Condition} \&}]{other}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}\label{structCondition_acff42edc68c70f109eb1e49d44679469}


\-Definition at line 75 of file \-Condition.\-h.



\-References m\-Extra\-Double, m\-Extra\-Int, m\-L\-Condition, m\-Needed\-Value, m\-Operator\-Type, m\-R\-Condition, m\-String, m\-Tech, m\-Type, m\-Unit\-Type, and m\-Upgrade.


\begin{DoxyCode}
        {
                mType = other.mType;
                mOperatorType = other.mOperatorType;
                mNeededValue = other.mNeededValue;
                mExtraInt = other.mExtraInt;
                mExtraDouble = other.mExtraDouble;
                mUnitType = other.mUnitType;
                mTech = other.mTech;
                mUpgrade = other.mUpgrade;
                mString = other.mString;

                mLCondition.reset(other.mLCondition ? new Condition(*other.
      mLCondition) : NULL);
                mRCondition.reset(other.mRCondition ? new Condition(*other.
      mRCondition) : NULL);

                return *this;
        }
\end{DoxyCode}
\hypertarget{structCondition_a46704f5624901a81ba98c784f003af9f}{\index{\-Condition@{\-Condition}!operator$|$$|$@{operator$|$$|$}}
\index{operator$|$$|$@{operator$|$$|$}!Condition@{\-Condition}}
\subsubsection[{operator$|$$|$}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition} \-Condition\-::operator$|$$|$ (
\begin{DoxyParamCaption}
\item[{const {\bf \-Condition} \&}]{other}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}\label{structCondition_a46704f5624901a81ba98c784f003af9f}


\-Definition at line 110 of file \-Condition.\-h.



\-References \-Condition(), and \-Operator\-Type\-Def\-::\-Or.


\begin{DoxyCode}
        {
                return Condition(*this, OperatorType::Or, other);
        }
\end{DoxyCode}


\-Here is the call graph for this function\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=326pt]{structCondition_a46704f5624901a81ba98c784f003af9f_cgraph}
\end{center}
\end{figure}


\hypertarget{structCondition_a52c3090c83be44ef2c25a03c085543fa}{\index{\-Condition@{\-Condition}!passes\-Value@{passes\-Value}}
\index{passes\-Value@{passes\-Value}!Condition@{\-Condition}}
\subsubsection[{passes\-Value}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf \-Condition\-::passes\-Value} (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a52c3090c83be44ef2c25a03c085543fa}


\-Definition at line 144 of file \-Condition.\-cpp.



\-References \-B\-W\-A\-P\-I\-::\-Broodwar, \-Condition\-Test\-Def\-::can\-Forge\-Expand, \-B\-W\-A\-P\-I\-::\-Player\-::dead\-Unit\-Count(), \-Condition\-Test\-Def\-::enemy\-Doesnt\-Has\-Unit\-Less\-Than, \-Condition\-Test\-Def\-::enemy\-Has\-Researched, \-Condition\-Test\-Def\-::enemy\-Unit\-Count\-Greater\-Equal\-Than, \-B\-W\-A\-P\-I\-::\-Game\-::get\-Start\-Locations(), \-B\-W\-A\-P\-I\-::\-Player\-::get\-Upgrade\-Level(), \-B\-W\-A\-P\-I\-::\-Player\-::has\-Researched(), \-Singleton$<$ T $>$\-::\-Instance(), \-Condition\-Test\-Def\-::is\-Enemy\-Protoss, \-Condition\-Test\-Def\-::is\-Enemy\-Terran, \-Condition\-Test\-Def\-::is\-Enemy\-Zerg, \-Condition\-Test\-Def\-::is\-Researched, \-Condition\-Test\-Def\-::is\-Researching, \-B\-W\-A\-P\-I\-::\-Player\-::is\-Researching(), \-Condition\-Test\-Def\-::is\-Upgraded, \-Condition\-Test\-Def\-::is\-Upgrading, \-B\-W\-A\-P\-I\-::\-Player\-::is\-Upgrading(), \-Map\-Helper\-::map\-Is(), \-Condition\-Test\-Def\-::map\-Is, \-Condition\-Test\-Def\-::map\-Size, m\-Extra\-Int, \-Condition\-Test\-Def\-::min\-Distance\-Between\-Mains\-Greater\-Than, \-Condition\-Test\-Def\-::min\-Distance\-Between\-Mains\-Less\-Than, m\-Needed\-Value, m\-String, m\-Tech, m\-Type, m\-Unit\-Type, m\-Upgrade, \-Condition\-Test\-Def\-::my\-Planned\-Unit\-Total\-Greater\-Equal\-Than, \-Condition\-Test\-Def\-::my\-Planned\-Unit\-Total\-Less\-Than, \-Condition\-Test\-Def\-::my\-Unit\-Total\-Build\-Count\-Greater\-Equal\-Than, \-Condition\-Test\-Def\-::my\-Unit\-Total\-Build\-Count\-Less\-Than, \-Condition\-Test\-Def\-::\-None, \-Condition\-Test\-Def\-::number\-Of\-Enemies, \-B\-W\-A\-P\-I\-::\-Races\-::\-Protoss, \-B\-W\-A\-P\-I\-::\-Game\-::self(), \-B\-W\-A\-P\-I\-::\-Races\-::\-Terran, \-Safe\-Enum$<$ def, inner $>$\-::underlying(), and \-B\-W\-A\-P\-I\-::\-Races\-::\-Zerg.



\-Referenced by evauluate().


\begin{DoxyCode}
{
        switch(mType.underlying())
        {
        case ConditionTest::myUnitTotalBuildCountGreaterEqualThan:
                return BWAPI::Broodwar->self()->deadUnitCount(mUnitType) + 
      MacroManager::Instance().getPlannedTotal(mUnitType) >= mExtraInt;
        case ConditionTest::myUnitTotalBuildCountLessThan:
                return BWAPI::Broodwar->self()->deadUnitCount(mUnitType) + 
      MacroManager::Instance().getPlannedTotal(mUnitType) < mExtraInt;
        case ConditionTest::enemyUnitCountGreaterEqualThan:
                return PlayerTracker::Instance().enemyUnitCount(mUnitType) >= 
      mExtraInt;
        case ConditionTest::enemyDoesntHasUnitLessThan:
                return PlayerTracker::Instance().enemyUnitCount(mUnitType) < 
      mExtraInt;
        case ConditionTest::minDistanceBetweenMainsLessThan:
                //return MapInformation::Instance().minMainDistance() <
       mExtraFloat;
        case ConditionTest::minDistanceBetweenMainsGreaterThan:
                //return MapInformation::Instance().minMainDistance() >
       mExtraFloat;
        case ConditionTest::None:
                return mNeededValue;
        case ConditionTest::isEnemyProtoss:
                return PlayerTracker::Instance().isEnemyRace(
      BWAPI::Races::Protoss) == mNeededValue;
        case ConditionTest::isEnemyZerg:
                return PlayerTracker::Instance().isEnemyRace(BWAPI::Races::Zerg
      ) == mNeededValue;
        case ConditionTest::isEnemyTerran:
                return PlayerTracker::Instance().isEnemyRace(
      BWAPI::Races::Terran) == mNeededValue;
        case ConditionTest::enemyHasResearched:
                return PlayerTracker::Instance().enemyHasReseached(mTech);
        case ConditionTest::mapSize:
                return BWAPI::Broodwar->getStartLocations().size() == mExtraInt
      ;
        case ConditionTest::numberOfEnemies:
                return PlayerTracker::Instance().getEnemies().size() == 
      mExtraInt;
        case ConditionTest::canForgeExpand:
                return WallTracker::Instance().canForgeExpand();
        case ConditionTest::myPlannedUnitTotalGreaterEqualThan:
                return MacroManager::Instance().getPlannedTotal(mUnitType) >= 
      mExtraInt;
        case ConditionTest::myPlannedUnitTotalLessThan:
                return MacroManager::Instance().getPlannedTotal(mUnitType) < 
      mExtraInt;
        case ConditionTest::mapIs:
                return MapHelper::mapIs(mString);
        case ConditionTest::isResearching:
                return BWAPI::Broodwar->self()->isResearching(mTech) || 
      BWAPI::Broodwar->self()->hasResearched(mTech);
        case ConditionTest::isResearched:
                return BWAPI::Broodwar->self()->hasResearched(mTech);
        case ConditionTest::isUpgrading:
                return BWAPI::Broodwar->self()->isUpgrading(mUpgrade) && (
      mExtraInt == 1 || BWAPI::Broodwar->self()->getUpgradeLevel(mUpgrade) == 
      mExtraInt-1);
        case ConditionTest::isUpgraded:
                return BWAPI::Broodwar->self()->getUpgradeLevel(mUpgrade) == 
      mExtraInt;
        }
        return false;
}
\end{DoxyCode}


\-Here is the call graph for this function\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{structCondition_a52c3090c83be44ef2c25a03c085543fa_cgraph}
\end{center}
\end{figure}




\-Here is the caller graph for this function\-:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{structCondition_a52c3090c83be44ef2c25a03c085543fa_icgraph}
\end{center}
\end{figure}




\subsection{\-Member \-Data \-Documentation}
\hypertarget{structCondition_a302acfc53b5bcf0899be97a38d37edd7}{\index{\-Condition@{\-Condition}!m\-Extra\-Double@{m\-Extra\-Double}}
\index{m\-Extra\-Double@{m\-Extra\-Double}!Condition@{\-Condition}}
\subsubsection[{m\-Extra\-Double}]{\setlength{\rightskip}{0pt plus 5cm}double {\bf \-Condition\-::m\-Extra\-Double}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a302acfc53b5bcf0899be97a38d37edd7}


\-Definition at line 124 of file \-Condition.\-h.



\-Referenced by operator=().

\hypertarget{structCondition_ae77e7c2401f44222ded87864836fa613}{\index{\-Condition@{\-Condition}!m\-Extra\-Int@{m\-Extra\-Int}}
\index{m\-Extra\-Int@{m\-Extra\-Int}!Condition@{\-Condition}}
\subsubsection[{m\-Extra\-Int}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf \-Condition\-::m\-Extra\-Int}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_ae77e7c2401f44222ded87864836fa613}


\-Definition at line 123 of file \-Condition.\-h.



\-Referenced by operator=(), and passes\-Value().

\hypertarget{structCondition_a15d544f10d4ed9fbf0d34a3b5d44fe6e}{\index{\-Condition@{\-Condition}!m\-L\-Condition@{m\-L\-Condition}}
\index{m\-L\-Condition@{m\-L\-Condition}!Condition@{\-Condition}}
\subsubsection[{m\-L\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}boost\-::scoped\-\_\-ptr$<${\bf \-Condition}$>$ {\bf \-Condition\-::m\-L\-Condition}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a15d544f10d4ed9fbf0d34a3b5d44fe6e}


\-Definition at line 119 of file \-Condition.\-h.



\-Referenced by evauluate(), and operator=().

\hypertarget{structCondition_a44e25c31a8176ae6fbdf8010c3724b3d}{\index{\-Condition@{\-Condition}!m\-Needed\-Value@{m\-Needed\-Value}}
\index{m\-Needed\-Value@{m\-Needed\-Value}!Condition@{\-Condition}}
\subsubsection[{m\-Needed\-Value}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf \-Condition\-::m\-Needed\-Value}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a44e25c31a8176ae6fbdf8010c3724b3d}


\-Definition at line 122 of file \-Condition.\-h.



\-Referenced by operator=(), and passes\-Value().

\hypertarget{structCondition_a0c4c6f75344ba14f06d0cbece4cb6860}{\index{\-Condition@{\-Condition}!m\-Operator\-Type@{m\-Operator\-Type}}
\index{m\-Operator\-Type@{m\-Operator\-Type}!Condition@{\-Condition}}
\subsubsection[{m\-Operator\-Type}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Operator\-Type} {\bf \-Condition\-::m\-Operator\-Type}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a0c4c6f75344ba14f06d0cbece4cb6860}


\-Definition at line 118 of file \-Condition.\-h.



\-Referenced by evauluate(), and operator=().

\hypertarget{structCondition_a68ee5c1ee5db0adae443bcb19aa4b102}{\index{\-Condition@{\-Condition}!m\-R\-Condition@{m\-R\-Condition}}
\index{m\-R\-Condition@{m\-R\-Condition}!Condition@{\-Condition}}
\subsubsection[{m\-R\-Condition}]{\setlength{\rightskip}{0pt plus 5cm}boost\-::scoped\-\_\-ptr$<${\bf \-Condition}$>$ {\bf \-Condition\-::m\-R\-Condition}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a68ee5c1ee5db0adae443bcb19aa4b102}


\-Definition at line 120 of file \-Condition.\-h.



\-Referenced by evauluate(), and operator=().

\hypertarget{structCondition_a3a672bc99bd647965bcfd3ae9888f1a6}{\index{\-Condition@{\-Condition}!m\-String@{m\-String}}
\index{m\-String@{m\-String}!Condition@{\-Condition}}
\subsubsection[{m\-String}]{\setlength{\rightskip}{0pt plus 5cm}std\-::string {\bf \-Condition\-::m\-String}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a3a672bc99bd647965bcfd3ae9888f1a6}


\-Definition at line 129 of file \-Condition.\-h.



\-Referenced by operator=(), and passes\-Value().

\hypertarget{structCondition_a8c1846c5c7aaee4b86acc21f7a191474}{\index{\-Condition@{\-Condition}!m\-Tech@{m\-Tech}}
\index{m\-Tech@{m\-Tech}!Condition@{\-Condition}}
\subsubsection[{m\-Tech}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-B\-W\-A\-P\-I\-::\-Tech\-Type} {\bf \-Condition\-::m\-Tech}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a8c1846c5c7aaee4b86acc21f7a191474}


\-Definition at line 127 of file \-Condition.\-h.



\-Referenced by operator=(), and passes\-Value().

\hypertarget{structCondition_a7bbc3eb4bc4f93c4b84cd8117e29c521}{\index{\-Condition@{\-Condition}!m\-Type@{m\-Type}}
\index{m\-Type@{m\-Type}!Condition@{\-Condition}}
\subsubsection[{m\-Type}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-Condition\-Test} {\bf \-Condition\-::m\-Type}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a7bbc3eb4bc4f93c4b84cd8117e29c521}


\-Definition at line 116 of file \-Condition.\-h.



\-Referenced by operator=(), and passes\-Value().

\hypertarget{structCondition_ac65d6ec914e81ee1386c876419ddcb55}{\index{\-Condition@{\-Condition}!m\-Unit\-Type@{m\-Unit\-Type}}
\index{m\-Unit\-Type@{m\-Unit\-Type}!Condition@{\-Condition}}
\subsubsection[{m\-Unit\-Type}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-B\-W\-A\-P\-I\-::\-Unit\-Type} {\bf \-Condition\-::m\-Unit\-Type}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_ac65d6ec914e81ee1386c876419ddcb55}


\-Definition at line 126 of file \-Condition.\-h.



\-Referenced by operator=(), and passes\-Value().

\hypertarget{structCondition_a375ec1b2f899c8436d43c8a6d2e7b21d}{\index{\-Condition@{\-Condition}!m\-Upgrade@{m\-Upgrade}}
\index{m\-Upgrade@{m\-Upgrade}!Condition@{\-Condition}}
\subsubsection[{m\-Upgrade}]{\setlength{\rightskip}{0pt plus 5cm}{\bf \-B\-W\-A\-P\-I\-::\-Upgrade\-Type} {\bf \-Condition\-::m\-Upgrade}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}\label{structCondition_a375ec1b2f899c8436d43c8a6d2e7b21d}


\-Definition at line 128 of file \-Condition.\-h.



\-Referenced by operator=(), and passes\-Value().



\-The documentation for this struct was generated from the following files\-:\begin{DoxyCompactItemize}
\item 
\-Skynet/\-Skynet/\hyperlink{Condition_8h}{\-Condition.\-h}\item 
\-Skynet/\-Skynet/\hyperlink{Condition_8cpp}{\-Condition.\-cpp}\end{DoxyCompactItemize}
