C# Class Problem, thinksy_unity_plugin

Inheritance: MonoBehaviour
Mostra file Open project: senseix/thinksy_unity_plugin Class Usage Examples

Public Methods

Method Description
AddGivenAnswerPart ( ProblemPart, newGivenAnswerPart ) : void

Sets the given answer. This can then be checked for correctness through CheckAnswer.

AnswersGivenSoFar ( ) : int

Returns the number of answers which have been given so far.

CheckAnswer ( ) : bool

Checks the Problem's given answer against its correct answer. DOES NOT report to the senseix server. Consider SubmitAnswer() if this is a final answer.

CheckAnswer ( Answer, answer ) : bool

Sets the given answer to the argument, then checks it. DOES NOT submit. Consider SubmitAnswer() if this is a final answer.

CountDistractors ( ) : int

Counts the number of distractors available for this problem.

CountProblemsAnsweredCorrectlySoFar ( ) : uint

Counts the problems answered correctly so far.

GetCategoryName ( ) : string

A category is a group of Thinksy questions which are formatted the same way. Gets the name of the category. This string is mostly meaningless, but can be compared with other strings and looked up on the Thinksy website for information about the category.

GetCategoryNumber ( ) : uint

Gets the category number. Higher number means more advanced categories.

GetCorrectAnswer ( ) : Answer,

Returns the correct answer to this Problem

GetCurrentCorrectAnswerPart ( ) : ProblemPart,

Gets the next correct answer part based on how many answer parts have been given so far.

GetDistractor ( ) : ProblemPart,

Gets one distractor. Distractors are wrong answers which can be presented as options to the player.

GetDistractors ( int howManyDistractors ) : ProblemPart[],

Gets distractors. These are wrong answers which can be presented as options to the player.

GetGivenAnswer ( ) : Answer,

Returns the answer set by SetGivenAnswer

GetGivenAnswerIDs ( ) : string[]

Gets the IDs of the given answers. Mostly for internal use. Only use this if you want a bunch of uuids.

GetLearningAction ( ) : LearningAction,

Returns the learning action associated with this problems. Learning actions are representations of actions the player can complete successfully or unsuccessfully. There are five types (sub-classes) of learning actions. The type of a learning action can be determined via learningAction.GetActionType()

GetQuestion ( ) : Question,

Returns the question to be answered.

GetQuestionHTML ( ) : string

Gets an HTML representation of this problem's question.

GetQuestionImage ( ) : Texture2D

Gets the question image. The same as GetQuestion ().GetImage ()

HasBeenSubmitted ( ) : bool
Problem ( Senseix newProtobufsProblemBuilder ) : System

Don't use this unless you know what you're doing- instead get a problem from SenseixPlugin.NextProblem().

SetGivenAnswer ( Answer, newGivenAnswer ) : void

Sets the given answer. This will then be reflected in CheckAnswer().

SubmitAnswer ( ) : bool

Submits the given answer. This will update communicate with the senseix server asynchronously and update your player's progress accordingly.

SubmitAnswer ( Answer, answer ) : bool

Sets the given answer, then submits. This will update communicate with the senseix server asynchronously and update your player's progress accordingly.

Method Details

AddGivenAnswerPart() public method

Sets the given answer. This can then be checked for correctness through CheckAnswer.
public AddGivenAnswerPart ( ProblemPart, newGivenAnswerPart ) : void
newGivenAnswerPart ProblemPart,
return void

AnswersGivenSoFar() public method

Returns the number of answers which have been given so far.
public AnswersGivenSoFar ( ) : int
return int

CheckAnswer() public method

Checks the Problem's given answer against its correct answer. DOES NOT report to the senseix server. Consider SubmitAnswer() if this is a final answer.
public CheckAnswer ( ) : bool
return bool

CheckAnswer() public method

Sets the given answer to the argument, then checks it. DOES NOT submit. Consider SubmitAnswer() if this is a final answer.
public CheckAnswer ( Answer, answer ) : bool
answer Answer,
return bool

CountDistractors() public method

Counts the number of distractors available for this problem.
public CountDistractors ( ) : int
return int

CountProblemsAnsweredCorrectlySoFar() public static method

Counts the problems answered correctly so far.
public static CountProblemsAnsweredCorrectlySoFar ( ) : uint
return uint

GetCategoryName() public method

A category is a group of Thinksy questions which are formatted the same way. Gets the name of the category. This string is mostly meaningless, but can be compared with other strings and looked up on the Thinksy website for information about the category.
public GetCategoryName ( ) : string
return string

GetCategoryNumber() public method

Gets the category number. Higher number means more advanced categories.
public GetCategoryNumber ( ) : uint
return uint

GetCorrectAnswer() public method

Returns the correct answer to this Problem
public GetCorrectAnswer ( ) : Answer,
return Answer,

GetCurrentCorrectAnswerPart() public method

Gets the next correct answer part based on how many answer parts have been given so far.
public GetCurrentCorrectAnswerPart ( ) : ProblemPart,
return ProblemPart,

GetDistractor() public method

Gets one distractor. Distractors are wrong answers which can be presented as options to the player.
public GetDistractor ( ) : ProblemPart,
return ProblemPart,

GetDistractors() public method

Gets distractors. These are wrong answers which can be presented as options to the player.
public GetDistractors ( int howManyDistractors ) : ProblemPart[],
howManyDistractors int How many random distractors to return.
return ProblemPart[],

GetGivenAnswer() public method

Returns the answer set by SetGivenAnswer
public GetGivenAnswer ( ) : Answer,
return Answer,

GetGivenAnswerIDs() public method

Gets the IDs of the given answers. Mostly for internal use. Only use this if you want a bunch of uuids.
public GetGivenAnswerIDs ( ) : string[]
return string[]

GetLearningAction() public method

Returns the learning action associated with this problems. Learning actions are representations of actions the player can complete successfully or unsuccessfully. There are five types (sub-classes) of learning actions. The type of a learning action can be determined via learningAction.GetActionType()
public GetLearningAction ( ) : LearningAction,
return LearningAction,

GetQuestion() public method

Returns the question to be answered.
public GetQuestion ( ) : Question,
return Question,

GetQuestionHTML() public method

Gets an HTML representation of this problem's question.
public GetQuestionHTML ( ) : string
return string

GetQuestionImage() public method

Gets the question image. The same as GetQuestion ().GetImage ()
public GetQuestionImage ( ) : Texture2D
return UnityEngine.Texture2D

HasBeenSubmitted() public method

public HasBeenSubmitted ( ) : bool
return bool

Problem() public method

Don't use this unless you know what you're doing- instead get a problem from SenseixPlugin.NextProblem().
public Problem ( Senseix newProtobufsProblemBuilder ) : System
newProtobufsProblemBuilder Senseix
return System

SetGivenAnswer() public method

Sets the given answer. This will then be reflected in CheckAnswer().
public SetGivenAnswer ( Answer, newGivenAnswer ) : void
newGivenAnswer Answer, New given answer.
return void

SubmitAnswer() public method

Submits the given answer. This will update communicate with the senseix server asynchronously and update your player's progress accordingly.
public SubmitAnswer ( ) : bool
return bool

SubmitAnswer() public method

Sets the given answer, then submits. This will update communicate with the senseix server asynchronously and update your player's progress accordingly.
public SubmitAnswer ( Answer, answer ) : bool
answer Answer,
return bool