Esempio n. 1
0
        public void Save(IniParser ini, string section)
        {
            ini.AddSetting(section, "Enabled", Enabled);
            ini.AddSetting(section, "ID", ID.ToString());
            ini.AddSetting(section, "Alias", Alias.ToString());
            ini.AddSetting(section, "Multihex", Multihex.ToString());
            ini.AddSetting(section, "Aim", Aim);
            ini.AddSetting(section, "Armor", Armor);
            ini.AddSetting(section, "Rotate", Rotate);

            ini.AddSetting(section, "Walk", Walk.ToString());
            ini.AddSetting(section, "Run", Run.ToString());
            ini.AddSetting(section, "Step1", Step1.ToString());
            ini.AddSetting(section, "Step2", Step2.ToString());
            ini.AddSetting(section, "Step3", Step3.ToString());
            ini.AddSetting(section, "Step4", Step4.ToString());

            if (Sound.Length > 0)
            {
                ini.AddNewSetting(section, "Sound", Sound);
            }
            else
            {
                ini.DeleteSetting(section, "Sound");
            }

            if (Comment.Length > 0)
            {
                ini.AddNewSetting(section, "Comment", Comment);
            }
            else
            {
                ini.DeleteSetting(section, "Comment");
            }
        }
    // Update is called once per frame
    void Update()
    {
        _timer += Time.deltaTime;
        if (PlayStepSounds && (_timer > stepDelay) && (_playerRB.velocity.x * _playerRB.velocity.x) > 0)
        {
            int caseValue = Random.Range(0, 5);
            switch (caseValue)
            {
            case 1:
                Step1.Play();
                break;

            case 2:
                Step2.Play();
                break;

            case 3:
                Step3.Play();
                break;

            case 4:
                Step4.Play();
                break;
            }
            _timer = 0;
        }
    }
    public ActionResult Index()
    {
        var p1 = new Projection()
        {
            Id = 1, DirectCostOfOperation = "111", Turnover = "100"
        };
        var p2 = new Projection()
        {
            Id = 2, DirectCostOfOperation = "222", Turnover = "200"
        };
        var p3 = new Projection()
        {
            Id = 3, DirectCostOfOperation = "333", Turnover = "300"
        };
        var p4 = new Projection()
        {
            Id = 4, DirectCostOfOperation = "444", Turnover = "400"
        };
        var p5 = new Projection()
        {
            Id = 5, DirectCostOfOperation = "555", Turnover = "500"
        };
        Step4 step = new Step4();

        step.Projections = new List <Projection> {
            p1, p2, p3, p4, p5
        };
        return(View(step));
    }
Esempio n. 4
0
 private static void Run()
 {
     Step1.Run();
     Step2.Run();
     Step3.Run();
     Step4.Run();
 }
Esempio n. 5
0
    public void MainMenu()
    {
        Step0.SetActive(false);
        Step1.SetActive(false);
        Step2.SetActive(false);
        Step3.SetActive(false);
        Step4.SetActive(false);
        Step5.SetActive(false);

        StartButton.SetActive(true);
        Hide1.SetActive(false);
        Next1.SetActive(false);
        Previous1.SetActive(false);
    }
Esempio n. 6
0
 public void StepFive()
 {
     Debug.Log("StepFiveInit");
     Step0.SetActive(false);
     Step1.SetActive(false);
     Step2.SetActive(false);
     Step3.SetActive(false);
     Step4.SetActive(false);
     Step5.SetActive(true);
     StartButton.SetActive(false);
     Hide1.SetActive(true);
     Next1.SetActive(true);
     Previous1.SetActive(true);
 }
Esempio n. 7
0
 // Use this for initialization
 void Start()
 {
     Time.fixedDeltaTime = 0.5f;
     Step1.SetActive(false);
     Step2.SetActive(false);
     Step3.SetActive(false);
     Step4.SetActive(false);
     Step5.SetActive(false);
     Step6.SetActive(false);
     Step7.SetActive(false);
     Step8.SetActive(false);
     Step9.SetActive(false);
     currenttime = Time.time;
     printcount  = 0;
     loop        = -1;
 }
Esempio n. 8
0
    public void StepOne()
    {
        Marker1.SetActive(true);
        Marker2.SetActive(true);
        Debug.Log("StepOneInit");
        FindObjectOfType <DistanceCalculator>();
        Step0.SetActive(false);
        Step1.SetActive(true);
        Step2.SetActive(false);
        Step3.SetActive(false);
        Step4.SetActive(false);
        Step5.SetActive(false);

        StartButton.SetActive(false);
        Hide1.SetActive(true);
        Next1.SetActive(true);
        Previous1.SetActive(false);
    }
