protected void OnQuestsOperation(LiteNetLibSyncList.Operation operation, int index) { if (CharacterEntity.IsOwnerClient && CacheUISceneGameplay != null) { CacheUISceneGameplay.UpdateQuests(); } }
protected virtual void OnStorageItemsOperation(LiteNetLibSyncList.Operation operation, int index) { if (onStorageItemsOperation != null) { onStorageItemsOperation.Invoke(operation, index); } }
protected void OnAttributesOperation(LiteNetLibSyncList.Operation operation, int index) { if (PlayerCharacterEntity.IsOwnerClient && CacheUISceneGameplay != null) { CacheUISceneGameplay.UpdateCharacter(); } }
/// <summary> /// Override this to do stuffs when skill usages changes /// </summary> /// <param name="operation"></param> /// <param name="index"></param> protected virtual void OnSkillUsagesOperation(LiteNetLibSyncList.Operation operation, int index) { if (onSkillUsagesOperation != null) { onSkillUsagesOperation.Invoke(operation, index); } // Call update skill operations to update uis switch (operation) { case LiteNetLibSyncList.Operation.Add: case LiteNetLibSyncList.Operation.Insert: case LiteNetLibSyncList.Operation.Set: case LiteNetLibSyncList.Operation.Dirty: int skillIndex = this.IndexOfSkill(SkillUsages[index].dataId); if (skillIndex >= 0) { skillsRecachingState = new SyncListRecachingState() { isRecaching = true, operation = LiteNetLibSyncList.Operation.Dirty, index = skillIndex }; } break; } }
protected void OnSkillsOperation(LiteNetLibSyncList.Operation operation, int index) { if (CharacterEntity.IsOwnerClient && CacheUISceneGameplay != null) { CacheUISceneGameplay.UpdateCharacter(); CacheUISceneGameplay.UpdateSkills(); CacheUISceneGameplay.UpdateHotkeys(); } }
/// <summary> /// Override this to do stuffs when summons changes /// </summary> /// <param name="operation"></param> /// <param name="index"></param> protected virtual void OnSummonsOperation(LiteNetLibSyncList.Operation operation, int index) { summonsRecachingState = new SyncListRecachingState() { isRecaching = true, operation = operation, index = index }; }
/// <summary> /// Override this to do stuffs when non equip items changes /// </summary> /// <param name="operation"></param> /// <param name="index"></param> protected virtual void OnNonEquipItemsOperation(LiteNetLibSyncList.Operation operation, int index) { nonEquipItemsRecachingState = new SyncListRecachingState() { isRecaching = true, operation = operation, index = index }; }
/// <summary> /// Override this to do stuffs when summons changes /// </summary> /// <param name="operation"></param> /// <param name="index"></param> protected virtual void OnSummonsOperation(LiteNetLibSyncList.Operation operation, int index) { isRecaching = true; if (onSummonsOperation != null) { onSummonsOperation.Invoke(operation, index); } }
protected void OnNonEquipItemsOperation(LiteNetLibSyncList.Operation operation, int index) { if (PlayerCharacterEntity.IsOwnerClient && CacheUISceneGameplay != null) { CacheUISceneGameplay.UpdateCharacter(); CacheUISceneGameplay.UpdateNonEquipItems(); CacheUISceneGameplay.UpdateHotkeys(); CacheUISceneGameplay.UpdateQuests(); } }
protected void OnBuffsOperation(LiteNetLibSyncList.Operation operation, int index) { if (PlayerCharacterEntity.IsOwnerClient && CacheUISceneGameplay != null) { if (operation == LiteNetLibSyncList.Operation.Add || operation == LiteNetLibSyncList.Operation.RemoveAt || operation == LiteNetLibSyncList.Operation.Insert || operation == LiteNetLibSyncList.Operation.Clear) { CacheUISceneGameplay.UpdateCharacter(); } } }
/// <summary> /// Override this to do stuffs when equip items changes /// </summary> /// <param name="operation"></param> /// <param name="index"></param> protected virtual void OnEquipItemsOperation(LiteNetLibSyncList.Operation operation, int index) { if (CharacterModel != null) { CharacterModel.SetEquipItems(equipItems); } equipItemsRecachingState = new SyncListRecachingState() { isRecaching = true, operation = operation, index = index }; }
/// <summary> /// Override this to do stuffs when buffs changes /// </summary> /// <param name="operation"></param> /// <param name="index"></param> protected virtual void OnBuffsOperation(LiteNetLibSyncList.Operation operation, int index) { if (CharacterModel != null) { CharacterModel.SetBuffs(buffs); } buffsRecachingState = new SyncListRecachingState() { isRecaching = true, operation = operation, index = index }; }
/// <summary> /// Override this to do stuffs when equip items changes /// </summary> /// <param name="operation"></param> /// <param name="index"></param> protected virtual void OnEquipItemsOperation(LiteNetLibSyncList.Operation operation, int index) { isRecaching = true; if (CharacterModel != null) { CharacterModel.SetEquipItems(equipItems); } if (onEquipItemsOperation != null) { onEquipItemsOperation.Invoke(operation, index); } }