Exemple #1
0
 public Computer(ClockCycle clockCycle, ROM rom, CPU16Bit.CPUAnalyzer analyzer)
 {
     CurrentComputer = this;
     this.rom = rom;
     cpu = new CPU16Bit(analyzer);
     memory = new Memory(16);
     clockCycle.Start();
 }
Exemple #2
0
        public static Angle GetClockAngle(float aClockValue, ClockCycle aCycle, float aMod = -90.0f)
        {
            if (aCycle == ClockCycle.None)
            {
                return(new Angle(aClockValue, AngleType.Undefined));
            }

            float CycleBase = (int)aCycle;

            //  Вычитаем превышение часов (более 12) или минут (более 60).
            aClockValue = aClockValue - ((float)Math.Round(aClockValue / CycleBase) * CycleBase);

            float Result = (360.0f / CycleBase) * aClockValue;

            Result += aMod;
            return(new Angle(Result, AngleType.Degrees));
        }
Exemple #3
0
 public Computer(ClockCycle clockCycle)
     : this(clockCycle, new ROM(new List<bool[]>()),null)
 {
 }
Exemple #4
0
 public Arrow(ClockCycle aCycle)
 {
     Vector     = new Vector2D(0, -1);
     ClockValue = 0;
     ClockCycle = aCycle;
 }