< Summary

Class:RecipeBaseState
Assembly:Test
File(s):E:/Unity/Unity Project/VR-Cooking-Demo/Assets/_Scripts/Recipe States/RecipeBaseState.cs
Covered lines:10
Uncovered lines:0
Coverable lines:10
Total lines:52
Line coverage:100% (10 of 10)
Covered branches:0
Total branches:0
Covered methods:1
Total methods:1
Method coverage:100% (1 of 1)

Coverage History

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
EnterState(...)0%000100%

File(s)

E:/Unity/Unity Project/VR-Cooking-Demo/Assets/_Scripts/Recipe States/RecipeBaseState.cs

#LineLine coverage
 1/*
 2 *
 3 * Code by:
 4 *      Dimitrios Vlachos
 5 *      djv1@student.london.ac.uk
 6 *      dimitri.j.vlachos@gmail.com
 7 *
 8 * Adapted from our Games Dev FSM lecture
 9 *
 10 */
 11
 12using System.Collections;
 13using System.Collections.Generic;
 14using TMPro;
 15using UnityEngine;
 16
 17public abstract class RecipeBaseState
 18{
 19    #region Variables
 20    protected TextMeshProUGUI objective;
 21    protected TextMeshProUGUI status;
 22    protected GameObject pot;
 23    protected PotBehaviour potBehaviour;
 24
 25    // Objective information
 26    protected int numberOfPotatos;
 27    protected int numberOfCarrots;
 28    protected int water;
 29
 30    protected RecipeManager recipeManager;
 31    #endregion
 32    public virtual void EnterState(RecipeManager rm)
 133    {
 34        // Set variables
 135        objective = rm.objective;
 136        status = rm.status;
 137        pot = rm.pot;
 138        potBehaviour = rm.potBehaviour;
 39
 140        numberOfPotatos = rm.numberOfPotatos;
 141        numberOfCarrots = rm.numberOfCarrots;
 142        water = rm.water;
 43
 144        recipeManager = rm;
 145    }
 46
 47    public abstract void Update();
 48
 49    public abstract void FixedUpdate();
 50
 51
 52}

Methods/Properties

EnterState(RecipeManager)