mirror of
https://github.com/neoStudiosLCE/neoLegacy.git
synced 2026-07-08 13:47:02 +00:00
Merge branch 'neoStudiosLCE:main' into dlc-skin-corrections
This commit is contained in:
commit
e048395679
|
|
@ -26,6 +26,7 @@ void Creeper::_init()
|
|||
oldSwell = 0;
|
||||
maxSwell = 30;
|
||||
explosionRadius = 3;
|
||||
ignited = false;
|
||||
}
|
||||
|
||||
Creeper::Creeper(Level *level) : Monster( level )
|
||||
|
|
@ -190,3 +191,38 @@ void Creeper::thunderHit(const LightningBolt *lightningBolt)
|
|||
Monster::thunderHit(lightningBolt);
|
||||
entityData->set(DATA_IS_POWERED, static_cast<byte>(1));
|
||||
}
|
||||
|
||||
void Creeper::Ignite()
|
||||
{
|
||||
setSwellDir(1);
|
||||
ignited = true;
|
||||
}
|
||||
|
||||
bool Creeper::isIgnited()
|
||||
{
|
||||
return ignited;
|
||||
}
|
||||
|
||||
bool Creeper::mobInteract(shared_ptr<Player> player)
|
||||
{
|
||||
shared_ptr<ItemInstance> item = player->inventory->getSelected();
|
||||
|
||||
if (item == nullptr || item->id != Item::flintAndSteel_Id)
|
||||
return Mob::mobInteract(player);
|
||||
|
||||
playSound(eSoundType_FIRE_NEWIGNITE, 1, random->nextFloat() * 0.4f + 0.8f);
|
||||
player->swing();
|
||||
|
||||
if (!level->isClientSide)
|
||||
{
|
||||
if (!isIgnited())
|
||||
{
|
||||
Ignite();
|
||||
item->hurtAndBreak(1, player);
|
||||
return true;
|
||||
}
|
||||
return Mob::mobInteract(player);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,6 +21,8 @@ private:
|
|||
int maxSwell;
|
||||
int explosionRadius;
|
||||
|
||||
bool ignited;
|
||||
|
||||
void _init();
|
||||
|
||||
public:
|
||||
|
|
@ -34,6 +36,8 @@ public:
|
|||
|
||||
virtual int getMaxFallDistance();
|
||||
|
||||
virtual bool mobInteract(shared_ptr<Player> player);
|
||||
|
||||
protected:
|
||||
virtual void causeFallDamage(float distance);
|
||||
virtual void defineSynchedData();
|
||||
|
|
@ -61,5 +65,9 @@ protected:
|
|||
public:
|
||||
int getSwellDir();
|
||||
void setSwellDir(int dir);
|
||||
void thunderHit(const LightningBolt *lightningBolt) ;
|
||||
void thunderHit(const LightningBolt *lightningBolt);
|
||||
|
||||
public:
|
||||
void Ignite();
|
||||
bool isIgnited();
|
||||
};
|
||||
|
|
|
|||
|
|
@ -32,6 +32,12 @@ void SwellGoal::stop()
|
|||
|
||||
void SwellGoal::tick()
|
||||
{
|
||||
if(creeper->isIgnited())
|
||||
{
|
||||
creeper->setSwellDir(1);
|
||||
return;
|
||||
}
|
||||
|
||||
if (target.lock() == nullptr)
|
||||
{
|
||||
creeper->setSwellDir(-1);
|
||||
|
|
|
|||
|
|
@ -156,7 +156,7 @@ bool Villager::mobInteract(shared_ptr<Player> player)
|
|||
shared_ptr<ItemInstance> item = player->inventory->getSelected();
|
||||
bool holdingSpawnEgg = item != nullptr && item->id == Item::spawnEgg_Id;
|
||||
|
||||
if (!holdingSpawnEgg && isAlive() && !isTrading() && !isBaby())
|
||||
if (!player->isSneaking() && !holdingSpawnEgg && isAlive() && !isTrading() && !isBaby())
|
||||
{
|
||||
if (!level->isClientSide)
|
||||
{
|
||||
|
|
@ -776,3 +776,19 @@ wstring Villager::getDisplayName()
|
|||
};
|
||||
return app.GetString(name);
|
||||
}
|
||||
|
||||
void Villager::thunderHit(const LightningBolt *lightningBolt)
|
||||
{
|
||||
if (level->isClientSide) return;
|
||||
shared_ptr<Witch> witch = std::make_shared<Witch>(level);
|
||||
witch->moveTo(x, y, z, yRot, xRot);
|
||||
|
||||
if (this->hasCustomName())
|
||||
witch->setCustomName(this->getCustomName());
|
||||
|
||||
if (this->isPersistenceRequired())
|
||||
witch->setPersistenceRequired();
|
||||
|
||||
level->addEntity(witch);
|
||||
remove();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -147,4 +147,5 @@ public:
|
|||
virtual shared_ptr<AgableMob> getBreedOffspring(shared_ptr<AgableMob> target);
|
||||
virtual bool canBeLeashed();
|
||||
virtual wstring getDisplayName();
|
||||
virtual void thunderHit(const LightningBolt *lightningBolt);
|
||||
};
|
||||
14
NOTES.md
14
NOTES.md
|
|
@ -1,8 +1,16 @@
|
|||
# neoLegacy v1.0.3b
|
||||
# neoLegacy v1.0.4b
|
||||
|
||||
- Fixed a crash when running the server software on Linux via Wine.
|
||||
### Bug Fixes
|
||||
- Fixed Podzol bottom face displaying incorrect texture (was using side texture instead of dirt)
|
||||
|
||||
<img width="784" height="410" alt="image" src="https://github.com/user-attachments/assets/3731d5b4-b2d6-4c62-ab52-2e241fb7dcb4" />
|
||||
### Changes
|
||||
- Cursor icon now changes when hovering over different UI elements
|
||||
- Added TU31 parity changes which include:
|
||||
- Creepers can now be ignited with Flint and Steel
|
||||
- Village gravel roads now have Cobblestone underneath
|
||||
- Villagers now transform into Witches when struck by lightning
|
||||
|
||||
<img width="784" height="410" alt="roadmap" src="https://github.com/user-attachments/assets/134856ae-b151-4003-aa97-7ecf19ccd278" />
|
||||
|
||||
# Download
|
||||
Get the latest build from [LCE Emerald Launcher](https://github.com/LCE-Hub/LCE-Emerald-Launcher/releases) or the upcoming LC Launcher.
|
||||
|
|
|
|||
|
|
@ -21,8 +21,8 @@ Users can download our [Nightly Build](https://github.com/pieeebot/neoLegacy/rel
|
|||
Huge thanks to the following projects:
|
||||
|
||||
- [Patoke/LCERenewed](https://github.com/Patoke/LCERenewed) - for some of the patches that required deep decompilation
|
||||
- [itsRevela/LCE-Revelations](https://github.com/itsRevela/LCE-Revelations) - for providing a stable project for neoLegacy to continue with
|
||||
- [GabsPuNs/MinecraftConsoles](https://github.com/GabsPuNs/MinecraftConsoles) - for providing us with their implemention of the Classic Crafting Feature.
|
||||
- [itsRevela/LCE-Revelations](https://git.revela.dev/itsRevela/LCE-Revelations) - for providing a stable project for neoLegacy to continue with
|
||||
- [GabsPuNs/Project-Zenith](https://github.com/GabsPuNs/Project-Zenith-Main) - for providing us with their implemention of the Classic Crafting Feature.
|
||||
|
||||
# Build & Run
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue