diff options
author | LaG1924 <12997935+LaG1924@users.noreply.github.com> | 2017-08-16 17:11:07 +0200 |
---|---|---|
committer | LaG1924 <12997935+LaG1924@users.noreply.github.com> | 2017-08-16 17:11:07 +0200 |
commit | dee50239be8fff566b3ca687bc70900b391a8164 (patch) | |
tree | 6ff6ae2e8e2ea5109d031be8c588f4b8f38f68eb /src/Entity.hpp | |
parent | 2017-08-12 (diff) | |
download | AltCraft-dee50239be8fff566b3ca687bc70900b391a8164.tar AltCraft-dee50239be8fff566b3ca687bc70900b391a8164.tar.gz AltCraft-dee50239be8fff566b3ca687bc70900b391a8164.tar.bz2 AltCraft-dee50239be8fff566b3ca687bc70900b391a8164.tar.lz AltCraft-dee50239be8fff566b3ca687bc70900b391a8164.tar.xz AltCraft-dee50239be8fff566b3ca687bc70900b391a8164.tar.zst AltCraft-dee50239be8fff566b3ca687bc70900b391a8164.zip |
Diffstat (limited to 'src/Entity.hpp')
-rw-r--r-- | src/Entity.hpp | 138 |
1 files changed, 132 insertions, 6 deletions
diff --git a/src/Entity.hpp b/src/Entity.hpp index 6df7983..c818abe 100644 --- a/src/Entity.hpp +++ b/src/Entity.hpp @@ -3,12 +3,138 @@ #include "Utility.hpp" #include "Vector.hpp" +enum class ObjectType{ + Boat=1, + ItemStack, + AreaEffectCloud, + Minecart=10, + ActivatedTNT=50, + EnderCrystal, + TippedArrow=60, + Snowball, + Egg, + FireBall, + FireCharge, + ThrownEnderpearl, + WitherSkull, + ShulkerBullet, + LlamaSpit, + FallingObjects=70, + Itemframes, + EyeOfEnder, + ThrownPotion, + ThrownExpBottle=75, + FireworkRocket, + LeashKnot, + ArmorStand, + EvocationFangs, + FishingHook=90, + SpectralArrow, + DragonFireball=93, +}; + +enum MobType { + Item = 1, + XPOrb, + AreaEffectCloud, + ElderGuardian, + WitherSkeleton, + Stray, + ThrownEgg, + LeashKnot, + Painting, + Arrow, + Snowball, + Fireball, + SmallFireball, + ThrownEnderpearl, + EyeOfEnderSignal, + ThrownPotion, + ThrownExpBottle, + ItemFrame, + WitherSkull, + PrimedTnt, + FallingSand, + FireworksRocketEntity, + Husk, + SpectralArrow, + ShulkerBullet, + DragonFireball, + ZombieVillager, + SkeletonHorse, + ZombieHorse, + ArmorStand, + Donkey, + Mule, + EvocationFangs, + EvocationIllager, + Vex, + VindicationIllager, + IllusionIllager, + MinecartCommandBlock=40, + Boat, + MinecartRideable, + MinecartChest, + MinecartFurnace, + MinecartTNT, + MinecartHopper, + MinecartSpawner, + Creeper=50, + Skeleton, + Spider, + Giant, + Zombie, + Slime, + Ghast, + PigZombie, + Enderman, + CaveSpider, + Silverfish, + Blaze, + LavaSlime, + EnderDragon, + WitherBoss, + Bat, + Witch, + Endermite, + Guardian, + Shulker, + Pig=90, + Sheep, + Cow, + Chicken, + Squid, + Wolf, + MushroomCow, + SnowMan, + Ozelot, + VillagerGolem, + Horse, + Rabbit, + PolarBear, + Llama, + LlamaSpit, + Parrot, + Villager=120, + EnderCrystal=200, +}; + struct Entity { Uuid uuid; - VectorF pos; - VectorF vel; - unsigned int entityId; - double yaw; - double pitch; + VectorF pos = 0; + VectorF vel = 0; + unsigned int entityId = 0; + double yaw = 0; + double pitch = 0; + double width = 1.0; + double height = 1.0; + glm::vec3 renderColor; + int entityType=0; + bool isMob=false; static VectorF DecodeVelocity(short x, short y, short z); -};
\ No newline at end of file + static VectorF DecodeDeltaPos(short deltaX, short deltaY, short deltaZ); +}; + +Entity CreateObject(ObjectType type); + +Entity CreateMob(MobType type);
\ No newline at end of file |