mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-05-12 04:03:53 +00:00
Revert "Project modernization (#630)"
This code was not tested and breaks in Release builds, reverting to restore
functionality of the nightly. All in-game menus do not work and generating
a world crashes.
This reverts commit a9be52c41a.
This commit is contained in:
parent
a9be52c41a
commit
087b7e7abf
1373 changed files with 19449 additions and 19903 deletions
|
|
@ -62,7 +62,7 @@ void ModifiableAttributeInstance::getModifiers(unordered_set<AttributeModifier *
|
|||
|
||||
AttributeModifier *ModifiableAttributeInstance::getModifier(eMODIFIER_ID id)
|
||||
{
|
||||
AttributeModifier *modifier = nullptr;
|
||||
AttributeModifier *modifier = NULL;
|
||||
|
||||
auto it = modifierById.find(id);
|
||||
if(it != modifierById.end())
|
||||
|
|
@ -85,7 +85,7 @@ void ModifiableAttributeInstance::addModifiers(unordered_set<AttributeModifier *
|
|||
void ModifiableAttributeInstance::addModifier(AttributeModifier *modifier)
|
||||
{
|
||||
// Can't add modifiers with the same ID (unless the modifier is anonymous)
|
||||
if (modifier->getId() != eModifierId_ANONYMOUS && getModifier(modifier->getId()) != nullptr)
|
||||
if (modifier->getId() != eModifierId_ANONYMOUS && getModifier(modifier->getId()) != NULL)
|
||||
{
|
||||
assert(0);
|
||||
// throw new IllegalArgumentException("Modifier is already applied on this attribute!");
|
||||
|
|
@ -126,7 +126,7 @@ void ModifiableAttributeInstance::removeModifier(AttributeModifier *modifier)
|
|||
void ModifiableAttributeInstance::removeModifier(eMODIFIER_ID id)
|
||||
{
|
||||
AttributeModifier *modifier = getModifier(id);
|
||||
if (modifier != nullptr) removeModifier(modifier);
|
||||
if (modifier != NULL) removeModifier(modifier);
|
||||
}
|
||||
|
||||
void ModifiableAttributeInstance::removeModifiers()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue