CommandHelper

CommandHelper

46.5k Downloads

Using switch_ic the break() function gives a compile error

Sketsi opened this issue ยท 1 comments

commented

When I changed switch to switch_ic the break() in console spits out
"COMPILE ERROR: The break() function can only break out of loops."

Works:

/switch $ = >>>
 switch($){
   case '1':
     msg('one')
     break()
   case 'two':
     msg('2')
     break()
   default:
     msg('That number is too high for me.')
 }
<<<

Doesn't work:

/switch $ = >>>
  switch_ic($){
    case '1':
      msg('one')
      break()
    case 'two':
      msg('2')
      break()
    default:
      msg('That number is too high for me.')
  }
<<<

Console:

[19:42:45 INFO]: COMPILE ERROR: The break() function can only break out of loops.
[19:42:45 INFO]: at :C:\Users\Zack\Desktop\Skyblock Dev\plugins\CommandHelper\aliases.msa:5.7
[19:42:45 INFO]:
[19:42:45 INFO]: COMPILE ERROR: The break() function can only break out of loops.
[19:42:45 INFO]: at :C:\Users\Zack\Desktop\Skyblock Dev\plugins\CommandHelper\aliases.msa:8.7
[19:42:45 INFO]:
[19:42:45 ERROR]: [CommandHelper] Execution halted due to compile errors.
switch_console
switch_in-game

commented

Fixed in build 313.