Example #1
0
    private void setProgress(int lastOpenedScenarioNo)
    {
        float ratio   = lastOpenedScenarioNo / (float)Def.MAX_SCENARIO;
        int   percent = Mathf.FloorToInt(ratio * 100);

        ProgressPanel.SetValue(percent, VALUE_FORMAT);
    }
Example #2
0
    private void setFeeling(int feeling)
    {
        float ratio   = feeling / (float)Def.MAX_FEELING;
        int   percent = Mathf.FloorToInt(ratio * 100);

        FeelingPanel.SetValue(percent, VALUE_FORMAT);
    }