remove unused function GetNeededMatStr

qteditor
Maikel de Vries 2016-04-30 14:00:10 +02:00
parent c820dac7c3
commit 5841b55f7e
6 changed files with 0 additions and 68 deletions

View File

@ -1,22 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!DOCTYPE funcs
SYSTEM '../../../clonk.dtd'>
<?xml-stylesheet type="text/xsl" href="../../../clonk.xsl"?>
<funcs>
<func>
<title>GetNeededMatStr</title>
<category>Objects</category>
<subcat>Status</subcat>
<version>5.1 OC</version>
<syntax>
<rtype>string</rtype>
</syntax>
<desc>Returns the still needed construction materials of an object.</desc>
<related>
<funclink>GetComponent</funclink>
<funclink>GetCon</funclink>
<funclink>ComponentAll</funclink>
</related>
</func>
<author>wipfmetz</author><date>2002-08</date>
</funcs>

View File

@ -87,7 +87,6 @@ IDS_COMM_UNGRAB=Loslassen
IDS_COMM_WAIT=Warten
IDS_CON_BUILD=%s bauen.
IDS_CON_BUILDMATNEED=%s|braucht noch
IDS_CON_BUILDMATNONE=%s braucht kein|weiteres Baumaterial.
IDS_CON_FAILURE=%s|nicht möglich!
IDS_CON_FAILUREOF=%s von %s|nicht möglich!
IDS_CON_HELP=Hilfe

View File

@ -87,7 +87,6 @@ IDS_COMM_UNGRAB=Let go
IDS_COMM_WAIT=Wait
IDS_CON_BUILD=Build %s.
IDS_CON_BUILDMATNEED=%s|needs
IDS_CON_BUILDMATNONE=%s needs|no more material.
IDS_CON_FAILURE=%s failed!
IDS_CON_FAILUREOF=%s of %s failed!
IDS_CON_HELP=Help

View File

@ -4945,42 +4945,6 @@ void C4Object::UpdateScriptPointers()
pEffects->ReAssignAllCallbackFunctions();
}
StdStrBuf C4Object::GetNeededMatStr() const
{
C4Def* pComponent;
int32_t cnt, ncnt;
StdStrBuf NeededMats;
C4IDList NeededComponents;
Def->GetComponents(&NeededComponents, NULL);
C4ID idComponent;
for (cnt = 0; (idComponent=NeededComponents.GetID(cnt)); cnt ++)
{
if (NeededComponents.GetCount(cnt)!=0)
{
ncnt = NeededComponents.GetCount(cnt) - Component.GetIDCount(idComponent);
if (ncnt > 0)
{
NeededMats.AppendFormat("|%dx ", ncnt);
if ((pComponent = C4Id2Def(idComponent)))
NeededMats.Append(pComponent->GetName());
else
NeededMats.Append(idComponent.ToString());
}
}
}
StdStrBuf result;
if (!!NeededMats)
{ result.Format(LoadResStr("IDS_CON_BUILDMATNEED"), GetName()); result.Append(NeededMats.getData()); }
else
result.Format(LoadResStr("IDS_CON_BUILDMATNONE"), GetName());
return result;
}
bool C4Object::IsPlayerObject(int32_t iPlayerNumber) const
{
bool fAnyPlr = (iPlayerNumber == NO_OWNER);

View File

@ -381,8 +381,6 @@ public:
bool IsMoveableBySolidMask(int ComparisonPlane) const;
StdStrBuf GetNeededMatStr() const;
// This function is used for:
// -Objects to be removed when a player is removed
// -Objects that are not to be saved in "SaveScenario"-mode

View File

@ -1251,11 +1251,6 @@ static C4Object *FnComposeContents(C4Object *Obj, C4ID c_id)
return Obj->ComposeContents(c_id);
}
static C4String *FnGetNeededMatStr(C4Object *Obj)
{
return String(Obj->GetNeededMatStr().getData());
}
static bool FnMakeCrewMember(C4Object *Obj, long iPlayer)
{
if (!ValidPlr(iPlayer)) return false;
@ -2645,7 +2640,6 @@ void InitObjectFunctionMap(C4AulScriptEngine *pEngine)
F(CreateContents);
F(ShiftContents);
F(ComposeContents);
F(GetNeededMatStr);
F(GetID);
F(Contents);
F(ScrollContents);