public AbilityHitPointEvent(Vector3 point, OldContext context) { this.point = point; this.context = context; ability = context.ability; caster = ability.caster; }
public AbilityHitEntityEvent(Entity target, OldContext context) { this.target = target; this.context = context; ability = context.ability; caster = ability.caster; }
public override void Synchronize(Func <ProductionScheduleKey> getInput) { var productionScheduleKey = getInput(); var productionSchedule = UnitOfWork.ProductionScheduleRepository.FindByKey(productionScheduleKey, p => p.ScheduledItems.Select(i => i.PackSchedule.ProductionBatches)); var location = UnitOfWork.LocationRepository.FindByKey(productionScheduleKey.ToLocationKey()); string street; int row; LocationDescriptionHelper.GetStreetRow(location.Description, out street, out row); var oldProductionSchedule = OldContext.tblProductionSchedules .Include(p => p.tblProductionScheduleGroups.Select(g => g.tblProductionScheduleItems)) .FirstOrDefault(p => p.ProductionDate == productionScheduleKey.ProductionScheduleKey_ProductionDate && (int)p.LineNumber == row); if (productionSchedule == null) { if (oldProductionSchedule != null) { DeleteSchedule(oldProductionSchedule); } } else { SetSchedule(oldProductionSchedule, productionSchedule, row); } OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.SyncProductionSchedule, productionScheduleKey.ProductionScheduleKey_ProductionDate.ToString("yyyyMMdd"), row); }
public override void Synchronize(Func <SalesOrderKey> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var orderKey = getInput(); var order = UnitOfWork.SalesOrderRepository.FindByKey(orderKey, o => o.InventoryShipmentOrder); var tblOrder = OldContext.tblOrders .FirstOrDefault(o => o.OrderNum == order.InventoryShipmentOrder.MoveNum); if (tblOrder == null) { throw new Exception(string.Format("Could not find tblOrder[{0}]", order.InventoryShipmentOrder.MoveNum)); } tblOrder.Status = (int?)tblOrderStatus.Invoiced; tblOrder.InvoiceDate = order.InvoiceDate; tblOrder.InvoiceNotes = order.InvoiceNotes; OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.InvoicedOrder, tblOrder.OrderNum); }
public override void Synchronize(Func <IntraWarehouseOrderKey> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var orderKey = getInput(); var order = UnitOfWork.IntraWarehouseOrderRepository.FindByKey(orderKey, o => o.PickedInventory.Items.Select(i => i.PackagingProduct.Product), o => o.PickedInventory.Items.Select(i => i.FromLocation), o => o.PickedInventory.Items.Select(i => i.CurrentLocation)); if (order == null) { throw new Exception(string.Format("IntraWarehouseOrder[{0}] not found in new context.", orderKey)); } bool createdNew; var oldOrder = Synchronize(order, out createdNew); if (createdNew) { UnitOfWork.Commit(); } OldContext.SaveChanges(); Console.Write(ConsoleOutput.SynchronizedIntraWarehouserMovement, oldOrder.RinconID.ToString(DateTimeFormat)); }
public Ability UpdateCast() { if (queuedExpire.ReadyWithReset(0.2f)) { queuedAbility = null; } if (currentAbility == null || !gcdTimer.Ready) return null; CastState castState = currentAbility.UpdateCast(); if (castState == CastState.Invalid) { Clear(); } else if (castState == CastState.Completed) { if (currentAbility.IsInstant && !currentAbility.IgnoreGCD) { gcdTimer.Reset(GetGlobalCooldownTime(currentAbility)); } currentAbility = queuedAbility; currentContext = queuedContext; queuedAbility = null; queuedContext = null; if (currentAbility != null && !currentAbility.Use(currentContext)) { currentAbility = null; currentContext = null; } } return currentAbility; }
public override void Synchronize(Func <LotKey> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var lotKey = getInput(); var oldLot = new SyncLotHelper(OldContext, UnitOfWork, OldContextHelper).SynchronizeOldLot(lotKey, false, false); var inventory = UnitOfWork.InventoryRepository .Filter(i => i.LotDateCreated == lotKey.LotKey_DateCreated && i.LotDateSequence == lotKey.LotKey_DateSequence && i.LotTypeId == lotKey.LotKey_LotTypeId, i => i.PackagingProduct.Product, i => i.Location, i => i.Treatment) .ToList(); foreach (var item in inventory) { OldContext.tblIncomings.AddObject(CreateIncoming(oldLot, item)); } OldContext.SaveChanges(); Console.Write(ConsoleOutput.ReceivedInventory, oldLot.Lot); }
protected override IEnumerable <AdditiveProduct> BirthRecords() { _loadCount.Reset(); var productId = _newContext.NextIdentity <Product>(p => p.Id); foreach (var additiveProduct in OldContext.CreateObjectSet <tblProduct>().ToList().Where(p => p.PTypeID == (int)LotTypeEnum.Additive && p.ProdGrpID != 11 && p.ProdGrpID != 7)) { _loadCount.AddRead(EntityTypes.AdditiveProduct); _loadCount.AddRead(EntityTypes.Product); _loadCount.AddLoaded(EntityTypes.AdditiveProduct); _loadCount.AddLoaded(EntityTypes.Product); yield return(new AdditiveProduct { Id = productId, Product = new Product { Id = productId, ProductType = ProductTypeEnum.Additive, IsActive = additiveProduct.InActive == false, Name = additiveProduct.Product, ProductCode = additiveProduct.ProdID.ToString(CultureInfo.InvariantCulture) }, AdditiveTypeId = additiveProduct.IngrID ?? AdditiveTypeMother.Unknown.Id }); productId += 1; } _loadCount.LogResults(l => Log(new CallbackParameters(l))); }
public void Clear() { currentAbility = null; currentContext = null; queuedAbility = null; queuedContext = null; }
public override void Synchronize(Func <NotebookKey> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var notebookKey = getInput(); var notebook = UnitOfWork.NotebookRepository.FindByKey(notebookKey, n => n.Notes); if (notebook == null) { throw new Exception(string.Format("Notebook[{0}] not found.", notebookKey)); } var productionBatch = UnitOfWork.ProductionBatchRepository.Filter(b => b.InstructionNotebookDateCreated == notebook.Date && b.InstructionNotebookSequence == notebook.Sequence).FirstOrDefault(); if (productionBatch != null) { var lotNumber = LotNumberBuilder.BuildLotNumber(productionBatch); new SyncTblBatchInstr(OldContext).Synchronize(notebook, lotNumber); OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.UpdatedBatchInstructions, lotNumber); return; } var contract = UnitOfWork.ContractRepository.GetContractForSynch(notebookKey); if (contract != null) { new SyncContract(UnitOfWork).Synchronize(contract, false); } }
protected override IEnumerable <PackagingProduct> BirthRecords() { _loadCount.Reset(); var productId = _newContext.NextIdentity <Product>(p => p.Id); foreach (var package in OldContext.CreateObjectSet <tblPackaging>().ToList()) { _loadCount.AddRead(EntityTypes.PackagingProduct); _loadCount.AddRead(EntityTypes.Product); _loadCount.AddLoaded(EntityTypes.PackagingProduct); _loadCount.AddLoaded(EntityTypes.Product); yield return(new PackagingProduct { Id = productId, Product = new Product { Id = productId, ProductType = ProductTypeEnum.Packaging, IsActive = package.InActive == false, Name = package.Packaging, ProductCode = package.PkgID.ToString(CultureInfo.InvariantCulture), }, Weight = (double)(package.NetWgt ?? 0), PackagingWeight = (double)(package.PkgWgt ?? 0), PalletWeight = (double)(package.PalletWgt ?? 0) }); productId += 1; } _loadCount.LogResults(l => Log(new CallbackParameters(l))); }
public override void Synchronize(Func <int?> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var orderNum = getInput(); var order = OldContext.tblOrders .Include(o => o.tblOrderDetails.Select(d => d.tblStagedFGs)) .FirstOrDefault(o => o.OrderNum == orderNum); if (order == null) { throw new Exception(string.Format("Could not find customer order with key[{0}].", orderNum)); } foreach (var detail in order.tblOrderDetails.ToList()) { foreach (var staged in detail.tblStagedFGs.ToList()) { OldContext.tblStagedFGs.DeleteObject(staged); } OldContext.tblOrderDetails.DeleteObject(detail); } OldContext.tblOrders.DeleteObject(order); OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.RemovedTblOrder, orderNum); }
public static void Sync(INetworker networker) { // For now, allowing both sides to push. This behaviour needs to be replaced in general anyways if (networker.Hosting || true) { var save = Scene.Current.FindComponent <GamePieces>()?.GetSave(); if (!save.HasValue || save.Value.Res == null) { Logs.Game.WriteWarning("Attempted to sync, but no gave save found."); OldContext.ShowNotification("Error", "Failed to start sync.", 3); } else { SendSave(networker, save.Value.Res); OldContext.ShowNotification("Info", "Sync started.", 3); } } else if (networker.Connected) { networker.SendData(CommandChannel, "Sync"); OldContext.ShowNotification("Info", "Sync requested.", 3); } else { Logs.Game.WriteWarning($"Cannot try to sync while {networker.Status.ToString().ToLower()}"); } }
public override void Synchronize(Func <SynchronizeCustomerProductSpecs> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var parameters = getInput(); int prodID; string company_IA; if (parameters.Delete != null) { Delete(parameters.Delete, out prodID, out company_IA); } else if (parameters.ChileProductKey != null && parameters.CustomerKey != null) { Serialize(parameters.ChileProductKey, parameters.CustomerKey, out prodID, out company_IA); } else { return; } OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.UpdatedCustomerSpecs, company_IA, prodID); }
public override void Synchronize(Func<SyncSampleOrderParameters> getInput) { if(getInput == null) { throw new ArgumentNullException("getInput"); } var parameters = getInput(); lock(Lock) { string message; var commitNewContext = false; if(parameters.DeleteSampleID != null) { DeleteSampleOrder(parameters.DeleteSampleID.Value); message = string.Format(ConsoleOutput.DeletedTblSample, parameters.DeleteSampleID); } else if(parameters.SampleOrderKey != null) { var tblSample = Sync(parameters.SampleOrderKey, out commitNewContext); message = string.Format(ConsoleOutput.SynchedTblSample, tblSample.SampleID); } else { return; } OldContext.SaveChanges(); if(commitNewContext) { UnitOfWork.Commit(); } Console.WriteLine(message); } }
public void Decrease(float amount, OldContext context) { float adjustedValue = 0; for (int i = 0; i < adjusters.Count; i++) { adjustedValue -= adjusters[i].Adjust(amount, this, context); } currentValue -= adjustedValue; }
private List <tblRinconDTO> SelectRinconRecordsToLoad() { return(OldContext.CreateObjectSet <tblRincon>() .Where(r => r.Updated != null) .Select(r => new tblRinconDTO { EmployeeID = r.EmployeeID, RinconID = r.RinconID, MoveDate = r.MoveDate, SheetNum = r.SheetNum, PrepBy = r.PrepBy, tblRinconDetails = r.tblRinconDetails.Select(d => new tblRinconDetailDTO { RDetailID = d.RDetailID, EmployeeID = d.EmployeeID, RinconID = d.RinconID, Lot = d.Lot, PTypeID = d.tblLot.PTypeID, PkgID = d.PkgID, TrtmtID = d.TrtmtID, Quantity = d.Quantity, CurrLocID = d.CurrLocID, DestLocID = d.DestLocID }) }) .ToList()); }
public sealed override void Synchronize(Func <LotKey> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var key = getInput(); var production = UnitOfWork.ChileLotProductionRepository.FindByKey(key, m => m.ResultingChileLot.ChileProduct.Product, m => m.Results.ProductionLineLocation, m => m.Results.ResultItems.Select(i => i.PackagingProduct.Product), m => m.Results.ResultItems.Select(i => i.Location), m => m.PickedInventory.Items.Select(i => i.PackagingProduct.Product), m => m.PickedInventory.Items.Select(i => i.FromLocation), m => m.PickedInventory.Items.Select(i => i.Treatment)); bool newLot; var tblLot = GetOrCreateLot(production, out newLot); SetIncomingRecords(tblLot, production.Results.ResultItems); SetOutgoingRecords(tblLot, production); OldContext.SaveChanges(); Console.Write(newLot ? ConsoleOutput.AddedLot : ConsoleOutput.UpdatedLot, tblLot.Lot); }
public static void OnGameStart() { SceneSelector selector = null; foreach (var scene in ContentProvider.GetAvailableContent <Scene>()) { selector = scene.Res?.FindComponent <SceneSelector>() ?? selector; } if (selector == null) { Logs.Game.WriteWarning("Unable to set scenes, SceneSelector not found."); } else { _gameScene = selector.Game; _menuScene = selector.Menu; if (_gameScene.Res == null || _menuScene.Res == null) { Logs.Game.WriteWarning("Scene Selector ContentRefs aren't available, unable to set scenes."); } } OldContext.ClearNotifications(); }
private static void Networker_Disconnected(object sender, ClientDisconnectedEventArgs e) { string reason = e.Reason; if (string.IsNullOrWhiteSpace(reason)) { reason = ". No reason given."; } else { reason = ": " + reason; } if (CupboardApp.Networker.Hosting) { OldContext.ShowNotification("Info", e.RemoteEndPoint + " left the server.", duration: 3); } else { string type = reason == "Quit" ? "Info" : "Error"; OldContext.ShowNotification(type, "Disconnected from server" + reason, duration: 3, channel: "Main"); Scene.SwitchTo(_menuScene); } }
public override void Synchronize(Func <InventoryAdjustmentKey> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var key = getInput(); var inventoryAdjustment = UnitOfWork.InventoryAdjustmentRepository.FindByKey(key, a => a.Notebook.Notes, a => a.Items.Select(i => i.PackagingProduct.Product), a => a.Items.Select(i => i.Location), a => a.Items.Select(i => i.Treatment), a => a.Items.Select(i => i.Lot.PackagingLot.PackagingProduct.Product)); var adjustId = inventoryAdjustment.TimeStamp.ConvertUTCToLocal().RoundMillisecondsForSQL(); var newAdjustment = new tblAdjust { AdjustID = adjustId, EmployeeID = inventoryAdjustment.EmployeeId, Reason = inventoryAdjustment.Notebook.Notes.Select(n => n.Text).FirstOrDefault() }; AddOutgoingRecords(newAdjustment, inventoryAdjustment.Items); OldContext.tblAdjusts.AddObject(newAdjustment); OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.AddedAdjust, newAdjustment.AdjustID.ToString(DateTimeExtensions.SQLDateTimeFormat)); }
public override void Synchronize(Func <List <Contract> > getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var contracts = getInput(); if (contracts.Any()) { foreach (var contract in contracts) { var oldContract = OldContext.tblContracts.FirstOrDefault(c => c.ContractID == contract.ContractId); if (oldContract == null) { throw new Exception(string.Format("Could not find tblContract[{0}] referenced by Contract[{1}]", contract.ContractId, new ContractKey(contract))); } oldContract.KStatus = ContractStatus.Completed.ToString(); } OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.CompletedExpiredContracts, contracts.Count); } else { Console.WriteLine(ConsoleOutput.NoExpiredContracts); } }
private IEnumerable <TransactionDTO> GetOutgoing() { return(OldContext.CreateObjectSet <tblOutgoing>() .OrderByDescending(o => o.EntryDate) .Where(o => CutoffDate == null || o.EntryDate > CutoffDate) .Select(o => new TransactionDTO { EmployeeID = o.EmployeeID, EntryDate = o.EntryDate, TTypeID = o.TTypeID, Lot = o.Lot, PkgID = o.PkgID, LocID = o.LocID, TrtmtID = o.TrtmtID, Tote = o.Tote, Quantity = -o.Quantity, NewLot = o.NewLot, OutgoingID = o.ID, RinconID = o.RinconID, MoveNum = o.MoveNum, OrderNum = o.OrderNum, AdjustID = o.AdjustID, PackSchId = o.PackSchID })); }
public StatusEffect AddStatusEffect(string effectId, OldContext context) { Entity caster = context.entity; StatusEffect existing = statusList.Find((StatusEffect s) => { return(s.Id == effectId && s.caster == caster || s.IsUnique); }); if (existing != null && existing.IsRefreshable) { existing.Refresh(context); return(existing); } StatusEffect statusEffect = EntitySystemLoader.Instance.Create <StatusEffect>(effectId); if (existing != null) { existing.Remove(); statusList.Remove(existing); } statusEffect.Apply(entity, context); statusList.Add(statusEffect); return(statusEffect); }
public bool Use(OldContext context) { if (!Usable(context)) { return(false); } this.context = context; context.ability = this; SetComponentContext(context); OnUse(); if (castState == CastState.Invalid) { if (castMode == CastMode.Channel) { float actualChannelTime = channelTime.Value; castTimer.Reset(actualChannelTime); channelTimer.Reset(actualChannelTime / channelTicks.Value); } else { float actualCastTime = castTime.Value; castTimer.Reset(actualCastTime); actualCastMode = (actualCastTime <= 0f) ? CastMode.Instant : castMode; } castState = CastState.Casting; OnCastStarted(); } return(true); }
public override void Synchronize(Func <SyncSalesOrderParameters> getInput) { lock (_lock) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var parameters = getInput(); var key = parameters.SalesOrderKey; var salesOrder = GetSalesOrder(key); if (salesOrder == null) { throw new Exception(string.Format("Could not find SalesOrder with key[{0}].", key)); } _commitNewContext = false; var oldOrder = GetOldOrder(salesOrder, parameters.New); oldOrder.SetSalesOrder(salesOrder); SyncOrderItems(salesOrder, oldOrder); if (_commitNewContext) { UnitOfWork.Commit(); } OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.SyncTblOrder, salesOrder.InventoryShipmentOrder.MoveNum); } }
public override void Synchronize(Func <int?> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var contractId = getInput(); if (contractId == null) { return; } var contract = OldContext.tblContracts.Include("tblContractDetails").FirstOrDefault(c => c.ContractID == contractId.Value); foreach (var detail in contract.tblContractDetails.ToList()) { OldContext.tblContractDetails.DeleteObject(detail); } OldContext.tblContracts.DeleteObject(contract); OldContext.SaveChanges(); Console.Write(ConsoleOutput.RemovedContract, contractId); }
public override void Synchronize(Func <PackScheduleKey> getInput) { if (getInput == null) { throw new ArgumentNullException("getInput"); } var packScheduleKey = getInput(); var newPackSchedule = UnitOfWork.PackScheduleRepository.SelectPackScheduleForSynch(packScheduleKey); var oldPackSchedule = OldContext.tblPackSches.Select(p => new { packSchedule = p, lots = p.tblLots }).FirstOrDefault(p => p.packSchedule.PackSchID == newPackSchedule.PackSchID); if (oldPackSchedule == null) { throw new Exception(string.Format("Could not find tblPackSch[{0}] record.", newPackSchedule.PackSchID)); } SynchronizePackScheduleHelper.SynchronizeOldContextPackSchedule(oldPackSchedule.packSchedule, newPackSchedule); OldContext.SaveChanges(); Console.Write(ConsoleOutput.UpdatedPackSchedule, oldPackSchedule.packSchedule.PackSchID.ToPackSchIdString()); }
//this is pseudo private public void AddStatusEffectFromTemplate(StatusEffectTemplate template) { StatusEffect effect = template.Create(entity); OldContext context = template.GetContext(entity); effect.Apply(entity, context); statusList.Add(effect); }
public override void Synchronize(Func <LotKey> getInput) { var lotNumber = LotNumberBuilder.BuildLotNumber(getInput()); new DeleteTblLotHelper(OldContext).DeleteLots(lotNumber); OldContext.SaveChanges(); Console.WriteLine(ConsoleOutput.DeletedTblLot, lotNumber); }
///------------------------------------------------------------------------------------------------- /// <summary> /// When overridden in a derived class, creates a copy of the synchronization context. /// </summary> /// <returns> /// A new <see cref="T:System.Threading.SynchronizationContext" /> object. /// </returns> ///------------------------------------------------------------------------------------------------- public override SynchronizationContext CreateCopy() { if (OldContext != null) { return(OldContext.CreateCopy()); } return(base.CreateCopy()); }
public override bool OnTest(OldContext context, RequirementType type) { Entity target = context.Get<Entity>("Target"); Entity caster = context.Get<Entity>("Caster"); if(target == null) { return true; } return Vector3.Angle(target.transform.position, caster.transform.forward) < maximumAngleDifference; }
public float GetDamage(OldContext context) { if (formula == null) { return(baseValue); } return(formula.Invoke(context, baseValue)); }
public void Increase(float amount, OldContext context) { float adjustedValue = 0; for (int i = 0; i < adjusters.Count; i++) { adjustedValue += adjusters[i].Adjust(amount, this, context); } currentValue += adjustedValue; //currentValue = Mathf.Clamp(currentValue, float.MinValue, baseTotal); }
public void SetAbilityContext(OldContext context) { this.context = context; targetPoint = transform.position; Vector2 offset = UnityEngine.Random.insideUnitCircle * originXZOffsetRadius; originPoint = targetPoint + (Vector3.up * spawnHeight); originPoint.x += offset.x; originPoint.z += offset.y; transform.position = originPoint; }
public virtual OldContext GetContext(Entity target) { if (context == null) { context = new OldContext(); } context["target"] = target; context.entity = EntityManager.ImplicitEntity; return context; }
public override bool OnTest(OldContext context, RequirementType type) { var target = context.Get<Entity>("Target"); var caster = context.entity; if(target == null) { return false; } return target.transform.DistanceToSquared(caster.transform) <= range.Value; }
public override bool OnTest(OldContext context, RequirementType type) { var caster = context.entity; for (int i = 0; i < statuses.Length; i++) { if (statuses[i] == null) continue; if (caster.statusManager.HasStatus(statuses[i])) { return true; } } return false; }
public void Enqueue(Ability ability, OldContext context) { if (ability == null || context == null) return; if (currentAbility == null) { currentAbility = ability; currentContext = context; currentAbility.Use(context); } else { queuedAbility = ability; queuedContext = context; } }
public bool Test(OldContext context, RequirementType type) { if (supressed || (type & RequirementType) == 0) { return true; } bool requirementMet = OnTest(context, type); if (requirementMet) { OnPassed(context, type); } else { OnFailed(context, type); } return requirementMet; }
public StatusEffect AddStatusEffect(string effectId, OldContext context) { Entity caster = context.entity; StatusEffect existing = statusList.Find((StatusEffect s) => { return s.Id == effectId && s.caster == caster || s.IsUnique; }); if (existing != null && existing.IsRefreshable) { existing.Refresh(context); return existing; } StatusEffect statusEffect = EntitySystemLoader.Instance.Create<StatusEffect>(effectId); if (existing != null) { existing.Remove(); statusList.Remove(existing); } statusEffect.Apply(entity, context); statusList.Add(statusEffect); return statusEffect; }
public override float Adjust(float delta, Resource resource, OldContext context) { float armor = context.Get<float>("armor"); return delta - armor; }
public virtual void OnEffectRefreshed(OldContext context) { }
public void SetAbilityContext(OldContext context) { this.context = context; target = context.Get<Entity>("target"); transform.position = Vector3.zero;//context.entity.CastPoint; }
public virtual void OnFailed(OldContext context, RequirementType type) { }
public bool Cast(string abilityId, OldContext context) { Ability ability = GetAbility(abilityId); if (ability == null) throw new AbilityNotFoundException(abilityId); if (ability.Usable(context)) { castQueue.Enqueue(ability, context); return true; } return false; }
public static float ShadowSlash(OldContext context, float baseValue) { return 11; }
public void SetContext(OldContext context) { this.context = context; }
public void Start() { context = new OldContext(); }
public static float Slash(OldContext context, float baseValue) { return 10f; }
public virtual bool OnTest(OldContext context, RequirementType type) { return true; }
public float GetDamage(OldContext context) { if(formula == null) { return baseValue; } return formula.Invoke(context, baseValue); }
public void DecreaseNormalized(float amount, OldContext context) { // Decrease(Mathf.Clamp01(amount / baseTotal), context); }
public abstract float Adjust(float delta, Resource resource, OldContext context);