Ejemplo n.º 1
0
    void Update()
    {
        if (!SaveChanges)
        {
            return;
        }

        SaveChanges = false;

        NoteBehaviour note    = GetComponent <NoteBehaviour>();
        NoteCreator   creator = note.transform.parent.GetComponent <NoteCreator>();

        if (EditSpeed)
        {
            note.Speed     = NewSpeed;
            note.SpawnTime = Mathf.Clamp(note.EndTime - (GameManager.SPAWN_DISTANCE_FROM_ORIGIN / note.Speed), 0.0f, float.MaxValue);
        }

        if (EditEndTime)
        {
            note.SpawnTime = Mathf.Clamp(NewEndTime - (GameManager.SPAWN_DISTANCE_FROM_ORIGIN / note.Speed), 0.0f, float.MaxValue);
            note.EndTime   = NewEndTime;
        }

        if (EditPositionIndex)
        {
            creator.PositionsGenerator();
            note.StartingPosition = creator.Positions[NewPositionIndex];
            note.PositionIndex    = NewPositionIndex;
        }
    }
Ejemplo n.º 2
0
        public void Init()
        {
            Driver.Initialize();
            LoginPage.GoTo();
            LoginPage.LoginAs("*****@*****.**").Continue().WithPassword("georgiana").Login();

            //create a basic note
            NoteCreator.CreateNote();
        }
        public void CanCreateABlankMeetingNote()
        {
            NoteCreator.CreateBlankMeetingNote();

            Assert.AreEqual(NotesPage.Title, NoteCreator.PreviousTitle, "Title did not match new note.");
            var noteContent = Driver.Instance.FindElement(By.CssSelector(".focus-NotesView-Note-snippet.qa-snippet")).Text.Trim();

            Assert.AreEqual("Date Time Location Participants Description Notes Next Steps", noteContent, "Content did not match new blank meeting note.");
        }
        public void Init()
        {
            Driver.Initialize();
            LoginPage.GoTo();
            LoginPage.LoginAs("*****@*****.**").Continue().WithPassword("georgiana").Login();

            //create a basic note
            //NewNotePage.GoTo();
            //NewNotePage.CreateNote("This is search note title").WithContent("Hi, this is the content").Done();
            NoteCreator.CreateNote();
        }
Ejemplo n.º 5
0
    void Start()
    {
        if (string.IsNullOrEmpty(Helpers.songInfoName) ||
            Helpers.songInfoXmlId == -1)
        {
            if (LocalizationManager.instance != null)
            {
                panelIndicator.LoadLevel(2,
                                         LocalizationManager.instance.GetLocalizedValue("Loading song list") + "...");
            }
            return;
        }

        ButtonInstrumentVoice.SetActive(false);

        if (LocalizationManager.instance != null)
        {
            panelIndicator.ShowIndicator(LocalizationManager.instance.GetLocalizedValue("Generating") +
                                         " " + Helpers.songInfoName + " - " + Helpers.songInfoComposer + "...",
                                         "GetScore Start");
        }

        noteCreator = GetComponent <NoteCreator>();
        Debug.Log("songInfoName " + Helpers.songInfoName + " songInfoComposer " + Helpers.songInfoComposer +
                  " songInfoXmlId " + Helpers.songInfoXmlId);
        Helpers.Score = null;


        FirebaseApp.DefaultInstance.SetEditorDatabaseUrl("https://doremipiano-cee8a.firebaseio.com/");

        FirebaseApp.CheckAndFixDependenciesAsync().ContinueWith(task =>
        {
            var dependencyStatus = task.Result;
            if (dependencyStatus == DependencyStatus.Available)
            {
                // Set a flag here indiciating that Firebase is ready to use by your
                // application.
                InitializeFirebase();
            }
            else
            {
                Debug.LogError(String.Format(
                                   "Could not resolve all Firebase dependencies: {0}", dependencyStatus));
                // Firebase Unity SDK is not safe to use here.
            }
        });

        Invoke("GetSongDataTimeOut", 15);
    }
Ejemplo n.º 6
0
    void Start()
    {
        dictGenerate        = new Dictionary <int, IEnumerator>();
        deGenerateCoroutine = null;
        noteCreator         = GetComponent <NoteCreator>();
        noteFlowControl     = GameObject.Find("NoteFlow").GetComponent <NoteFlowControl>();
        var            scaleUp = 1.2f;
        SpriteRenderer sr      = GetComponent <SpriteRenderer>();

        sr.size = new Vector2(Helpers.CamWidth, Helpers.CamHeight * scaleUp);
        BoxCollider2D bc = GetComponent <BoxCollider2D>();

        bc.size = new Vector2(Helpers.CamWidth, Helpers.CamHeight * scaleUp);
        transform.localPosition = new Vector3(0, (Helpers.CamHeight * scaleUp - Helpers.CamHeight) / 2, 0);
    }
Ejemplo n.º 7
0
        public override XmlElement Export(XmlDocument doc, XmlElement parent)
        {
            XmlElement current = base.Export(doc, parent);

            if (Message != null)
            {
                current.SetAttribute("MESSAGE", Message);
            }
            if (TimeStamp != null)
            {
                current.SetAttribute("TIME_STAMP", TimeStamp);
            }
            if (UserName != null)
            {
                current.SetAttribute("USER_NAME", UserName);
            }
            current.SetAttribute("NOTE_CREATOR", NoteCreator.ToString());
            return(current);
        }
        public void AddedNotesShowUp()
        {
            //Go to notes, get notes count, store
            LeftNavigation.Notes.Select();
            NotesPage.StoreCount();

            //Add a new note
            NoteCreator.CreateNote();

            //Go to Notes, get new note count
            LeftNavigation.Notes.Select();
            Assert.AreEqual(NotesPage.PreviousNoteCount + 1, NotesPage.CurrentNoteCount, "Count of notes did not increase");

            //Check for added note
            Assert.IsTrue(NotesPage.DoesNoteExistWithTitle(NoteCreator.PreviousTitle));

            //Trash note (clean up)
            NotesPage.TrashNote(NoteCreator.PreviousTitle);
            Assert.AreEqual(NotesPage.PreviousNoteCount, NotesPage.CurrentNoteCount, "Coundn't trah note");
        }
Ejemplo n.º 9
0
        private void AddNote_Click(object sender, RoutedEventArgs e)
        {
            NoteCreator NoteCreatorWindow = new NoteCreator(options);

            NoteCreatorWindow.Show();
        }
 public void CanCreateABasicNote()
 {
     NoteCreator.CreateNote();
     Assert.AreEqual(NotesPage.Title, NoteCreator.PreviousTitle, "Title did not match new note.");
 }