Class automaticDynamicResponseChecklistItem

Inherits from the automaticChecklistItem class and provides a dynamic key for the response sound.

It uses a callback to get the actual key for the response sound.

See also:

Info:

  • Copyright: 2022 Patrick Lang
  • Author: Patrick Lang

Methods

automaticDynamicResponseChecklistItem:new (challengeText, responseText, challengeKey, responseKeyFunction, evaluateFunction) Creates a checklist item, which will be completed automatically if the conditions are met.
automaticDynamicResponseChecklistItem:getResponseKey () Gets the key of the response sound.


Methods

automaticDynamicResponseChecklistItem:new (challengeText, responseText, challengeKey, responseKeyFunction, evaluateFunction)
Creates a checklist item, which will be completed automatically if the conditions are met.

Parameters:

  • challengeText string The challenge text of the checklist item.
  • responseText string The response text of the checklist item.
  • challengeKey string The key of the challenge sound.
  • responseKeyFunction func The function to get the key of the response sound to use.
  • evaluateFunction func The function to evaluate whether the conditions for the checklist item are met. If the function returns any value other than true, the conditions are considered as not met.

Returns:

    automaticDynamicResponseChecklistItem The created checklist item.
automaticDynamicResponseChecklistItem:getResponseKey ()
Gets the key of the response sound.

Returns:

    optional string The key of the response sound.
generated by LDoc 1.4.6 Last updated 2022-05-28 12:58:52