Example #1
0
    /// <summary>
    /// Add a new patient
    /// </summary>
    /// <param name="p">Patient</param>
    public void PatientObjectPatientAdd(Patient p)
    {
        patient = p;
        p.PatientHotspot(this);
        p.PersonMove(locationPatient, tag, true, this);

        Debug.Log(gameObject + " has added patient " + p);
        OfficeObjectSetReadyState(true); //handled inside of the person class now.

        //Hotfix for now. Ron Come back and change this!!!
        if (CompareTag("ExamRoom"))
        {
            (this as ExamRoom).Computer().Highlight(true);
        }
    }
Example #2
0
    private float timeGreeting, timeInitialDelay; //the amount of time spent greeting the patient. // The amount of time to wait before speaking to patient

    #endregion Fields

    #region Methods

    /// <summary>
    /// Called by Manager after spawning a new patient.
    /// </summary>
    /// <param name="p">The New Patient</param>
    public void TriagePatientAdd(Patient p)
    {
        //p.PersonMove(triage.locationPatient, "Triage");

        //Add patient to patient list

        //Debug.Log(patients);
        patients.Add(p);
        //Debug.Log(patients.Count);
        //tell patient to move to next open location

        p.PersonMove(patientLocations[patients.Count -1],tag,true);
        //tell patient to wait, and not tick down timer
        p.PatientToggleCountdown(true);
        //determine if I only have 1 patient
        if (patients.Count == 1)
        {
            newPatient = true;
            timeInitialDelay = setTimeInitialDelay;
        }
    }
Example #3
0
    //If time permits, come back and revamp this. These two methods may be similar enough near the end of the project that they can easily be simplified and molded into a single method depending on what we have each of them do.
    /// <summary>
    /// Leave the practice / emergency facility angrily. 
    /// </summary>
    /// <param name="p">The Patient leaving</param>
    public void ManagerPatientStormOut(Patient p)
    {
        //play Leave Angry sound
        if (SoundManager._SoundManager)
        {
            SoundManager._SoundManager.PlaySound("PatientLeave");
        }

        //update the amount of patients.
        currentPatients--;
        //update the amount of patients that have been seen.
        scorePatientsSeen++;

        //spawn another patient if we are down to 0.
        if (currentPatients <= 0)
        {
            ManagerPatientSpawn();
        }

        //listPatients.Remove(p);

        //Perform some kind of animation

        //update the total amount of patients to leave angry
        scoreAngryPatients++;

        //decrease points based on level of satisfaction
        UpdateSatisfactionScore(-5);
        UpdatePatientsTreated();

        //inform abg that the diagnosis is no longer being used.
        //abg.PatientDiagnosisComplete(p.MyDiagnosis());

        //make the patient go to the exit
        p.PersonMove(locationExit.position,"Exit");
    }
Example #4
0
    /// <summary>
    /// Leave the facility happily, and award points
    /// </summary>
    /// <param name="p"></param>
    public void ManagerPatientLeave(Patient p)
    {
        //update the amount of patients.
        currentPatients--;
        //update the amount of patients that have been seen.
        scorePatientsSeen++;

        //spawn another patient if we are down to 0.
        if (currentPatients <= 0)
        {
            ManagerPatientSpawn();
        }

        //listPatients.Remove(p);
        //perform some kind of animation

        //Determine if the initial assessment of the patient was correct.
        bool rm = (p.InitialAssessmentGetRM() == p.MyDiagnosis().AnswerRespiratoryMetabolic);
        bool aa = (p.InitialAssessmentGetAA() == p.MyDiagnosis().AnswerAcidosisAlkalosis);

        //update score
        scoreCorrectDiagnoses++;
        if (rm && aa)
        {
            scoreCorrectInitialAssessment++;
        }

        gameplayUI.PatientFeedback().PatientFeedback(p, rm, aa);
        gameplayUI.PatientFeedback().gameObject.SetActive(true);
        Time.timeScale = 0;
        //gain/increase points based on level of satisfaction
        UpdateSatisfactionScore(6);
        UpdatePatientsTreated();

        //inform abg that the diagnosis is no longer being used.
        //abg.PatientDiagnosisComplete(p.MyDiagnosis());

        p.PersonMove(locationExit.position, "Exit");
    }