feat: remove experience

This commit is contained in:
str1k3r committed 2026-09-26 17:17:51 -04:00
1 parent bdfe5350cd
commit 41d166afed
83 files changed
+47 -1501

No files matched your search

+1 -2
View File
@@ -153,7 +153,7 @@ void EnchantmentMenu::slotsChanged() // 4J used to take a shared_ptr<Container>
bool EnchantmentMenu::clickMenuButton(shared_ptr<Player> player, int i)
{
shared_ptr<ItemInstance> item = enchantSlots->getItem(0);
if (costs[i] > 0 && item != NULL && (player->experienceLevel >= costs[i] || player->abilities.instabuild) )
if (costs[i] > 0 && item != NULL && (player->abilities.instabuild) )
{
if (!level->isClientSide)
{
@@ -162,7 +162,6 @@ bool EnchantmentMenu::clickMenuButton(shared_ptr<Player> player, int i)
vector<EnchantmentInstance *> *newEnchantment = EnchantmentHelper::selectEnchantment(&random, item, costs[i]);
if (newEnchantment != NULL)
{
player->withdrawExperienceLevels(costs[i]);
if (isBook) item->id = Item::enchantedBook_Id;
int randomIndex = isBook ? random.nextInt(newEnchantment->size()) : -1;
//for (EnchantmentInstance e : newEnchantment)