Пример #1
0
 public Sensor(int x1, int x2, int y1, int y2, SensorManager manager, string color, bool ignoreSolid, string letter)
 {
     X1 = x1;
     X2 = x2;
     Y1 = y1;
     Y2 = y2;
     Manager = manager;
     Color = color;
     IgnoreSolid = ignoreSolid;
     Letter = letter;
 }
Пример #2
0
        /*    
    obtainedRing = [];   
*/

        public Sonic()
        {
            Watcher = new Watcher();

            physicsVariables = SonicConstants.Sonic();

            var sonicManager = SonicManager.Instance;
            sonicLevel = sonicManager.SonicLevel;
            X = sonicLevel.StartPositions[0].X;
            Y = sonicLevel.StartPositions[0].Y;
            SensorManager = new SensorManager();
            HaltSmoke = new List<Point>();
            Rings = 7;
            SensorManager.CreateVerticalSensor("a", -9, 0, 36, "#F202F2");
            SensorManager.CreateVerticalSensor("b", 9, 0, 36, "#02C2F2");
            SensorManager.CreateVerticalSensor("c", -9, 0, -20, "#2D2C21");
            SensorManager.CreateVerticalSensor("d", 9, 0, -20, "#C24222");
            SensorManager.CreateHorizontalSensor("m1", 4, 0, -12, "#212C2E");
            SensorManager.CreateHorizontalSensor("m2", 4, 0, 13, "#22Ffc1");

            SpriteState = "normal";
            myRec = new Rectangle(0, 0, 0, 0);
            sonicLastHitTick = int.MinValue;

        }