forked from Mirrors/openclonk
C4Id: Removed some deprecated defitions
These are not used anymore in openclonk, if there is any need for the functionalitiy at all, it can be implemented in C4Script. To remove the other definitions some more work is required.
parent
6a17914955
commit
32993624c0
|
@ -3286,7 +3286,6 @@ void C4Game::UpdateRules()
|
|||
if (::Game.iTick255) return;
|
||||
Rules=0;
|
||||
if (ObjectCount(C4ID::CnMaterial)) Rules|=C4RULE_ConstructionNeedsMaterial;
|
||||
if (ObjectCount(C4ID::FlagRemvbl)) Rules|=C4RULE_FlagRemoveable;
|
||||
if (ObjectCount(C4ID::StructuresSnowIn)) Rules|=C4RULE_StructuresSnowIn;
|
||||
}
|
||||
|
||||
|
|
|
@ -313,8 +313,7 @@ public:
|
|||
|
||||
const int32_t
|
||||
C4RULE_ConstructionNeedsMaterial = 1,
|
||||
C4RULE_FlagRemoveable = 2,
|
||||
C4RULE_StructuresSnowIn = 4;
|
||||
C4RULE_StructuresSnowIn = 2;
|
||||
|
||||
extern C4Game Game;
|
||||
|
||||
|
|
|
@ -282,7 +282,6 @@ void C4RoundResults::EvaluateGoals(C4IDList &GoalList, C4IDList &FulfilledGoalLi
|
|||
// clear prev
|
||||
GoalList.Clear(); FulfilledGoalList.Clear();
|
||||
// Items
|
||||
bool fRivalvry = !!Game.ObjectCount(C4ID::Rivalry);
|
||||
int32_t cnt; C4ID idGoal;
|
||||
for (cnt=0; (idGoal=::Objects.GetListID(C4D_Goal,cnt)); cnt++)
|
||||
{
|
||||
|
@ -290,15 +289,7 @@ void C4RoundResults::EvaluateGoals(C4IDList &GoalList, C4IDList &FulfilledGoalLi
|
|||
bool fFulfilled = false;;
|
||||
C4Object *pObj;
|
||||
if ((pObj = ::Objects.Find(idGoal)))
|
||||
{
|
||||
if (fRivalvry)
|
||||
{
|
||||
C4AulParSet pars(C4VInt(iPlayerNumber));
|
||||
fFulfilled = !!pObj->Call(PSF_IsFulfilledforPlr, &pars);
|
||||
}
|
||||
else
|
||||
fFulfilled = !!pObj->Call(PSF_IsFulfilled);
|
||||
}
|
||||
fFulfilled = !!pObj->Call(PSF_IsFulfilled);
|
||||
GoalList.SetIDCount(idGoal, cnt, true);
|
||||
if (fFulfilled) FulfilledGoalList.SetIDCount(idGoal, 1, true);
|
||||
}
|
||||
|
|
|
@ -612,9 +612,7 @@ bool C4TeamList::Load(C4Group &hGroup, class C4Scenario *pInitDefault, class C4L
|
|||
if (!pInitDefault) return false;
|
||||
// no teams defined: Activate default melee teams if a melee rule is found
|
||||
// default: FFA for anything that looks like melee
|
||||
if ( pInitDefault->Game.Goals.GetIDCount(C4ID::Melee, 1)
|
||||
|| pInitDefault->Game.Rules.GetIDCount(C4ID::Rivalry, 1)
|
||||
|| pInitDefault->Game.Goals.GetIDCount(C4ID::TeamworkMelee, 1))
|
||||
if ( pInitDefault->Game.Goals.GetIDCount(C4ID::Melee, 1))
|
||||
{
|
||||
fAllowHostilityChange = true;
|
||||
fActive = true;
|
||||
|
|
|
@ -526,7 +526,7 @@ void C4SDefinitions::CompileFunc(StdCompiler *pComp)
|
|||
|
||||
bool C4SGame::IsMelee()
|
||||
{
|
||||
return (Goals.GetIDCount(C4ID::Melee) || Goals.GetIDCount(C4ID::TeamworkMelee));
|
||||
return (Goals.GetIDCount(C4ID::Melee));
|
||||
}
|
||||
|
||||
// scenario sections
|
||||
|
|
|
@ -38,15 +38,10 @@ const C4ID C4ID::Contents(std::string("Contents"));
|
|||
const C4ID C4ID::StructuresSnowIn(std::string("STSN"));
|
||||
const C4ID C4ID::CnMaterial(std::string("CNMT"));
|
||||
const C4ID C4ID::Flag(std::string("FLAG"));
|
||||
const C4ID C4ID::FlagRemvbl(std::string("FGRV"));
|
||||
const C4ID C4ID::Conkit(std::string("CNKT"));
|
||||
const C4ID C4ID::Clonk(std::string("Clonk"));
|
||||
const C4ID C4ID::Flame(std::string("FLAM"));
|
||||
const C4ID C4ID::Meteor(std::string("METO"));
|
||||
const C4ID C4ID::Blast(std::string("FXB1"));
|
||||
const C4ID C4ID::Melee(std::string("MELE"));
|
||||
const C4ID C4ID::TeamworkMelee(std::string("MEL2"));
|
||||
const C4ID C4ID::Rivalry(std::string("RVLR"));
|
||||
const C4ID C4ID::Bubble(std::string("Fx_Bubble"));
|
||||
|
||||
C4ID::C4ID(const std::string &s) { assign(s); }
|
||||
|
|
|
@ -54,15 +54,10 @@ public:
|
|||
DEPRECATED static const C4ID CnMaterial; // Buildings need construction material
|
||||
DEPRECATED static const C4ID StructuresSnowIn;
|
||||
DEPRECATED static const C4ID Flag;
|
||||
DEPRECATED static const C4ID FlagRemvbl; // Flag removable
|
||||
DEPRECATED static const C4ID Conkit; // Construction kit
|
||||
DEPRECATED static const C4ID Clonk;
|
||||
DEPRECATED static const C4ID Flame;
|
||||
DEPRECATED static const C4ID Meteor;
|
||||
DEPRECATED static const C4ID Blast;
|
||||
DEPRECATED static const C4ID Melee;
|
||||
DEPRECATED static const C4ID TeamworkMelee;
|
||||
DEPRECATED static const C4ID Rivalry;
|
||||
DEPRECATED static const C4ID Bubble;
|
||||
|
||||
C4ID(): v(None.v) {}
|
||||
|
|
Loading…
Reference in New Issue