DenizenScript / Denizen

NPC and general Spigot scripting, using the Denizen Scripting Language!
https://denizenscript.com/
MIT License
207 stars 104 forks source link

Repeat Command Complains with "ERROR! Malformed braced section! Missing a - symbol!" #440

Closed mythan closed 10 years ago

mythan commented 10 years ago

The following script:

"Repeattest":
  type: assignment

  actions:
    on assignment:
    - trigger name:click toggle:true

  interact scripts:
  - 10 Repeat Test

"Repeat Test":
  type: interact

  steps:
    1:
      click trigger:
        script:
        - repeat 5 {
          - if 1 == 1 {
            - narrate "Hello"
            }
          }

Gives the following error:

20:36:59 [INFO] +- Getting interact script: Testy/mythanical ------+
20:36:59 [INFO]  OKAY! '10 REPEAT TEST' meets requirements.
20:36:59 [INFO]
20:36:59 [INFO]  OKAY! Highest scoring script is REPEAT TEST.
20:36:59 [INFO] +---------------------+
20:36:59 [INFO] +- Parsing CLICK trigger: Testy/mythanical ------+
20:36:59 [INFO]  Starting TimedQueue
                   'D72E1B0A-B70B-41C5-91E4-15AEC5C9E33E'
20:36:59 [INFO] +- Executing dCommand: REPEAT/mythanical ------+
20:36:59 [INFO]  ERROR! Malformed braced section! Missing a - symbol!
20:36:59 [INFO]  ERROR! Empty braces!
20:36:59 [INFO]  Completing queue D72E1B0A-B70B-41C5-91E4-15AEC5C9E33E...
20:36:59 [INFO]  Completing queue D72E1B0A-B70B-41C5-91E4-15AEC5C9E33E...
davidcernat commented 10 years ago

It would appear that BracedCommand is partially broken at this time. A small sacrifice to Hanuman the Hindu monkey god would probably help.

mythan commented 10 years ago

Since I know nothing about Hinduism, I presume this human baby will suffice?

mcmonkey4eva commented 10 years ago

@mythan - The human baby was enough for this minor error. In the future I prefer adult virgins though.

mythan commented 10 years ago

You did not specify gender, so I hope Morph knows what's in store for him.

mcmonkey4eva commented 10 years ago

@mythan - I said adult.