public void DrawDestination() { if (Destination != null && Selection.Instance.DestinationOverlay && entity.Selectable.IsSelected) { EntityDebug.DrawDestination(entity); } }
public void DrawTarget() { if (Target && Selection.Instance.TargetOverlay && entity.Selectable.IsSelected) { EntityDebug.DrawTarget(entity); } }
public State Run(bool debug = false) { DebugHash = new HashSet <EntityDebug>(); checked { Debug = debug; if (debug) { _memory.SetDebugMode(); } while (_entity.Instruction != Instruction.Terminate && !_requestTermination) { _entity = GetInstruction(_index); if (debug) { WriteLine($"Executing {_entity.Instruction} [{_index}]"); } var entityDebug = new EntityDebug { Instruction = _entity.Instruction, ParameterModes = _entity.ParameterModes?.ToArray() ?? Enumerable.Empty <ParameterMode>().ToArray() }; if (!DebugHash.Contains(entityDebug)) { DebugHash.Add(entityDebug); } if (!_entity.Execute()) { return(State.WaitingForInput); } if (_jumpTo >= 0) { _index = _jumpTo; _jumpTo = -1; } else { _index += _entity.Step; } } } return(State.Finished); }
private void DebugFunctions(Entity entity) { if (entity.Meta.Type != EntityType.Character) { return; } if (LineOfSight) { EntityDebug.DrawLineOfSight(entity); } if (Range) { EntityDebug.DrawRange(entity); } if (AggroList) { EntityDebug.DrawAggroList(entity); } }