Esempio n. 9
0
        void NextStep()
        {
            next.IsEnabled = false;
            ++currentStep;

            switch (currentStep)
            {
            case 0:
                pageTransition.TransitionType = Transitions.PageTransitionType.GrowAndFade;
                var step0 = new Step0();
                next.IsEnabled = true;
                pageTransition.ShowPage(step0);
                break;

            case 1:
                pageTransition.TransitionType = Transitions.PageTransitionType.SlideAndFade;
                var step1 = new Step1();
                step1.Success += OnSuccess;
                pageTransition.ShowPage(step1);
                break;

            case 2:
                var step2 = new Step2();
                step2.Success += OnSuccess;
                pageTransition.ShowPage(step2);
                break;

            case 3:
                Telestat.CancelGetDialogs();
                var step3 = new Step3();
                step3.Success += OnSuccess;
                step3.Failure += OnFailure;
                pageTransition.ShowPage(step3);
                break;

            case 4:
                var step4 = new Step4();
                pageTransition.ShowPage(step4);
                break;
            }
        }
Esempio n. 10
0
        private static void MainSafe(Arguments arguments)
        {
            var targetDirectoryPath = arguments.TargetDirectoryPath;

            IImmutableDictionary <AssemblyShortName, AssemblyDetails> mainAssemblies;
            IImmutableDictionary <AssemblyShortName, AssemblyDetails> usedRoslynAssemblies;
            IImmutableDictionary <AssemblyShortName, string>          roslynAssemblyPaths;
            IImmutableDictionary <AssemblyShortName, IImmutableSet <PackageInfo> > roslynPackageMap;
            IImmutableDictionary <AssemblyShortName, AssemblyDetails> othersReferencedByRoslyn;

            Step1.CollectMainAssemblies(arguments.SourceProjectAssemblyDirectoryPath, out mainAssemblies);
            Step2.CollectRoslynAssemblies(arguments.RoslynBinariesDirectoryPath, ref mainAssemblies, out usedRoslynAssemblies, out roslynAssemblyPaths);
            Step3.CollectRoslynPackageReferences(arguments.RoslynBinariesDirectoryPath, out roslynPackageMap);
            Step4.CollectRoslynReferences(ref usedRoslynAssemblies, roslynAssemblyPaths, ref mainAssemblies, roslynPackageMap, out othersReferencedByRoslyn);

            Step5.CleanTargetDirectory(arguments.TargetDirectoryPath);

            Step6.CopyAssembliesReferencedByRoslyn(othersReferencedByRoslyn, targetDirectoryPath);
            Step7.CopyRoslynAssemblies(usedRoslynAssemblies, targetDirectoryPath);
            Step8.RewriteAndCopyMainAssemblies(mainAssemblies, targetDirectoryPath, usedRoslynAssemblies);
            Step9.UpdateBindingRedirects(arguments.TargetApplicationConfigurationPath, othersReferencedByRoslyn.Values);
        }
Esempio n. 11
0
 void FixedUpdate()
 {
     if (loop >= 0 && loop < 1)
     {
         if (printcount % 11 == 0)
         {
             Step1.SetActive(true);
             Step2.SetActive(false);
             Step3.SetActive(false);
             Step4.SetActive(false);
             Step5.SetActive(false);
             Step6.SetActive(false);
             Step7.SetActive(false);
             Step8.SetActive(false);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 1)
         {
             Step1.SetActive(false);
             Step2.SetActive(true);
             Step3.SetActive(false);
             Step4.SetActive(false);
             Step5.SetActive(false);
             Step6.SetActive(false);
             Step7.SetActive(false);
             Step8.SetActive(false);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 2)
         {
             Step1.SetActive(false);
             Step2.SetActive(false);
             Step3.SetActive(true);
             Step4.SetActive(false);
             Step5.SetActive(false);
             Step6.SetActive(false);
             Step7.SetActive(false);
             Step8.SetActive(false);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 3)
         {
             Step1.SetActive(false);
             Step2.SetActive(false);
             Step3.SetActive(false);
             Step4.SetActive(true);
             Step5.SetActive(false);
             Step6.SetActive(false);
             Step7.SetActive(false);
             Step8.SetActive(false);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 4)
         {
             Step1.SetActive(false);
             Step2.SetActive(false);
             Step3.SetActive(false);
             Step4.SetActive(false);
             Step5.SetActive(true);
             Step6.SetActive(false);
             Step7.SetActive(false);
             Step8.SetActive(false);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 5)
         {
             Step1.SetActive(false);
             Step2.SetActive(false);
             Step3.SetActive(false);
             Step4.SetActive(false);
             Step5.SetActive(false);
             Step6.SetActive(true);
             Step7.SetActive(false);
             Step8.SetActive(false);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 6)
         {
             Step1.SetActive(false);
             Step2.SetActive(false);
             Step3.SetActive(false);
             Step4.SetActive(false);
             Step5.SetActive(false);
             Step6.SetActive(false);
             Step7.SetActive(true);
             Step8.SetActive(false);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 7)
         {
             Step1.SetActive(false);
             Step2.SetActive(false);
             Step3.SetActive(false);
             Step4.SetActive(false);
             Step5.SetActive(false);
             Step6.SetActive(false);
             Step7.SetActive(false);
             Step8.SetActive(true);
             Step9.SetActive(false);
         }
         else if (printcount % 11 == 8)
         {
             Step1.SetActive(false);
             Step2.SetActive(false);
             Step3.SetActive(false);
             Step4.SetActive(false);
             Step5.SetActive(false);
             Step6.SetActive(false);
             Step7.SetActive(false);
             Step8.SetActive(false);
             Step9.SetActive(true);
             loop++;
         }
         printcount++;
     }
     if (loop == 1)
     {
         SceneManager.LoadScene("Game3", LoadSceneMode.Single);
     }
 }
