@SuppressWarnings("incomplete-switch") public S42PacketCombatEvent(CombatTracker combatTrackerIn, S42PacketCombatEvent.Event combatEventType) { this.eventType = combatEventType; EntityLivingBase entitylivingbase = combatTrackerIn.func_94550_c(); switch (combatEventType) { case END_COMBAT: this.field_179772_d = combatTrackerIn.func_180134_f(); this.field_179775_c = entitylivingbase == null ? -1 : entitylivingbase.getEntityId(); break; case ENTITY_DIED: this.field_179774_b = combatTrackerIn.getFighter().getEntityId(); this.field_179775_c = entitylivingbase == null ? -1 : entitylivingbase.getEntityId(); this.deathMessage = combatTrackerIn.getDeathMessage().getUnformattedText(); } }
@SuppressWarnings("incomplete-switch") public SPacketCombatEvent(CombatTracker tracker, SPacketCombatEvent.Event eventIn, boolean p_i46932_3_) { this.eventType = eventIn; EntityLivingBase entitylivingbase = tracker.getBestAttacker(); switch (eventIn) { case END_COMBAT: this.duration = tracker.getCombatDuration(); this.entityId = entitylivingbase == null ? -1 : entitylivingbase.getEntityId(); break; case ENTITY_DIED: this.playerId = tracker.getFighter().getEntityId(); this.entityId = entitylivingbase == null ? -1 : entitylivingbase.getEntityId(); if (p_i46932_3_) { this.deathMessage = tracker.getDeathMessage(); } else { this.deathMessage = new TextComponentString(""); } } }
@Override public CombatTracker getCombatTracker() { if (m_realPlayer == null) { return super.getCombatTracker(); } else { syncToRealPlayer(); return syncPublicFieldsFromRealAndReturn(m_realPlayer.getCombatTracker()); } }
@Override public CombatTracker getCombatTracker() { if (m_realPlayer == null) { return super.getCombatTracker(); } else { return m_realPlayer.getCombatTracker(); } }
public void reset() { float exp = 0; boolean keepInventory = this.worldObj.getGameRules().getGameRuleBooleanValue("keepInventory"); if (this.keepLevel || keepInventory) { exp = this.experience; this.newTotalExp = this.experienceTotal; this.newLevel = this.experienceLevel; } this.setHealth(this.getMaxHealth()); this.fire = 0; this.fallDistance = 0; this.foodStats = new FoodStats(this); this.experienceLevel = this.newLevel; this.experienceTotal = this.newTotalExp; this.experience = 0; this.deathTime = 0; this.clearActivePotions(); // Should be remapped: removeAllEffects should be remapped to this. super.potionsNeedUpdate = true; // Cauldron - change to super to temporarily workaround remapping bug with SpecialSource this.openContainer = this.inventoryContainer; this.attackingPlayer = null; this.entityLivingToAttack = null; this._combatTracker = new CombatTracker(this); this.lastExperience = -1; if (this.keepLevel || keepInventory) { this.experience = exp; } else { this.addExperience(this.newExp); } this.keepLevel = false; }
public CombatTracker getCombatTracker() { return this._combatTracker; }
/** * 1.8.9 */ public CombatTracker getCombatTracker() { return this._combatTracker; }
public SPacketCombatEvent(CombatTracker tracker, SPacketCombatEvent.Event eventIn) { this(tracker, eventIn, true); }
public CombatTracker func_110142_aN() { return this._combatTracker; }
public CombatTracker func_110142_aN() { return this.field_94063_bt; }
@Shadow public abstract CombatTracker getCombatTracker();