コード例 #1
0
    private void CallRecipeEventFunction(MainReciepeState reciepeState)
    {
        switch (reciepeState)
        {
        case MainReciepeState.CUT_OPEN:
            if (patientNeedsCutOpen != null)
            {
                patientNeedsCutOpen(0);
            }
            break;

        case MainReciepeState.PULL_OUT_STICK:
            if (patientNeedsPullOutStick != null)
            {
                patientNeedsPullOutStick(0);
            }
            break;

        case MainReciepeState.SOAK_BLOOD:
            if (patientNeedsBloodSoak != null)
            {
                patientNeedsBloodSoak(0);
            }
            break;

        case MainReciepeState.STICH_BODY:
            if (patientNeedsStitches != null)
            {
                patientNeedsStitches(0);
            }
            break;
        }
    }
コード例 #2
0
    private Tool.ToolType RequiredToolForReciepeState(MainReciepeState recipeState)
    {
        switch (recipeState)
        {
        case MainReciepeState.CUT_OPEN:
            return(Tool.ToolType.SCALPEL);

        case MainReciepeState.PULL_OUT_STICK:
            return(Tool.ToolType.FORCEPS);

        case MainReciepeState.SOAK_BLOOD:
            return(Tool.ToolType.GAUZE);

        case MainReciepeState.STICH_BODY:
            return(Tool.ToolType.SUTURE);

        default:
            return(Tool.ToolType.NONE);
        }
    }