diff options
| author | Ethryan <dborrfors@gmail.com> | 2017-07-23 14:13:19 +0200 |
|---|---|---|
| committer | Ethryan <dborrfors@gmail.com> | 2017-07-23 14:13:19 +0200 |
| commit | 9698f77fd04e8ad04c462fe6e6f76a7ebd25e0fa (patch) | |
| tree | f3f718112f5049e137f505598ec6b81dea8675e9 /src/main/java/com/detrav/events | |
| parent | 6b5540c9a943eab1803857c3c83912cebac5fa37 (diff) | |
| download | GT5-Unofficial-9698f77fd04e8ad04c462fe6e6f76a7ebd25e0fa.tar.gz GT5-Unofficial-9698f77fd04e8ad04c462fe6e6f76a7ebd25e0fa.tar.bz2 GT5-Unofficial-9698f77fd04e8ad04c462fe6e6f76a7ebd25e0fa.zip | |
Only keep the Scanners
Diffstat (limited to 'src/main/java/com/detrav/events')
4 files changed, 0 insertions, 2277 deletions
diff --git a/src/main/java/com/detrav/events/DetravCraftingEventHandler.java b/src/main/java/com/detrav/events/DetravCraftingEventHandler.java deleted file mode 100644 index 0350b9b7b7..0000000000 --- a/src/main/java/com/detrav/events/DetravCraftingEventHandler.java +++ /dev/null @@ -1,46 +0,0 @@ -package com.detrav.events; - -import com.detrav.utils.DetravRepairRecipe; -import cpw.mods.fml.common.FMLCommonHandler; -import cpw.mods.fml.common.eventhandler.SubscribeEvent; -import cpw.mods.fml.common.gameevent.PlayerEvent; -import gregtech.api.util.GT_Utility; -import net.minecraft.inventory.InventoryCrafting; -import net.minecraft.item.ItemStack; -import net.minecraftforge.common.MinecraftForge; - -/** - * Created by Detrav on 02.10.2016. - */ -public class DetravCraftingEventHandler { - @SubscribeEvent - public void onCrafting(PlayerEvent.ItemCraftedEvent e) { - if(DetravRepairRecipe.INSTANCE == null) return; - if(!(e.craftMatrix instanceof InventoryCrafting)) return; - if(DetravRepairRecipe.INSTANCE.matches((InventoryCrafting) e.craftMatrix,null)) - { - if(!GT_Utility.areStacksEqual(e.crafting, e.craftMatrix.getStackInSlot(4),true)) return; - for(int i =0; i<e.craftMatrix.getSizeInventory(); i++) { - ItemStack stack = e.craftMatrix.getStackInSlot(i); - if(stack == null) continue; - if (stack.stackSize < 2) - e.craftMatrix.setInventorySlotContents(i, null); - else { - //stack.stackSize -= 1; - //e.craftMatrix.setInventorySlotContents(i,stack); - } - } - } - } - - static boolean inited = false; - - public static void register() { - if (!inited) { - inited = true; - DetravCraftingEventHandler handler = new DetravCraftingEventHandler(); - MinecraftForge.EVENT_BUS.register(handler); - FMLCommonHandler.instance().bus().register(handler); - } - } -} diff --git a/src/main/java/com/detrav/events/DetravDrawBlockHighlightEventHandler.java b/src/main/java/com/detrav/events/DetravDrawBlockHighlightEventHandler.java deleted file mode 100644 index 25b29c8e96..0000000000 --- a/src/main/java/com/detrav/events/DetravDrawBlockHighlightEventHandler.java +++ /dev/null @@ -1,268 +0,0 @@ -package com.detrav.events; - -import cpw.mods.fml.common.FMLCommonHandler; -import cpw.mods.fml.common.eventhandler.SubscribeEvent; -import net.minecraft.block.Block; -import net.minecraft.client.Minecraft; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.init.Blocks; -import net.minecraft.item.ItemStack; -import net.minecraft.util.AxisAlignedBB; -import net.minecraft.util.MovingObjectPosition; -import net.minecraftforge.client.event.DrawBlockHighlightEvent; -import net.minecraftforge.common.MinecraftForge; -import org.lwjgl.opengl.GL11; - -import static org.lwjgl.opengl.GL11.GL_TRIANGLES; -//import net.minecraftforge.client.event.RenderWorldLastEvent; - -/** - * Created by wital_000 on 18.04.2016. - */ -public class DetravDrawBlockHighlightEventHandler { - - public static long modeBlockBreak = 0L; - public static boolean disableDepthBuffer = false; - public static float thickness = 4F; - public static float offset = 0.01F; - public static float red = 1F;//0.1F; - public static float green = 1F; - public static float blue = 1F;//0.1F; - public static float alpha = 0.1F; - - @SubscribeEvent - public void onDrawBlockHighlight(DrawBlockHighlightEvent e) { - if (drawMoreSelectionBox(e.player, e.target, 0, e.currentItem, e.partialTicks)) - e.setCanceled(true); - } - - public static boolean drawMoreSelectionBox(EntityPlayer player, MovingObjectPosition mouseHit, int par3, ItemStack par4ItemStack, float par5) { - switch ((int) modeBlockBreak) { - //case 0: Просто рисуем без экспанда - case 0: - //drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX , mouseHit.blockY, mouseHit.blockZ , par3, par4ItemStack, par5); - return false; - case 1: - switch (mouseHit.sideHit) {//Рисуеи по моусхиту - case 0: - case 1://x,z - for (int i = -1; i <= 1; i++) - for (int j = -1; j <= 1; j++) - drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX + i, mouseHit.blockY, mouseHit.blockZ + j, par3, par4ItemStack, par5); - break; - case 2: - case 3://x,y - for (int i = -1; i <= 1; i++) - for (int j = -1; j <= 1; j++) - drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX + i, mouseHit.blockY + j, mouseHit.blockZ, par3, par4ItemStack, par5); - break; - case 4: - case 5://y,z - for (int i = -1; i <= 1; i++) - for (int j = -1; j <= 1; j++) - drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX, mouseHit.blockY + i, mouseHit.blockZ + j, par3, par4ItemStack, par5); - break; - } - break; - case 2://x,z - for (int i = -1; i <= 1; i++) - for (int j = -1; j <= 1; j++) - drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX + i, mouseHit.blockY, mouseHit.blockZ + j, par3, par4ItemStack, par5); - break; - case 3: - float rotationYaw = player.rotationYaw; - while (rotationYaw > 0) rotationYaw -= 360F; - while (rotationYaw < -360) rotationYaw += 360F; - if ((-135 <= rotationYaw && rotationYaw <= -45) || (-315 <= rotationYaw && rotationYaw <= -225)) { - //y,z - for (int i = -1; i <= 1; i++) - for (int j = -1; j <= 1; j++) - drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX, mouseHit.blockY + i, mouseHit.blockZ + j, par3, par4ItemStack, par5); - } else if ((-225 <= rotationYaw && rotationYaw <= -135) || -45 <= rotationYaw || rotationYaw <= -315) { - //x,y - for (int i = -1; i <= 1; i++) - for (int j = -1; j <= 1; j++) - drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX + i, mouseHit.blockY + j, mouseHit.blockZ, par3, par4ItemStack, par5); - } - break; - case 4: - //x,y,z - for (int i = -1; i <= 1; i++) - for (int j = -1; j <= 1; j++) - for (int k = -1; k <= 1; k++) - drawSelectionBox(player, mouseHit.typeOfHit, mouseHit.blockX + i, mouseHit.blockY + j, mouseHit.blockZ + k, par3, par4ItemStack, par5); - break; - } - return false; - } - - public static void drawSelectionBox(EntityPlayer player,MovingObjectPosition.MovingObjectType typeOfHit, int blockX,int blockY, int blockZ, int par3, ItemStack par4ItemStack, float par5) { - if ((par3 == 0) && (typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK)) { - //float breakProgress = getBlockDamage(player, block); - if (disableDepthBuffer) { - GL11.glDisable(2929); - } - GL11.glEnable(3042); - GL11.glBlendFunc(770, 771); - GL11.glLineWidth(thickness); - GL11.glDisable(3553); - GL11.glDepthMask(false); - float f1 = offset; - - Minecraft mc = Minecraft.getMinecraft(); - Block b = mc.theWorld.getBlock(blockX, blockY, blockZ); - if (b != Blocks.air && b!= null) { - b.setBlockBoundsBasedOnState(mc.theWorld, blockX, blockY, blockZ); - - double xOffset = player.lastTickPosX + (player.posX - player.lastTickPosX) * par5; - double yOffset = player.lastTickPosY + (player.posY - player.lastTickPosY) * par5; - double zOffset = player.lastTickPosZ + (player.posZ - player.lastTickPosZ) * par5; - - float xExpand = 0F; - float yExpand = 0F; - float zExpand = 0F; - - - - try { - AxisAlignedBB bb = b.getSelectedBoundingBoxFromPool(mc.theWorld, blockX, blockY, blockZ).expand(xExpand + f1, yExpand + f1, zExpand + f1).getOffsetBoundingBox(-xOffset, -yOffset, -zOffset); - GL11.glColor4f(red, green, blue, alpha); - //drawOutlinedBoundingBox(bb); - drawBlock(bb); - }catch(Exception e) { - - } - - } - GL11.glDepthMask(true); - GL11.glEnable(3553); - GL11.glDisable(3042); - if (disableDepthBuffer) { - GL11.glEnable(2929); - } - } - } - - private static void drawBlock(AxisAlignedBB par1AxisAlignedBB) { - //Tessellator tessellator = Tessellator.instance; - if(alpha > 0.0F) { - - - renderDown(par1AxisAlignedBB); - renderUp(par1AxisAlignedBB); - renderNorth(par1AxisAlignedBB); - renderSouth(par1AxisAlignedBB); - renderWest(par1AxisAlignedBB); - renderEast(par1AxisAlignedBB); - } - - } - - - public static void renderUp(AxisAlignedBB par1AxisAlignedBB) { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.draw(); - } - - public static void renderDown(AxisAlignedBB par1AxisAlignedBB) { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.draw(); - } - - public static void renderNorth(AxisAlignedBB par1AxisAlignedBB) { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.draw(); - } - - public static void renderSouth(AxisAlignedBB par1AxisAlignedBB) { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.draw(); - } - - public static void renderWest(AxisAlignedBB par1AxisAlignedBB) { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.draw(); - } - - public static void renderEast(AxisAlignedBB par1AxisAlignedBB) { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawingQuads(); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.draw(); - } - - private static void drawOutlinedBoundingBox(AxisAlignedBB par1AxisAlignedBB) { - Tessellator tessellator = Tessellator.instance; - tessellator.startDrawing(3); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.draw(); - tessellator.startDrawing(3); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.draw(); - tessellator.startDrawing(1); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.minZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.maxX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.minY, par1AxisAlignedBB.maxZ); - tessellator.addVertex(par1AxisAlignedBB.minX, par1AxisAlignedBB.maxY, par1AxisAlignedBB.maxZ); - tessellator.draw(); - } - - - static boolean inited = false; - - public static void register() { - if (!inited) { - inited = true; - DetravDrawBlockHighlightEventHandler handler = new DetravDrawBlockHighlightEventHandler(); - MinecraftForge.EVENT_BUS.register(handler); - FMLCommonHandler.instance().bus().register(handler); - } - } -}
\ No newline at end of file diff --git a/src/main/java/com/detrav/events/DetravEntityDropEvent.java b/src/main/java/com/detrav/events/DetravEntityDropEvent.java deleted file mode 100644 index 6c84ab31c2..0000000000 --- a/src/main/java/com/detrav/events/DetravEntityDropEvent.java +++ /dev/null @@ -1,90 +0,0 @@ -package com.detrav.events; - -import cpw.mods.fml.common.FMLCommonHandler; -import cpw.mods.fml.common.eventhandler.SubscribeEvent; -import gregtech.api.enums.ItemList; -import gregtech.api.items.GT_MetaGenerated_Item_X01; -import ic2.core.Ic2Items; -import net.minecraft.entity.EnumCreatureType; -import net.minecraft.entity.item.EntityItem; -import net.minecraft.entity.monster.EntityEnderman; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.init.Items; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ChatComponentText; -import net.minecraftforge.common.MinecraftForge; -import net.minecraftforge.event.entity.living.LivingDropsEvent; - -import java.util.Random; - -/** - * Created by Detrav on 02.10.2016. - */ -public class DetravEntityDropEvent { - - final static int baseShance = 70; - static Random random = new Random(); - - @SubscribeEvent - public void onLivingDropsEvent(LivingDropsEvent event) { - if(event.entity.isCreatureType(EnumCreatureType.monster, false)) { - - float shance = (baseShance + event.entityLiving.getMaxHealth()); - if(event.entity instanceof EntityEnderman) shance -= event.entityLiving.getMaxHealth()/2f; - int count = 0; - while (shance > 100) { - count++; - shance -= 100; - } - - if(count>0) - { - count = (int)(Math.pow(count,event.lootingLevel+1)*1.57f + 1); - - while (count>Ic2Items.coin.getMaxStackSize()) { - ItemStack itemStackToDrop = Ic2Items.coin.copy(); - itemStackToDrop.stackSize = itemStackToDrop.getMaxStackSize(); - event.drops.add(new EntityItem(event.entity.worldObj, event.entity.posX, - event.entity.posY, event.entity.posZ, itemStackToDrop)); - count -= itemStackToDrop.getMaxStackSize(); - } - ItemStack itemStackToDrop = Ic2Items.coin.copy(); - itemStackToDrop.stackSize = count; - event.drops.add(new EntityItem(event.entity.worldObj, event.entity.posX, - event.entity.posY, event.entity.posZ, itemStackToDrop)); - } - - count = 0; - shance += baseShance; - - shance = shance*(event.lootingLevel*1.57f +1); - while (shance > 100) { - count++; - shance -= 100; - } - if(random.nextInt(100) < shance) count ++; - ItemStack itemStackToDrop = ItemList.Credit_Copper.get(count); - event.drops.add(new EntityItem(event.entity.worldObj, event.entity.posX, - event.entity.posY, event.entity.posZ, itemStackToDrop)); - } - /*if(event.source.getEntity() instanceof EntityPlayer) - { - - ((EntityPlayer)event.source.getEntity()).addChatComponentMessage( - new ChatComponentText(event.entity.toString()) - ); - }*/ - } - - - static boolean inited = false; - - public static void register() { - if (!inited) { - inited = true; - DetravEntityDropEvent handler = new DetravEntityDropEvent(); - MinecraftForge.EVENT_BUS.register(handler); - FMLCommonHandler.instance().bus().register(handler); - } - } -} diff --git a/src/main/java/com/detrav/events/DetravLevelUpEvent.java b/src/main/java/com/detrav/events/DetravLevelUpEvent.java deleted file mode 100644 index 6dbcf4bfca..0000000000 --- a/src/main/java/com/detrav/events/DetravLevelUpEvent.java +++ /dev/null @@ -1,1873 +0,0 @@ -package com.detrav.events; - -import cpw.mods.fml.common.FMLCommonHandler; -import cpw.mods.fml.common.eventhandler.SubscribeEvent; -import net.minecraft.entity.SharedMonsterAttributes; -import net.minecraft.entity.ai.attributes.AttributeModifier; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraftforge.common.MinecraftForge; -import net.minecraftforge.event.entity.player.PlayerPickupXpEvent; - -import java.util.UUID; - -/** - * Created by Detrav on 26.03.2017. - */ -public class DetravLevelUpEvent { - - public static UUID mod_id = UUID.fromString("9a090263-953b-4d9f-947e-d4636cf3cd7e"); - - - - @SubscribeEvent - public void onPlayerPickupXpEvent(PlayerPickupXpEvent ev) { - EntityPlayer player = ev.entityPlayer; - if (player != null) { - if (!player.getEntityWorld().isRemote) { - if ((player.experience + ev.orb.xpValue*2) >= player.xpBarCap()) { - UpdateHealthAttribute(player,1); - } - } - } - } - - public static void UpdateHealthAttribute(EntityPlayer player) - { - UpdateHealthAttribute(player,0); - } - - public static void UpdateHealthAttribute(EntityPlayer player,int bonus) - { - if (!player.getEntityWorld().isRemote) { - AttributeModifier mod = GetAttributeModifier(player.experienceLevel+bonus); - player.getEntityAttribute( - SharedMonsterAttributes.maxHealth - ).removeModifier(mod); - player.getEntityAttribute( - SharedMonsterAttributes.maxHealth - ).applyModifier(mod); - player.heal(player.getMaxHealth()); - } - } - - public static AttributeModifier GetAttributeModifier(int level) { - int hp_boost = 0; - switch (level) { - case 0: - hp_boost = 0; - break; - case 1: - hp_boost = 1; - break; - case 2: - hp_boost = 2; - break; - case 3: - hp_boost = 2; - break; - case 4: - hp_boost = 3; - break; - case 5: - hp_boost = 3; - break; - case 6: - hp_boost = 4; - break; - case 7: - hp_boost = 4; - break; - case 8: - hp_boost = 5; - break; - case 9: - hp_boost = 5; - break; - case 10: - hp_boost = 6; - break; - case 11: - hp_boost = 6; - break; - case 12: - hp_boost = 7; - break; - case 13: - hp_boost = 7; - break; - case 14: - hp_boost = 8; - break; - case 15: - hp_boost = 8; - break; - case 16: - hp_boost = 9; - break; - case 17: - hp_boost = 9; - break; - case 18: - hp_boost = 10; - break; - case 19: - hp_boost = 10; - break; - case 20: - hp_boost = 11; - break; - case 21: - hp_boost = 11; - break; - case 22: - hp_boost = 11; - break; - case 23: - hp_boost = 12; - break; - case 24: - hp_boost = 12; - break; - case 25: - hp_boost = 12; - break; - case 26: - hp_boost = 13; - break; - case 27: - hp_boost = 13; - break; - case 28: - hp_boost = 13; - break; - case 29: - hp_boost = 14; - break; - case 30: - hp_boost = 14; - break; - case 31: - hp_boost = 14; - break; - case 32: - hp_boost = 15; - break; - case 33: - hp_boost = 15; - break; - case 34: - hp_boost = 15; - break; - case 35: - hp_boost = 16; - break; - case 36: - hp_boost = 16; - break; - case 37: - hp_boost = 16; - break; - case 38: - hp_boost = 17; - break; - case 39: - hp_boost = 17; - break; - case 40: - hp_boost = 17; - break; - case 41: - hp_boost = 18; - break; - case 42: - hp_boost = 18; - break; - case 43: - hp_boost = 18; - break; - case 44: - hp_boost = 18; - break; - case 45: - hp_boost = 19; - break; - case 46: - hp_boost = 19; - break; - case 47: - hp_boost = 19; - break; - case 48: - hp_boost = 19; - break; - case 49: - hp_boost = 20; - break; - case 50: - hp_boost = 20; - break; - case 51: - hp_boost = 20; - break; - case 52: - hp_boost = 20; - break; - case 53: - hp_boost = 21; - break; - case 54: - hp_boost = 21; - break; - case 55: - hp_boost = 21; - break; - case 56: - hp_boost = 21; - break; - case 57: - hp_boost = 22; - break; - case 58: - hp_boost = 22; - break; - case 59: - hp_boost = 22; - break; - case 60: - hp_boost = 22; - break; - case 61: - hp_boost = 23; - break; - case 62: - hp_boost = 23; - break; - case 63: - hp_boost = 23; - break; - case 64: - hp_boost = 23; - break; - case 65: - hp_boost = 23; - break; - case 66: - hp_boost = 24; - break; - case 67: - hp_boost = 24; - break; - case 68: - hp_boost = 24; - break; - case 69: - hp_boost = 24; - break; - case 70: - hp_boost = 24; - break; - case 71: - hp_boost = 25; - break; - case 72: - hp_boost = 25; - break; - case 73: - hp_boost = 25; - break; - case 74: - hp_boost = 25; - break; - case 75: - hp_boost = 25; - break; - case 76: - hp_boost = 26; - break; - case 77: - hp_boost = 26; - break; - case 78: - hp_boost = 26; - break; - case 79: - hp_boost = 26; - break; - case 80: - hp_boost = 26; - break; - case 81: - hp_boost = 26; - break; - case 82: - hp_boost = 27; - break; - case 83: - hp_boost = 27; - break; - case 84: - hp_boost = 27; - break; - case 85: - hp_boost = 27; - break; - case 86: - hp_boost = 27; - break; - case 87: - hp_boost = 27; - break; - case 88: - hp_boost = 28; - break; - case 89: - hp_boost = 28; - break; - case 90: - hp_boost = 28; - break; - case 91: - hp_boost = 28; - break; - case 92: - hp_boost = 28; - break; - case 93: - hp_boost = 28; - break; - case 94: - hp_boost = 29; - break; - case 95: - hp_boost = 29; - break; - case 96: - hp_boost = 29; - break; - case 97: - hp_boost = 29; - break; - case 98: - hp_boost = 29; - break; - case 99: - hp_boost = 29; - break; - case 100: - hp_boost = 30; - break; - case 101: - hp_boost = 30; - break; - case 102: - hp_boost = 30; - break; - case 103: - hp_boost = 30; - break; - case 104: - hp_boost = 30; - break; - case 105: - hp_boost = 30; - break; - case 106: - hp_boost = 30; - break; - case 107: - hp_boost = 31; - break; - case 108: - hp_boost = 31; - break; - case 109: - hp_boost = 31; - break; - case 110: - hp_boost = 31; - break; - case 111: - hp_boost = 31; - break; - case 112: - hp_boost = 31; - break; - case 113: - hp_boost = 31; - break; - case 114: - hp_boost = 31; - break; - case 115: - hp_boost = 32; - break; - case 116: - hp_boost = 32; - break; - case 117: - hp_boost = 32; - break; - case 118: - hp_boost = 32; - break; - case 119: - hp_boost = 32; - break; - case 120: - hp_boost = 32; - break; - case 121: - hp_boost = 32; - break; - case 122: - hp_boost = 33; - break; - case 123: - hp_boost = 33; - break; - case 124: - hp_boost = 33; - break; - case 125: - hp_boost = 33; - break; - case 126: - hp_boost = 33; - break; - case 127: - hp_boost = 33; - break; - case 128: - hp_boost = 33; - break; - case 129: - hp_boost = 33; - break; - case 130: - hp_boost = 34; - break; - case 131: - hp_boost = 34; - break; - case 132: - hp_boost = 34; - break; - case 133: - hp_boost = 34; - break; - case 134: - hp_boost = 34; - break; - case 135: - hp_boost = 34; - break; - case 136: - hp_boost = 34; - break; - case 137: - hp_boost = 34; - break; - case 138: - hp_boost = 34; - break; - case 139: - hp_boost = 35; - break; - case 140: - hp_boost = 35; - break; - case 141: - hp_boost = 35; - break; - case 142: - hp_boost = 35; - break; - case 143: - hp_boost = 35; - break; - case 144: - hp_boost = 35; - break; - case 145: - hp_boost = 35; - break; - case 146: - hp_boost = 35; - break; - case 147: - hp_boost = 35; - break; - case 148: - hp_boost = 36; - break; - case 149: - hp_boost = 36; - break; - case 150: - hp_boost = 36; - break; - case 151: - hp_boost = 36; - break; - case 152: - hp_boost = 36; - break; - case 153: - hp_boost = 36; - break; - case 154: - hp_boost = 36; - break; - case 155: - hp_boost = 36; - |
