setToCondition method

Score setToCondition(
  1. Condition cond, {
  2. bool useSuccess = false,
})

sets the score to the success of the given condition result

Implementation

Score setToCondition(Condition cond, {bool useSuccess = false}) {
  return addCommandRet(
    Command(
      'execute store ${useSuccess ? 'success' : 'result'} score ${_getESStr()} ${Condition.getPrefixes(cond.getList())[0]}',
    ),
  );
}