the game where you go into mines and start crafting! but for consoles (forked directly from smartcmd's github)
at main 33 lines 913 B view raw
1#include "stdafx.h" 2#include "net.minecraft.world.level.h" 3#include "net.minecraft.world.entity.ai.attributes.h" 4#include "net.minecraft.world.entity.monster.h" 5#include "Giant.h" 6#include "..\Minecraft.Client\Textures.h" 7 8 9 10Giant::Giant(Level *level) : Monster( level ) 11{ 12 // 4J Stu - This function call had to be moved here from the Entity ctor to ensure that 13 // the derived version of the function is called 14 this->defineSynchedData(); 15 registerAttributes(); 16 17 heightOffset*=6; 18 setSize(bbWidth * 6, bbHeight * 6); 19} 20 21void Giant::registerAttributes() 22{ 23 Monster::registerAttributes(); 24 25 getAttribute(SharedMonsterAttributes::MAX_HEALTH)->setBaseValue(100); 26 getAttribute(SharedMonsterAttributes::MOVEMENT_SPEED)->setBaseValue(0.5f); 27 getAttribute(SharedMonsterAttributes::ATTACK_DAMAGE)->setBaseValue(50); 28} 29 30float Giant::getWalkTargetValue(int x, int y, int z) 31{ 32 return level->getBrightness(x, y, z)-0.5f; 33}