Esempio n. 12
0
        public string ToFOnlineString(bool verbose = false)
        {
            string result = "";

            List <string> args = new List <string>();

            var sbool = new Func <bool, string>(b =>
            {
                return(b ? "1" : "0");
            });

            var anim = new Func <string, string>(name =>
            {
                return(this[name] != null ? "1" : "0");
            });

            var animGroup = new Func <char, string>(name =>
            {
                return(this[name] != null ? "1" : "0");
            });

            // cvet plz, no format changes ;_;

            args.Add((Enabled ? "@" : "#"));
            args.Add(ID.ToString());
            args.Add(Name.ToLower());
            args.Add(Alias.ToString());
            args.Add(Multihex.ToString());
            args.Add("0");        // Type
            args.Add(anim("AB")); // Walk
            args.Add(anim("AT")); // Run
            args.Add(sbool(Aim));
            args.Add(sbool(Armor));
            args.Add(sbool(Rotate));
            args.Add(animGroup('A'));
            args.Add(animGroup('B'));
            args.Add(animGroup('C'));
            args.Add(animGroup('D'));
            args.Add(animGroup('E'));
            args.Add(animGroup('F'));
            args.Add(animGroup('G'));
            args.Add(animGroup('H'));
            args.Add(animGroup('I'));
            args.Add(animGroup('J'));
            args.Add(anim("KJ"));     // K
            args.Add(animGroup('L'));
            args.Add(anim("KL"));     // M
            args.Add(animGroup('N'));
            args.Add(animGroup('J')); // O
            args.Add(animGroup('P'));
            args.Add(animGroup('Q'));
            args.Add(animGroup('R'));
            args.Add(animGroup('S'));
            args.Add(animGroup('T'));
            args.Add(animGroup('U'));
            args.Add(animGroup('V'));
            args.Add(animGroup('W'));
            args.Add(animGroup('X'));
            args.Add(animGroup('Y'));
            args.Add(animGroup('Z'));
            args.Add(Walk.ToString());
            args.Add(Run.ToString());
            args.Add(Step1.ToString());
            args.Add(Step2.ToString());
            args.Add(Step3.ToString());
            args.Add(Step4.ToString());
            args.Add((Sound.Length == 0 ? "-" : Sound));
            args.Add((Comment.Length > 0) ? " # " + Comment : "");

            if (!verbose)
            {
                bool first = true;
                foreach (string str in args)
                {
                    if (first)
                    {
                        first = false;
                    }
                    else
                    {
                        result += " ";
                    }

                    result += str;
                }
            }
            else
            {
                int len = 5;
                if (Name.Length > len - 1)
                {
                    len = Name.Length + 1;
                }
                args.Insert(0, "Name");
                string format =
                    "# ID  {0," + -len + "}Alias MH Type Walk Run Aim Armor Rotate  A B C D E F G H I J K L M N O P Q R S T U V W X Y Z  Walk Run Walk steps Sound"
                    + Environment.NewLine
                    + "{1,-2}{2,-4}{3," + -len + "}{4,-6}{5,-3}{6,-5}{7,-5}{8,-4}{9,-4}{10,-6}{11,-8}";

                // A-Z
                for (int a = 12; a <= 37; a++)
                {
                    format += "{" + a + ",-2}";
                }

                // walk, run
                format += " {38,-5}{39,-4}";

                // walk steps
                for (int s = 40; s <= 43; s++)
                {
                    format += "{" + s + ",-3}";
                }

                format += "{44}{45}";

                result += string.Format(format, args.ToArray());
            }

            return(result);
        }
Esempio n. 13
0
 public ActionResult Step4(Step4 step4)
 {
     return View();
 }